Zunia Public API

website·Indexed 30 days ago

https://developers.ehgqa.com

API documentation for Zunia, providing endpoints to manage student data, including current, past, and future students, medical conditions, legal information, and photo permissions. It also includes a comprehensive set of lookup endpoints for school-related metadata such as visa classes, qualification levels, transport types, and staff employment types.

Tokens
59.5K
Snippets
216
Records
388
Agent score
49%

What's inside Zunia

  1. Overview of Zunia OneRoster API

    The Zunia OneRoster API is based on the OneRoster 1.1 specification, enabling the secure exchange of roster information, course materials, and grades. It ensures interoperability with other vendors and integrations like Google Classroom and Microsoft Teams for Education. The API is available to third-party developers to extend Zunia's capabilities.
  2. Fetch interview outcome lookup values

    Use the GET /lookup/interview-outcome endpoint to retrieve a list of available lookup values for interview outcomes. The response returns a data object containing a list of options, each providing detailed metadata about the outcome, including its unique ID, code, display title, and associated interview type.
    // Example Response Schema
    {
      "code": "string", // Status Code
      "data": {
        "name": "string",
        "displayName": "string",
        "options": [
          {
            "id": "uuid",
            "description": "string",
            "code": "string",
            "sortOrder": 0,
            "active": true,
            "value": "string",
            "title": "string",
            "interviewTypeId": "uuid",
            "interviewTypeDescription": "string"
          }
        ]
      }
    }
  3. Understand Zunia Community IDs

    Zunia uses a 'community record' system. Every individual (student, parent, contact, staff member, or business) is assigned a unique community ID upon creation. This ID remains constant throughout the individual's lifecycle in the system, regardless of their role change (e.g., from pre-enrolment to student, then to alumni or staff).
  4. Understand the Community Member response schema

    The API returns a JSON object containing the following key data structures:

    • personalInfo: Contains names (givenName, surname, prefName), birth date, gender, and deceased status.
    • companyInfo: Details about the member's company, including companyName and schoolId.
    • addressInfo: Includes a list of addresses with systemMeaning (e.g., 'Postal' or 'Home'), street details, postalCode, and formatted display strings (displayAddressComma, displayAddressFull).
    • contactDetails: Contains arrays of emailAddress, phoneNumber (with phoneType and countryCode), and internetAndSocialMedia links.
    • demographics: Includes religion, indigenousStatus, parish, region, birthCountry, homeLanguages, and nationalities.
    • occupation: Details the member's company, industry, occupation title, and positionCategory.
    • education: Contains education level, qualifications, lastYearOfStudy, and qualification levels (secondary, highest, and non-national).
  5. Fetch transport stop lookup values

    Use the GET /lookup/transport-stop endpoint to retrieve a list of lookup values for transport stops. The response returns a JSON object containing a list of options, each providing detailed metadata about a transport stop, including its unique identifier, description, sort order, and associated transport type information.
    GET /lookup/transport-stop
  6. Fetch lookup values for other requirements using /lookup/other-requirement

    Use the GET /lookup/other-requirement endpoint to retrieve a list of lookup values associated with other requirements. The response is returned as application/json and contains a data object with a list of options, each including a unique identifier, description, code, sort order, active status, value, and title.
    {
      "code": "string",
      "data": {
        "name": "string",
        "displayName": "string",
        "options": [
          {
            "id": "uuid",
            "description": "string",
            "code": "string",
            "sortOrder": 0,
            "active": true,
            "value": "string",
            "title": "string"
          }
        ]
      }
    }
  7. Generate an API Key for Zunia OneRoster API

    To authenticate with the Zunia OneRoster API, you must first generate an API key. When creating the key, select the 'Advanced' option and ensure the GET, PUT, and DELETE HTTP verbs are selected. You must also assign a permissions group containing the required scopes. Available permissions include:

    • View classes: View classes only.
    • View subjects: View subjects only.
    • Student view: View student details and search profiles.
    • Future student view: View future student profiles.
    • Past student view: View past student profiles.
    • Staff view: View staff details and search profiles.
    • Community view: View community profiles.
    • View school configuration of enrolment year: View enrolment year settings.
    • View Maintain school configuration of enrolment period: View enrolment period settings.
  8. Dietary Requirement lookup response schema

    The /lookup/dietary-requirement endpoint returns a JSON response with the following structure:

    • code (string, required): The status or identifier code.
    • data (object):
      • name (string, required): The internal name of the lookup.
      • displayName (string, required): The human-readable name of the lookup.
      • options (array, required): A list of dietary requirement options, each containing:
        • id (uuid, required): Unique identifier for the option.
        • description (string, required): Detailed description of the requirement.
        • code (string, required): Technical code for the requirement.
        • sortOrder (number, required): The display order of the option.
        • active (boolean, required): Whether the option is currently active.
        • value (string, required): The value of the requirement.
        • title (string, required): The display title of the requirement.
  9. Make authenticated requests to Zunia OneRoster API

    Once you have obtained an access token, include it in the Authorization header as a Bearer token for all subsequent API requests.
    HOST=public-api-ap-se-2.zunia.com
    ACCESS_TOKEN=<ACCESS_TOKEN>
    
    curl --location "https://$HOST/ims/oneroster/v1p1/students" \
    --header "Accept: application/json" \
    --header "Authorization: Bearer $ACCESS_TOKEN"
  10. Authenticate with Zunia Public API using OAuth 2.0

    Zunia Public API uses OAuth 2.0 Client Credentials flow for authentication. All requests must be made over HTTPS. To authenticate, you must first generate a Client ID and Secret in the Zunia tenant under System configuration > API keys (selecting 'Zunia Public API V2' as the type), then exchange these credentials for an access token.
    # Step 1: Obtain an access token
    TOKEN_URL=https://auth.zunia.com/oauth2/token
    CLIENT_ID=YOUR_CLIENT_ID
    CLIENT_SECRET=YOUR_CLIENT_SECRET
    
    curl --request POST \
      --url $TOKEN_URL \
      --header 'Content-Type: application/x-www-form-urlencoded' \
      --data grant_type=client_credentials \
      --data client_id=$CLIENT_ID \
      --data client_secret=$CLIENT_SECRET
    
    # Step 2: Use the access token to call an endpoint
    HOST=public-api-ap-se-2.zunia.com
    
    curl "https://$HOST/api/v2/students/current" \
      -H "Authorization: Bearer {ACCESS_TOKEN}"
  11. Understand the Physical Requirement lookup response schema

    The /lookup/physical-requirement endpoint returns a JSON response with the following structure:

    • code (string, required): The status or identifier code.
    • data (object): Contains the lookup details:
      • name (string, required): The internal name of the requirement.
      • displayName (string, required): The human-readable name.
      • options (array, required): A list of available options, each containing:
        • id (uuid, required): Unique identifier for the option.
        • description (string, required): Detailed description of the option.
        • code (string, required): The option code.
        • sortOrder (number, required): The sequence order for display.
        • active (boolean, required): Whether the option is currently active.
        • value (string, required): The value of the option.
        • title (string, required): The display title of the option.