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

# Count annual reports

> Returns the number of remaining annual report IDs.

Use this endpoint to estimate how many records a sync will process before starting. For example, you can use it to show a progress bar, build structured logs, or decide whether to run a full sync or a targeted one.

It accepts the same filters as [List annual reports](/ruz/api-reference/identifier-lists/list-annual-reports) and returns a single count. It is not required for pagination.

***

## Common patterns

<AccordionGroup>
  <Accordion title="Log the number of remaining records">
    Fetch the count before starting a sync to know how many records you'll process.

    ```js Counting annual reports theme={null}
    // 1. Fetch the count of remaining annual reports
    const { pocetZostavajucichId } = await fetch(
      `/api/zostavajuce-id/vyrocne-spravy?zmenene-od=2025-01-01`
    ).then(r => r.json());

    // 2. Log the number of remaining records
    console.log(`${pocetZostavajucichId} records to process`);
    ```
  </Accordion>
</AccordionGroup>


## OpenAPI

````yaml ruz/openapi.json GET /api/zostavajuce-id/vyrocne-spravy
openapi: 3.1.0
info:
  title: RÚZ API
  description: >-
    Public REST API for Slovakia's Register of Financial Statements (Register
    účtovných závierok). Exposes accounting units, financial statements,
    financial reports, and annual reports in JSON. Data is updated throughout
    the day as records are published.
  version: 2.5.0
  license:
    name: Creative Commons Zero (CC0)
    url: https://creativecommons.org/publicdomain/zero/1.0/
servers:
  - url: https://www.registeruz.sk/cruz-public
    description: Production
security: []
paths:
  /api/zostavajuce-id/vyrocne-spravy:
    get:
      summary: Count annual reports
      description: >-
        Returns the number of remaining annual report IDs matching the given
        filters. Useful for progress tracking — not required for pagination.
      operationId: countRemainingAnnualReports
      parameters:
        - $ref: '#/components/parameters/zmeneneOd'
        - $ref: '#/components/parameters/pokracuvatZaId'
      responses:
        '200':
          description: Remaining count returned successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RemainingCountResponse'
components:
  parameters:
    zmeneneOd:
      name: zmenene-od
      in: query
      required: true
      description: >-
        Return IDs changed on or after this date. Accepts `YYYY-MM-DD` or
        `YYYY-MM-DDThh:mm:ssZ`.
      schema:
        type: string
        example: '2000-01-01'
    pokracuvatZaId:
      name: pokracovat-za-id
      in: query
      description: Pagination cursor. Pass the last `id` from the previous response.
      schema:
        type: integer
  schemas:
    RemainingCountResponse:
      type: object
      description: Count of remaining IDs matching the given filters.
      properties:
        pocetZostavajucichId:
          type: integer
          description: Number of remaining IDs.

````