POST
/ng-cms/content-types/{projectId}/{key}/ai-actions/{actionId}/runhttps://apis-spb.konso.io/ng-cms/content-types/{projectId}/{key}/ai-actions/{actionId}/runRun an AI action for a content type
Параметры запроса
projectIdstringProject (bucket) identifier
keystringContent type ID or key
actionIdstringAI action ID to run
Тело запроса
RunCmsTypeAiActionRequestentryIdstringID of the content entry to run the action against
Ответы
202Action ran successfully against the entry.
тип: ApiResponse<bool>
successbooleanAlways true on successresultbooleanAlways trueerrorsErrorDetail[]Empty on success400entryId missing from the request body, or the action failed for a reason other than not-found/locked (e.g. publish failed after running).
тип: ApiResponse<bool>
successbooleanAlways falseresultbooleanAlways falseerrorsErrorDetail[]One error describing why the run failed401Unauthorized.
404Either the content type does not exist for projectId/key (empty body), or the actionId/entryId does not exist (ApiResponse<bool> body with an error message).
тип: ApiResponse<bool> | empty
successbooleanAlways false (only present when action/entry not found)errorsErrorDetail[]One error describing what wasn't found (only present when action/entry not found)409The target entry is currently locked (e.g. being edited/processed by another operation).
тип: ApiResponse<bool>
successbooleanAlways falseerrorsErrorDetail[]One error describing the lock500Unexpected server error.
тип: ApiResponse<bool>
successbooleanAlways falseerrorsErrorDetail[]Server-side errorscorrelationIdstringTrace IDmessagestringError messagestackstringStack trace (non-production only)Язык:
expand_more
Пример запроса
curl --request POST \
--url https://apis-spb.konso.io/ng-cms/content-types/{projectId}/{key}/ai-actions/{actionId}/run \
--header 'x-api-key: <your-api-key>' \
--header 'Content-Type: application/json' \
--data '{"entryId":"cnt_a1b2c3d4e5f6"}'Response Example202
{
"success": true,
"result": true,
"errors": []
}KONSO