Codevisor Docs
Api reference

POST Sessions Id Fork

POST/v1/sessions/{id}/fork

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/v1/sessions/string/fork"
{  "id": "string",  "projectId": "string",  "serverId": "string",  "harnessId": "string",  "harnessAccountId": "string",  "agentSessionId": "string",  "title": "string",  "origin": "codevisor",  "worktreeName": "string",  "workspaceId": "string",  "cwd": "string",  "checkoutId": "string",  "isArchived": true,  "archivedAt": "string",  "isDetached": true,  "configSelections": {    "property1": "string",    "property2": "string"  },  "unavailableConfigSelections": {    "property1": "string",    "property2": "string"  },  "createdAt": "string",  "updatedAt": "string",  "sidebarState": "idle",  "sidebarStateChangedAt": "string",  "usage": {    "used": 0,    "size": 0,    "inputTokens": 0,    "cachedInputTokens": 0,    "outputTokens": 0,    "reasoningOutputTokens": 0,    "totalTokens": 0,    "costAmount": 0,    "costCurrency": "string",    "costKind": "reported"  },  "latestAttentionSequence": 0,  "lastSeenAttentionSequence": 0,  "unreadCount": 0,  "hasUnreadError": true,  "actionRequired": true,  "actionRequiredKind": "question",  "pendingPlanApproval": true,  "lastTurnFailure": "error",  "talkingToAgent": true,  "latestBotMessage": {    "text": "string",    "attachmentNames": [      "string"    ]  },  "createdBy": "agent",  "createdByAgentId": "string",  "createdByAgentMachineId": "string",  "forkedFromAgentId": "string",  "forkedFromAgentMachineId": "string",  "labels": {    "property1": "string",    "property2": "string"  }}
{  "error": "string"}
{  "error": "string"}
{  "error": "string"}
{  "error": "string"}
{  "error": "string"}
{  "error": "string"}