2

i have a simple web server, trying to use the npm-package 'express-stormpath' for basic user registration.

everything works fine locally - but consistently getting this error when i deploy to Heroku:

 Error: apiKey.id is required.
 2015-10-23T00:23:52.603692+00:00 app[web.1]:     at new RequestExecutor           (/app/node_modules/express-stormpath/node_modules/stormpath/lib/ds/RequestExecutor.js:26:37)

i have tried every possible way i can find on the internet to configure this: 1) entirely environment vars, as laid out in https://docs.stormpath.com/nodejs/express/latest/configuration.html#environment-variables

2) a small, private config file in ./stormfront as laid out here : 'apiKey.id is required' error thrown when using express-stormpath with node.js

3) i've tried the following method, manually creating the apiKey object:

https://github.com/stormpath/express-stormpath/issues/135

and nothing works on heroku. any tips?

adamdiy
  • 43
  • 5
  • Here's another SO question you should have a look at [StormPath Node Express Heroku Error 'apiKey.id is required'](http://stackoverflow.com/questions/32983531/stormpath-node-express-heroku-error-apikey-id-is-required). – Nocturno Oct 23 '15 at 01:00
  • funny thing is, if i config as answered there: client: { apiKey: { id: process.env.STORMPATH_API_KEY_ID, secret: process.env.STORMPATH_API_KEY_SECRET, } } it doesn't even work locally. i have to change 'id' to 'apiKey.id' to get it to work locally... – adamdiy Oct 23 '15 at 01:26

1 Answers1

3

We have a momentary bug in our Node SDK, please modify your configuration variables to use these new names:

STORMPATH_CLIENT_APIKEY_ID
STORMPATH_CLIENT_APIKEY_SECRET
STORMPATH_APPLICATION_HREF

We made a new release that accepts these new paramaters, but unfortunately it broke backwards compatibility with the old ones. We will relase a fix tomorrow, but you can fix the problem now by using the variables names. Our apologies for this problem!

robertjd
  • 4,723
  • 1
  • 25
  • 29