v2.public.get_token_by_resend_code
POST /api/v2/public/get_token_by_resend_code
Use the resend code to get access token and refresh token. When you lost your access token or refresh token, you can go to authorization management page to resend code by yourselves. You can only use this endpoint in live environment, we don't support in test-stable environment.
Endpoint URL
URL: https://partner.shopeemobile.com/api/v2/public/get_token_by_resend_code
Common Request Parameters
| Name | Type | Sample | Description |
|---|---|---|---|
| partner_id | int | 1 | Partner ID is assigned upon registration is successful. Required for all requests. |
| timestamp | timestamp | 1610000000 | This is to indicate the timestamp of the request. Required for all requests. Expires in 5 minutes. |
| sign | string | e318d3e932719916a9f9ebb57e2011961bd47abfa54a36e040d050d8931596e2 | Signature generated by partner_id, api path, timestamp and partner_key via HMAC-SHA256 hashing algorithm. More details: https://open.shopee.com/documents?module=87&type=2&id=58&version=2 |
Request Parameters
| Name | Type | Required | Sample | Description |
|---|---|---|---|---|
| resend_code | string | True | resend5a4d6e6a7a745a767276586f53476849 | the code in redirect url after you resend code in shop authorization management page. valid for one-time use, expires in 10minutes. |
Response Parameters
| Name | Type | Sample | Description |
|---|---|---|---|
| request_id | string | a3a4277823b1019960cc92cfd972c506 | The identifier for an API request for error tracking. |
| error | string | common.error_auth | Indicate error type if hit error. |
| message | string | Invalid access_token. | Indicate error details if hit error. |
| shop_id_list | int[] | [1] | Return when resend code in shop module |
| merchant_id_list | int[] | [1] | Return when resend code in merchant module |
| refresh_token | string | abcd | Use refresh_token to obtain new access_token. Valid for each shop_id and merchant_id respectively one-time use, expires in 30 days. |
| access_token | string | abcd | The token for API access, using to identify your permission to the api. Valid for multiple use and expires in 4 hours. |
| expire_in | int | 123 | Access_token expiration time, unit is second. |