Upload Translations Manually
Learn how to manually upload translation tables per Flow via the Appcues API.
Table of Contents
This article describes how to manually upload translation tables per flow via the Appcues API.
Get your auth token
- Log into studio.appcues.com.
- Open the JavaScript console (Cmd-Shift-J on Mac, Ctrl-Shift-J elsewhere).
- Enter the following command and hit Return:
await window.apc_auth.getCurrentCustomToken()
- The command will return a very long character string, enclosed in quotes. Copy the contents (not the quotes). This is your auth token. As an example:
ABC.123.XYZ
Get your account ID
You can find your account ID on the Account Settings page: https://studio.appcues.com/settings/account
We'll use 12345 as an example.
Get your flow ID
You can find the flow ID from the flow's URL in studio.appcues.com. We'll use https://studio.appcues.com/journeys/-L9876543210 as an example URL, making our flow ID -L9876543210.
Prepare your translations
We'll use the example filename translations.json. This API endpoint accepts uploads in either CSV and JSON format.
Upload files to the Appcues translation upload endpoint
Using all the example values mentioned previously, here is an example of an upload request, using the curl command-line HTTP client (installed by default on Mac, widely available):
curl -X POST -v \
-F file=@translations.json \
-H 'Authorization: Bearer ABC.123.XYZ' \
https://customer-api-main.prod.us-west-2.aws.appcues.net/v1/accounts/12345/flows/-L9876543210/translations
On success, the API will return a 200 OK status code, also returning the uploaded and parsed translation in the response.