# 预授权码

预授权码(pre_auth_code)是第三方平台方实现授权托管的必备信息,每个预授权码有效期为 10 分钟。需要先获取 令牌才能调用

# # 请求地址
POST https://api.q.qq.com/api/component/preauthcode/get?component_access_token=COMPONENT_ACCESS_TOKEN
1
# # 请求参数说明
参数 类型 必填 说明
component_access_token string 令牌
component_appid string 第三方平台 appid

POST 数据示例:

{"component_appid":"appid_value"}
1
# 结果参数说明
参数 类型 说明
pre_auth_code string 预授权码
expires_in number 有效期,单位:秒

返回结果示例:

{"pre_auth_code":"Cx_Dk6qiBE0Dmx4EmlT3oRfArPvwSQ-oa3NL_fwHM7VI08r52wazoZX2Rhpz1dEw","expires_in":600}
1