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

# Licznik puli żądań API

> Stan puli w bieżącym okresie rozliczeniowym: jednostki w cenie planu, zużycie, nadwyżka i jej koszt, limit wydatków oraz łączna dopuszczalna liczba jednostek. `document_units` to koszt jednego dokumentu (PDF, sprawozdanie RDF). Nie zużywa jednostek.



## OpenAPI

````yaml /openapi.json get /v1/usage/api
openapi: 3.1.0
info:
  title: krdata API
  description: >

    krdata udostępnia dane z polskich rejestrów gospodarczych (KRS, CRBR, KRZ,
    MSiG, BZP, RDF, KNF, UOKiK, SUDOP,

    biała lista VAT) w postaci jednego, spójnego API.


    Uwierzytelnianie odbywa się przez klucz API w nagłówku `x-api-key`. Płatne
    endpointy zużywają jednostki

    z jednej puli; koszt każdego z nich podany jest w jego opisie, a zasady w
    sekcji Rozliczanie.

    Bieżący stan puli zwraca `GET /v1/usage/api`.
  version: 0.1.0
servers:
  - url: https://api.krdata.pl
    description: Production
security: []
paths:
  /v1/usage/api:
    get:
      tags:
        - Usage
      summary: Licznik puli żądań API
      description: >-
        Stan puli w bieżącym okresie rozliczeniowym: jednostki w cenie planu,
        zużycie, nadwyżka i jej koszt, limit wydatków oraz łączna dopuszczalna
        liczba jednostek. `document_units` to koszt jednego dokumentu (PDF,
        sprawozdanie RDF). Nie zużywa jednostek.
      operationId: usage-api
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiMeter'
      security:
        - APIKeyHeader: []
components:
  schemas:
    ApiMeter:
      properties:
        period_start:
          type: string
          format: date-time
          title: Period Start
        period_end:
          type: string
          format: date-time
          title: Period End
        included:
          anyOf:
            - type: integer
            - type: 'null'
          title: Included
        used:
          type: integer
          title: Used
        overage_units:
          type: integer
          title: Overage Units
        overage_grosz:
          type: integer
          title: Overage Grosz
        unit_grosz:
          type: integer
          title: Unit Grosz
        document_units:
          type: integer
          title: Document Units
        trial:
          type: boolean
          title: Trial
        trial_requests:
          type: integer
          title: Trial Requests
        spend_cap_pln:
          anyOf:
            - type: integer
            - type: 'null'
          title: Spend Cap Pln
        max_overage_pln:
          type: integer
          title: Max Overage Pln
        allowance:
          anyOf:
            - type: integer
            - type: 'null'
          title: Allowance
      type: object
      required:
        - period_start
        - period_end
        - included
        - used
        - overage_units
        - overage_grosz
        - unit_grosz
        - document_units
        - trial
        - trial_requests
        - spend_cap_pln
        - max_overage_pln
        - allowance
      title: ApiMeter
  securitySchemes:
    APIKeyHeader:
      type: apiKey
      in: header
      name: x-api-key

````