There are different ways to check what part of a skeleton was touched. Just to clear up nomenclature: a slot itself doesn't have a representation you could check against. However, a slot can have an attachment (bounding box attachment, region attachment, mesh attachment) which you might want to test against.
For bounding box attachments, you can check out the SkeletonBounds. You can use it like this (provided you have a reference to spSkeleton*
and your skeleton world transforms have been updated):
spSkeletonBounds* bounds = spSkeletonBounds_create();
spSkeletonBounds_update(bounds, skeleton, true);
spBoundingBoxAttachment* hitAttachment = spSkeletonBounds_containsPoint(bounds, touchX, touchY);
The last function will return the bounding box attachment that contains the point (touchX, touchY), or null. You can find out how to create bounding box attachments on your skeleton in the editor here Bounding Boxes - Spine User Guide
If you want to check against other attachment types (region, mesh), you will have to get your hands dirty a little bit and replicate what spSkeletonBounds_containsPoint does. Here's a bit of code that iterates through the slots and the attachments attached to them spine-runtimes/SkeletonRenderer.m at 3.6