🇺🇸 => 🇪🇺
A script to copy the latest published automations US instance of Courier to the EU instance of Courier and mutate automation content as needed.
Run every time an automation is changed in US.
Make sure you have node
installed and run yarn
.
cp .env.example .env
- Log into both the Courier US and EU instances.
- Open the network tab and inspect any XHR request to
api{.eu}.courier.com/studio/q?=
and copy theauthorization
value (JWT) - Paste these values into their respective
US_AUTHORIZATION
andEU_AUTHORIZATION
environment keys. - Copy the
tenant_id
query param from the request and use in theTENANT_ID
environment key.
$ node index.js <environment>
environment
must equal test
or production
. By default it will run in test
The US_AUTHORIZATION
or EU_AUTHORIZATION
values are stale. Repeat setup steps 3-4 and try again.