Greetings…
We’ve used stormpath earlier with custom /login /register and /forgot… Since everything now is ported / depricated to Okta we struggle to get the routes working properly, except /login…
Especially crucial now, is to get /forgot implemented but i’m endring up with a 404 (not found) exception in the browser…
Here is the Implementation (VUE) :
tryResetPassword(resetEmail){
var config = {
headers: {
'Content-Type': ' application/json',
'Accept': ' application/json'
}
};
return axios.post('/forgot', resetEmail, config)
.then(response => response.data)
},
Here is the configuration of okta… (server.js)
const stormpath = require('express-stormpath');
const path = require('path');
function configureStormpath(app, site){
app.use(stormpath.init(app, {
org: process.env.oktaURL || "https://myaddressxxx.oktapreview.com",
debug: 'info',
application: {
id: process.env.oktaApplicationId || "mykeyxxxxx"
},
apiToken: process.env.oktaApiToken || "mytokenxxxx",
web: {
me: {
expand: {
customData: true
}
},
forgot: {
enabled: true
},
register: {
enabled: true,
form : {
fields: {
givenName: {
required: false,
enabled: true
},
surname: {
required: false,
enabled: true
},
CompanyName: {
enabled: true,
label:"Firmanavn",
placeholder: "Stuff..",
required: true,
type: "text"
},
CompanyId: {
enabled: true,
label:"Firmakode",
placeholder: "Stuff...",
required: true,
type: "text"
}
}
}
}
},
}));
console.log('(Octa-wannabe-stormpath installed')
console.log(stormpath)
}
module.exports = configureStormpath;
So my question is… what do i need to configure additionally to make it accept /forgot ? And… why isn’t it working “out of the box” like /login does ?