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

# Claim a project as its original creator

> Signed in to Patch as yourself, not with an API key (403 `session_required`). A project whose `original_creator` hasn't claimed it can be claimed by them; Patch knows them by their GitHub account, so a Patch account with no GitHub linked gets 422 `github_required` (link it in Settings, Account). When a GitHub account linked to yours is the one Patch recorded, the claim is approved at once (200): the project moves to your own account, keeping its slug, or the next free one there (`project.slug_changed`), and its old address keeps leading to it. Otherwise the claim waits for Patch's staff (202), and needs `evidence` (422 `evidence_required`): a link that shows it's yours, or a few words. Asking again while it waits replaces the evidence. A project with no original creator answers 409 `no_original_creator`, one already claimed 409 `already_claimed`, and one on an account you're in 409 `already_yours`. You need a username first (422 `username_required`).



## OpenAPI

````yaml /api-reference/openapi.json post /projects/{owner}/{slug}/claim
openapi: 3.1.0
info:
  title: Patch API
  version: 1.0.0
  description: >-
    The public API behind patch.gg, the desktop app and pch. Changes within v1
    are additive only. Errors are { error: { code, message, details } }; branch
    on code.
servers:
  - url: https://patch.gg/api/v1
security: []
paths:
  /projects/{owner}/{slug}/claim:
    post:
      tags:
        - Projects
      summary: Claim a project as its original creator
      description: >-
        Signed in to Patch as yourself, not with an API key (403
        `session_required`). A project whose `original_creator` hasn't claimed
        it can be claimed by them; Patch knows them by their GitHub account, so
        a Patch account with no GitHub linked gets 422 `github_required` (link
        it in Settings, Account). When a GitHub account linked to yours is the
        one Patch recorded, the claim is approved at once (200): the project
        moves to your own account, keeping its slug, or the next free one there
        (`project.slug_changed`), and its old address keeps leading to it.
        Otherwise the claim waits for Patch's staff (202), and needs `evidence`
        (422 `evidence_required`): a link that shows it's yours, or a few words.
        Asking again while it waits replaces the evidence. A project with no
        original creator answers 409 `no_original_creator`, one already claimed
        409 `already_claimed`, and one on an account you're in 409
        `already_yours`. You need a username first (422 `username_required`).
      parameters:
        - schema:
            type: string
            example: patch
          required: true
          name: owner
          in: path
        - schema:
            type: string
            example: demo-mod
          required: true
          name: slug
          in: path
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                evidence:
                  type: string
                  maxLength: 2000
                  description: >-
                    What shows it's yours, for staff: a link (the original's
                    page or repo naming you) or a few words. Not needed when
                    your GitHub account is the one recorded.
                  example: https://github.com/mira/lantern
      responses:
        '200':
          description: 'It''s yours: the project is on your account now'
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - approved
                  claim:
                    $ref: '#/components/schemas/ProjectClaim'
                  project:
                    type: object
                    properties:
                      owner:
                        type: string
                      slug:
                        type: string
                      handle:
                        type: string
                        example: mira/lantern
                      slug_changed:
                        type: boolean
                        description: >-
                          Your account already had a project at that slug, so it
                          took the next free one
                    required:
                      - owner
                      - slug
                      - handle
                      - slug_changed
                  old_handle:
                    type: string
                    description: Where it was, which keeps leading to it
                    example: patch/lantern
                required:
                  - status
                  - claim
                  - project
                  - old_handle
        '202':
          description: Your claim waits for Patch's staff
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - pending
                  claim:
                    $ref: '#/components/schemas/ProjectClaim'
                required:
                  - status
                  - claim
        '308':
          description: Renamed or moved; follow the Location header
        '400':
          description: Invalid request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: Not signed in
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: Not allowed
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '409':
          description: Nothing to claim, or already claimed
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '422':
          description: GitHub, evidence or a username needed
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      security:
        - bearer: []
components:
  schemas:
    ProjectClaim:
      type: object
      properties:
        id:
          type: string
          format: uuid
        status:
          type: string
          enum:
            - pending
            - approved
            - rejected
        evidence:
          type:
            - string
            - 'null'
        github_login:
          type:
            - string
            - 'null'
          description: The GitHub account it was made with, when Patch knows its login
        reviewed_at:
          type:
            - string
            - 'null'
        created_at:
          type: string
      required:
        - id
        - status
        - evidence
        - github_login
        - reviewed_at
        - created_at
    Error:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
              example: version_exists
            message:
              type: string
            details: {}
          required:
            - code
            - message
      required:
        - error
  securitySchemes:
    bearer:
      type: http
      scheme: bearer
      description: An API key (pch_...) or the token from pch login.

````

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