Set user status

Activate or deactivate users.

PUT https://cotlet.dev/api/v1/absorb-lms/user-status

write Confirm

Sets the listed users to Active or Inactive, like the Activate Users and Deactivate Users mass actions. An Inactive user cannot take part in or record new training, and their enrollment records, scores and history stay in reports. One call with the opposite status undoes it. It changes who can sign in, so it asks first. By default you confirm each call; you can switch that off for this tool.

Parameters

Parameters: set_user_status
NameTypeDescription
user_ids array required array user_id values from list_users.
status enum required enum active or inactive.

Request

cURL
curl -X PUT https://cotlet.dev/api/v1/absorb-lms/user-status \
  -H "Authorization: Bearer $COTLET_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"user_ids":"user ids","status":"active"}'
Python
result = client.call("absorb-lms", "set_user_status", {"user_ids":"user ids","status":"active"})
Node.js
const result = await cotlet.call('absorb-lms', 'set_user_status', {"user_ids":"user ids","status":"active"});
CLI
cotlet call absorb-lms set_user_status --data '{"user_ids":"user ids","status":"active"}'

Example response

JSON

{
  "updated": [
    {
      "user_id": "9b7e5d10-2c44-4f0b-8a31-6e2f9c4d7702",
      "name": "Omar Haddad",
      "status": "Inactive"
    }
  ]
}

Sign in once. Your agent does the rest.

Sign up and add the apps you need. Free 7-day trial with 2,000 credits, no card needed.