> ## Documentation Index
> Fetch the complete documentation index at: https://fal.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Sign file URL

> 
Creates a signed URL that grants temporary access to a fal CDN file,
regardless of its ACL. Useful for sharing access-restricted files.

The signature is valid for `expiration_seconds` (up to 7 days).

**Authentication:** Required. The API key must have the `assets:read` permission.
    



## OpenAPI

````yaml /api-reference/platform-apis/openapi/v1.json post /storage/files/sign
openapi: 3.1.0
info:
  title: Platform APIs
  version: v1
  description: fal REST API for programmatic access to platform resources.
servers:
  - url: https://api.fal.ai/v1
    description: Production server
security: []
paths:
  /storage/files/sign:
    post:
      tags:
        - Storage
      summary: Sign file URL
      description: >-

        Creates a signed URL that grants temporary access to a fal CDN file,

        regardless of its ACL. Useful for sharing access-restricted files.


        The signature is valid for `expiration_seconds` (up to 7 days).


        **Authentication:** Required. The API key must have the `assets:read`
        permission.
            
      operationId: signStorageFileUrl
      parameters:
        - schema:
            type: string
            format: uri
            description: >-
              Full URL of the fal CDN file, as returned by the upload APIs
              (https://v3.fal.media/files/b/<id>/<filename>). Must not contain
              query parameters.
            example: https://v3.fal.media/files/b/0a1b2c3d/output.png
          required: true
          description: >-
            Full URL of the fal CDN file, as returned by the upload APIs
            (https://v3.fal.media/files/b/<id>/<filename>). Must not contain
            query parameters.
          name: url
          in: query
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                expiration_seconds:
                  type: integer
                  minimum: 1
                  maximum: 604800
                  description: How long the signed URL stays valid, in seconds (max 7 days)
                  example: 3600
              required:
                - expiration_seconds
              additionalProperties: false
              description: Signing options for the file URL
            example:
              expiration_seconds: 3600
      responses:
        '200':
          description: Signed URL granting temporary access
          content:
            application/json:
              schema:
                type: object
                properties:
                  signed_url:
                    type: string
                    description: URL with an embedded signature granting temporary access
                    example: >-
                      https://v3.fal.media/files/b/0a1b2c3d/output.png?identity=...
                required:
                  - signed_url
                description: Signed URL response
              example:
                signed_url: https://v3.fal.media/files/b/0a1b2c3d/output.png?identity=...
        '400':
          description: Invalid request parameters
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      type:
                        type: string
                        enum:
                          - authorization_error
                          - validation_error
                          - not_found
                          - rate_limited
                          - server_error
                          - not_implemented
                        description: The category of error that occurred
                      message:
                        type: string
                        description: Human-readable error message
                      docs_url:
                        type: string
                        format: uri
                        description: Link to relevant documentation
                      request_id:
                        type: string
                        description: Unique request identifier for debugging
                    required:
                      - type
                      - message
                    description: Error details
                required:
                  - error
                description: Standard error response format
              example:
                error:
                  type: validation_error
                  message: Invalid request parameters
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      type:
                        type: string
                        enum:
                          - authorization_error
                          - validation_error
                          - not_found
                          - rate_limited
                          - server_error
                          - not_implemented
                        description: The category of error that occurred
                      message:
                        type: string
                        description: Human-readable error message
                      docs_url:
                        type: string
                        format: uri
                        description: Link to relevant documentation
                      request_id:
                        type: string
                        description: Unique request identifier for debugging
                    required:
                      - type
                      - message
                    description: Error details
                required:
                  - error
                description: Standard error response format
              example:
                error:
                  type: authorization_error
                  message: Authentication required
        '403':
          description: Access denied
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      type:
                        type: string
                        enum:
                          - authorization_error
                          - validation_error
                          - not_found
                          - rate_limited
                          - server_error
                          - not_implemented
                        description: The category of error that occurred
                      message:
                        type: string
                        description: Human-readable error message
                      docs_url:
                        type: string
                        format: uri
                        description: Link to relevant documentation
                      request_id:
                        type: string
                        description: Unique request identifier for debugging
                    required:
                      - type
                      - message
                    description: Error details
                required:
                  - error
                description: Standard error response format
              example:
                error:
                  type: authorization_error
                  message: Access denied
        '404':
          description: Resource not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      type:
                        type: string
                        enum:
                          - authorization_error
                          - validation_error
                          - not_found
                          - rate_limited
                          - server_error
                          - not_implemented
                        description: The category of error that occurred
                      message:
                        type: string
                        description: Human-readable error message
                      docs_url:
                        type: string
                        format: uri
                        description: Link to relevant documentation
                      request_id:
                        type: string
                        description: Unique request identifier for debugging
                    required:
                      - type
                      - message
                    description: Error details
                required:
                  - error
                description: Standard error response format
              example:
                error:
                  type: not_found
                  message: Resource not found
        '429':
          description: Rate limit exceeded
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      type:
                        type: string
                        enum:
                          - authorization_error
                          - validation_error
                          - not_found
                          - rate_limited
                          - server_error
                          - not_implemented
                        description: The category of error that occurred
                      message:
                        type: string
                        description: Human-readable error message
                      docs_url:
                        type: string
                        format: uri
                        description: Link to relevant documentation
                      request_id:
                        type: string
                        description: Unique request identifier for debugging
                    required:
                      - type
                      - message
                    description: Error details
                required:
                  - error
                description: Standard error response format
              example:
                error:
                  type: rate_limited
                  message: Rate limit exceeded
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      type:
                        type: string
                        enum:
                          - authorization_error
                          - validation_error
                          - not_found
                          - rate_limited
                          - server_error
                          - not_implemented
                        description: The category of error that occurred
                      message:
                        type: string
                        description: Human-readable error message
                      docs_url:
                        type: string
                        format: uri
                        description: Link to relevant documentation
                      request_id:
                        type: string
                        description: Unique request identifier for debugging
                    required:
                      - type
                      - message
                    description: Error details
                required:
                  - error
                description: Standard error response format
              example:
                error:
                  type: server_error
                  message: An unexpected error occurred
      security:
        - apiKey: []
components:
  securitySchemes:
    apiKey:
      type: apiKey
      in: header
      name: Authorization
      description: >-
        API key must be prefixed with "Key ", e.g. Authorization: Key
        YOUR_API_KEY

````