1. Files
The Delegation
  • Documentation
    • Getting started
    • TypeScript client
    • Python client
    • Go client
    • Operations and observability
  • AI Gateway
    • Chat
      • Create a chat completion
    • Embeddings
      • Create text embeddings
    • Audio
      • Transcribe audio with AWS Transcribe
      • Text-to-speech
    • Images
      • Generate images with Gemini
    • Models
      • List available models
      • Retrieve a model
    • Users
      • List all users
      • Create a user
      • Get a user
      • Delete a user
      • Get user usage and cost summary
    • Health
      • Liveness / readiness probe
      • Provider health check
      • Gateway info
    • Admin
      • Per-provider request metrics
      • List configured providers
    • Schemas
      • ContentPartText
      • ContentPartImageURL
      • ContentPartAudio
      • ContentPartVideo
      • ContentPartDocument
      • ContentPart
      • FunctionDef
      • Tool
      • ToolCall
      • ChatMessage
      • ChatRequest
      • Usage
      • Choice
      • ChatResponse
      • EmbeddingsRequest
      • EmbeddingObject
      • EmbeddingsResponse
      • TranscriptionResponse
      • TTSRequest
      • ImageGenerationRequest
      • ImageData
      • ImageGenerationResponse
      • ModelInfo
      • ModelList
      • UsageRecord
      • User
      • UserUsageSummary
      • ProviderHealth
      • HealthResponse
      • ProviderMetrics
      • MetricsResponse
      • ErrorDetail
      • ErrorResponse
  • Platform API
    • Projects
      • List projects
      • Create project
      • Get project
      • Update project
      • Delete project
    • Tasks
      • Create task
      • Get task
      • Update task
    • Conversations
      • Get conversation
      • Clear conversation
      • Send message
    • Keys
      • Gateway usage statistics
    • Account
      • Get account
      • Update account role
      • Delete account
    • Schemas
      • Error
      • ChatMessage
      • ToolDefinition
      • ToolCall
      • ChatCompletionRequest
      • ChatCompletionResponse
      • EmbeddingRequest
      • ImageGenRequest
      • Project
      • Task
      • Message
      • Conversation
      • UserFile
      • GatewayKey
      • User
      • UserBalance
      • AuthSession
      • Session
  • File Service
    • Files
      • List files
        GET
      • Upload file
        POST
      • Update file
        PATCH
      • Delete / trash file
        DELETE
      • Restore file from trash
        POST
    • Schemas
      • Error
      • ChatMessage
      • ToolDefinition
      • ToolCall
      • ChatCompletionRequest
      • ChatCompletionResponse
      • EmbeddingRequest
      • ImageGenRequest
      • Project
      • Task
      • Message
      • Conversation
      • UserFile
      • GatewayKey
      • User
      • UserBalance
      • AuthSession
      • Session
  1. Files

List files

GET
/api/user-files
Returns active files. Add ?trash=1 to list soft-deleted files.

Request

Authorization
JWT Bearer
Add the parameter
Authorization
to Headers
Example:
Authorization: ********************
or
Query Params

Responses

🟢200
application/json
File array.
Bodyapplication/json

🟠401Unauthorized
Request Request Example
Shell
JavaScript
Java
Swift
curl --location '/api/user-files?trash=' \
--header 'Authorization: Bearer <token>'
Response Response Example
200 - Example 1
[
    {
        "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
        "display_name": "string",
        "mime_type": "string",
        "size_bytes": 0,
        "is_public": true,
        "url": "http://example.com",
        "storage_key": "string",
        "deleted_at": "2019-08-24T14:15:22.123Z",
        "created_at": "2019-08-24T14:15:22.123Z"
    }
]
Modified at 2026-10-20 19:18:40
Previous
Session
Next
Upload file
Built with