Clusters
Applications
Models
Artifacts
- GETGet Artifact
- DELDelete Artifact
- GETList Artifacts
- GETGet Artifact Version
- DELDelete Artifact Version
- GETList Artifact Versions
- PUTApply Artifact Version
- POSTDelete Artifact Version
- POSTGet Signed Urls For Artifact Version
- POSTCreate Multi Part Upload
- POSTStage Artifact Version
- POSTList Files For Artifact Version
- POSTMark Stage Failure
Prompts
Secret Groups
Model Deployments
Users
Personal Access Tokens
Virtual Accounts
Prompts
Apply Prompt Version
PUT
/
api
/
ml
/
v1
/
prompt-versions
curl --request PUT \
--url https://{controlPlaneURL}/api/ml/v1/prompt-versions \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"manifest": {
"name": "<string>",
"description": "<string>",
"metadata": {},
"version_alias": "<string>",
"ml_repo": "<string>",
"version": 2,
"type": "chat_prompt",
"messages": [
{
"role": "system",
"content": "<string>",
"name": "<string>"
}
],
"variables": {},
"model_configuration": {
"provider": "<string>",
"model": "<string>",
"parameters": {
"max_tokens": 123,
"temperature": 123,
"top_k": 123,
"top_p": 123,
"stop": [
"<string>"
]
},
"extra_parameters": {}
},
"tools": [
{
"type": "function",
"function": {
"name": "<string>",
"description": "<string>",
"parameters": {},
"strict": false
}
}
]
}
}'
{
"data": {
"id": "<string>",
"fqn": "<string>",
"created_by_subject": {
"subjectId": "<string>",
"subjectType": "user",
"subjectSlug": "<string>",
"subjectDisplayName": "<string>"
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"manifest": {
"name": "<string>",
"description": "<string>",
"metadata": {},
"version_alias": "<string>",
"ml_repo": "<string>",
"version": 2,
"type": "chat_prompt",
"messages": [
{
"role": "system",
"content": "<string>",
"name": "<string>"
}
],
"variables": {},
"model_configuration": {
"provider": "<string>",
"model": "<string>",
"parameters": {
"max_tokens": 123,
"temperature": 123,
"top_k": 123,
"top_p": 123,
"stop": [
"<string>"
]
},
"extra_parameters": {}
},
"tools": [
{
"type": "function",
"function": {
"name": "<string>",
"description": "<string>",
"parameters": {},
"strict": false
}
}
]
},
"usage_code_snippet": "<string>",
"ml_repo_id": "<string>",
"prompt_id": "<string>"
}
}
Authorizations
Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
Body
application/json
Response
200
application/json
Successful Response
The response is of type object
.
Was this page helpful?
curl --request PUT \
--url https://{controlPlaneURL}/api/ml/v1/prompt-versions \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"manifest": {
"name": "<string>",
"description": "<string>",
"metadata": {},
"version_alias": "<string>",
"ml_repo": "<string>",
"version": 2,
"type": "chat_prompt",
"messages": [
{
"role": "system",
"content": "<string>",
"name": "<string>"
}
],
"variables": {},
"model_configuration": {
"provider": "<string>",
"model": "<string>",
"parameters": {
"max_tokens": 123,
"temperature": 123,
"top_k": 123,
"top_p": 123,
"stop": [
"<string>"
]
},
"extra_parameters": {}
},
"tools": [
{
"type": "function",
"function": {
"name": "<string>",
"description": "<string>",
"parameters": {},
"strict": false
}
}
]
}
}'
{
"data": {
"id": "<string>",
"fqn": "<string>",
"created_by_subject": {
"subjectId": "<string>",
"subjectType": "user",
"subjectSlug": "<string>",
"subjectDisplayName": "<string>"
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"manifest": {
"name": "<string>",
"description": "<string>",
"metadata": {},
"version_alias": "<string>",
"ml_repo": "<string>",
"version": 2,
"type": "chat_prompt",
"messages": [
{
"role": "system",
"content": "<string>",
"name": "<string>"
}
],
"variables": {},
"model_configuration": {
"provider": "<string>",
"model": "<string>",
"parameters": {
"max_tokens": 123,
"temperature": 123,
"top_k": 123,
"top_p": 123,
"stop": [
"<string>"
]
},
"extra_parameters": {}
},
"tools": [
{
"type": "function",
"function": {
"name": "<string>",
"description": "<string>",
"parameters": {},
"strict": false
}
}
]
},
"usage_code_snippet": "<string>",
"ml_repo_id": "<string>",
"prompt_id": "<string>"
}
}
Assistant
Responses are generated using AI and may contain mistakes.