This method returns a list of training completion records for users within your organization. Completions can be filtered by user or by training and are returned sorted (most recent dates are first). Use paging to load the entire collection.

NOTE: This endpoint contains "v2" in the title because the previous version is deprecated and will be removed October 1, 2020. The new response format is very similar, but with the following changes:

  • database keys (training_id and group_training_id) are now integers instead of strings
  • camel cased properties such as `dateNumber` are now underscored: `date_number`
  • the property `user_id` has been renamed to `m_user_id`
  • the property `instructor_id` has been renamed to `m_instructor_id`


Your request data may contain the following parameters. GET or POST the object (as JSON) to

Parameter Example Required Description
token "YOUR_TOKEN" Required Your API Token
pretty true Optional true means the response json will include white space for readability. Default is false.
training_id 1024 Optional The id of the training to search for
user_id "C906DA7B026376DA7B02BB12" Optional The id of the user to search for
limit 100 Optional The maximum number of completions to return. Max 1000. Defaults to 100. Use page to fetch additional responses.
page 1 Optional The page of responses to return. Defaults to 1 (the first page). Completions are sorted by date, newest first. The response field paging.last_page tells you what the last valid page number is.

Example Request

Example Response

  "ok": true,
  "completedtrainings": [
      "id": 1238,
      "training_id": 1046,
      "m_user_id": "5e580f0cb780600088bd2c11",
      "created": 1582830441803,
      "date_number": 20200227,
      "special_expiration_date_number": null,
      "m_instructor_id": null,
      "group_training_id": null
      "id": 1236,
      "training_id": 1042,
      "m_user_id": "5e580f0db780600088bd2ca6",
      "created": 1582829521694,
      "date_number": 20200227,
      "special_expiration_date_number": 20210101,
      "m_instructor_id": "5e580f0db780600088bd2ccd",
      "group_training_id": 1050
      "id": 1233,
      "training_id": 1042,
      "m_user_id": "5e580f0db780600088bd2c43",
      "created": 1582829521693,
      "date_number": 20200227,
      "special_expiration_date_number": null,
      "m_instructor_id": "5e580f0db780600088bd2ccd",
      "group_training_id": 1050


If an error occurs, the response JSON will have ok set to false:

  "ok": false,
  "error": "token_invalid",
  "description": "The token `YOUR_TOKEN` was not found."

The error field will contain one of the following error identifiers and there may also be a description field with a more detailed explanation:

Identifier Description
api_method_not_found The requested url did not match any KPA EHS API method.
request_method_invalid The requested method was not GET or POST.
request_data_invalid The request did not include a valid JSON request object.
rate_limit_exceeded This token is exceeding its request limit.
token_missing The request did not include a token.
token_invalid The request token was invalid.
token_inactive The request token was has been deactivated.
token_permission The request token does not have write permission.
account_inactive The request token was for an account that is not active.
parameter_unexpected The request data included a parameter that is not supported.
parameter_missing The request data failed to include a parameter which was required.
parameter_invalid The request data included a parameter which had a value that is not allowed.
server_error The server encountered an internal error.
content_not_found The requested content was not found.