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

# Create Team

> Create a team with its wallet and an optional opening credit.

The team is created with no members, as the admin UI does; use
`POST /admin/teams/{team_id}/members` to add them.



## OpenAPI

````yaml https://api.primeintellect.ai/openapi.json post /api/admin/teams
openapi: 3.1.0
info:
  title: PI API
  version: 0.1.0
servers:
  - url: https://api.primeintellect.ai
security: []
paths:
  /api/admin/teams:
    post:
      tags:
        - admin-teams
      summary: Create Team
      description: |-
        Create a team with its wallet and an optional opening credit.

        The team is created with no members, as the admin UI does; use
        `POST /admin/teams/{team_id}/members` to add them.
      operationId: create_team_api_admin_teams_post
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateTeamRequest'
      responses:
        '201':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GenericResponse_TeamDetailResponse_'
        '401':
          description: Authorization failed
        '403':
          description: Insufficient permissions
        '422':
          description: Invalid request data
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - HTTPBearer: []
components:
  schemas:
    CreateTeamRequest:
      properties:
        name:
          type: string
          minLength: 1
          title: Name
        email:
          type: string
          format: email
          title: Email
        slug:
          anyOf:
            - type: string
              maxLength: 30
              minLength: 3
              pattern: ^[a-z0-9]+(-[a-z0-9]+)*$
            - type: 'null'
          title: Slug
        bio:
          anyOf:
            - type: string
            - type: 'null'
          title: Bio
        url:
          anyOf:
            - type: string
            - type: 'null'
          title: Url
        logo:
          anyOf:
            - type: string
            - type: 'null'
          title: Logo
        amount:
          anyOf:
            - type: integer
              maximum: 9223372036854776000
              minimum: 0
            - type: 'null'
          title: Amount
      additionalProperties: false
      type: object
      required:
        - name
        - email
      title: CreateTeamRequest
      description: >-
        Admin creation of a team.


        ``email`` is marked verified on creation, as the admin UI does — an
        admin

        entering it is the verification. ``logo`` is a URL, not an upload: the
        web UI

        stores an image and passes the resulting URL, and the CLI has nowhere to

        upload from.


        ``amount`` is an opening credit in stored units (USD * 10000), matching

        ``AdminTopupRequest``. It is written as a TOPUP transaction so the
        balance

        has a ledger entry behind it rather than appearing from nowhere.


        The team is created with no members; the admin UI does the same. Use

        ``teams add-member`` afterwards.
    GenericResponse_TeamDetailResponse_:
      properties:
        data:
          anyOf:
            - $ref: '#/components/schemas/TeamDetailResponse'
            - type: 'null'
          description: Response data
        status:
          anyOf:
            - type: string
            - type: 'null'
          title: Status
          description: Response status
      type: object
      title: GenericResponse[TeamDetailResponse]
    ErrorResponse:
      properties:
        errors:
          items:
            $ref: '#/components/schemas/ErrorDetail'
          type: array
          title: Errors
      type: object
      required:
        - errors
      title: ErrorResponse
    TeamDetailResponse:
      properties:
        id:
          type: string
          title: Id
        name:
          type: string
          title: Name
        slug:
          anyOf:
            - type: string
            - type: 'null'
          title: Slug
        email:
          anyOf:
            - type: string
            - type: 'null'
          title: Email
        emailVerified:
          type: boolean
          title: Emailverified
          default: false
        allowedEmailDomain:
          anyOf:
            - type: string
            - type: 'null'
          title: Allowedemaildomain
        logo:
          anyOf:
            - type: string
            - type: 'null'
          title: Logo
        bio:
          anyOf:
            - type: string
            - type: 'null'
          title: Bio
        url:
          anyOf:
            - type: string
            - type: 'null'
          title: Url
        hasBetaAccess:
          type: boolean
          title: Hasbetaaccess
          default: false
        defaultEnvironmentVisibility:
          anyOf:
            - type: string
            - type: 'null'
          title: Defaultenvironmentvisibility
        createdAt:
          type: string
          format: date-time
          title: Createdat
        updatedAt:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Updatedat
      type: object
      required:
        - id
        - name
        - createdAt
      title: TeamDetailResponse
      description: DB details for a single team.
    ErrorDetail:
      properties:
        param:
          type: string
          title: Param
        details:
          type: string
          title: Details
      type: object
      required:
        - param
        - details
      title: ErrorDetail
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````