Hi, we’re using both pre-user-registration and post-login actions, and seems that error codes and descriptions are not consistent, so we’re trying to find ways to align them.
Can we customize the error field (error_description matches our code, correctly)? Or it’s always hard-coded to be “extensibility_error” in pre-user-registration and “access-denied” in post-login?
Can we specify the HTTP response code, so in post-login it returns a 40x instead of a 500? Or at least, can we make them match between pre-user-registration and post-login?
We tried passing a second argument to api.access.deny (as described in API object) in the pre-user-registration flow, but we don’t see the extra string show up in the response.
Thanks for confirming that we cannot edit the error field or the HTTP response code. Is that something that’s in the roadmap? Getting an HTTP 500 for auth or bad request is not ideal.
Also, can you give me context on how you got all those fields in the response? When calling the API via curl, I only get “error_description” and “error”. Is there an extra param or header that will return more info?
Unfortunately, modifying the HTTP response code is not in our roadmap.
If you believe that this is a feature you and many others would benefit from, please submit a feedback request asking for support for modifying the response code in Actions.
And for clarification, I was using Postman to register a user using the Authentication API. The response was the one shown in the screenshot.
Please let me know if there’s anything else I can do to help.