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

# Get usage and limits

> Return current API usage, allowance state, and request limits for the authenticated API key.



## OpenAPI

````yaml /api-reference/openapi.json get /usage
openapi: 3.1.0
info:
  title: Osintly API
  version: 1.0.0
  description: OpenAPI specification for the Osintly API service.
  contact:
    name: Osintly
    url: https://docs.osint.ly/api-reference/quick-start
servers:
  - url: https://api.osint.ly
    description: Production
security: []
tags:
  - name: System
    description: Health and service checks
  - name: Auth
    description: Authorization validation
  - name: Search
    description: Create, monitor and retrieve search results
  - name: Usage
    description: Rate limit and usage information
  - name: Radar
    description: Breach intelligence endpoints (free with API key)
  - name: Webhooks
    description: Webhook callback payloads configured from search creation
paths:
  /usage:
    get:
      tags:
        - Usage
      summary: Get usage and limits
      description: >-
        Return current API usage, allowance state, and request limits for the
        authenticated API key.
      operationId: getUsage
      responses:
        '200':
          description: Usage limits
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UsageSuccessResponse'
              examples:
                limits:
                  value:
                    success: true
                    message: Usage limits fetched
                    limits:
                      allowed: true
                      limits:
                        global:
                          used: 12
                          max: 500
                        daily:
                          used: 2
                          max: 50
                    code: 200
        '401':
          $ref: '#/components/responses/UnauthorizedError'
        '500':
          description: Usage retrieval error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UsageErrorResponse'
      security:
        - bearerAuth: []
components:
  schemas:
    UsageSuccessResponse:
      type: object
      required:
        - success
        - message
        - limits
        - code
      properties:
        success:
          type: boolean
          enum:
            - true
        message:
          type: string
          enum:
            - Usage limits fetched
        limits:
          $ref: '#/components/schemas/CheckLimitsResult'
        code:
          type: integer
          enum:
            - 200
    UsageErrorResponse:
      type: object
      required:
        - success
        - message
        - error
      properties:
        success:
          type: boolean
          enum:
            - false
        message:
          type: string
          enum:
            - An error occurred while fetching usage limits
        error:
          type: object
          required:
            - message
          properties:
            message:
              type: string
    CheckLimitsResult:
      type: object
      required:
        - allowed
        - limits
      properties:
        allowed:
          type: boolean
        limits:
          anyOf:
            - $ref: '#/components/schemas/UsageLimits'
            - type: 'null'
    BasicErrorResponse:
      type: object
      required:
        - success
        - message
      properties:
        success:
          type: boolean
          enum:
            - false
        message:
          type: string
      additionalProperties: true
    UsageLimits:
      type: object
      required:
        - global
        - daily
      properties:
        global:
          $ref: '#/components/schemas/LimitWindow'
        daily:
          $ref: '#/components/schemas/LimitWindow'
    LimitWindow:
      type: object
      required:
        - used
        - max
      properties:
        used:
          type:
            - integer
            - 'null'
        max:
          type:
            - integer
            - 'null'
  responses:
    UnauthorizedError:
      description: Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/BasicErrorResponse'
          examples:
            unauthorized:
              value:
                success: false
                message: Unauthorized
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API Key

````