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

# Deploy an uploaded source

> Queues the build of an archive uploaded with `POST /api/apps/{app}/deployments/source-uploads`. For a multipart upload, send its `uploadId` and each part's number and ETag to finish it first. The archive is checked as `frogbot share` checks one: a source that can never build (no lockfile, Bun, no FrogBot, not a .tar.gz) answers 422 `invalid_source` and is deleted. Read the build with `GET /api/deployments/{id}/log-lines`.



## OpenAPI

````yaml https://dojo.frogbot.ai/api/openapi.json post /api/apps/{app}/deployments/from-upload
openapi: 3.1.0
info:
  title: Dojo API
  version: '1'
  description: >-
    Everything Dojo's pages do, for scripts and agents. Sign in with an API key
    as `Authorization: Bearer fb_…`. Paying and accepting the terms happen at a
    link a route answers, for a person to open.
servers:
  - url: https://dojo.frogbot.ai
security:
  - apiKey: []
tags:
  - name: Sign-in
  - name: Workspaces
  - name: Projects
  - name: Apps
  - name: Templates
  - name: Sharing
  - name: Deployments
  - name: Environment variables
  - name: Domains
  - name: Data
  - name: Billing
  - name: API keys
paths:
  /api/apps/{app}/deployments/from-upload:
    post:
      tags:
        - Deployments
      summary: Deploy an uploaded source
      description: >-
        Queues the build of an archive uploaded with `POST
        /api/apps/{app}/deployments/source-uploads`. For a multipart upload,
        send its `uploadId` and each part's number and ETag to finish it first.
        The archive is checked as `frogbot share` checks one: a source that can
        never build (no lockfile, Bun, no FrogBot, not a .tar.gz) answers 422
        `invalid_source` and is deleted. Read the build with `GET
        /api/deployments/{id}/log-lines`.
      operationId: post/api/apps/:app/deployments/from-upload
      parameters:
        - name: app
          in: path
          required: true
          description: The app's slug, such as `deals`, or its id.
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                key:
                  type: string
                uploadId:
                  type: string
                parts:
                  type: array
                  items:
                    type: object
                    properties:
                      partNumber:
                        type: integer
                      etag:
                        type: string
                    required:
                      - partNumber
                      - etag
                data:
                  anyOf:
                    - type: boolean
                    - type: string
                      enum:
                        - replace
                  description: >-
                    `true` on a first deploy that brings its database (uploaded
                    with the data upload routes); `replace`, from an owner,
                    swaps the live data for the one uploaded with `replace:
                    true`.
              required:
                - key
      responses:
        '201':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  deploymentId:
                    type: string
                    description: A document id.
                required:
                  - deploymentId
        '400':
          description: '`invalid_request`'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Errors'
        '401':
          description: '`unauthorized`'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Errors'
        '402':
          description: '`payment_required`'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Errors'
        '403':
          description: '`forbidden`'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Errors'
        '404':
          description: '`not_found`'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Errors'
        '409':
          description: '`conflict`'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Errors'
        '413':
          description: '`too_large`'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Errors'
        '422':
          description: '`invalid_source`'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Errors'
        '429':
          description: '`rate_limited`'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Errors'
components:
  schemas:
    Errors:
      type: object
      required:
        - errors
      properties:
        errors:
          type: array
          items:
            type: object
            required:
              - message
            properties:
              message:
                type: string
              data:
                type: object
                properties:
                  code:
                    type: string
                  url:
                    type: string
                    description: Where a person takes the next step, such as paying.
  securitySchemes:
    apiKey:
      type: http
      scheme: bearer
      description: >-
        An API key from `frogbot deploy`'s sign-in, `/api/cli/device/token`, or
        the API keys page.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.