account icon indicating copy to clipboard operation
account copied to clipboard

Documenting more errors from /v1/api/oauth20/access_token/generate

Open InternalLoss opened this issue 3 years ago • 0 comments

If serial number format or deviceID format is incorrect, Nintendo sends 0002:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<errors>
    <error>
        <code>0002</code>
        <message>deviceId format is invalid</message>
    </error>
</errors>
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<errors>
    <error>
        <code>0002</code>
        <message>serialNumber format is invalid</message>
    </error>
</errors>

If the client cert is empty/missing, the server always sends 0110 even if the NNID is correct:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<errors>
    <error>
        <code>0110</code>
        <message>Unlinked device</message>
    </error>
</errors>

If the grant type is wrong:

<errors><error><cause>grant_type</cause><code>0004</code><message>Invalid Grant Type</message></error></errors>

If client ID or secret is wrong, or either is missing:

<errors><error><cause>client_id</cause><code>0004</code><message>API application invalid or incorrect application credentials</message></error></errors>

InternalLoss avatar Feb 01 '22 01:02 InternalLoss