Get the ID of a certificate via API

For some reasons you may need to get the ID of a certificate and this article describes the steps of how to get this ID with the help of an LMS365 (Learn365) API endpoint. With the help of this API, you can get the ID of the template used for the certificate as well.

 

So, to get the ID of a certificate in LMS365 (Learn365):

1. Go to https://api.365.systems/ and log in. You can find more about the authorization process here.

2. Find the Certificates section, expand it, find the GET method /odata/v2/Certificates with the Returns the list of Certificates owned by current user description and then select Try it out in the top left corner.

 

 

You can use query options parameters to control the data in the response by setting filters. Using a combination of filters can help you to narrow the response and easily find the relevant certificate. 


EXAMPLES

  • To make it easier to find a certificate template awarded for a specific course, in $expand enter Course. After selecting Execute, the response will contain course titles and you can use Cntr+F to search for a relevant course and get the ID of the certificate template used for this course.

  • To get a list of courses or training plans that have a specific certificate template configured in their settings, in $filter enter Title eq 'certificate's template' where certificate template is replaced with the relevant certificate template title (you can find it in the Certificate Templates section in the Learn365 Admin Center, for example). After selecting Execute, the response will show these courses or training plans only that have this certificate template configured in their settings.

    2022-10-19_16_29_51-LMS365_API.png

  • To get a list of certificates awarded to a specific user, in the $filter field enter UserId eq ID of the user, for example UserId eq 7af3f4b0-65dc-4dfd-a4dc-287733b61e6d.

  • To get a list of certificates associated with a specific course, in the $filter field enter CourseId eq ID of the course, for example CourseId eq 6bf3f3b0-65dc-4dfd-a4dc-287733b61e6d.

  • A combination of UserId and CourseID will give you in the response all user's certificates for a specific course only. In this case, the request will contain both parameters in the $filter field with and between them, for example UserId eq 7af3f4b0-65dc-4dfd-a4dc-287733b61e6d and CourseId eq 6bf3f3b0-65dc-4dfd-a4dc-287733b61e6d.

 

3. Select Execute to run the request. 

 

4. Go to the Responses block to check the results:

  • Number 2xx (for example, 200) under Code shows that the request worked correctly. You can Download the data from the response to your computer in the .JSON format.



  • If no query parameters were set to narrow the response, in the Response body field you can see all the certificates of the tenant and their data, including the ID. Search via Ctrl+F for a specific certificate to find its ID and copy it to use wherever you need. 

    2022-06-23_11_45_41-LMS365_API.png

  • If query parameters were set, the response shows only the information relevant limited by the query parameters. However, the ID of the certificate is displayed regardless the parameters set to limit the response.

     

    2022-10-19_16_34_11-LMS365_API.png

 

Was this article helpful?
0 out of 0 found this helpful

Comments

Article is closed for comments.