• Register
0 votes
18 views

Problem :

The Salesforce developer account is not allowing my app to be authenticated through the oauth. Recently I just  changed my redirect url and I started getting below error:

Error=redirect_uri_mismatch&error_description=redirect_uri%20must%20match%20configuration

How to resolve this issue?

8 4 2
2,300 points

1 Answer

0 votes

Solution :

I have gone through your question. I will guide you in fixing your error. The salesforce always provides you with the Client Id and Client secret. After that the third party application can start accessing the System via a third party application.
So when you try to invoke Oauth Endpoint in your salesforce, you must send the callback URI. This is very important URL as the salesforce will invoke it once it successfully Authorizes and sends back you the Code. So please cross check if that Call back URI is exactly same as you specified in your Connected app settings as below.
https://login.salesforce.com/services/oauth2/authorize?response_type=code&client_id=<your_client_id>&redirect_uri=<your_redirect_uri>
As soon as the Application is defined the salesforce will try to send this information to all instances of its servers which will take some time.
So in your case it might have happened that you only changed a callbackURI and after that salesforce took a littele time to send those changes to instances as a result you were facing a redirectr URI mismatch or a URI that you were trying to use while invoking a salesforce was still a old URI. 

5 2 1
4,980 points

Related questions

1 vote
1 answer 181 views
181 views
Problem: I have very recently started understanding salesforce. I want to catch the exception which gets thrown in my @myfuture mymethod nevertheless my test mymethod is unable to detecting it. Please find below my class under test for your reference: public with ... Mymethods defined as TestMymethod do not support Web service callouts, test skipped Please help me in unit testing my above code.
asked May 29 Martin K 6.6k points
1 vote
1 answer 80 views
80 views
Problem : I am very new to Apex Programming. I am trying to learn Apex using the tutorials available online. I am trying to write Apex Code. I want to set my RecordType.Name in a test class but my class gives me the below message:  "System.NullPointerException: ... : line 45, column 3 External entry point". I am completely stuck with above error. I need help in fixing above Apex related error.
asked May 16 Martin K 6.6k points