App reviews, troubleshooting, and recommendations
Hi,
I’m trying to integrate my Shopify app with the Shoffi Affiliate Platform but I have problem to do that.
According to this official document - https://docs.shoffi.app/for-apps-owners/adding-a-new-app
I need to extract the 'X-Forwarded-For' header in the oauth process after Shopify sends request to my app: “When OAuth is complete, you will get a request from Shopify, which contains the shop name and the 'X-Forwarded-For' header.”
What does it mean?
Which request I need to receive from Shopify?
Hi @Maoragai,
X-Forwarded-For header is basically IP address of user which installed the app.
I recently faced same issue, because "X-Forwarded-For" header wasn't returned by OAuth during authentication process in my case. So I simply used IP address of client which installed the app.
Hope this helps you to solve your issue.
Hi @simon-skrod ,
I am also not getting the "X-Forwarded-For" header during the OAuth process to integrate Shoffi. I see that you used IP address of client which installed the app. How can we get that during the installation flow ?
Hi @bingika ,
In my case, my BE is running on .NET so I was able to use RemoteIpAddress of HttpContext.Connection.
string remoteIpAddress = Request.HttpContext.Connection.RemoteIpAddress.ToString();
I asked Shoffi support if there are any specific requirements while providing Client IP, but they assured me that my approach is fine as well.
Thanks @simon-skrod ,
I have one final question. During which part of the OAuth flow is your BE endpoint getting hit from Shopify ? Is that the redirect URL endpoint with authorization code ?
Hi @bingika , sorry for late response.
Whenever someone install your app, shopify redirect client to your provided redirect url, where you need to observe shopify parameters and get Oauth token from shopify. You can execute shoffi call once you successfully received Oauth code from shopify.
Hey Maor!
Itay from Shoffi.
I can see you already got your answer and solved the matter.
Wanted to let you know that we updated our docs to make that more clear.
Thanks for joining us 🤝
By investing 30 minutes of your time, you can unlock the potential for increased sales,...
By Jacqui Sep 11, 2024We appreciate the diverse ways you participate in and engage with the Shopify Communi...
By JasonH Sep 9, 2024Thanks to everyone who participated in our AMA with 2H Media: Marketing Your Shopify St...
By Jacqui Sep 6, 2024