Tag Archives: 401Access Denied

Request MWS error 401: access denied [How to Solve]

Running MWS interface, an error is reported:

Caught Exception: Access denied
Response Status Code: 401
Error Code: AccessDenied
Error Type: Sender
Request ID: c5a634e6-0e1b-42d9-ba6b-de5e0f16b94c
XML: <ErrorResponse xmlns="http://mws.amazonaws.com/doc/2009-01-01/"><Error><Type>Sender</Type><Code>AccessDenied</Code><Message>Access denied</Message></Error><RequestID>c5a634e6-0e1b-42d9-ba6b-de5e0f16b94c</RequestID></ErrorResponse>ResponseHeaderMetadata: null

Asked Xiadu Niang and said that when a web service is called remotely, the IIS configuration must be “allow anonymous access”. How to configure it?This computer – > computer   -> Administration   -> Services and Applications   ->   Internet Informatica Services(IIS) -> Double click “authentication” – > under IIS in the pop-up window on the right; Right click anonymous authentication – > Enabled

If IIS has not been opened, open it as follows: control panel – > Procedures and functions – > Turn windows features on or off  -> Internet Informatica Services  -> Web management tools  -> Tick “IIS management console”

 

I opened the IIS configuration on my computer and found that anonymous authentication had been checked. The configuration problem was eliminated. Then I continued to check and found that I put the marketplaceid into the merchant ID to request when setting parameters. In fact, merchantid is sellerid. If you change it and ask again, it will return normally:

GetReportCount Action Response
=============================================================================

    GetReportCountResponse
        GetReportCountResult
            Count
                1724
        ResponseMetadata
            RequestId
                c9537c0e-8789-4dd0-9dd5-ecc08b85d8c0

requestId : c9537c0e-8789-4dd0-9dd5-ecc08b85d8c0
responseContext : acyGtvqxlRDN1124g2ngAMFQESRJvItIl1W0Bm0I3aCeZFMQ3FPGlNZxT5wlBV0iltkOK6zQ5xM=
timestamp : 2018-07-05T11:34:01.270Z