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

# Add a party to a project

> Links a legal entity to a project with a role: `controller`, `operator` or `sub_operator`. An operator of a project whose controller is not the tenant waits for the controller's approval.



## OpenAPI

````yaml openapi/en/control.json POST /v1/projects/{project_id}/parties
openapi: 3.1.0
info:
  title: Niadra control API
  version: '1'
  description: >-
    Tenants, projects, sources, keys, people, configuration and usage. It never
    receives customer content.
servers:
  - url: https://control.api.niadra.com
security: []
paths:
  /v1/projects/{project_id}/parties:
    post:
      tags:
        - accounts
      summary: Add a party to a project
      description: >-
        409 `controller_approval_required` for an operator of a project whose
        controller is not the tenant,

        until the controller approves `add:<role>:<entity id>`.


        **Authentication.** Person token issued by the control plane
        (`Authorization: Bearer <JWT>`), with the role the operation needs.
      operationId: add_party_v1_projects__project_id__parties_post
      parameters:
        - in: path
          name: project_id
          required: true
          schema:
            format: uuid
            title: Project Id
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PartyCreate'
        required: true
      responses:
        '201':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Party'
          description: Successful Response
        '422':
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Problem'
          description: The request does not match the contract.
      security:
        - personToken: []
components:
  schemas:
    PartyCreate:
      additionalProperties: false
      properties:
        entity_id:
          format: uuid
          title: Entity Id
          type: string
        role:
          enum:
            - controller
            - operator
            - sub_operator
          title: Role
          type: string
        tenant_id:
          anyOf:
            - format: uuid
              type: string
            - type: 'null'
          description: The tenant through which the party uses the Console, if it does.
          title: Tenant Id
      required:
        - entity_id
        - role
      title: PartyCreate
      type: object
    Party:
      additionalProperties: false
      properties:
        entity_id:
          format: uuid
          title: Entity Id
          type: string
        entity_name:
          title: Entity Name
          type: string
        party_id:
          format: uuid
          title: Party Id
          type: string
        role:
          enum:
            - controller
            - operator
            - sub_operator
          title: Role
          type: string
        since:
          format: date-time
          title: Since
          type: string
        status:
          enum:
            - active
            - ended
          title: Status
          type: string
        tenant_id:
          anyOf:
            - format: uuid
              type: string
            - type: 'null'
          title: Tenant Id
        until:
          anyOf:
            - format: date-time
              type: string
            - type: 'null'
          title: Until
      required:
        - party_id
        - entity_id
        - entity_name
        - role
        - since
        - status
      title: Party
      type: object
    Problem:
      additionalProperties: false
      description: RFC 9457 problem details; `code` comes from the versioned error catalog.
      properties:
        code:
          title: Code
          type: string
        detail:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          title: Detail
        request_id:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          title: Request Id
        status:
          title: Status
          type: integer
        title:
          title: Title
          type: string
        type:
          default: about:blank
          title: Type
          type: string
      required:
        - title
        - status
        - code
      title: Problem
      type: object
  securitySchemes:
    personToken:
      type: http
      scheme: bearer
      bearerFormat: JWT

````