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

# /v1/teams/{teamId}

> This endpoint retrieves information about a specific team by its ID.

> [!NOTE]
>
> `applicationsCount` and `databaseInstancesCount` are only returned by the team list, not by this endpoint.


## OpenAPI

````yaml GET /v1/teams/{teamId}
openapi: 3.1.0
info:
  title: CamposCloud API Documentation
  description: >-
    This documentation provides an overview of the CamposCloud API, including
    authentication, endpoints, and data structures. It is designed to help
    developers integrate with the CamposCloud platform effectively.
  version: 1.0.0
servers:
  - url: https://api.camposcloud.com
security:
  - bearerAuth: []
paths:
  /v1/teams/{teamId}:
    get:
      tags:
        - Teams
      description: Returns a team you own or are a member of.
      parameters:
        - name: teamId
          in: path
          required: true
          description: ID of the team to retrieve
          schema:
            type: string
      responses:
        '200':
          description: The team.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TeamDetails'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          description: >-
            Team not found, or you are neither the owner nor a member of the
            team.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                error: Team not found or you are not a member of this team.
        '429':
          $ref: '#/components/responses/TooManyRequests'
        '500':
          $ref: '#/components/responses/InternalError'
components:
  schemas:
    TeamDetails:
      type: object
      description: >-
        A single team. Unlike the list, the owner includes its current
        subscription and the application/database counters are not returned.
      properties:
        _id:
          type: string
          description: The unique identifier of the team.
          example: '000000000000000000000003'
        name:
          type: string
          description: The name of the team.
          example: My Team
        owner:
          type: object
          description: The user who owns the team.
          properties:
            _id:
              type: string
              description: The unique identifier of the user.
              example: '000000000000000000000002'
            name:
              type: string
              description: The name of the user.
              example: John Doe
            email:
              type: string
              description: The e-mail address of the user.
              example: user@example.com
            currentSubscription:
              $ref: '#/components/schemas/TeamOwnerSubscription'
              description: >-
                Plan and resources of the owner, without billing values. Absent
                when the owner has no plan.
        members:
          type: array
          description: Members of the team. The owner is not part of this list.
          items:
            $ref: '#/components/schemas/TeamMemberPopulated'
        invites:
          type: array
          description: Pending invites.
          items:
            $ref: '#/components/schemas/TeamInvite'
        createdAt:
          type: string
          format: date-time
          description: When the team was created.
          example: '2025-01-01T12:00:00.000Z'
        updatedAt:
          type: string
          format: date-time
          description: When the team was last updated.
          example: '2025-01-01T12:00:00.000Z'
        __v:
          type: integer
          description: Internal document version.
          example: 0
    Error:
      type: object
      description: >-
        Every error returned by the API has this shape. The message can be in
        English or in Portuguese depending on the endpoint.
      required:
        - error
      properties:
        error:
          type: string
          description: Human readable description of the error.
          example: Application not found.
    TeamOwnerSubscription:
      type: object
      description: >-
        Plan and resources of the team owner. Billing values (amount paid,
        negotiated price) are not included.
      properties:
        planReference:
          $ref: '#/components/schemas/Plan'
          description: The subscribed plan.
        allocatedMemoryMB:
          type: integer
          description: >-
            Memory available to the account, in MB. Only on `customized` and
            `business` plans.
          example: 2048
        allocatedVCpus:
          type: number
          description: vCPUs given to each application. Only on `customized` plans.
        status:
          type: string
          description: Status of the subscription.
          example: active
          enum:
            - active
            - pending_cleanup
            - grace_period
        startAt:
          type: string
          format: date-time
          description: When the current period started.
          example: '2025-01-01T12:00:00.000Z'
        endAt:
          type: string
          format: date-time
          description: When the current period ends.
          example: '2025-01-01T12:00:00.000Z'
    TeamMemberPopulated:
      type: object
      properties:
        _id:
          type: string
          description: The unique identifier of the membership entry.
          example: '000000000000000000000006'
        user:
          $ref: '#/components/schemas/TeamUser'
          description: >-
            The member. `user._id` is the `memberId` used by the member
            endpoints.
        permissions:
          $ref: '#/components/schemas/TeamPermissions'
    TeamInvite:
      type: object
      description: >-
        A pending invite. The invite code is never returned by the API; it is
        only sent to the invited e-mail address.
      properties:
        _id:
          type: string
          description: The unique identifier of the invite.
          example: '000000000000000000000006'
        email:
          type: string
          description: E-mail address that was invited.
          example: invited@example.com
        userId:
          type: string
          description: ID of the invited user.
          example: '000000000000000000000005'
        invitedAt:
          type: string
          format: date-time
          description: When the invite e-mail was last sent.
          example: '2025-01-01T12:00:00.000Z'
        permissions:
          $ref: '#/components/schemas/TeamPermissions'
          description: Permissions the user receives when accepting the invite.
        subscriptionEndsAt:
          type: string
          format: date-time
          description: >-
            When the invite expires (2 days after it was created). Expired
            invites are removed automatically.
          example: '2025-01-01T12:00:00.000Z'
    Plan:
      type: object
      description: A CamposCloud plan.
      properties:
        _id:
          type: string
          description: Identifier of the plan.
          example: plan-id
        name:
          type: string
          description: Name of the plan.
          example: Standard
        type:
          type: string
          description: Type of the plan.
          example: standard
          enum:
            - free
            - standard
            - customized
            - business
        enabled:
          type: boolean
          description: Whether the plan can currently be purchased.
          example: true
        description:
          type: string
          description: Description of the plan.
          example: Plan description
        color:
          type: string
          description: Display color of the plan.
          example: '#000000'
        ramMB:
          type: integer
          description: Memory included in the plan, in MB. Only on `standard` plans.
          example: 1024
        planPrice:
          type: number
          description: Price of the plan. Only on `standard` plans.
        allocatedVCpu:
          type: number
          description: >-
            vCPUs given to each application. Only on `standard` and `business`
            plans.
          example: 2
        minRamMB:
          type: integer
          description: Minimum purchasable memory, in MB. Only on `business` plans.
        maxRamMB:
          type: integer
          description: Maximum purchasable memory, in MB. Only on `business` plans.
        pricePerGB:
          type: number
          description: Price per GB of memory. Only on `business` plans.
        createdAt:
          type: string
          format: date-time
          description: When the plan was created.
          example: '2025-01-01T12:00:00.000Z'
        updatedAt:
          type: string
          format: date-time
          description: When the plan was last updated.
          example: '2025-01-01T12:00:00.000Z'
    TeamUser:
      type: object
      properties:
        _id:
          type: string
          description: The unique identifier of the user.
          example: '000000000000000000000002'
        name:
          type: string
          description: The name of the user.
          example: John Doe
        email:
          type: string
          description: The e-mail address of the user.
          example: user@example.com
    TeamPermissions:
      type: object
      description: >-
        What a team member is allowed to do. The team owner always has every
        permission.
      properties:
        canCreateApplication:
          type: boolean
          description: Create applications in the team.
        canDeleteApplication:
          type: boolean
          description: Delete applications of the team.
        canUpdateApplicationSettings:
          type: boolean
          description: Update the settings of applications of the team.
        canChangeStatusApplication:
          type: boolean
          description: Start, stop and restart applications of the team.
        canManageApplicationBackup:
          type: boolean
          description: Manage backups of applications of the team.
        canEditApplicationFiles:
          type: boolean
          description: Upload and edit files of applications of the team.
        canSeeApplicationFiles:
          type: boolean
          description: List, read and download files of applications of the team.
        canDeleteApplicationFiles:
          type: boolean
          description: Delete files of applications of the team.
        canCreateDatabase:
          type: boolean
          description: Create databases in the team.
        canDeleteDatabase:
          type: boolean
          description: Delete databases of the team.
        canUpdateDatabaseSettings:
          type: boolean
          description: Update the settings of databases of the team.
        canChangeStatusDatabase:
          type: boolean
          description: Start, stop and restart databases of the team.
      example:
        canCreateApplication: false
        canDeleteApplication: false
        canUpdateApplicationSettings: false
        canChangeStatusApplication: true
        canManageApplicationBackup: false
        canEditApplicationFiles: true
        canSeeApplicationFiles: true
        canDeleteApplicationFiles: false
        canCreateDatabase: false
        canDeleteDatabase: false
        canUpdateDatabaseSettings: false
        canChangeStatusDatabase: false
  responses:
    Unauthorized:
      description: >-
        The `Authorization` header is missing or malformed, or the API token is
        invalid.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            error: Invalid developer token
    TooManyRequests:
      description: >-
        A rate limit was exceeded. See the `RateLimit-*` and `Retry-After`
        response headers.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            error: Too many requests, please try again later
    InternalError:
      description: >-
        Unexpected error. On endpoints that do not document a `400` for it, this
        is also returned when an ID in the URL is not a valid identifier.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            error: Internal server error. Please try again later.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: 'Your CamposCloud API token, sent as `Authorization: Bearer <token>`.'

````

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