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

# Create a new project



## OpenAPI

````yaml /api-reference/earnie/projects-openapi.json post /v1/projects
openapi: 3.0.3
info:
  title: Earnie Projects API
  description: List, create, read, and update projects.
  version: 1.0.0
servers:
  - url: https://{tenant}.earnie.dev
    description: Your Earnie deployment
    variables:
      tenant:
        default: your-company
        description: >-
          Your organization's Earnie address, as shown in your browser when you
          sign in.
security:
  - bearerAuth: []
paths:
  /v1/projects:
    post:
      tags:
        - projects
      summary: Create a new project
      operationId: PostV1Projects
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateProjectRequest'
      responses:
        '201':
          description: Project created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Project'
        '401':
          description: Not authenticated
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '409':
          description: Duplicate slug or name
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '422':
          description: Invalid slug format or other validation error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    CreateProjectRequest:
      type: object
      required:
        - slug
        - name
      properties:
        slug:
          type: string
          description: Must match ^[a-z0-9-]+$, 1..64 characters. Immutable after creation.
        name:
          type: string
          minLength: 1
          maxLength: 128
        description:
          type: string
          maxLength: 1024
    Project:
      type: object
      required:
        - id
        - org_id
        - slug
        - name
        - is_default
        - created_at
        - updated_at
      properties:
        id:
          type: string
          format: uuid
        org_id:
          type: string
          format: uuid
        slug:
          type: string
          description: Immutable. Must match ^[a-z0-9-]+$, 1..64 characters.
        name:
          type: string
          description: Mutable. 1..128 characters.
        description:
          type: string
          nullable: true
        is_default:
          type: boolean
        archived_at:
          type: string
          format: date-time
          nullable: true
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
        created_by:
          type: string
          format: uuid
          nullable: true
        repo_full_name:
          type: string
          nullable: true
          description: >-
            The bound source repository's path on its provider when the project
            was imported from one. Null for projects without a source binding.
        repo_provider:
          type: string
          nullable: true
          description: >-
            The provider of the bound repository, such as github or gitlab. Null
            for projects without a source binding.
        repo_connection_id:
          type: string
          format: uuid
          nullable: true
          description: >-
            The connection the bound repository is reached through; null when
            unbound or when that connection was disconnected.
    Error:
      type: object
      required:
        - code
        - message
      properties:
        code:
          type: string
        message:
          type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        An Earnie API key, sent as `Authorization: Bearer sk_earnie_...`. Create
        one under Settings > API keys. The key's scopes decide which operations
        it may call.

````

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