Quickstart

Get your credentials and make your first request to the Easyflow API in a few minutes.

On this page

The Easyflow API is a REST API served over HTTPS. Requests and responses use JSON, and every request is authenticated with credentials that you generate in the Easyflow platform.

1. Get your credentials

Sign in to the Easyflow platform and open the Integrations tab. Copy the two credentials shown there:

Credential Header Purpose
API key x-api-key Identifies your integration.
API secret x-api-secret Proves that the request was sent by you.

Some endpoints also need the identifier of the business you are working with, sent in the business-id header. The Headers section of each endpoint in the API reference says whether it is required, and the Authentication guide explains how it works.

Keep your API secret on your server. Never expose it in browsers, mobile apps or public repositories.

2. Make your first request

Every endpoint is relative to the base URL of the API:

https://9iq81tsdy4.execute-api.sa-east-1.amazonaws.com

A good first call is Get balance, which returns the balance of a business:

curl --request GET \
  --url 'https://9iq81tsdy4.execute-api.sa-east-1.amazonaws.com/business/balance' \
  --header 'x-api-key: YOUR_API_KEY' \
  --header 'x-api-secret: YOUR_API_SECRET' \
  --header 'business-id: YOUR_BUSINESS_ID'

The same request in JavaScript:

const response = await fetch('https://9iq81tsdy4.execute-api.sa-east-1.amazonaws.com/business/balance', {
  headers: {
    'x-api-key': process.env.EASYFLOW_API_KEY,
    'x-api-secret': process.env.EASYFLOW_API_SECRET,
    'business-id': process.env.EASYFLOW_BUSINESS_ID,
  },
});

const { data } = await response.json();
console.log(data.totalFundsInCents);

3. Read the response

A successful request returns the HTTP status 200 and a JSON body with the result inside data:

{
  "statusCode": 200,
  "data": {
    "accountFundsInCents": 67673,
    "toBeReleasedFundsInCents": 79906,
    "lastTimeBalanceWasCalculated": "2025-02-17T21:13:32.241Z",
    "totalFundsInCents": 147579,
    "blockedFundsInCents": 0
  }
}

Amounts are always integers in cents, so 67673 means R$ 676.73. The Requests and responses guide covers this and the other conventions of the API.

Next steps