### API v1 Output Example (JSON) Source: https://360learning.readme.io/docs/list-all-courses-statistics-migration-guide Example of the JSON output structure for API v1, which includes user and attempt details. ```json [ { "attempts": [ { "_id": "62f244ffb4ccfd37306abbe7", "progress": 9, "completedAt": "2022-08-11T09:07:37.371Z", "firstActivity": "2022-08-09T11:29:03.498Z", "lastActivity": "2022-08-09T11:30:08.658Z", "globalTime": 51190 }, { "_id": "6307bb41627414ebe6fa4a96", "progress": 100, "score": 75, "completedAt": "2022-08-25T18:11:55.650Z", "firstActivity": "2022-08-25T18:11:14.238Z", "lastActivity": "2022-08-25T18:11:55.628Z", "path": "6307bb2f66977c8e2316d6d5", "pathSession": "6307bb305ab5e0ebdb1138e8", "globalTime": 41390 } ], "user": { "_id": "62bdbc00291a605543f24386", "mail": "mister.crabs@360learning.com" } } ] ``` -------------------------------- ### API v1 Input/Output Examples for Session Creation Source: https://360learning.readme.io/docs/create-a-path-session-migration-guide Provides examples of the JSON payload for API v1 when creating a session. It highlights the structure and parameters used in the older version. ```json { "status": "session_created", "_id": "6853e37f9bd3525326e240f6" } ``` -------------------------------- ### API v1 Output Example Source: https://360learning.readme.io/docs/retrieve-metrics-for-a-path-session-migration-guide An example of the JSON output structure for API v1. ```APIDOC ## API v1 Output Example ### Description This endpoint returns detailed session and user statistics. ### Method GET ### Endpoint /api/v1/output ### Response #### Success Response (200) - **sessionId** (string) - The unique identifier for the session. - **sessionName** (string) - The name of the session. - **pathName** (string) - The name of the learning path. - **pathId** (string) - The unique identifier for the learning path. - **usersStatus** (object) - An object containing counts of users by their status (completed, enrolled, inProgress, etc.). - **completed** (integer) - **enrolled** (integer) - **inProgress** (integer) - **selfEnrolled** (integer) - **started** (integer) - **successful** (integer) - **certificates** (integer) - The number of certificates issued. - **detailedStatus** (object) - An object detailing user status breakdown. - **awaitingCorrection** (integer) - **late** (integer) - **notYetStarted** (integer) - **onTime** (integer) - **sessionNotOpened** (integer) - **successful** (integer) - **toRetake** (integer) - **unsuccessful** (integer) - **usersStats** (array) - An array of objects, each representing a user's statistics. - **_id** (string) - The user's unique identifier. - **deleted** (boolean) - Indicates if the user account is deleted. - **firstName** (string) - The user's first name. - **lastName** (string) - The user's last name. - **mail** (string) - The user's email address. - **progress** (integer) - The user's progress percentage. - **totalTimeSpentInSeconds** (number) - Total time spent by the user in seconds. - **score** (integer|null) - The user's score, if applicable. - **status** (string) - The user's status (e.g., 'late', 'onTime'). - **completedAt** (string|null) - The timestamp when the user completed the session. - **detailedStatus** (object) - Detailed status of the user. - **type** (string) - The type of detailed status (e.g., 'unsuccessful'). - **reason** (string) - The reason for the detailed status (e.g., 'sessionEnded'). - **result** (string) - The result of the session for the user (e.g., 'retake'). - **certificate** (boolean) - Indicates if a certificate was issued to the user. - **customFields** (array) - An array of custom fields associated with the user. ### Response Example ```json { "sessionId": "65859a418d8f19cd4063457a", "sessionName": "January Session", "pathName": "Digital skills", "pathId": "6585958a3c2446e9b399f341", "usersStatus": { "completed": 0, "enrolled": 5, "inProgress": 5, "selfEnrolled": 0, "started": 5, "successful": 0 }, "certificates": 0, "detailedStatus": { "awaitingCorrection": 0, "late": 0, "notYetStarted": 0, "onTime": 0, "sessionNotOpened": 0, "successful": 0, "toRetake": 0, "unsuccessful": 5 }, "usersStats": [ { "_id": "647092a741a809ed36889ecf", "deleted": false, "firstName": "Ada", "lastName": "Lovelace", "mail": "Ada.lovelace@domain.com", "progress": 20, "totalTimeSpentInSeconds": 4.084, "score": null, "status": "late", "completedAt": null, "detailedStatus": { "type": "unsuccessful", "reason": "sessionEnded" }, "certificate": false, "customFields": [] } ] } ``` ``` -------------------------------- ### API v2 Output Example Source: https://360learning.readme.io/docs/retrieve-metrics-for-a-path-session-migration-guide An example of the JSON output structure for API v2. ```APIDOC ## API v2 Output Example ### Description This endpoint returns a summary of user counts by status for a given path. ### Method GET ### Endpoint /api/v2/output ### Response #### Success Response (200) - **certificates** (integer) - The total number of certificates issued. - **usersCountByStatus** (object) - An object containing counts of users by their status. - **awaitingCorrection** (integer) - **late** (integer) - **notYetStarted** (integer) - **onTime** (integer) - **sessionNotOpened** (integer) - **successful** (integer) - **toRetake** (integer) - **unsuccessful** (integer) ### Response Example ```json { "certificates": 0, "usersCountByStatus": { "awaitingCorrection": 0, "late": 0, "notYetStarted": 0, "onTime": 0, "sessionNotOpened": 0, "successful": 0, "toRetake": 0, "unsuccessful": 0 } } ``` ``` -------------------------------- ### API v2: List all users - Shell Example Source: https://360learning.readme.io/docs/list-all-users-migration-guide This code snippet shows how to list users using the v2 API endpoint. It utilizes GET request with specific headers for API version and content type. ```shell curl --request GET \ --url https://app.staging.360learning-dev.com/api/v2/users \ --header '360-api-version: v2.0' \ --header 'accept: application/json' ``` -------------------------------- ### API v2 Courses Stats Input Example (Shell) Source: https://360learning.readme.io/docs/list-all-courses-statistics-migration-guide Example of how to call the API v2 endpoint to retrieve courses statistics. This demonstrates the use of headers for API version and content type. ```shell curl --request GET \ --url https://app.staging.360learning-dev.com/api/v2/courses/stats \ --header '360-api-version: v2.0' \ --header 'accept: application/json' ``` -------------------------------- ### API v1 Retrieve Path Output Example (JSON) Source: https://360learning.readme.io/docs/retrieve-a-path-migration-guide Example of a successful response from the API v1 'Retrieve a path' endpoint. It includes path details such as ID, author, creation date, and steps. ```json { "_id": "6307bb2f66977c8e2316d6d5", "authorId": "62bdbc00293a604543f44386", "description": "
This is my first path.
", "certificatePDF": "My certificate", "createdAt": "2022-08-25T18:10:55.000Z", "defaultLang": "en", "groupId": "62bdbc00293a604543f44387", "modifiedAt": "2023-05-15T16:04:24.334Z", "name": "My first path", "sessionIds": [ "6307bb305ab5e0ebdb1138e8" ], "sourceLang": "en", "steps": [ { "_id": "62e29a923c24c589a7f21aa5", "title": "Welcome to the team!", "type": "course" }, { "_id": "6372592c18f8f7bf27527977", "title": "First classroom", "type": "classroom" } ], "translationsLangs": [ { "lang": "fr", "published": true, "translators": [ "jeandupont@example.com" ] } ] } ``` -------------------------------- ### API v1 User Retrieval Example (Shell) Source: https://360learning.readme.io/docs/retrieve-a-user-migration-guide Example of how to retrieve user information using the v1 API endpoint with curl. This method requires company and apiKey as query parameters. ```shell curl --location -g 'https://app.360learning.com/api/v1/users/5b56f4c392af558eb5f1386c?company={{company}}&apiKey={{apiKey}}' ``` -------------------------------- ### API v1 Courses Stats Input Example (Shell) Source: https://360learning.readme.io/docs/list-all-courses-statistics-migration-guide Example of how to call the API v1 endpoint to retrieve courses statistics. This uses basic curl with query parameters for company and API key. ```shell curl --location -g 'https://{{host}}/api/v1/courses/stats?company={{company}}&apiKey={{apiKey}}' ``` -------------------------------- ### API v1 Group Listing Request Example Source: https://360learning.readme.io/docs/list-all-groups-migration-guide Example of how to list all groups using the v1 API endpoint. This version does not support pagination and requires company and apiKey parameters. ```shell curl --location 'http://app.360learning.com/api/v1/groups?company=`{company}`&apiKey=`{apiKey}`' ``` -------------------------------- ### API v1 Add User Role Output Example Source: https://360learning.readme.io/docs/add-a-user-role-migration-guide Example JSON output for a successful user addition to a group using API v1. It includes a status message indicating the outcome. ```json { "status": "invitation_created_and_added" } ``` -------------------------------- ### API v1 to v2 Migration Guide Source: https://360learning.readme.io/docs/create-a-user-20-migration-guide Summary of breaking changes and key differences between 360Learning API v1 and v2 user creation endpoints. Includes parameter mapping and guidance for migrating existing integrations. ```APIDOC ## API v1 to v2 Migration Guide ### Authentication Changes - **v1**: Query parameters (company, apiKey) - **v2**: Bearer token in Authorization header ### Removed Parameters | Parameter | v1 | v2 | Notes | |-----------|----|----|-------| | primaryGroupId | Supported | Removed | ID of user's primary group | | sendCredentials | Supported | Removed | Boolean to control credential email sending | | password | Supported | Removed | Use dedicated password replacement endpoint instead | ### Modified Parameters | Parameter | v1 | v2 | Migration Path | |-----------|----|----|----------------| | groups | Array of group IDs | Removed | Use membership object for initial group, then Add User Role endpoint for additional groups | | roles | Array of role names | Removed | Use membership.role field for initial role assignment | | N/A | N/A | membership (Required) | New required object containing role and groupId | ### Request Format Changes - **v1**: Form-encoded body with query authentication - **v2**: JSON body with Bearer token authentication ### Response Format Changes - **v1**: Returns acknowledgment object with status and user ID ```json { "status": "user_created", "_id": "5be2b954b44a1b6e3526e091" } ``` - **v2**: Returns complete user object (RESTful) ```json { "_id": "5be2b954b44a1b6e3526e091", "mail": "john.smith@yopmail.com", "username": "johnsmith", "firstName": "John", "lastName": "Smith", "job": "Engineer", "organization": "360Learning", "phone": "+33123456789", "custom": "Half-time worker", "lang": "en", "deleted": false, "lastLoginDate": "2025-06-06T13:21:38.271Z" } ``` ### Multi-Group Assignment - **v1**: Assign to multiple groups in single request using groups and roles arrays - **v2**: Assign initial group via membership object, use separate "Add User Role" endpoint for additional groups ### Related Endpoints - Replace User Password: Use dedicated endpoint instead of password parameter - Add User to Additional Groups: Use "Add a user's role" endpoint ### Shared Parameters These parameters work the same in both versions: - mail (Required) - firstName (Required) - lastName (Required) - phone (Optional) - lang (Optional) - job (Optional) - organization (Optional) - custom (Optional) ``` -------------------------------- ### API v2 Retrieve Path Input Example (Shell) Source: https://360learning.readme.io/docs/retrieve-a-path-migration-guide Example of how to call the API v2 'Retrieve a path' endpoint using curl. It uses GET request with specific headers for API version and content type. ```shell curl --request GET \ --url https://app.360learning.com/api/v2/paths/pathId \ --header '360-api-version: v2.0' \ --header 'accept: application/json' ``` -------------------------------- ### GET /api/v2/courses (Combine multiple filters on different fields) Source: https://360learning.readme.io/docs/filtering Refine your search by combining filters on different fields using the '&' operator for a logical AND operation. This example retrieves courses that are both published and created before January 1, 2023. ```APIDOC ## GET /api/v2/courses ### Description Retrieves a list of courses, allowing for combined filtering on different fields using the '&' operator for a logical AND. ### Method GET ### Endpoint /api/v2/courses ### Query Parameters - **createdAt[lt]** (string) - Optional - Filters courses created before the specified date. - **status[eq]** (string) - Optional - Filters courses with the specified status (e.g., 'published'). ### Request Example ```shell curl --request GET \ --url 'https://app.360learning.com/api/v2/courses?createdAt[lt]=2023-01-01&status[eq]=published' \ --header 'accept: application/json' \ --header '360-api-version: v2.0' \ --header 'authorization: Bearer your_access_token' ``` ### Response #### Success Response (200) - **courses** (array) - A list of course objects matching the filter criteria. #### Response Example ```json { "courses": [ { "id": "course_id_1", "title": "Course Title 1", "status": "published", "createdAt": "2022-12-15T10:00:00Z" } ] } ``` ``` -------------------------------- ### GET /api/v2/courses (Combine advanced filters) Source: https://360learning.readme.io/docs/filtering Combine various advanced filtering scenarios for complex queries. This example returns courses created between April 1, 2023, and January 1, 2024, marked as deleted and of type SCORM. ```APIDOC ## GET /api/v2/courses ### Description Retrieves a list of courses by combining multiple advanced filtering criteria, including date ranges, status, and type, using '&' for logical AND operations. ### Method GET ### Endpoint /api/v2/courses ### Query Parameters - **createdAt[lt]** (string) - Optional - Filters courses created before the specified date. - **createdAt[gte]** (string) - Optional - Filters courses created on or after the specified date. - **status[eq]** (string) - Optional - Filters courses with the specified status (e.g., 'deleted'). - **type[eq]** (string) - Optional - Filters courses of the specified type (e.g., 'scorm'). ### Request Example ```shell curl --request GET \ --url 'https://app.360learning.com/api/v2/courses?createdAt[lt]=2024-01-01&createdAt[gte]=2023-04-01&status[eq]=deleted&type[eq]=scorm' \ --header 'accept: application/json' \ --header '360-api-version: v2.0' \ --header 'authorization: Bearer your_access_token' ``` ### Response #### Success Response (200) - **courses** (array) - A list of course objects matching all specified advanced filter criteria. #### Response Example ```json { "courses": [ { "id": "course_id_4", "title": "SCORM Course", "status": "deleted", "createdAt": "2023-08-10T09:00:00Z" } ] } ``` ``` -------------------------------- ### API v1 Course Output Example Source: https://360learning.readme.io/docs/courses-migration Example JSON output for a course retrieved using the API v1 endpoint. This includes details like course ID, author, dates, name, status, and group information. ```json { "_id": "58eb5c621a92bb4fb526b2b0", "author": "mister.crabs@360learning.com", "creationDate": "2021-05-19T14:43:23.000Z", "description": "", "modificationDate": "2021-05-20T08:08:23.195Z", "name": "course name", "status": "published", "group": "58eb5c621a92bb4fb526b2b0", "lang": "en", "coAuthors": [ "spongebob.squarepants@360learning.com" ], "courseDuration": 15, "translationsLangs": [ { "lang": "fr", "published": true, "translators": [ "spongebob.squarepants@360learning.com" ] } ], "groupName": "Onboarding" } ``` -------------------------------- ### GET /api/v2/courses (Combine multiple filters on the same field) Source: https://360learning.readme.io/docs/filtering Apply multiple filters with different operators on the same field using '&' to define ranges or complex conditions. This example retrieves courses created between April 1, 2022, and January 1, 2023. ```APIDOC ## GET /api/v2/courses ### Description Retrieves a list of courses, allowing for multiple filters with different operators on the same field to define ranges or complex conditions using the '&' operator for a logical AND. ### Method GET ### Endpoint /api/v2/courses ### Query Parameters - **createdAt[lt]** (string) - Optional - Filters courses created before the specified date. - **createdAt[gte]** (string) - Optional - Filters courses created on or after the specified date. ### Request Example ```shell curl --request GET \ --url 'https://app.360learning.com/api/v2/courses?createdAt[lt]=2023-01-01&createdAt[gte]=2022-04-01' \ --header 'accept: application/json' \ --header '360-api-version: v2.0' \ --header 'authorization: Bearer your_access_token' ``` ### Response #### Success Response (200) - **courses** (array) - A list of course objects matching the date range criteria. #### Response Example ```json { "courses": [ { "id": "course_id_2", "title": "Course Title 2", "createdAt": "2022-07-20T12:30:00Z" } ] } ``` ``` -------------------------------- ### API v2 Input/Output Examples for Session Creation Source: https://360learning.readme.io/docs/create-a-path-session-migration-guide Demonstrates the JSON output structure for API v2 after a session has been created. This includes new fields and modified parameter names compared to v1. ```json { "_id": "68540b86685753a2d27f42db", "createdAt": "2025-06-19T13:07:18.000Z", "groupId": "6776986afff311b995274b73", "instructorIds": [ "67769f32553f1e9171a186c0" ], "isAudienceBuilder": true, "mainInstructorId": "647098a731a809ed36889ed1", "modifiedAt": "2025-06-19T13:07:18.516Z", "name": "Employee Onboarding July Session", "pathId": "6853f6de567dc5f80528f80d", "registrationRequestValidation": "disabled", "startDate": "2025-07-01T13:00:00.812Z", "additionalInformation": "A0015221", "endDate": "2025-07-31T13:00:00.812Z", "userLimit": 30, "translations": [] } ``` -------------------------------- ### API v1 User Output Example (JSON) Source: https://360learning.readme.io/docs/retrieve-a-user-migration-guide Sample JSON output from the v1 API endpoint for retrieving user data. This response includes a comprehensive set of user details including custom fields, certifications, and achievements. ```json { "_id": "5b56f4c392af558eb5f1386c", "mail": "dummy_user1@360learning.com", "firstName": "Paul", "lastName": "Durand", "primaryGroupId": "5694ea540fa69fdd0ec0004f", "assignedPrograms": 7, "averageScore": 76, "custom": "updated custom field", "certifications": [], "customFields": [ { "customFieldId": "610aac9922cc37084f692457", "value": "custom_value_0", "name": "My New Custom Field" } ], "championAchievements": { "coursesCreated": [ "Champion", "Guide", "Role Model", "Guru" ], "repliesOnOwnActivitiesGiven": [ "Educator" ], "positiveReactionsOnOwnContent": [ "Recognized" ] }, "paths": [ "Product Rookie", "Product Influencer" ], "comments": 29, "completedPrograms": 15, "managers": [ "5bead800990d8867f3c5146c" ], "subordinates": [ "5c4f0499928e2f55fa8d3664", "5bead808880d8862f3c51473" ], "labels": [ "LabelCreatedWithTheAPI 0", "LabelCreatedWithTheAPI 1" ], "groups": [ { "_id": "5694ea540fa69fdd0ec0004f", "name": "360Learning", "public": false }, { "_id": "5ae6f360c3b99d7884975380", "name": "EXTERNAL", "public": false, "parent": "5694ea540fa69fdd0ec0004f" } ], "imageUrl": "https://team.360mooc.com/api/medias/user/5be3e234a7df8c2534ec570c", "lastLoginAt": "2019-11-07T09:30:19.716Z", "championStatus": "champion", "learnerAchievements": { "repliesGiven": [ "Helping hand", "Contributor" ], "reactionsGiven": [ "Community member", "Supporter" ], "coursesPlayed": [ "Curious", "Diligent" ] }, "messages": 64, "publications": 1, "reactions": 123, "skills": [ { "_id": "5be5e234caaa8c3534ec570c", "name": "Trello Expert", "assessmentScore": "", "averageScore": 100, "eLearningScore": 100 } ], "toDeactivateAt": "", "totalTimeSpentInMinutes": 2527 } ``` -------------------------------- ### GET /api/v2/external-ids (Exclude specific values with the 'nin' operator) Source: https://360learning.readme.io/docs/filtering Use the 'nin' operator to exclude items that match any of the specified values (logical AND for exclusion). Combine multiple 'nin' filters with '&'. This example excludes external IDs of type 'classroom' or 'registrationRequest'. ```APIDOC ## GET /api/v2/external-ids ### Description Retrieves external IDs, allowing exclusion of items matching any of the specified values using the 'nin' operator. Multiple 'nin' filters are combined with '&', acting as a logical AND for exclusion. ### Method GET ### Endpoint /api/v2/external-ids ### Query Parameters - **type[nin]** (string) - Optional - Excludes external IDs where the 'type' field matches any of the specified values (e.g., 'classroom', 'registrationRequest'). ### Request Example ```shell curl --request GET \ --url 'https://app.360learning.com/api/v2/external-ids?type[nin]=classroom&type[nin]=registrationRequest' \ --header 'accept: application/json' \ --header '360-api-version: v2.0' \ --header 'authorization: Bearer your_access_token' ``` ### Response #### Success Response (200) - **externalIds** (array) - A list of external ID objects excluding the specified types. #### Response Example ```json { "externalIds": [ { "id": "external_id_3", "type": "course" } ] } ``` ``` -------------------------------- ### API v2 Retrieve Course Request Source: https://360learning.readme.io/docs/courses-migration Example of a cURL request to retrieve a course using the API v2 endpoint. This method uses GET request, specifies the URL with a placeholder for course ID, and includes API version and accept headers. ```shell curl --request GET \ --url https://app.360learning.com/api/v2/courses/courseId \ --header '360-api-version: v2.0' \ --header 'accept: application/json' ``` -------------------------------- ### API v1: Get Path Session User Stats (Shell) Source: https://360learning.readme.io/docs/paths-migration This example demonstrates how to retrieve user statistics for a specific path session using the API v1 endpoint. It requires a session ID and optionally company and API key parameters. ```shell curl --location -g 'https://{{host}}/api/v1/paths/sessions/5bead809990d8862f3c514aa/users?company={{company}}&apiKey={{apiKey}}' ``` -------------------------------- ### GET /api/v2/external-ids (Include specific values with the 'in' operator) Source: https://360learning.readme.io/docs/filtering Use the 'in' operator to retrieve items where a field matches at least one of the specified values (logical OR). Combine multiple 'in' filters with '&' to expand acceptable values. This example retrieves external IDs for courses or paths. ```APIDOC ## GET /api/v2/external-ids ### Description Retrieves external IDs, allowing filtering based on multiple acceptable values for a specific field using the 'in' operator. Multiple 'in' filters are combined with '&', acting as a logical OR. ### Method GET ### Endpoint /api/v2/external-ids ### Query Parameters - **type[in]** (string) - Optional - Filters external IDs where the 'type' field matches at least one of the specified values (e.g., 'course', 'path'). ### Request Example ```shell curl --request GET \ --url 'https://app.360learning.com/api/v2/external-ids?type[in]=course&type[in]=path' \ --header 'accept: application/json' \ --header '360-api-version: v2.0' \ --header 'authorization: Bearer your_access_token' ``` ### Response #### Success Response (200) - **externalIds** (array) - A list of external ID objects matching the specified types. #### Response Example ```json { "externalIds": [ { "id": "external_id_1", "type": "course" }, { "id": "external_id_2", "type": "path" } ] } ``` ``` -------------------------------- ### Combine Range Filters on the Same Field (AND operation) Source: https://360learning.readme.io/docs/filtering This example shows how to apply multiple filters with different operators on the same field to define a date range. The '&' operator ensures both conditions must be met, functioning as a logical AND. This is ideal for retrieving data within specific start and end boundaries. ```Text Shell curl --request GET \ --url 'https://app.360learning.com/api/v2/courses?createdAt[lt]=2023-01-01&createdAt[gte]=2022-04-01' \ --header 'accept: application/json' \ --header '360-api-version: v2.0' \ --header 'authorization: Bearer your_access_token' ``` -------------------------------- ### API v1 Courses Stats Output Example (JSON) Source: https://360learning.readme.io/docs/list-all-courses-statistics-migration-guide Sample JSON output from the API v1 endpoint for courses statistics. It includes course details and nested user statistics. ```json [ { "course": { "_id": "62e29a923c24c589a7f21aa5", "name": "Welcome to the team!" }, "stats": [ { "attempts": [ { "_id": "63a430d158dedd7933ef84c1", "progress": 0, "firstActivity": "2022-12-22T10:26:25.648Z", "lastActivity": "2022-12-22T10:45:26.896Z", "path": "639af419b8a1da7e76278f4e", "pathSession": "63a430ae7901ab0524815225", "globalTime": 1133849 } ], "user": { "_id": "62bdbc00291a605543f24386", "mail": "mister.crabs@360learning.com" } } ] } ] ``` -------------------------------- ### API v2 Course Output Example Source: https://360learning.readme.io/docs/courses-migration Example JSON output for a course retrieved using the API v2 endpoint. This version includes changes like `authorId`, `coAuthorIds`, `createdAt`, `modifiedAt`, `duration`, and new properties like `externalPlatform`, `currentVersionNumber`, and `type`. ```json { "_id": "507f1f77bcf86cd799439011", "authorId": "507f1f77bcf86cd799439011", "coAuthorIds": [ "507f1f77bcf86cd799439011" ], "createdAt": "2025-09-12T12:33:30.423Z", "defaultLang": "bg", "groupId": "507f1f77bcf86cd799439011", "modifiedAt": "2025-09-12T12:33:30.423Z", "name": "Employee Onboarding", "sourceLang": "bg", "status": "archived", "translations": [ { "lang": "fr", "published": true, "translatorIds": [ "507f1f77bcf86cd799439011" ], "translatedFields": { "name": "Accueil des employés", "description": "Ce module vous apprend à intégrer un nouveau collaborateur !" } } ], "type": "elearning standard", "description": "This course will teach you how to onboard a new employee!", "duration": 0, "externalPlatform": "Udemy", "currentVersionNumber": 0 } ``` -------------------------------- ### POST /courses Source: https://360learning.readme.io/reference/v2coursesgetcoursescontroller_getcourses Creates a new course on the 360Learning platform. You can specify course details such as name, description, type, and initial translations. ```APIDOC ## POST /courses ### Description Creates a new course on the 360Learning platform. You can specify course details such as name, description, type, and initial translations. ### Method POST ### Endpoint /courses ### Parameters #### Request Body - **name** (string) - Required - The name of the course. - **description** (string) - Optional - The description of the course. - **type** (string) - Required - The type of the course. Enum: "elearning standard", "external", "native". - **translations** (array) - Optional - An array of course translation objects. - **lang** (string) - Required - The language of the translation. Example: "fr" - **published** (boolean) - Required - True if the translation is available to users in this language; false otherwise. - **translatorIds** (array of string) - Required - The list of unique IDs of the translators assigned to this language. Example: ["507f1f77bcf86cd799439011"] - **translatedFields** (object) - Required - The translations of the course fields for this language. - **name** (string) - Optional - The translation of the field `name` for this language. Example: "Accueil des employés" - **description** (string) - Optional - The translation of the field `description` for this language. Example: "Ce module vous apprend à intégrer un nouveau collaborateur !" ### Request Example ```json { "name": "New Employee Onboarding", "description": "A comprehensive guide for new hires.", "type": "elearning standard", "translations": [ { "lang": "en", "published": true, "translatorIds": ["507f1f77bcf86cd799439011"], "translatedFields": { "name": "New Employee Onboarding", "description": "This module teaches you how to onboard a new employee!" } }, { "lang": "fr", "published": false, "translatorIds": ["507f1f77bcf86cd799439011"], "translatedFields": { "name": "Accueil des employés", "description": "Ce module vous apprend à intégrer un nouveau collaborateur !" } } ] } ``` ### Response #### Success Response (201) - **id** (string) - The unique identifier of the newly created course. - **name** (string) - The name of the course. - **description** (string) - The description of the course. - **type** (string) - The type of the course. - **translations** (array) - An array of course translation objects. #### Response Example ```json { "id": "60f7b0d3b2f0b1a0a4e1d2f3", "name": "New Employee Onboarding", "description": "A comprehensive guide for new hires.", "type": "elearning standard", "translations": [ { "lang": "en", "published": true, "translatorIds": ["507f1f77bcf86cd799439011"], "translatedFields": { "name": "New Employee Onboarding", "description": "This module teaches you how to onboard a new employee!" } } ] } ``` ``` -------------------------------- ### API v1 Output Example Source: https://360learning.readme.io/docs/edit-a-path-session-migration-guide This is an example of the successful output returned by API v1. It indicates that a session has been updated. ```json { "status": "session_updated" } ``` -------------------------------- ### API v1 Successful Response Example Source: https://360learning.readme.io/docs/subscriptions-migration-guides This is an example of a successful response from the API v1 endpoints. It returns a 200 status code with a simple success message. ```json { "message": "Success" } ``` -------------------------------- ### API v1: Example tag output (JSON) Source: https://360learning.readme.io/docs/list-all-tags Sample JSON output for a single tag from the API v1 'getSkills' endpoint, including detailed translation and author information. ```JSON [ { "_id": "60c72b2f9b1e8b001c8e4a7e", "name": "Active listening", "isMain": true, "author": "mail@domain.com", "externalId": "1234", "sourceLang": "en", "defaultLang": "fr", "translationsLangs": [ { "lang": "fr", "published": true, "translators": [ "translatorAeMail@domain.com", "translatorBeMail@domain.com" ] } ], "translations": [ { "lang": "fr", "name": "Ecoute active" } ] } ] ``` -------------------------------- ### API v2 Output Example Source: https://360learning.readme.io/docs/edit-a-path-session-migration-guide This example showcases the successful output from API v2, which includes a more detailed structure with new parameters like `mainInstructorId`, `registrationRequestValidation`, and `pathId`. ```json { "mainInstructorId": "507f1f77bcf86cd799439011", "registrationRequestValidation": "disabled", "startDate": "2025-06-20T08:55:28.495Z", "endDate": "2025-06-20T08:55:28.495Z", "userLimit": 0, "_id": "507f1f77bcf86cd799439011", "createdAt": "2025-06-20T08:55:28.495Z", "groupId": "507f1f77bcf86cd799439011", "instructorIds": [ "507f1f77bcf86cd799439011" ], "isAudienceBuilder": true, "modifiedAt": "2025-06-20T08:55:28.495Z", "name": "Onboarding session", "pathId": "507f1f77bcf86cd799439011", "translations": [ { "lang": "fr", "published": true, "translatorIds": [ "507f1f77bcf86cd799439011" ], "translatedFields": { "name": "Accueil des employés Session de juin" } } ], "additionalInformation": "A0015221", "automaticReenrollment": { "type": "certificationExpiryDate", "delayDays": 90 }, "rootSessionId": "507f1f77bcf86cd799439011" } ``` -------------------------------- ### API v1: List all users - Shell Example Source: https://360learning.readme.io/docs/list-all-users-migration-guide This code snippet demonstrates how to list all users using the v1 API endpoint. It requires the company and API key as query parameters. ```shell curl --location -g 'https://{{host}}/api/v1/users?company={{company}}&apiKey={{apiKey}}' ``` -------------------------------- ### GET /api/v2/groups (Authenticated Request Example) Source: https://360learning.readme.io/docs/authentication Example of making an authenticated API request to retrieve groups. Demonstrates the required Authorization and 360-api-version headers needed for all API v2 requests. ```APIDOC ## GET /api/v2/groups ### Description Example endpoint demonstrating how to make authenticated requests to the 360Learning API v2. All API requests require a valid access token and the API version header. ### Method GET ### Endpoint https://app.360learning.com/api/v2/groups ### Headers - **Authorization** (string) - Required - Format: "Bearer {access_token}" - **360-api-version** (string) - Required - API version, e.g., "v2.0" - **accept** (string) - Optional - Set to "application/json" ### Request Example ``` curl --request GET \ --url https://app.360learning.com/api/v2/groups \ --header 'accept: application/json' \ --header '360-api-version: v2.0' \ --header 'authorization: Bearer your_access_token' ``` ### Response #### Success Response (200) Returns a list of groups accessible with the provided access token. ### Required Headers for All API v2 Requests 1. **Authorization**: Valid bearer token obtained from the /oauth2/token endpoint 2. **360-api-version**: The API version (e.g., v2.0) ### Authentication Notes - All requests must include a valid access token in the Authorization header - Use the format: Authorization: Bearer {access_token} - Token expires after 1 hour; implement automatic renewal - Contact your platform admin if you need API credentials ```