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

# Postman collection

> Download a ready-to-run Postman collection covering every endpoint, login flow included.

We maintain a Postman collection that covers the whole API, including authentication, with variables already wired up. Import it instead of copy-pasting curl commands.

<CardGroup cols={2}>
  <Card title="Download the collection" icon="file-arrow-down">
    `NoyaxApi.postman_collection.json` — every module in its own folder, authentication included.

    <a href="/postman/NoyaxApi.postman_collection.json" download>Start download ↓</a>
  </Card>

  <Card title="Download the environment" icon="gear">
    `NoyaxApi.postman_environment.json` — the same variables as a separate Postman Environment.

    <a href="/postman/NoyaxApi.postman_environment.json" download>Start download ↓</a>
  </Card>
</CardGroup>

<Steps>
  <Step title="Import">
    In Postman, click **Import** and select both files (the environment is optional — the collection already carries its own variables).
  </Step>

  <Step title="Fill in the variables">
    In the collection's **Variables** tab (or the environment, if you imported it), set:

    | Variable    | Description                                              |
    | ----------- | -------------------------------------------------------- |
    | `orgName`   | Your organization name                                   |
    | `apiKey`    | Your API key                                             |
    | `userId`    | Noyax user ID, sent as `X-UserID`                        |
    | `companyId` | Company ID, sent as `X-CompanyID`                        |
    | `periodId`  | Only needed for accounting tables; leave empty otherwise |

    `baseUrl` and `authBaseUrl` are set to the dev environment; change them if you're targeting a different one.
  </Step>

  <Step title="Run Login">
    Send the **Auth → Login** request. The access/refresh tokens from the response are saved automatically into the `accessToken`/`refreshToken` variables (the request's **Tests** script does this).
  </Step>

  <Step title="Run any other request">
    Every request in the collection inherits Bearer authentication from the collection level using `accessToken`, and the `X-UserID`/`X-CompanyID` headers already use the `userId`/`companyId` variables. Nothing else to configure.

    When the access token expires, run **Auth → Refresh token** instead of logging in again.
  </Step>
</Steps>

## What's in it

The collection is compiled from the same OpenAPI definition that generates this documentation, so it matches the API's real endpoints, fields and example values, and stays current with each release. `POST`/`PUT` bodies are filled with realistic example data; `PATCH` requests intentionally include only a couple of fields to illustrate partial update (see [Partial update](/en/v1/guides/partial-update)).

<Note>
  The collection's modules follow the same grouping as this documentation: Customers, Products, Definitions, Stock, Quotes, Orders, Despatches, Invoices, Finance.
</Note>
