Get the onboarding task template
Get the onboarding task template of one product line registry, or of all registries. This is an internal dependency: Create the onboarding checklist calls it to build the checklist. You only need it yourself to preview a checklist.
For each registry, the call returns its ID, name, display name, description, active flag and onboardingTaskConfig. The template has common task groups (taskGroupList) and optional per-product segments (segmentName, keyed by product name, each with its own taskGroupList). Nothing is written.
Send the bearer token of a signed-in Spyne Console user in Authorization: Bearer YOUR_TOKEN. The token is checked against the user validation endpoint on every call. When the checklist call uses this endpoint, it forwards the caller's token.
Before you call it
- To get one template, you need the product line registry ID. It is on the product line record and is returned as
productLineRegistryIdby Create the onboarding checklist. - The call is synchronous: one database read. The rate limit is not documented.
Request
- Authenticate: send the
Authorization: Bearer YOUR_TOKENandContent-Type: application/jsonheaders. - Pick the registry: send
product_line_registry_idfor one registry, or an empty body for all.
Headers
| Parameter | Type | Required | Description |
|---|---|---|---|
Authorization | string | Required | Bearer YOUR_TOKEN |
Content-Type | string | Required | application/json |
Body
| Parameter | Type | Required | Description |
|---|---|---|---|
product_line_registry_id | string | Optional | Registry ID. Leave it out to get all registries, newest first. |
Sample request
curl -X POST "https://api.spyne.ai/credit/v2/product-line-registry/get-onboarding-task-config" \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{ "product_line_registry_id": "PRODUCT_LINE_REGISTRY_ID" }'import requests
res = requests.post(
"https://api.spyne.ai/credit/v2/product-line-registry/get-onboarding-task-config",
json={"product_line_registry_id": "PRODUCT_LINE_REGISTRY_ID"},
headers={"Authorization": "Bearer YOUR_TOKEN"},
)
print(res.status_code, res.json())const res = await fetch(
"https://api.spyne.ai/credit/v2/product-line-registry/get-onboarding-task-config",
{
method: "POST",
headers: { Authorization: "Bearer YOUR_TOKEN", "Content-Type": "application/json" },
body: JSON.stringify({ product_line_registry_id: "PRODUCT_LINE_REGISTRY_ID" }),
}
);
console.log(res.status, await res.json());Sample response
The template content in the 200 response is shortened.
{
"message": "Onboarding task configuration retrieved successfully",
"error": false,
"code": "",
"details": null,
"data": {
"onboardingTaskConfigs": [
{
"productLineRegistryId": "PRODUCT_LINE_REGISTRY_ID",
"name": "conversationalAi",
"displayName": "<displayName>",
"description": "<description>",
"isActive": true,
"onboardingTaskConfig": {
"segmentName": {
"<productName>": {
"taskGroupList": [
{ "taskGroupName": "<taskGroupName>", "taskList": [{ "taskName": "<taskName>", "required": true }] }
]
}
},
"taskGroupList": [
{ "taskGroupName": "<taskGroupName>", "taskList": [{ "taskName": "<taskName>" }] }
]
}
}
]
}
}{ "message": "Invalid Token", "error": true, "code": "ERROR_AUTH_401", "details": null, "data": null }{
"message": "Product line registry not found for id: PRODUCT_LINE_REGISTRY_ID",
"error": true,
"code": 404,
"details": null,
"data": null
}{ "message": "General API error. Please try again later.", "error": true, "code": "ERROR_SERVER_500", "details": "" }Response parameters
| Parameter | Type | Description |
|---|---|---|
data.onboardingTaskConfigs | object[] | One entry per registry. |
data.onboardingTaskConfigs[].productLineRegistryId | string | Registry ID. |
data.onboardingTaskConfigs[].name | string | Product line name, for example conversationalAi. |
data.onboardingTaskConfigs[].displayName | string | Display name. |
data.onboardingTaskConfigs[].description | string | Description. |
data.onboardingTaskConfigs[].isActive | boolean | Whether the registry is active. |
data.onboardingTaskConfigs[].onboardingTaskConfig | object | Task template. {} if none is set. The stored shape is free-form. The checklist call reads taskGroupList[].taskGroupName, taskGroupList[].taskList[].taskName, the optional required, and segmentName (either a string, or an object keyed by product name, each with its own taskGroupList). |
Errors
| Status | Reason | When it happens |
|---|---|---|
401 | Invalid or missing token | No Bearer token, or the token failed validation. |
404 | Product line registry not found for id | No registry has this ID. In this response code is the number 404. |
404 | No product line registries found | No ID was sent and no registries exist. |
408 | Request timed out | The token validation call could not connect. |
500 | General API error | Any other error, including an ID that is not a valid ID format. |
What happens next
The checklist call turns the template into tasks. You do not need to call this endpoint during onboarding unless you want to preview the checklist.
Called before: none. Called after: used by Create the onboarding checklist.
Updated about 1 hour ago
