Skip to main content

Postman collection

Every endpoint in this reference, as an importable collection.

Download the collection · Download the environment

Import it​

  1. In Postman, Import → drop in LeadX.postman_collection.json.
  2. Import LeadX.postman_environment.json too, and select it in the environment picker.
  3. Set apikey to a key from POST /api, or from Settings → API keys in the LeadX web app.
  4. Send GET /lead. A 200 with a data array means you are connected.

baseUrl defaults to https://api.leadx.in. Point it somewhere else to run the same collection against another environment.

How it is organised​

Folders mirror this reference — CRM, Engagement, AI, Automation, Integrations, Analytics & logs, Account, Billing — and each request is named for its method and path, so a collection-wide search for /lead/:id finds it.

Each request arrives with:

  • the apikey header wired to the collection variable;
  • path parameters as Postman variables, so :id is a named field rather than a URL you have to edit;
  • a request body prefilled with each field's own default, taken from the controller — empty where it declares none;
  • query parameters added but disabled. List endpoints carry the full p / n / sortBy / sortOrder / searchBy / searchValue / filters / advancedFilters / ids / nids set. Enable the ones you need; see Pagination and Filtering;
  • a description naming what comes back, which fields are required, and every error that endpoint can raise.

:::note The /api/private folder needs a JWT, not a key Those requests send Authorization: Bearer {{jwt}} instead of apikey. An API key cannot reach them — see API keys. :::

Keeping it current​

The collection is generated from leadx-api's router by npm run postman, in the same pass that rebuilds this reference (npm run docs:refresh). It is never edited by hand, so it cannot drift from the API — but a collection you have already imported does not update itself. Re-import after an API change.

:::warning Requests here hit whatever baseUrl points at Bodies are prefilled to make sending easy, and the write endpoints really do write. Point baseUrl at a non-production environment before running anything destructive — DELETE /lead with selectAll: true deletes the company's leads. :::