I am using express-stormpath with node.js to set up a backend server. This is a snippet of my server.js code where I get an error thrown -
app.use(stormpath.init
I'm assuming you're using the latest version of the express-stormpath library, which is why you're probably having issues. As of the 2.0.0
release, the library uses new configuration options.
Here's an example of the same thing using the new options:
app.use(stormpath.init(app, {
client: {
apiKey: {
file: './config/.stormpath/apikey.properties'
}
},
application: {
href: '',
}
}));
NOTE: No secretKey
is required, as this is generated automatically from your Stormpath API key secret =)
We've made many new changes in the latest library releases that enable all sorts of new, cool stuff! <3