Skip to content
  • Auto
  • Light
  • Dark
DiscordForumGitHubSign up
View as Markdown
Copy Markdown

Open in Claude
Open in ChatGPT

Close File For Agent

patch/v1/agents/{agent_id}/files/{file_id}/close

Closes a specific file for a given agent.

This endpoint marks a specific file as closed in the agent's file state. The file will be removed from the agent's working memory view.

Path ParametersExpand Collapse
agent_id: string

The ID of the agent in the format 'agent-'

minLength42
maxLength42
file_id: string

The ID of the file in the format 'file-'

minLength41
maxLength41
Close File For Agent
curl https://api.letta.com/v1/agents/$AGENT_ID/files/$FILE_ID/close \
    -X PATCH \
    -H "Authorization: Bearer $LETTA_API_KEY"
{}
Returns Examples
{}