I'm getting an unhandled rejection restApi::ApiNotConfiguredError thrown inside t.getRestApi() and not sure why, because I am pretty sure I configured it properly.
Simplified version of my code, in an attachment-sections iframe:
var trelloAuth = { appKey: "...", appName: "..." };var t = TrelloPowerUp.iframe(trelloAuth);var Promise = TrelloPowerUp.Promise;t.render(render);function render() { return t.getRestApi() // Unhandled rejection error happens here // tried adding a catch() here, no effect .isAuthorized() .then(function(authorized) { if (authorized) { return loadAndRender(t); } else { // display auth } });}
And the error I get is:
Unhandled rejection restApi::ApiNotConfiguredError: To use the API helper, make sure you specify appKey and appName when you call TrelloPowerUp.iframe. See more at https://developers.trello.com/v1.0/reference#rest-api at uo.getRestApi (https://p.trellocdn.com/power-up.min.js:1:131807) at render (https://data-entry-trello.s3.amazonaws.com/trello-data-entry-xr/attachment-section.js:64:14) at https://p.trellocdn.com/power-up.min.js:1:131226 at A (https://p.trellocdn.com/power-up.min.js:1:11735) at C._settlePromiseFromHandler (https://p.trellocdn.com/power-up.min.js:1:58719) at C._settlePromiseAt (https://p.trellocdn.com/power-up.min.js:1:59992) at C._settlePromiseAtPostResolution (https://p.trellocdn.com/power-up.min.js:1:54662) at Q._drainQueue (https://p.trellocdn.com/power-up.min.js:1:18865) at Q._drainQueues (https://p.trellocdn.com/power-up.min.js:1:18943) at Q.drainQueues (https://p.trellocdn.com/power-up.min.js:1:17242)
Any ideas what can cause this? I'm pretty sure I'm setting up everything correctly.
You can see the full version of the code at https://data-entry-trello.s3.amazonaws.com/trello-data-entry-xr/attachment-section.js - nothing really fancy going on!
Hi Jess,
Thanks for reaching out!
This would be a really great question to share in our developer community. We have a number of Trello Engineers that are active there, and they'd be happy to give some guidance for more advanced topics like these.
https://community.developer.atlassian.com/c/trello
All the best,
LaraThe Trello Team
Oops, I didn't realize they were separate forums! I will move over there. Thanks!
It looks like you're new here. Sign in or register to get started.