If you're wanting to count socket colors, this'll require a ton of server requests using
socket query calls. Alternatively, if you want the gems themselves, you could parse the gem fields of the
ItemLink. Note, the ItemLink format may differ between retail and classic as many fields don't apply to both versions. Keep this in mind when reading API documentation and be sure to double-check with your own testing.