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

# Finalize an asset session



## OpenAPI

````yaml https://api.batchrelay.com/openapi.json post /v1/studios/{studio_id}/asset-sessions/{session_id}/finalize
openapi: 3.1.0
info:
  description: >-
    Provider-neutral print catalog and prepared-media validation. This document
    covers only routes owned by the Go service; it deliberately excludes
    migration-proxied order lifecycle routes and all provider payloads.
  license:
    name: Proprietary
    url: https://github.com/SENTINELITE/Batch-Relay-Go/blob/main/README.md
  title: Batch Relay API
  version: 1.0.1
servers:
  - url: https://api.batchrelay.com
security: []
tags:
  - description: Service health and the public API description.
    name: System
  - description: Test Mode session creation and API credential entry points.
    name: Authentication
  - description: >-
      Provider-neutral canonical catalog resources and platform-owned semantic
      definitions.
    name: Catalog
  - description: Studio-scoped guest checkout-link management.
    name: Checkout links
  - description: >-
      One-way operational event messages. Alert emails contain no message body
      and recipients read messages after Batch Relay authentication.
    name: Studio messages
  - description: >-
      Explicit, reviewable sandbox-to-Live promotion plans for forms, catalog,
      and storefront configuration.
    name: Sandbox promotions
  - description: Provider-neutral validation, quoting, and order lifecycle operations.
    name: Print orders
  - description: Managed fulfillment asset ingestion and metadata.
    name: Managed assets
  - description: Studio-scoped original asset upload sessions and objects.
    name: Studio assets
  - description: Prepared and confirmed event roster team changes.
    name: Event team changes
  - description: Authenticated studio, event, and form-management operations.
    name: Studio management
  - description: >-
      Authenticated studio retail catalog management. Draft and publication
      lifecycles are explicit per product or package.
    name: Studio catalog
  - description: >-
      Authenticated singular storefront assortment management. PATCH atomically
      publishes a new immutable assortment revision; no storefront draft
      lifecycle exists yet.
    name: Storefront
  - description: Managed media used by the studio retail catalog.
    name: Studio catalog assets
  - description: Template rendering job creation and retrieval.
    name: Template renders
  - description: >-
      Published browser-side template packages and short-lived server proof
      renders. Preview artifacts are never fulfillment artwork.
    name: Browser previews
  - description: API account and credential administration.
    name: API accounts
paths:
  /v1/studios/{studio_id}/asset-sessions/{session_id}/finalize:
    parameters:
      - $ref: '#/components/parameters/ClientSurface'
      - $ref: '#/components/parameters/ClientVersion'
      - $ref: '#/components/parameters/InvocationMode'
    post:
      tags:
        - Asset sessions
      summary: Finalize an asset session
      operationId: finalizeAssetSession
      parameters:
        - $ref: '#/components/parameters/StudioID'
        - in: path
          name: session_id
          required: true
          schema:
            type: string
        - $ref: '#/components/parameters/IdempotencyKey'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AssetSessionFinalizeRequest'
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AssetSession'
          description: Finalized session
        '503':
          description: Lifecycle unavailable
      security:
        - bearerAuth: []
components:
  parameters:
    ClientSurface:
      description: >-
        Untrusted optional analytics hint naming the calling client surface. It
        never affects authorization, routing, pricing, or behavior.
      in: header
      name: X-BatchRelay-Client-Surface
      required: false
      schema:
        maxLength: 100
        minLength: 1
        type: string
    ClientVersion:
      description: >-
        Untrusted optional analytics hint naming the calling client version. It
        never affects authorization, routing, pricing, or behavior.
      in: header
      name: X-BatchRelay-Client-Version
      required: false
      schema:
        maxLength: 100
        minLength: 1
        type: string
    InvocationMode:
      description: >-
        Untrusted optional analytics hint naming the invocation mode. It never
        affects authorization, routing, pricing, or behavior.
      in: header
      name: X-BatchRelay-Invocation-Mode
      required: false
      schema:
        maxLength: 100
        minLength: 1
        type: string
    StudioID:
      description: >-
        Stable public studio ID beginning with stu_. The API never selects a
        studio implicitly; a local CLI profile name is not a studio ID.
      in: path
      name: studio_id
      required: true
      schema:
        maxLength: 256
        minLength: 5
        pattern: ^stu_[A-Za-z0-9_-]+$
        type: string
    IdempotencyKey:
      in: header
      name: Idempotency-Key
      required: true
      schema:
        maxLength: 200
        minLength: 1
        type: string
  schemas:
    AssetSessionFinalizeRequest:
      additionalProperties: false
      properties:
        expected_revision:
          minimum: 1
          type: integer
      required:
        - expected_revision
      type: object
    AssetSession:
      additionalProperties: false
      properties:
        assets:
          items:
            $ref: '#/components/schemas/AssetSessionAsset'
          type: array
        destination_id:
          type: string
        destination_type:
          type: string
        id:
          type: string
        purpose:
          type: string
        revision:
          description: >-
            Monotonic lifecycle revision used as the expected_session_revision
            concurrency token.
          minimum: 1
          type: integer
        status:
          type: string
      required:
        - id
        - status
        - purpose
        - destination_type
        - destination_id
        - revision
        - assets
      type: object
    AssetSessionAsset:
      additionalProperties: false
      properties:
        alt_text:
          type: string
        asset_id:
          type: string
        byte_count:
          type: integer
        client_local_id:
          type: string
        display_filename:
          type: string
        disposition:
          type: string
        media_type:
          type: string
        pixel_height:
          type: integer
        pixel_width:
          type: integer
        sha256:
          type: string
        status:
          type: string
      required:
        - asset_id
        - client_local_id
        - display_filename
        - media_type
        - byte_count
        - sha256
        - status
        - disposition
      type: object
  securitySchemes:
    bearerAuth:
      bearerFormat: Batch Relay API key or anonymous session
      description: >-
        Batch Relay scoped API key or an anonymous Test Mode session. Scope
        names document required capabilities. Anonymous sessions are
        sandbox-only and do not authorize studio, event, billing, or Live Mode
        operations.
      scheme: bearer
      type: http

````