amzn / selling-partner-api-models

This repository contains OpenAPI models for developers to use when developing software to call Selling Partner APIs.
Apache License 2.0
580 stars 730 forks source link

ERROR MD900 - I need information to understand #1328

Closed Carlit-Auh closed 2 years ago

Carlit-Auh commented 3 years ago

Hello :)

I explain the context, I want to contact the API of the central Seller attached to my pro account that I have. I have an external application (nothing to do with Amazon) on which I want to retrieve my order list for example (the goal is to make statistics of all the marketplaces I use).

I followed the whole documentation on the Amazon git. I can get a token with your refresh token. I did the steps on AWS to have an account in the rules and have an ID and a secret.

However when I want to contact the API I get a 403 "Access to requested resource is denied. The step I am missing is adding a developer using the developer ID provided by AWS. When I want to add my developer I get MD9000 error. I have tried everything, I see that we are talking about the Oauth2.0 URL however my application is just a consumer of the API I have no direct authentication, I have a strong authentication but to enter my application.

I think I'm missing a step, but I don't understand well, is it possible to have the information to unlock me, I've been trying for more than a month...

Thank you very much, I attach a screen of my mistake.

Thanks Thibault C.

amazonError

Carlit-Auh commented 3 years ago

Yes and Yes... I problem it is for add developer to autorize the ressource. If it is not neccessary to authorize the developper it is so strange !

Carlit-Auh commented 3 years ago

It is not a problem with API, it is a problem to add developer in sellerCentral.... Access_token it is not a problem

Carlit-Auh commented 3 years ago

I can have any answer please ? I try everything...

My information :

My developer ID : 863622224934 I try with a second Developer ID : 642422088485

My application ID : amzn1.sp.solution.aac3d3f6-2d6c-4d05-a803-a36cf9be2794

I just need to contact the amazon api to get orders and more information with a external API.

I can't active my developer, can you help me ? Thank a lot

ShivikaK commented 3 years ago

Hello @Carlit-Auh

We will need to work with you via a support case to resolve this issue. Please open a support case so we can pursue the investigation.

Thanks, Shivika Khare Selling Partner API Developer Support

Carlit-Auh commented 3 years ago

Hello @ShivikaK

Thank for your answer !

I open a support case with the seller central account : "SP-API Developer Profile Update : Restricted Access Request" Case ID : 6958620052

I open this 22 april and i don't have solution...

If you can help me for that, your are the best !

Thank Thibault

ShivikaK commented 3 years ago

Hello @Carlit-Auh

Thank you for sharing the support case ID. The case is currently being reviewed and will be updated with next steps.

I did look up your application setup and we do not recommend using OAuth URI as the Login URL information in the application's OAuth section as you have used for the app ID - amzn1.sp.solution.aac3d3f6-2d6c-4d05-a803-a36cf9be2794

Login URI as name suggests is used to login into Developers website. So this should majorly be the developer website's login page URL. You will also require redirect URL added to app as Amazon loads your OAuth Redirect URI into the browser and adds the required parameters needed to complete authorization primarily the SP API OAuth code.

https://github.com/amzn/selling-partner-api-docs/blob/main/guides/en-US/developer-guide/SellingPartnerApiDeveloperGuide.md#step-4-amazon-sends-you-the-authorization-information

Can you please correct this and try again?

Thanks, Shivika Khare Selling Partner API Developer Support

ghost commented 3 years ago

Hello @ShivikaK,

Thank for you answer ! I am happy to see a evolution for my request.

But i have any question : So i need to create OAuth URI with this website : https://developer.amazon.com/fr/ ? And i see in the documentation, i need MWSToken, but i use AWS System (new system for SP API). And if i would'like to have this token, it is when i active my developer no ?

Thank, i work to the changement during that, you can answering ;)

CarlitAuh

Carlit-Auh commented 3 years ago

Hello @ShivikaK,

Have you any time to answer my question ?

I have a same problem, i don't understand witch OAuth URI i need to use. I get the page with i can accept the different authorization for the account (with beta tag) but i can't do anything...

Thank for your time ! CarlitAuh

ShivikaK commented 3 years ago

Hello @Carlit-Auh

Apologies for delay to the response.

The OAuth URI should be pointing to the seller central account of that region which will be authorizing your application.

To receive MWS Auth token in OAuth process, you need to create a hybrid application i.e. MWS + SP API should be selected in API type when you register the application. Please note, if you test the OAuth workflow for your own seller account, it will not return the MWS Auth token.

https://github.com/amzn/selling-partner-api-docs/blob/main/guides/en-US/developer-guide/SellingPartnerApiDeveloperGuide.md#Step-4-Amazon-sends-you-the-authorization-information

Please let me know if you have any further questions.

Thanks, Shivika Khare Selling Partner API Developer Support

Carlit-Auh commented 3 years ago

Helo @ShivikaK

Thank for your answer !

I am so sorry, but i try lot of thing and i don't have any solution. I think, i don't understand one thing...

Look my screenshot :

capture1 Capture2

I create application, SP-API. I add this URL : https://sellercentral-europe.amazon.com/apps/authorize/consent?application_id=amzn1.sp.solution.5ae49bd9-a73b-41b4-9fab-4a2a102b8baa&version=beta --> I have response but not return (it is normally it is for test) So i delete "version=beta", and i have this response : Capture3

I think, i have this because this application is in draft status. But i need to publish this application ? I would'like to have access on API to getOrders, information order.... not for create Amazon Application.

And you send me that : https://github.com/amzn/selling-partner-api-docs/blob/main/guides/en-US/developer-guide/SellingPartnerApiDeveloperGuide.md#Step-4-Amazon-sends-you-the-authorization-information

But i need to do the step 3 ? and so the step 2 and 1 but i need to publish application ?

Sorry for your time, but i need to understand and find a final solution because it is so long just for get my order...

Thank a lot for your time ! CarlitAuh

Carlit-Auh commented 3 years ago

Hello @ShivikaK,

Have you any answer for me please ?

Sorry for my many question...

ShivikaK commented 3 years ago

Hello @Carlit-Auh

Apologies for delay in response.

Please keep in mind that OAuth Login URI is not the OAuth authorization URI.

The OAuth Login URI defines the login page of your website during authorization. This URI is shown after a seller consents to authorize your application.

Please correct the value for Login URI detail and try again.

And to answer your question around removing the version=beta flag and getting an error, it is due to your app being in draft state and not published yet. To test OAuth workflow with draft app, you need to use version=beta in the OAuth authorization URL.

Can you please share the exact issue you are getting and where the workflow breaks?

Thanks, Shivika Khare Selling Partner API Developer Support

Carlit-Auh commented 3 years ago

Hello @ShivikaK

First of all, thank you for your feedback, and sorry for my many questions.

I would like to understand something, My application is simply a dashboard that includes all my marketplaces (With User authentification). I get my orders from each marketplace via the API service of each.

The only one I have problems with is Amazon. I would like to make sure that all these steps are mandatory to simply query the API to make "getOrders"?

I don't want to create an Amazon application, I don't have a login page that allows to contact me with amazon identifiers... I can't figure out if all these steps are what I need to do to simply query the API.

Can you confirm that I need to do all this?

Thank a lot,

CarlitAuh

ShivikaK commented 3 years ago

Hello @Carlit-Auh

If you are planning to use SP API for your own organization where the app is self-authored, you can create a private application.

In this situation, you will be creating an application for your seller account so you do not need to provide OAuth information while registering the application. You can then self-authorize the application using Authorize button to generate the refresh token.

Such a type of application is known as private application. This type of app is always in draft state, cannot be used for 3p authorization workflow (where a different seller authorizes your app) and is not required to be listed in the appstore.

https://github.com/amzn/selling-partner-api-docs/blob/main/guides/en-US/developer-guide/SellingPartnerApiDeveloperGuide.md#Self-authorization

Please let me know if this meets the business requirements you stated and helps address the questions you had.

Thanks, Shivika Khare Selling Partner API Developer Support

Carlit-Auh commented 3 years ago

Hi @ShivikaK

Thank you very much for your feedback it is clearer for me. But how do I manage the developer authorization because I still have the MD9000 error in the end?

I'm going to go back to the procedures to do the auto authorization. But it seems to me that the OAuth URLs at the creation of an application is mandatory, right? I'll go back to my solution to hopefully get it done and be able to contact my seller via the API!

Thanks for your time anyway!

Carlit-Auh commented 3 years ago

Hey @ShivikaK

Have you any information for the error MD9000 for authorize the developer on my seller central account ?

Is it necessary with the changes you have indicated to allow the developer on the seller central ?

Thank

github-actions[bot] commented 2 years ago

This is a very old issue that is probably not getting as much attention as it deserves. We encourage you to check if this is still an issue after the latest release and if you find that this is still a problem, please feel free to open a new issue and make a reference to this one.