Your plugin will receive a code from the parent window through the postMessage API. You can use this code to exchange for an access token for a specific entity.
POST
/plugins/{pluginId}/entities/{entityId}/exchange-code
curl \
--request POST 'https://tadatodo.com/api/plugins/{pluginId}/entities/{entityId}/exchange-code' \
--header "X-Plugin-Secret: $API_KEY" \
--data '{"code":"12345678901234567890123456789012"}'
Request examples
{
"code": "12345678901234567890123456789012"
}
Response examples (200)
{
"userToken": "string"
}