---
title: Conventions
summary: Base URL, the response envelope, pagination and scopes.
group: Get started
order: 30
---

## Base URL

Every call goes to one base URL for the environment you were given:

```
https://{apiId}.execute-api.us-west-1.amazonaws.com/{stage}
```

Replace `{apiId}` and `{stage}` with the values for your environment (staging or live).

## Response envelope

Successful and handled-error responses use the same envelope:

```json
{ "status": 200, "message": "success", "data": { } }
```

`status` mirrors the HTTP status code; `data` is `null` on errors.

## Scopes

Access is gated per route by a `module:action` scope the token must carry — for example `users:read` for the users endpoints. A token without the required scope gets `403`. Scopes are granted to the credential in SequiPay Core. See [Authentication](/guides/authentication.md).

## Pagination

List endpoints are paginated. Pass `page` and `per_page` as query parameters; the `data` object carries the page of results alongside the page counters:

```json
{
  "current_page": 1,
  "per_page": 20,
  "total": 42,
  "last_page": 3
}
```

Request the next page by incrementing `page` until `current_page` reaches `last_page`.

## Filtering

Many list endpoints accept filter query parameters (for example by status or by a related id). Each endpoint page in the reference lists the filters it supports.

See [Errors and retries](/guides/errors.md) for the status codes and when to retry.
