Maxim Logo
Prompts

Update Prompt

Update an existing prompt

PUT
/v1/prompts

Authorization

x-maxim-api-key<token>

API key for authentication

In: header

Request Body

application/jsonOptional
workspaceIdRequiredstring

Unique identifier for the workspace

idRequiredstring

Unique identifier for the prompt

namestring

Name of the prompt

descriptionstring

Description of the prompt

folderIdstring

Unique identifier for the folder

curl -X PUT "https://api.getmaxim.ai/v1/prompts" \
  -H "x-maxim-api-key: <token>" \
  -H "Content-Type: application/json" \
  -d '{
    "workspaceId": "string",
    "id": "string",
    "name": "string",
    "description": "string",
    "folderId": "string"
  }'

Prompt updated successfully

{
  "data": {
    "id": "string",
    "name": "string",
    "description": "string",
    "workspaceId": "string",
    "accountId": "string",
    "folderId": "string",
    "meta": null,
    "createdById": "string",
    "createdAt": "string",
    "updatedAt": "string",
    "deletedAt": "string",
    "deploymentHistory": {
      "id": "string",
      "workspaceId": "string",
      "accountId": "string",
      "promptId": "string",
      "strategy": {
        "type": "string",
        "config": {
          "property1": [
            {
              "id": "string",
              "rules": {
                "query": {
                  "not": true,
                  "rules": [
                    {
                      "field": "string",
                      "value": "string",
                      "operator": "string",
                      "valueSource": "string"
                    }
                  ],
                  "combinator": "string"
                },
                "version": 0
              },
              "timestamp": "string"
            }
          ],
          "property2": [
            {
              "id": "string",
              "rules": {
                "query": {
                  "not": true,
                  "rules": [
                    {
                      "field": "string",
                      "value": "string",
                      "operator": "string",
                      "valueSource": "string"
                    }
                  ],
                  "combinator": "string"
                },
                "version": 0
              },
              "timestamp": "string"
            }
          ]
        }
      },
      "createdAt": "string",
      "updatedAt": "string",
      "deletedAt": "string"
    }
  }
}