How do i add relationship count in REST API calls?

this is how i create speciality
so in the clinicians create page
all the speciality i created in here will be listed