Introduction
Most items in the platform that can be created, edited, or deleted have a unique ID. This ID is essential for performing API actions on those items. For example, if you want to view course data using the API endpoint GET /learn/v1/courses/{course_id}, you need the course ID to make the request.
This article explains how to retrieve unique IDs, such as user IDs, course IDs, and catalog IDs, which are required for performing API actions and accessing data. It provides methods and examples for how to obtain these IDs through API endpoints, using the API browser.
Retrieve IDs directly from the platform
The most common IDs platform administrators utilize are user IDs and course IDs. These can be retrieved directly from the platform.
- User IDs: You can find them by generating a Users custom report
- Course IDs: You can obtain them through an export of the course data in CSV or XLS format from the Course management page
For extra details on how to recover IDs directly from the Docebo platform interface, this Community article on finding unique IDs (opens in a new tab) can be helpful.
In the next chapter we will see how, by using APIs, we can retrieve IDs not just for users and courses, but also for catalogs, learning plans, notifications, and more.
Retrieve IDs using the API browser
When IDs cannot be retrieved via the platform interface, some GET API endpoints can help. Here’s how to do it:
Check the response sample
Before launching the endpoint, check the response sample to ensure it includes the ID you need. The sample shows what data the API will return.
Launch the endpoint
After verifying that the endpoint provides the needed ID, such as a course ID, you can launch the appropriate API (e.g. GET/learn/v1/courses). Remember to authenticate as described in the article Get started with the Docebo API browser.
Retrieve catalog IDs
To retrieve catalog IDs, you can follow a similar approach, but taking into consideration some differences with other endpoints.
Find the endpoint and validate the response schema
As explained earlier, reviewing the response schema helps determine if the endpoint returns the ID you're looking for. Typically, the ID appears at the top of the response. However, for catalog IDs, it is usually located toward the end of each item in the response. The table below highlights this difference:
| Returns all Courses | Retrieves some content for all the given catalogs |
Launch the Catalog endpoint
Keep in mind: When using the API, the returned list of catalog content depends on the course settings and catalog visibility rules for the user making the request. If a catalog is not visible or has not been associated with the requesting user, it will not appear in the results.
To retrieve catalog information within this scope, use the endpoint:
- GET/learn/v1/catalog_content/internal/preview
Scope the results
When using the API to retrieve catalog IDs, you can limit the number of results to just one to quickly access the course ID. This makes it easier to find the information you need. Keep in mind that only catalogs with associated courses or learning plans will be returned.
Authenticate and launch the endpoint
Authenticate as described in the article article Get started with the Docebo API browser. Then use the Try button to send your request.
Identify the catalog ID in the response
Once the response is displayed, identify the catalog ID. Look for the extra_data field, where the catalog ID integer will be displayed:
Example: Use a catalog ID to retrieve a given catalog information
To retrieve details about a specific catalog, use the following endpoint:
-
GET/learn/v1/catalog_content/internal/{catalog_id}.
This will provide all the content linked to that one catalog.
Identify the endpoint and its requirements
Endpoint: get/learn/v1/catalog_content/internal/{catalog_id}
Requirements: catalog_id is a required parameter
Retrieve the Catalog ID
Use the endpoint GET/learn/v1/catalog_content/internal/preview to get the catalog ID, as described in the preceding chapter.
Once you have the ID of the desired catalog, you can input it as a parameter for the endpoint get/learn/v1/catalog_content/internal/{catalog_id}
Authenticate and launch the endpoint
After authenticating, you can click Try to launch the endpoint.
The results will include the total number of courses in the catalog and detailed information for each course. The response structure is fixed and cannot be customized.
By following these steps, you can efficiently retrieve and use IDs within the platform to interact with its various components using APIs.
List of APIs to retrieve IDs
In the preceding chapters you saw some examples of how to use APIs to retrieve IDs of objects in the platform. Now you can try to apply a similar pattern to retrieve other IDs.
The following tables provide some suggestions of endpoints that you can use to retrieve commonly-used platform IDs. The lists are organized by service, but be aware that sometimes you can retrieve IDs of a particular object from more than one service. As explained in the preceding examples, after you make a call, use the schema in the API browser to determine where the ID can be found in the response.
Please note that this is not a comprehensive list of all the ways you can potentially retrieve IDs, but just a selection of useful endpoints. In addition, remember that visibility rules apply to the responses of these endpoints, so that the objects included in the responses will depend on the permissions and resource assignments of the user making the call. In particular:
→ For Power Users, their visibility on objects depends on their permissions and resource assignments
→ In addition, some endpoints may not return all objects. For example, users (even Superadmins) only have visibility on the catalogs to which they are assigned.
Service -Learn
| To retrieve IDs of: | Endpoint | Notes |
| Courses | get/learn/v1/courses | |
| Catalogs |
get/learn/v1/catalog_content/internal/preview |
cursor parameter required (use default value 0) The catalog ID is in the extra_data field. Only catalogs assigned to the user are included in the response |
| Categories | get/learn/v1/categories | |
| Certifications | get/learn/v1/certification | |
| Classrooms | get/learn/v1/classroom | |
| Sessions | get/learn/v1/courses/{course_id}/sessions/enrollments | course_id parameter required |
| Course Additional Fields | get/learn/v1/courses/field | |
| Training Materials | get/learn/v1/courses/{course_id}/los | |
| External Training | get/learn/v1/external_training | |
| Assignments submission | get/learn/v1/instructor/assignment | |
| Location Classroom | get/learn/v1/location | It is also visible in the platform interface |
| Subscription Bundle | get/learn/v1/sub_bundle | |
| Subscription Bundle Additional Fields | get/learn/v1/sub_field | |
| Subscription Plans | get/learn/v1/sub_plan | |
| Subscription Records | get/learn/v1/sub_record | |
| Web Conference Tools accounts paired with the platform |
get/learn/v1/webinar/accounts (Zoom) get/learn/v1/webinar/adobeconnect/accounts get/learn/v1/webinar/gotomeeting/accounts get/learn/v1/webinar/bluejeans/accounts get/learn/v1/webinar/msteams/accounts |
Service -Manage
| To retrieve IDs of: | Endpoint | Requirements |
| Channels | get/manage/v1/channels | Only channels visible to the user are returned |
| Conternt Partners | get /manage/v1/contentpartners | |
| Legacy Enrollment Rules | get/manage/v1/enrollment_rules | |
| Enrollment field | get/manage/v1/enrollment_fields | |
| Manager Types | get/manage/v1/managers/types | |
| Extended Enterprise Domains | get/manage/v1/multidomain | |
| Branches | get/manage/v1/orgchart | |
| Privacy Policies | get/manage/v1/policy | |
| Tags | get/manage/v1/tags | |
| Terms & Conditions | get/manage/v1/termsandconditions | |
| Users | get/manage/v1/user | |
| User’s additional Fields | get/manage/v1/user_fields |
Service -Skills
| To retrieve IDs of: | Endpoint | Notes |
| Skills list | get/skill/v1/skills/catalog | |
| Skill Groups | get/skill/v1/skillgroups | |
| Workforce Category List | get/skill/v1/workforce/categories |
Service -Share
| To retrieve IDs of: | Endpoint | Notes |
| Channels | get/share/v1/admin/channels | |
| Assets | get/share/v1/admin/assets | |
| Assets by user | get/share/v1/assets | assets assigned to channels visible to the user are returned |
| Experts | get/share/v1/admin/assets | |
| Questions |
get/share/v1/questions get/share/v1/questions/list |
|
| Answers | get/share/v1/answers | |
| Comments | get/share/v1/comments | |
| Playlists | get/share/v1/playlists | type_content parameter is required ( ‘asset’ or ‘my-course’) |
| Training materials | get/share/v1/gamification/courses/{id_course}/los | id_course parameter is required |
Service -Share (Gamification)
| To retrieve IDs of: | Endpoint | Notes |
| Badges | get/share/v1/gamification/badges | |
| Badges Collections | get/share/v1/gamification/collections | |
| Badge Images | get/share/v1/gamification/badges/images |
Service -Ecommerce
| To retrieve IDs of: | Endpoint | Notes |
| Coupons | get/ecommerce/v1/coupon | |
| Transactions |
get/ecommerce/v1/transaction get/ecommerce/v1/transaction/list - (New API) |
Service -Report
| To retrieve IDs of: | Endpoint | Notes |
| External Training Records (Transcript) | get/report/v1/mytranscript | |
| Query Builder Report ID | get/report/v1/query_builder | |
| Legacy reports ID | get/report/v1/report |
Service -Pages
| To retrieve IDs of: | Endpoint | Notes |
| Menus | get/pages/v1/menus | |
| Pages | get/pages/v1/pages |
Service -OTJ (Checklists)
| To retrieve IDs of: | Endpoint | Notes |
| Checklist | get/otj/v1/checklists | |
| Checklist Version | get/otj/v1/checklists/{checklist_id}/versions |
Service - Courses
| To retrieve IDs of: | Endpoint | Notes |
| Course | get/course/v1/courses | |
| Session | get/course/v1/sessions/ilt | |
| Events by Session | get/course/v1/sessions/{session_id}/events | session_id parameter is required |
| Thumbnails | get/course/v1/thumbnails |
Service - Analytics
| To retrieve IDs of: | Endpoint | Notes |
| Query Builder Reports IDs | get/analytics/v1/custom-report-types/active | |
| Query Builder Reports IDs | get/analytics/v1/custom-report-types | |
| New Reports (No Legacy) | get/analytics/v1/reports |
Service - Audiences
| To retrieve IDs of: | Endpoint | Notes |
| Audience ID (Group) | get/audiences/v1/audience | |
| Getting group ID by Audience ID | get/audiences/v1/audience/{uuid}/audience_to_group | |
| Get an Audience ID by group id | get/audiences/v1/audience/{id}/group_to_audience |
Service - Powerusers
| To retrieve IDs of: | Endpoint | Notes |
| Power Users | get/poweruser/v1/powerusers | |
| Power User profiles | get/poweruser/v1/profile | |
| Power Users according to profile | get/poweruser/v1/profiles/{profile_id}/poweruser | profile_id parameter is required |
Service - Learningplan
| To retrieve IDs of: | Endpoint | Notes |
| Learning Plans | get/learningplan/v1/learningplans | |
| Learning Plans Additional Fields | get/learningplans/2/additionalfields |
Service - Learningplan
| To retrieve IDs of: | Endpoint | Notes |
| Archived Enrollments record IDs | get/enrollment/v1/courses/{course_id}/archives | course_id parameter is required |
| Session List of Archived Course Enrollments | get/enrollment/v1/courses/archives/{record_id}/sessions | record_id is required |