Skip to content

Assign a certification, course or lesson

POST/v1/organization/{orgId}/learning/assignments/create

US Region: https://public-api.sessionboard.com · EU Region: https://public-api-eu.sessionboard.com

Assigns already-published training to the whole team or named teammates and messages each of them. Requires write:learning. Also at POST /v1/learning/assignments/create.

Request example

Terminal window
curl --request POST \
--url 'https://public-api.sessionboard.com/v1/organization/{orgId}/learning/assignments/create' \
--header 'x-access-token: <api-token>' \
--header 'Content-Type: application/json' \
--data '{
"targetKind": "certification",
"targetId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"audience": {
"allTeam": true,
"userIds": [
123
]
},
"dueInDays": 1,
"required": true,
"slackChannelId": "<string>"
}'

Try it

Authorization

Your token stays in this page. It is sent only to the region above and is never saved; it is gone when you leave or reload the page.

Path parameters
Body application/json
POST

Authorizations

  • x-access-tokenstringheader

    Organization API token. Generate from Organization Settings → API Tokens.

  • AuthorizationBearer <token>headeror

    OAuth 2.1 access token. Obtained via the OAuth PKCE flow at /oauth/token.

Send one of these. See Authentication.

Path parameters

  • orgIdstringpathrequired

    Your organization ID. Any other organization returns 404.

Request body

application/jsonrequired

  • targetKindstringrequired

    series is a course.

    Allowed values
    "certification", "series", "lesson"
  • targetIdstring<uuid>required
  • audienceobjectrequired
    Show child attributes
    • allTeamboolean
    • userIdsinteger[]
  • dueInDaysinteger | null
    Minimum
    1
    Maximum
    365
  • requiredboolean
  • slackChannelIdstring
    Max length
    32
{
"targetKind": "certification",
"targetId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"audience": {
"allTeam": true,
"userIds": [
123
]
},
"dueInDays": 1,
"required": true,
"slackChannelId": "<string>"
}

Responses

201

Assigned; payload.assignment and payload.delivery (who was messaged, and how).

403

  • SCOPE_REQUIRED — the token lacks read:learning (reads) or write:learning (writes). Legacy tokens with no scopes cannot write.
  • FORBIDDEN — Learning is not on for the organization, or the token's user lacks the Lessons permission.