• PhilippeM
  • NEWBIE
  • 0 Points
  • Member since 2013

  • Chatter
    Feed
  • 0
    Best Answers
  • 2
    Likes Received
  • 0
    Likes Given
  • 1
    Questions
  • 1
    Replies

Hi there,

 

After few hours trying to make it works, I find myself stuck and need your advice. I'm trying to implement the oauth2 workflow for our app, but I'm stuck with the redirect_uri...

 

We have 2 issues here:

 1 - Our redirect uri looks like the following

https://domain.com/rest/<user_id>/user/connect/salesforce?at=<credentials>

 

Where user_id is the id of  current user (obvious) and at=<credentials> is mandatory because our endpoint is secured and the call will fail without this value.

 

The problem here is that the redirect uri is different from one user to another because it contains the user_id. 

 

So I managed to change the previous url into

https://domain.com/rest/~/user/connect/salesforce?at=<credentials>&user_id=<user_id>

 in order to make the uri the same for all the user and be able to configure the application oauth callback.

 

2 - The second problem is that after the user authorized our application Salesforce redirect it to the specified redirect uri... But it has removed the query string parameters at and user_id... so we got stuck because our endpoint fails because the at param is missing and we're unable to determine who is the current user without the user_id param.

 

any idea?

 

I saw that people usually use the state parameters to pass data accross the steps, but I'm not a big fan Why do you remove the query string parameters from the redirect uri instead of just adding yours?

 

Regards,

 

Philippe

Hi there,

 

After few hours trying to make it works, I find myself stuck and need your advice. I'm trying to implement the oauth2 workflow for our app, but I'm stuck with the redirect_uri...

 

We have 2 issues here:

 1 - Our redirect uri looks like the following

https://domain.com/rest/<user_id>/user/connect/salesforce?at=<credentials>

 

Where user_id is the id of  current user (obvious) and at=<credentials> is mandatory because our endpoint is secured and the call will fail without this value.

 

The problem here is that the redirect uri is different from one user to another because it contains the user_id. 

 

So I managed to change the previous url into

https://domain.com/rest/~/user/connect/salesforce?at=<credentials>&user_id=<user_id>

 in order to make the uri the same for all the user and be able to configure the application oauth callback.

 

2 - The second problem is that after the user authorized our application Salesforce redirect it to the specified redirect uri... But it has removed the query string parameters at and user_id... so we got stuck because our endpoint fails because the at param is missing and we're unable to determine who is the current user without the user_id param.

 

any idea?

 

I saw that people usually use the state parameters to pass data accross the steps, but I'm not a big fan Why do you remove the query string parameters from the redirect uri instead of just adding yours?

 

Regards,

 

Philippe

Hi All, 

 

 I am crating a new package, once the package is installed, I would like to run the post install script that should automatically add the custom List buttons to the Search Layouts for the objects(Custom/Standard). Please post any idea to accomplish this. 

 

An Immediate help would be greately helpful. 

  • January 03, 2013
  • Like
  • 0