Getting access token in test environment in shopware account does not work, error 302 - shopware6

My app required an app server and api/search calls. It all works fine when the app is installed in our own shopware test shops.
But as the app is ready now I made an test environment in our shopware account. Installation including registration with our app server went fine. But all the api calls failed. The reason seems to be that I do not get an access token. The call for the access token gives me an 302 Found error.
But the code is ok as all works in our test shops, prod and dev.
So, what could be the problem in the sw account test environment?

I found the problem! The shop url I got during registration was
"https://....sw.testenvironment.de/shop/public".
Api calls didn't work with this url.
But I changed it to
"https://....sw.testenvironment.de/shop/public/".
It worked.
The shopware test environment seems to have a problem with the /.
In our own shopware test shops it worked fine without the / at the end.

Related

Access Denied error during step 1 of Xero API OAuth2 standard authorization code flow

I have an existing Xero app that's worked well for over a year that uses OAuth2 to connect a small number of organisations to one of three Web Apps: developer, sandbox, and production. Sandbox and production are working well. However, yesterday I started to create a new instance of the developer app and am unable to complete the first step. My app calls the following URL:
https://login.xero.com/identity/connect/authorize?response_type=code&client_id=069BFC79B7REDACTED&redirect_uri=https%3A%2F%2Fdev.addressredacted.ngrok.io%2Fcotrustee%2Fxero&scope=offline_access+accounting.transactions+accounting.settings+accounting.journals.read
This URL has the same form that has worked for over a year, just with a new client_id, but now I keep getting this error:
Access Denied
You don't have permission to access "http://authorize.xero.com/?" on this server.
Reference #18.d2fdda17.1671639885.53ec38b
I expect to be redirected to a Xero login page instead.
From the Ref# that you received, it looks like it has hit the Akamai WAF. Unfortunately the code has expired (it only has a lifetime of 24 hours) thus we are unable to check why it was blocked.
Can you contact Xero API Support - api at xero dot com - with a newer reference so we can further investigate?

Docusign app getting error this page isn't working right now, local host can't currently handle this request, http error 500

I'm developing an app based on the Docusign C# Quickstart.
Its working fine on my development PC (Win 11) in Visual Studio 2019 using IIS Express.
However, when I publish it to IIS (v10) on my development PC it runs and I can authenticate with Docusign just fine (once I got the proper redirect URI registered: https://localhost/ds/callback) but the step that actually sends the envelope is returning the following error in the browser:
This page isn't working right now.
Local host can't handle this request
http error 500
Any help is appreciated. I logged a support ticket with Docusign, but still waiting for a response.
Quickstart is just an app to show you how to use DocuSign APIs.
The redirect after signing is back to localhost, and your app, once ready to be deployed to server, has to be set with a proper URL, at which point you'll need to update the redirect URI to the one based on your server.
The 500 error is coming from your app, not from DocuSign. You need to figure out why your app cannot handle the URL that is set for redirect after signing by DocuSign.
The base API address demo.docusign.net/restapi is used to reach the development/ test platform. The na4.docusign.net/restapi address is one of DocuSign's (many) production platforms.
Remember that, once you have passed the Go-Live process, you have two Client IDs (integration keys) one for the test platform, one for all of the production platforms. Each has its own settings.
Added
The error
This page isn't working right now.
Local host can't handle this request http error 500
Is from IIS. Use IIS logging to see the URL request that is coming in that can't be handled.
To see if it is the redirect from the initial OAuth Authorization Code grant URL, examine the initial URL redirect to account.docusign.com (prod URL).
The redirect contained as a query parameter in the initial OAuth redirect must:
Be correct for your instance of IIS.
Be allowed by your setting for the client ID (integration key) in DocuSign
1, Be properly handled by your IIS and its app.

Etsy Authentication changes

I am working on Etsy Authentication. I have created an app and tried to test the Authentication via Postman in the same above process but I was not able to Authenticate I was getting an error
Error
And I was unable to Edit the App and also there is no option of "Request Full Access"
No Edit option and also no Request full access and the app state is in pending approval
Help me with the issue as I was previously able to Edit the App and I have tested few APIs as well but now I am unable to do it.
Postman image
If I hit this API in the browser as a response I need code but I was getting the above error
Your request isn't working because you haven't registered the callback URL for postman with your App, and of course you mentioned that you couldn't edit your app to add the callback URL.
There is a silly URL bug on the Etsy dev portal which sending you to a broken like when you click on your app to edit it.
Once you click on the App to edit it and end up at the 404 page,
Remove this from the URL and it will then work.
I have emailed the Etsy Developers to point out this bug so hopefully it will be resolved quickly.
To piggyback off of Gareth's answer:
Step 1:
In https://www.etsy.com/developers/edit/{account_id}/callbacks, add the following callback:
http://localhost:3003/oauth/redirect
Step 2:
Follow these instructions https://developer.etsy.com/documentation/essentials/authentication/, make sure to set:
redirect_uri=http://localhost:3003/oauth/redirect
*You don't actually need anything running at localhost:3003

Sendle returns unauthorised but working on local machine

Upon testing Sendle API sandbox it was working on local machine, the API ID and KEY that I used on local and test server are the same. Why is it that the test server, the API returns
{"error":"unauthorised","error_description":"The authorisation details are not valid. Either the Sendle ID or API key are incorrect."}
Is it the Sendle Sandbox only works are localhost or local machine?
It seems like, I have to regenerate new API key for Sendle, but still I don't have any idea why's the previous API KEY is not working. But well everything works fine now.

ember-simple-auth and IE

I've recently upgrated to 0.1.1 from 0.13, and after a few hiccups it seems to be working. I can login to my app using most browsers (IE9-11, FF, Chrome) when running in development on my local machine.
When I deploy to a staging environment on heroku I'm seeing some strange behaviour on IE (9-11). Basically it looks like the bearer token is never being set. After looking through the code for ember-simple-auth I can see that it uses the ajax prefilter function to add the bearer token prior to a call back to the server. When I look in the Network tools on IE the token isn't there, so I always receive a 401 and am transitioned back to the index page.
I can see the login call to retrieve the token working, it just is never added to any subsequent calls.
I've looked for bugs with jQuery, IE and prefilter but haven't turned anything up. The code on staging is minified and concatenated, which makes debugging somewhat problematic.
Any suggestions on what to try next much appreciated.
I've tracked this down to an issue with HTTPS and ports in ember-simple-auth. Details can be found in this issue.