Download QR Code Package API

Last edited on 2025-07-09

This API should be called on the server side and cannot be called directly on the client side (Mini Program, web page, APP, etc.). For details, please refer to API Call Guide.

API English Name: intp_marketcode_applycodedownload

Download the generated QR code data package

1. Call Method

HTTPS Call

POST https://api.weixin.qq.com/intp/marketcode/applycodedownload?access_token=ACCESS_TOKEN

Cloud Call

  • This API does not support cloud call.

Third-party Call

  • This API supports third-party platforms on behalf of Merchant call.

  • The permission set ID of this API is: 46

  • After the service provider obtains one of the permission set authorizations, it can use authorizer_access_token to call on behalf of Merchant, for details please refer to Third-party Call documentation.

2. Request Parameters

Query Parameters Query String Parameters

ParameterTypeRequiredDescription
access_tokenstringYesAPI call credential, you can use access_token, authorizer_access_token

Request Body Request Payload

ParameterTypeRequiredDescription
application_idnumberYesApplication ID
code_startnumberYesStart position, obtained from the Query QR Code Application API
code_endnumberYesEnd position, obtained from the Query QR Code Application API

3. Response Parameters

Response Body Response Payload

ParameterTypeDescription
bufferformdataFile buffer. It must be base64 decoded before performing the decryption operation (see 3.1 for decryption)
errcodenumberReturn status code
errmsgstringError message

4. Notes

Ensure the application status is FINISH before downloading

5. Code Example

Request Example

{
  "application_id":581865877,
  "code_start": 0,
  "code_end": 49999
}

Response Example

{
  "errcode":0,
  "errmsg":"ok",
  "buffer": "ajfiwejfoiawjfijweofi"
}

6. Error Codes

The following is the error code list of this API, other error codes can refer to Common Error Codes; When encountering errors in calling the API, you can use the official API Diagnostic Tool to assist in locating and analyzing problems.

Error CodeError DescriptionSolution
40001invalid credential  access_token isinvalid or not latestThe access_token is invalid or is not the most recently obtained access_token. Please ensure the developer verifies the validity of the access_token

7. Applicable Scope

This API supports 「Service Account (Need Apply)」 account type calls. Other account types cannot call unless otherwise specified.