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

# PublicApiGetApiUsage

> GET /api/v1/organizations/{orgId}/teams/api-usage

Use this endpoint through the Developer API or the matching `firstsales` CLI command when available. Responses use the stable FirstSales public error envelope.


## OpenAPI

````yaml GET /api/v1/organizations/{orgId}/teams/api-usage
openapi: 3.1.0
info:
  title: FirstSales Developer API
  version: 1.0.0
  description: >-
    Public v1 developer API for FirstSales.io. Generated from live step
    definitions — do not hand-edit.
servers:
  - url: https://sandbox.api.app.firstsales.io
  - url: https://api.app.firstsales.io
security:
  - bearerAuth: []
tags:
  - name: Activities
  - name: Alerts
  - name: API Keys
  - name: Authentication
  - name: Billing
  - name: Campaigns
  - name: Companies
  - name: Connectors
  - name: Contacts
  - name: Copilot
  - name: Dashboard
  - name: Deals
  - name: Email Authentication
  - name: Inbox
  - name: Knowledge Bases
  - name: Learning
  - name: Offerings
  - name: Organizations
  - name: Sequence Library
  - name: Team
  - name: Tracking Domains
  - name: Warmup
paths:
  /api/v1/organizations/{orgId}/teams/api-usage:
    get:
      tags:
        - API Keys
      summary: PublicApiGetApiUsage
      operationId: getApiUsage
      parameters:
        - name: orgId
          in: path
          required: true
          schema:
            type: string
            minLength: 1
        - name: days
          in: query
          required: false
          schema:
            type: integer
            minimum: 1
            maximum: 90
            default: 7
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiUsageResponse'
        '400':
          description: Public API error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicErrorEnvelope'
        '401':
          description: Public API error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicErrorEnvelope'
        '403':
          description: Public API error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicErrorEnvelope'
        '429':
          description: Public API error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicErrorEnvelope'
        '500':
          description: Public API error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicErrorEnvelope'
        default:
          description: Error response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicErrorEnvelope'
      security:
        - developerKeyBearer: []
components:
  schemas:
    ApiUsageResponse:
      type: object
      properties:
        windowDays:
          type: integer
          minimum: 1
          maximum: 90
        totalRequests:
          type: integer
          minimum: 0
          maximum: 9007199254740991
        errorRate:
          type: number
          minimum: 0
          maximum: 1
        byKey:
          maxItems: 20
          type: array
          items:
            type: object
            properties:
              apiKeyId:
                type: string
                minLength: 24
                maxLength: 24
                pattern: ^[a-f\d]{24}$
              keyPrefix:
                type: string
                minLength: 15
                maxLength: 15
                pattern: ^fs-key-[A-Za-z0-9_-]{8}$
              requests:
                type: integer
                minimum: 0
                maximum: 9007199254740991
              errors:
                type: integer
                minimum: 0
                maximum: 9007199254740991
            required:
              - apiKeyId
              - keyPrefix
              - requests
              - errors
            additionalProperties: false
        byRoute:
          maxItems: 20
          type: array
          items:
            type: object
            properties:
              routePattern:
                type: string
                maxLength: 200
                pattern: >-
                  ^(?![A-Za-z0-9_{}:/.-]{0,200}fs-key-)\/api\/v1\/(?:[a-z0-9-]+|\{[A-Za-z][A-Za-z0-9]*\})(?:\/(?:[a-z0-9-]+|\{[A-Za-z][A-Za-z0-9]*\}))*$
              requests:
                type: integer
                minimum: 0
                maximum: 9007199254740991
              errors:
                type: integer
                minimum: 0
                maximum: 9007199254740991
            required:
              - routePattern
              - requests
              - errors
            additionalProperties: false
      required:
        - windowDays
        - totalRequests
        - errorRate
        - byKey
        - byRoute
      additionalProperties: false
    PublicErrorEnvelope:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
            message:
              type: string
            requestId:
              type: string
            details:
              type: object
              additionalProperties: true
          required:
            - code
            - message
            - requestId
      required:
        - error
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: Legacy compatibility bearer scheme for generated consumers.
    developerKeyBearer:
      type: http
      scheme: bearer
      description: FirstSales developer API key bearer token (fs-key-*).

````