NOTE: This information is only relevant if you're a Typeform Enterprise customer with the EU Responses Data Center enabled.
As part of the EU Data Center for Responses feature, the Typeform API will now be reachable from both api.typeform.com
(for US accounts) and api.eu.typeform.com
(for EU accounts).
Most APIs will continue working in the same way as before, but the Responses API as well as any other that handles or returns Responses data (be it raw, aggregated, or processed in any other way) will not return any results when queried in a region different than what the account has configured. For example, querying a form’s responses in the US for an EU account will return empty results.
In order for Applications to continue working properly for EU accounts, they will need to interact with the correct API domain for each account.
For example, an Integration querying the Responses API to list the responses collected by a form owned by an EU account will need to use api.eu.typeform.com
.
You can keep the same token scopes, as no changes are needed. You can just take a look at the public documentation to understand the scopes that you need.
Some APIs, such as the Accounts, Workspaces, and Forms APIs, can be used on both api.typeform.com
and api.eu.typeform.com
and the result that we’ll get is the same.
In order to determine which API domain to use, we need to find the Responses Data Center region of the account.
To get the API address for a form, we need query /forms/<formID>
, extracting the _links.responses
property.
We can then use the provided URL or extract the domain to use it for another purpose. This domain will include the account region already in place.
# us: "api.typeform.com"
# eu: "api.eu.typeform.com"
# To get the form's responses URL with the proper domain.
RESPONSES_URL=$(curl --request GET \
--url 'https://api.typeform.com/forms/{form_id}' \
--header 'authorization: bearer {your_access_token}' \
| jq '._links.responses')
# We can extract the responses URL from the response body
# it's in form._links.responses
# and then query the responses!
curl --request GET \
--url ${RESPONSES_URL} \
--header 'authorization: bearer {your_access_token}'
If we want to use webhooks or applications connected to Typeform, we’ll need to make the same request as we saw above and extract the domain from the returned responses URL. Webhooks and applications are using responses, so we need to use the proper Responses Data Center URL to make them work.
There are no changes required for the authorization, the OAuth authorization endpoint remains the same: https://api.typeform.com/oauth/authorize
. Both OAuth tokens and Personal Access Tokens are valid for calls to both regions.