How can I remove a redirect uri using amplify.
Running amplify auth update
gives no option for removing a redirect uri, there is only a 'add/edit' option. I have tried to look through the documentation but with no success.
How can I remove a redirect uri using amplify.
Running amplify auth update
gives no option for removing a redirect uri, there is only a 'add/edit' option. I have tried to look through the documentation but with no success.
While it doesn't seem to be possible to remove redirects using the amplify CLI, you can do it manually by editing the (multiple) parameters.json
files that amplify creates. Search for the CallbackURLs
and LogoutURLs
fields in the oAuthMetadata
and you can manually delete the sign in/sign out redirects that you no longer want.
there are 2 places where you need to update the signin and signout urls to avoid breaking the backend build:
aws-exports.js
, which is usually located in the root of your project.
parameters.json
of the amplify/backend/auth/appname folder
Modify parameters.json seems not working. Instead, modify cli-inputs.json. It's in the path amplify/backend/ of your folder. Search for the CallbackURLs and LogoutURLs fields in the oAuthMetadata, and manually edit it.
After that amplify push will work, it will update the local's file: parameters.json and aws-export.js, and also update the Cognito's (backend) side.
By the way, if you use amplify hosting, you should build your frontend(e.g. git push if you link the repo) to sync the confi file for frontend application.
The easiest way is to:
amplify update auth
Add/Edit signin and signout redirect URIs
{your_app_name}://callback_to_remove
callback_to_remove
in your project and remove the uri.amplify push
Hi There I am sure you have probably figured it by now or they have recently added this option but in the backend, you can click on the bottom option rewrites and redirects.