API requests are counted based on the number of downstream API calls and webhook events.
So requests to Unify will trigger requests to integrations, and each request to the integration will be counted as usage.
Let's take the example when using a CRM integration.
Typically when you make a request to get a list of "opportunities", we hit the endpoint of the integration that provides the index of all deals.
GET https://unify.apideck.com/crm/opportunities
|-> GET https://api.pipedrive.com/v1/deals
So generally that means 1 Unify request, will result in 1 API request towards the integration.
This can vary per integration since some integrations will require multiple API requests to the integration to provide 1 Unify response, while other integrations return all the data in 1 API request.
GET https://unify.apideck.com/crm/opportunities
|-> GET https://api.hubapi.com/crm/v3/objects/deals
|-> GET https://api.hubapi.com/crm/v3/properties/deals
In the example above, there is 1 Unify integration request that results in 2 requests to Hubspot. They are counted as 2 usage requests.
Some integrations, provide limited numbers of fields on their "List" endpoints.
To still provide more relevant data, we enrich responses with additional data.
Let's take an HRIS example.
There will be more HRIS integrations that will not return all employee data (employment details, compensations, bank accounts, ...) on the “List employees”, but these will be enriched on the “Get employee” response.
GET https://unify.apideck.com/hris/employee/12345
|-> GET https://charliehr.com/api/v1/bank_accounts/...
|-> GET https://charliehr.com/api/v1/company
|-> GET https://charliehr.com/api/v1/team_members/.../salaries
|-> GET https://charliehr.com/api/v1/team_members/...
|-> GET https://charliehr.com/api/v1/offices/..
|-> GET https://charliehr.com/api/v1/team_members/...
In the example above, there is 1 Unify integration request that results in 6 requests to Charlie. They are counted as 6 usage requests to get the employee:
Bank account info
Company info
Employee salary info
Manager info
Office info
Employee details
For Vault, we only count the API calls needed to create sessions.
As you look at the screenshot below, you will see that there are 2 POST /vault/sessions
and the other requests are Vault GET requests.
The Vault request counter on top shows 2, which are only the 2 POST /vault/sessions