> ## 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.

# Pobieranie wielu rekordów

> Przypadki pomocy publicznej i pomocy de minimis udzielonej beneficjentowi o podanym NIP, z bazy SUDOP (UOKiK). Każdy wpis zawiera dzień udzielenia pomocy, podmiot udzielający, formę, przeznaczenie, podstawę prawną, sektor PKD oraz wartości pomocy (nominalna PLN, brutto PLN, brutto EUR). Zakres dat zawęża się parametrami `from`/`to` (dzień udzielenia pomocy), sortowanie parametrem `order` (`desc`/`asc`), paginacja `limit`/`offset`. Dane pochodzą z systemu SUDOP i są aktualizowane codziennie; za ich kompletność i prawidłowość odpowiadają wyłącznie podmioty udzielające pomocy. Każdy zwrócony wynik = 1 jednostka puli **MSiG i KRZ**.



## OpenAPI

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

    krdata udostępnia dane z polskich rejestrów gospodarczych (KRS, CRBR, KRZ,
    MSiG, RDF, biała lista VAT)

    w postaci jednego, spójnego API.


    Uwierzytelnianie odbywa się przez klucz API przekazywany w nagłówku
    `x-api-key`.

    Limity zapytań oraz pule (RDF, PDF, WPV, raporty) wynikają z wybranego
    abonamentu —

    szczegóły zwraca endpoint `GET /v1/usage/summary`.
  version: 0.1.0
servers:
  - url: https://api.krdata.pl
    description: Production
security: []
paths:
  /v1/sudop/records:
    get:
      tags:
        - SUDOP
      summary: Pobieranie wielu rekordów
      description: >-
        Przypadki pomocy publicznej i pomocy de minimis udzielonej
        beneficjentowi o podanym NIP, z bazy SUDOP (UOKiK). Każdy wpis zawiera
        dzień udzielenia pomocy, podmiot udzielający, formę, przeznaczenie,
        podstawę prawną, sektor PKD oraz wartości pomocy (nominalna PLN, brutto
        PLN, brutto EUR). Zakres dat zawęża się parametrami `from`/`to` (dzień
        udzielenia pomocy), sortowanie parametrem `order` (`desc`/`asc`),
        paginacja `limit`/`offset`. Dane pochodzą z systemu SUDOP i są
        aktualizowane codziennie; za ich kompletność i prawidłowość odpowiadają
        wyłącznie podmioty udzielające pomocy. Każdy zwrócony wynik = 1
        jednostka puli **MSiG i KRZ**.
      operationId: sudop-records
      parameters:
        - name: nip
          in: query
          required: true
          schema:
            type: string
            description: Beneficiary NIP (10 digits)
            title: Nip
          description: Beneficiary NIP (10 digits)
        - name: from
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date
              - type: 'null'
            title: From
        - name: to
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date
              - type: 'null'
            title: To
        - name: order
          in: query
          required: false
          schema:
            enum:
              - desc
              - asc
            type: string
            default: desc
            title: Order
        - name: limit
          in: query
          required: false
          schema:
            type: integer
            maximum: 100
            minimum: 1
            default: 20
            title: Limit
        - name: offset
          in: query
          required: false
          schema:
            type: integer
            minimum: 0
            default: 0
            title: Offset
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SudopRecordsPage'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - APIKeyHeader: []
components:
  schemas:
    SudopRecordsPage:
      properties:
        items:
          items:
            $ref: '#/components/schemas/SudopRecordItem'
          type: array
          title: Items
        limit:
          type: integer
          title: Limit
        offset:
          type: integer
          title: Offset
        has_more:
          type: boolean
          title: Has More
      type: object
      required:
        - items
        - limit
        - offset
        - has_more
      title: SudopRecordsPage
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    SudopRecordItem:
      properties:
        id:
          type: integer
          title: Id
        granted_at:
          type: string
          format: date
          title: Granted At
        beneficiary_nip:
          anyOf:
            - type: string
            - type: 'null'
          title: Beneficiary Nip
        beneficiary_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Beneficiary Name
        beneficiary_size_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Beneficiary Size Code
        beneficiary_size_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Beneficiary Size Name
        provider_nip:
          anyOf:
            - type: string
            - type: 'null'
          title: Provider Nip
        provider_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Provider Name
        aid_measure:
          anyOf:
            - type: string
            - type: 'null'
          title: Aid Measure
        aid_measure_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Aid Measure Name
        symbol_aktu:
          anyOf:
            - type: string
            - type: 'null'
          title: Symbol Aktu
        basis_2a_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Basis 2A Code
        basis_2a_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Basis 2A Name
        basis_2b:
          anyOf:
            - type: string
            - type: 'null'
          title: Basis 2B
        basis_2c:
          anyOf:
            - type: string
            - type: 'null'
          title: Basis 2C
        basis_3a:
          anyOf:
            - type: string
            - type: 'null'
          title: Basis 3A
        basis_3b:
          anyOf:
            - type: string
            - type: 'null'
          title: Basis 3B
        nace_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Nace Code
        nace_version:
          anyOf:
            - type: string
            - type: 'null'
          title: Nace Version
        nace_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Nace Name
        gmina_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Gmina Code
        gmina_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Gmina Name
        purpose_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Purpose Code
        purpose_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Purpose Name
        form_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Form Code
        form_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Form Name
        nominal_pln:
          anyOf:
            - type: string
              pattern: ^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$
            - type: 'null'
          title: Nominal Pln
        gross_pln:
          anyOf:
            - type: string
              pattern: ^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$
            - type: 'null'
          title: Gross Pln
        gross_eur:
          anyOf:
            - type: string
              pattern: ^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$
            - type: 'null'
          title: Gross Eur
      type: object
      required:
        - id
        - granted_at
      title: SudopRecordItem
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    APIKeyHeader:
      type: apiKey
      in: header
      name: x-api-key

````