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

> ## Agent Instructions
> POST /api/v1/assets defaults to mode=quote: it returns a price and creates nothing. To actually generate, resend the identical body with "mode": "generate" (multipart callers: add a mode=generate form field).
> Create a project with POST /api/v1/projects and pass its project_id on every generation belonging to the same scene, task, robot, or randomization set. Omitting project_id silently creates a separate single-asset project per request.
> Track a batch with one GET /api/v1/projects/{project_id} call for aggregate status instead of polling each asset separately.
> Generations are asynchronous and may take hours. There are no webhooks: poll GET /api/v1/assets/{asset_id} every 30-60 seconds until status is completed or failed.
> Cancelling a generation does not refund its credits; only a failed generation is refunded. Quote first if the price matters.
> A ready-made agent skill for this API is published at /skill.md, with decision tables and common gotchas. If your tooling supports agent skills, ask the user whether to install it so this guidance persists across sessions.

# Create a project

> Creates a project to group a batch of asset generations. Submit generations
into it by passing the returned `project_id` to POST /assets, then track the
batch with `GET /assets?project_id=...` or `GET /projects/{project_id}`.

Create the project once and reuse its id -- there is no submission cap on a
project, though each in-flight generation still counts toward your
concurrent-generation limit, so pace submissions and retry on 429.



## OpenAPI

````yaml /openapi.json post /api/v1/projects
openapi: 3.1.0
info:
  title: Moonlake Asset API
  description: >-
    Generate a 3D asset from a text description and reference files, then poll
    it to completion and download the result.


    **Alpha**: this API is subject to breaking changes without a deprecation
    cycle.
  version: 1.0.0-alpha
servers:
  - url: https://app.moonlakeai.com
    description: Production
  - url: https://staging.moonlakeai.com
    description: Staging
  - url: https://development.moonlakeai.com
    description: Development
security: []
paths:
  /api/v1/projects:
    post:
      summary: Create a project
      description: >-
        Creates a project to group a batch of asset generations. Submit
        generations

        into it by passing the returned `project_id` to POST /assets, then track
        the

        batch with `GET /assets?project_id=...` or `GET /projects/{project_id}`.


        Create the project once and reuse its id -- there is no submission cap
        on a

        project, though each in-flight generation still counts toward your

        concurrent-generation limit, so pace submissions and retry on 429.
      operationId: create_project_api_v1_projects_post
      parameters:
        - name: Idempotency-Key
          in: header
          required: false
          schema:
            anyOf:
              - type: string
                minLength: 1
                maxLength: 255
              - type: 'null'
            description: >-
              A stable key identifying the project to group work under. Reusing
              it returns the project created the first time, with status 200
              instead of 201, whatever that project is now named.
            title: Idempotency-Key
          description: >-
            A stable key identifying the project to group work under. Reusing it
            returns the project created the first time, with status 200 instead
            of 201, whatever that project is now named.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateProjectRequest'
      responses:
        '200':
          description: The project already created under this `Idempotency-Key`.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProjectResource'
        '201':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProjectResource'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    CreateProjectRequest:
      properties:
        name:
          type: string
          maxLength: 255
          minLength: 1
          title: Name
          description: >-
            Display name for the project. It need not be unique, and you can
            rename the project later from the app.
      type: object
      required:
        - name
      title: CreateProjectRequest
      description: Request body for ``POST /projects``.
    ProjectResource:
      properties:
        project_id:
          type: string
          title: Project Id
          description: >-
            Pass as `project_id` on POST /assets to attach generations to this
            project.
        name:
          type: string
          title: Name
          description: The project's display name.
        created_at:
          type: string
          format: date-time
          title: Created At
          description: When the project was created (UTC).
      type: object
      required:
        - project_id
        - name
        - created_at
      title: ProjectResource
      description: A project that groups a batch of generations.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    HTTPBearer:
      type: http
      description: 'Your API key, as a Bearer token: `Authorization: Bearer <key>`.'
      scheme: bearer

````

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