question

PrashantChauda-2827 avatar image
0 Votes"
PrashantChauda-2827 asked HimanshuSinha-MSFT commented

Authorization Code Flow (3-legged OAuth) – Connect to Azure Data factory

I have registered the LinkedIn API in LinkedIn developer portal and able to generate the ClientID/ Client Secret and also able to generate the code while using the redirect link in web (https://www.linkedin.com/oauth/v2/authorization?response_type=code&client_id=xxxxxxx&scope=r_liteprofile&state=123456&redirect_uri=https://xxxxx.com/) and also able to generate the access token (POST- https://www.linkedin.com/oauth/v2/accessToken) by using the postman but could not able to understand how this can be done in Azure data factory , I can understand we have the REST API which can retrieve the token and copy the data in ADLS Gen2 but how we can get the code in Azure data factory (without authorization consent)


  1.  Configure your application in the Developer Portal to obtain Client ID and Client Secret. – This has been done
    
  2.  Your application directs the browser to LinkedIn's OAuth 2.0 authorization page where the member authenticates. – how this can be handled in ADF
    
  3.  After authentication, LinkedIn's authorization server passes an authorization code to your application. – how this can be handled in ADF
    
  4.  Your application sends this code to LinkedIn and LinkedIn returns an access token. – This can be done
    
  5.  Your application uses this token to make API calls on behalf of the member. – This can be done
    

As I can understand we need to follow above 5 step and some of steps I can able to manage it.


It would be great help if someone guide me, Thanks in advance.


azure-data-factory
· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Do we have any properties which we can set true for code so authorisation code would not required.

0 Votes 0 ·

Hello @PrashantChauda-2827 ,
At ths time ADF does not any authentication of that form , but your question regarding the supportablity should be on the linkedin forum .
Thanks
Himanshu

0 Votes 0 ·

1 Answer

HimanshuSinha-MSFT avatar image
0 Votes"
HimanshuSinha-MSFT answered PrashantChauda-2827 commented

Hello @PrashantChauda-2827 ,
Thanks for the ask and using the Microsoft Q&A platform .

Reading more here , i see that the worfklow for 3-legged- OAuth does need manual intervention and so does not work in ADF / automatioin scenario . , please read here .

I think you will have to take the 2-legged approach ( I have not tried this for linkedin API , but then this is very normal approach which I have seen across many other services )

Please do let me know how it goes .
Thanks
Himanshu
Please do consider clicking on "Accept Answer" and "Up-vote" on the post that helps you, as it can be beneficial to other community members


· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Thanks for response.
2- legged approach could not work for marketing data (pls refer the 2 ledger article in MS) and even I have tried to implement the same and that has not to be implemented directory it would required the approval in Linked side.

Is there some other way, we can bypass the manual intervention can we write up some function so it would return the code which we can pass to web activity to get the token ? Any suggested function link or advise .
Thanks in advance.

0 Votes 0 ·