FruxonDocs
ApiAgentdraft

Load the working-copy draft for an agent revision.

Returns the caller's draft for the given base revision together with its full undo/redo history. The studio calls this on every open; not having a draft yet is a normal, expected state (e.g. a brand-new agent), so it is reported as `204 No Content` rather than an error — the client then seeds one from the current revision and creates it with the first PUT.

GET
/v1/tenants/{tenant}/agents/{agent}/revisions/{revision}/draft
AuthorizationBearer <token>

JWT Authorization header using the Bearer scheme. Enter 'Bearer' [space] and then your token.

In: header

Path Parameters

agent*string

The unique identifier of the agent.

revision*string

The base revision the draft forks from.

tenant*string

The tenant identifier

Response Body

curl -X GET "https://api.fruxon.com/v1/tenants/string/agents/string/revisions/string/draft"
{
  "agentId": "string",
  "baseRevision": 0,
  "version": 0,
  "historyCursor": 0,
  "canUndo": false,
  "canRedo": false,
  "updatedAt": 0,
  "headData": {
    "comment": "string",
    "subAgents": [
      {
        "id": "string",
        "slug": "string",
        "integrationId": "sub_agent",
        "agentId": "string",
        "displayName": "string",
        "description": "string",
        "toolType": "AGENT_TOOL",
        "actionType": "READ_ONLY",
        "resultType": "STRING",
        "authSettings": {
          "supportsOAuth": true,
          "oAuth": []
        },
        "flow": null,
        "parametersMetadata": [],
        "avatarFileId": "string"
      }
    ],
    "flow": {
      "steps": [],
      "edges": []
    },
    "integrationSlots": [
      {
        "id": "00000000-0000-0000-0000-000000000000",
        "integrationId": "string",
        "displayName": "string",
        "tenantConfigId": "00000000-0000-0000-0000-000000000000"
      }
    ],
    "integrationBindings": {},
    "assets": [
      {
        "id": "string"
      }
    ],
    "slots": [
      {
        "name": "string",
        "displayName": "string",
        "requiredKind": "UNSPECIFIED"
      }
    ]
  },
  "history": [
    {
      "seqNo": 0,
      "contentHash": "string",
      "pinned": false,
      "label": "string",
      "createdAt": 0
    }
  ]
}
Empty
Empty
Empty
{
  "type": "string",
  "title": "string",
  "status": 0,
  "detail": "string",
  "instance": "string",
  "property1": null,
  "property2": null
}