Skip to main content
POST
Attach files to a running session

Authorizations

Authorization
string
header
required

A Recursion API key, created in the console under API keys.

Path Parameters

session_id
string<uuid>
required

Session id (UUID) as returned by startSession or listSessions.

Body

application/json

Request body for attaching files to a running session. The files are staged into the sandbox on the session's next tool call and are visible to the agent from its next turn.

resources
object[] | null

Files to attach. All-or-nothing: one unknown file_id or one path collision refuses the whole batch and attaches nothing.

Required array length: 1 - 500 elements

Response

Response body of GET and POST /v1/sessions/{session_id}/resources. A POST returns only the resources it attached.

Response body of GET and POST /v1/sessions/{session_id}/resources. A POST returns only the resources it attached.

resources
object[] | null
required

Every file attached to the session, in attachment order, each with its sandbox path once staged.