Is there a way to get student_id in bulk from Users API?

Hi everyone,

We’re currently using this endpoint for user sync:
GET /school/v1/users?roles={{roleid}}

The issue is it doesn’t return student_id.

We found this endpoint:
GET /school/v1/users/extended/{user_id}
which does include student_id, but it requires one API call per user — which isn’t practical for bulk sync, especially across multiple schools (tenants).

Has anyone faced this before?

  • Is there any way (parameter, expansion, or different endpoint) to get student_id in bulk with the users list?
  • Or how are you handling this efficiently in your integrations?

Any suggestions or best practices would be really helpful.

Answers

  • Brian Gray
    Brian Gray Community All-Star
    Ninth Anniversary Kudos 5 First Reply bbcon 2025 Attendee Badge

    You're looking for Users Extended by Role (https://developer.sky.blackbaud.com/api#api=school&operation=V1UsersExtendedGet)

    It includes the Student ID field.

    Beware: Users Get By Role uses the Role ID. Users Extended Get by Role uses the BASE Role ID. See Core Roles endpoint https://developer.sky.blackbaud.com/api#api=school&operation=v1rolesget for details.

  • Hi Brian Gray,

    Thank you for your suggestion.

    As per Blackbaud’s documentation, Users Extended Get by Role relies on base_role_id, which represents predefined base roles. In our case, role definitions (e.g., Student, Parent, Staff) are determined at the school level, and there is a possibility of conflicts if custom roles share the same base_role_id as roles in the school’s exclusion list. This could impact our synchronization logic.

    Could you please confirm if there is:

    • Any parameter or filter to safely retrieve student_id without relying on base_role_id, or
    • An alternative API that supports bulk retrieval of users along with student_id and related data?

    Appreciate your guidance.

  • Brian Gray
    Brian Gray Community All-Star
    Ninth Anniversary Kudos 5 First Reply bbcon 2025 Attendee Badge

    I am not aware of any endpoints that will return the student_id field that doesn't require the base_role_id. In the data returned by User Extended Get, the array of roles assigned to the user includes both the role_id and base_role_id for each role. You could identify the users you really want by cycling through that array looking for the role_id of the custom role.

    You may want to look at the two end-points related to retrieving data from Advanced Lists: List of Lists and List Single.

    1. List of Lists returns a list of the Advanced Lists available, including the name and the List ID.
    2. List Single takes the List ID and returns the data produced by that list.

    You could create an advanced list that includes the data fields you want (filtered for the users you want) and read it into your program for processing. Advanced Lists are somewhat limited - newer data fields are not always available. The newer SKY Lists are not yet readable by the API.

    It's not a perfect solution.

  • Thank you, Brain Gray. We will proceed with the list-based approach and evaluate its effectiveness.

Categories