Overview
Required Headers
Key | Value | Example |
---|---|---|
Accept | application/json | |
Authorization | Bearer <your token> | Bearer wV1MLk5+sFzioJw/3M5r9A== |
Content-Type | application/json | |
X-LearnerId | <the learner id> | The DMTD-supplied identifier that identifies the learner (see Getting started and /1/learner - POST) |
X-LearnerCode | <the learner code> | A REST-client-supplied identifier that identifies the learner (see Getting started and /1/learner - POST) |
X-UserId | <the user id> | The DMTD-supplied identifier that identifies the owner of the purchase (see Getting started and /1/user - POST) |
X-UserCode | <the user code> | A REST-client-supplied identifier that identifies the owner of the purchase (see Getting started and /1/user - POST) |
Fields
Field | Type | Optional | Description |
---|---|---|---|
systemDomain | String | Required | The DMTD-Supported domain of the purchase ('vbmapp', 'efl') |
type | String | Required | The type of product being purchased in the SystemDomain ('assessment', 'training') |
trainingProduct | String | Optional | Type type of training product being purchased ('conducting'). Required when type == 'training' |
Example
Example
curl -X POST \
-H 'Authorization: Bearer L2Hth4lRwgHRBWtX8Hkl5w==' \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "X-UserId: 7" \
-H "X-LearnerId: 1" \
-d '{ "systemDomain": "vbmapp", "type": "assessment" }' \
http://data-sandbox.datamtd.com/1/purchase
Response