glhcp/server/vendor/alipaysdk/easysdk/APIDoc.md

822 lines
30 KiB
Java
Raw Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

# Base
## OAuth
### 访
* API
getToken(code: string)
*
| | | | |
|------|--------|----|----|
| code | string | | |
*
[alipay.system.oauth.token](https://docs.open.alipay.com/api_9/alipay.system.oauth.token)查看更加详细的参数说明。
### 访
* API
refreshToken(refreshToken: string)
*
| | | | |
|------|--------|----|----|
| refreshToken | string | | 访refresh_token |
*
[alipay.system.oauth.token](https://docs.open.alipay.com/api_9/alipay.system.oauth.token)查看更加详细的参数说明。
---
## Qrcode
###
* API
create(urlParam: string, queryParam: string, describe: string)
*
| | | | |
|------|--------|----|----|
| urlParam | string | | 访page/component/component-pages/view/view |
| queryParam | string | | query onLaunch |
| describe | string | | |
*
[alipay.open.app.qrcode.create](https://docs.open.alipay.com/api_5/alipay.open.app.qrcode.create)查看更加详细的参数说明。
---
## Image
###
* API
upload(imageName: string, imageFilePath: string)
*
| | | | |
|------|--------|----|----|
| imageName | string | | |
| imageFilePath | string | | |
*
[alipay.offline.material.image.upload](https://docs.open.alipay.com/api_3/alipay.offline.material.image.upload)查看更加详细的参数说明。
---
## Video
###
* API
upload(videoName: string, videoFilePath: string)
*
| | | | |
|------|--------|----|----|
| videoName | string | | |
| videoFilePath | string | | |
*
[alipay.offline.material.image.upload](https://docs.open.alipay.com/api_3/alipay.offline.material.image.upload)查看更加详细的参数说明。
---
# Marketing
## OpenLife
###
* API
createImageTextContent(title: string, cover: string, content: string, contentComment: string, ctype: string, benefit: string, extTags: string, loginIds: string)
*
| | | | |
|------|--------|----|----|
| title | string | | |
| cover | string | | URL, 996*4503M.jpg.pngURL |
| content | string | | |
| contentComment | string | | TF |
| ctype | string | | activity |
| benefit | string | | ctypeactivity10 |
| extTags | string | | 5 |
| loginIds | string | | 10 |
*
[alipay.open.public.message.content.create](https://docs.open.alipay.com/api_6/alipay.open.public.message.content.create)查看更加详细的参数说明。
###
* API
modifyImageTextContent(contentId: string, title: string, cover: string, content: string, couldComment: string, ctype: string, benefit: string, extTags: string, loginIds: string)
*
| | | | |
|------|--------|----|----|
| contentId | string | | ID |
| title | string | | |
| cover | string | | URL, 996*4503M.jpg.pngURL |
| content | string | | |
| contentComment | string | | TF |
| ctype | string | | activity |
| benefit | string | | ctypeactivity10 |
| extTags | string | | 5 |
| loginIds | string | | 10 |
*
[alipay.open.public.message.content.modify](https://docs.open.alipay.com/api_6/alipay.open.public.message.content.modify)查看更加详细的参数说明。
###
* API
sendText(text: string)
*
| | | | |
|------|--------|----|----|
| text | string | | |
*
[alipay.open.public.message.total.send](https://docs.open.alipay.com/api_6/alipay.open.public.message.total.send)查看更加详细的参数说明。
###
* API
sendImageText(articles: [ Article ])
*
| | | | |
|------|--------|----|----|
| articles | Article | | |
Article
| | | | |
|------|--------|----|----|
| title | string | | |
| desc | string | | |
| imageUrl | string | | URL |
| url | string | | |
| actionName | string | | |
*
[alipay.open.public.message.total.send](https://docs.open.alipay.com/api_6/alipay.open.public.message.total.send)查看更加详细的参数说明。
###
* API
sendSingleMessage(toUserId: string, template: Template)
*
| | | | |
|------|--------|----|----|
| toUserId | string | | UserId |
| template | Template | | UserId |
Template
| | | | |
|------|--------|----|----|
| templateId | string | | ID |
| context | Context | | |
Context
| | | | |
|------|--------|----|----|
| headColor | string | | #85be53 |
| url | string | | |
| actionName | string | | 816 |
| keyword1 | Keyword | | |
| keyword2 | Keyword | | |
| first | Keyword | | |
| remark | Keyword | | |
Keyword
| | | | |
|------|--------|----|----|
| color | string | | #85be53 |
| value | string | | |
*
[alipay.open.public.message.single.send](https://docs.open.alipay.com/api_6/alipay.open.public.message.single.send)查看更加详细的参数说明。
###
* API
recallMessage(messageId: string)
*
| | | | |
|------|--------|----|----|
| messageId | string | | ID |
*
[alipay.open.public.life.msg.recall](https://docs.open.alipay.com/api_6/alipay.open.public.life.msg.recall)查看更加详细的参数说明。
###
* API
setIndustry(primaryIndustryCode: string, primaryIndustryName: string, secondaryIndustryCode: string, secondaryIndustryName: string)
*
| | | | |
|------|--------|----|----|
| primaryIndustryCode | string | | [](https://alipay.open.taobao.com/doc2/detail?treeId=197&docType=1&articleId=105043) |
| primaryIndustryName | string | | |
| secondaryIndustryCode | string | | |
| secondaryIndustryName | string | | |
*
[alipay.open.public.template.message.industry.modify](https://docs.open.alipay.com/api_6/alipay.open.public.template.message.industry.modify)查看更加详细的参数说明。
###
* API
getIndustry()
*
*
[alipay.open.public.setting.category.query](https://docs.open.alipay.com/api_6/alipay.open.public.setting.category.query)查看更加详细的参数说明。
---
## Pass
###
* API
createTemplate(uniqueId: string, tplContent: string)
*
| | | | |
|------|--------|----|----|
| uniqueId | string | | 使 |
| tplContent | string | | JSONtpl_content[](https://doc.open.alipay.com/doc2/detail.htm?treeId=193&articleId=105249&docType=1#tpl_content) |
*
[alipay.pass.template.add](https://docs.open.alipay.com/api_24/alipay.pass.template.add)查看更加详细的参数说明。
###
* API
updateTemplate(uniqueId: string, tplContent: string)
*
| | | | |
|------|--------|----|----|
| uniqueId | string | | 使 |
| tplContent | string | | JSONtpl_content[](https://doc.open.alipay.com/doc2/detail.htm?treeId=193&articleId=105249&docType=1#tpl_content) |
*
[alipay.pass.template.update](https://docs.open.alipay.com/api_24/alipay.pass.template.update)查看更加详细的参数说明。
###
* API
addInstance(tplId: string, tplParams: string, recognitionType: string, recognitionInfo: string)
*
| | | | |
|------|--------|----|----|
| tplId | string | | passIDtpl_id |
| tplParams | string | | $$tpl_params |
| recognitionType | string | | Alipass1 |
| recognitionInfo | string | | [UID](https://docs.open.alipay.com/199/sy3hs4 ) |
*
[alipay.pass.instance.add](https://docs.open.alipay.com/api_24/alipay.pass.instance.add)查看更加详细的参数说明。
###
* API
updateInstance(serialNumber: string, channelId: string, tplParams: string, status: string, verifyCode: string, verifyType: string)
*
| | | | |
|------|--------|----|----|
| serialNumber | string | | JSONfileInfo->serialNumber |
| channelId | string | | PID/AppID |
| tplParams | string | | Alipass1 |
| status | string | | USEDCLOSED |
| verifyCode | string | | USEDOperationmessage |
| verifyType | string | | OperationformatverifyCodeverifyType |
*
[alipay.pass.instance.update](https://docs.open.alipay.com/api_24/alipay.pass.instance.update)查看更加详细的参数说明。
---
## TemplateMessage
###
* API
send(toUserId: string, formId: string, userTemplateId: string, page: string, data: string)
*
| | | | |
|------|--------|----|----|
| toUserId | string | | |
| formId | string | | |
| userTemplateId | string | | idid |
| page | string | | page/component/index |
| data | string | | {"keyword1": {"value" : "12:00"},"keyword2": {"value" : "20180808"},"keyword3": {"value" : "支付宝"}} |
*
[alipay.open.app.mini.templatemessage.send](https://docs.open.alipay.com/api_5/alipay.open.app.mini.templatemessage.send)查看更加详细的参数说明。
---
# Member
## Identification
###
* API
init(outerOrderNo: string, bizCode: string, identityParam: IdentityParam, merchantConfig: MerchantConfig)
*
| | | | |
|------|--------|----|----|
| outerOrderNo | string | | 32使使 |
| bizCode | string | | FACECERT_PHOTOCERT_PHOTO_FACESMART_FACE |
| identityParam | IdentityParam | | |
| merchantConfig | MerchantConfig | | |
IdentityParam
| | | | |
|------|--------|----|----|
| identityType | string | | CERT_INFO |
| certType | string | | IDENTITY_CARD |
| certName | string | | |
| certNo | string | | |
MerchantConfig
| | | | |
|------|--------|----|----|
| returnUrl | string | | URL |
*
[alipay.user.certify.open.initialize](https://docs.open.alipay.com/api_2/alipay.user.certify.open.initialize)查看更加详细的参数说明。
###
* API
certify(certifyId: string)
*
| | | | |
|------|--------|----|----|
| certifyId | string | | |
*
[alipay.user.certify.open.certify](https://docs.open.alipay.com/api_2/alipay.user.certify.open.certify)查看更加详细的参数说明。
###
* API
query(certifyId: string)
*
| | | | |
|------|--------|----|----|
| certifyId | string | | |
*
[alipay.user.certify.open.query](https://docs.open.alipay.com/api_2/alipay.user.certify.open.query)查看更加详细的参数说明。
---
# Payment
## Common
###
* API
create(subject: string, outTradeNo: string, totalAmount: string, buyerId: string)
*
| | | | |
|------|--------|----|----|
| subject | string | | |
| outTradeNo | string | | 64线 |
| totalAmount | string | | [0.01,100000000] |
| buyerId | string | | 208816 |
*
[alipay.trade.create](https://docs.open.alipay.com/api_1/alipay.trade.create)查看更加详细的参数说明。
###
* API
query(outTradeNo: string)
*
| | | | |
|------|--------|----|----|
| outTradeNo | string | | |
*
[alipay.trade.query](https://docs.open.alipay.com/api_1/alipay.trade.query)查看更加详细的参数说明。
### 退
* API
refund(outTradeNo: string, refundAmount: string)
*
| | | | |
|------|--------|----|----|
| outTradeNo | string | | |
| refundAmount | string | | 退 |
*
[alipay.trade.refund](https://docs.open.alipay.com/api_1/alipay.trade.refund)查看更加详细的参数说明。
###
* API
close(outTradeNo: string)
*
| | | | |
|------|--------|----|----|
| outTradeNo | string | | |
*
[alipay.trade.close](https://docs.open.alipay.com/api_1/alipay.trade.close)查看更加详细的参数说明。
###
* API
cancel(outTradeNo: string)
*
| | | | |
|------|--------|----|----|
| outTradeNo | string | | |
*
[alipay.trade.cancel](https://docs.open.alipay.com/api_1/alipay.trade.cancel)查看更加详细的参数说明。
### 退
* API
queryRefund(outTradeNo: string, outRequestNo: string)
*
| | | | |
|------|--------|----|----|
| outTradeNo | string | | |
| outRequestNo | string | | 退退退 |
*
[alipay.trade.fastpay.refund.query](https://opendocs.alipay.com/apis/api_1/alipay.trade.fastpay.refund.query)查看更加详细的参数说明。
###
* API
downloadBill(billType: string, billDate: string)
*
| | | | |
|------|--------|----|----|
| billType | string | | tradesigncustomertradesigncustomer |
| billDate | string | | yyyy-MM-dd201611yyyy-MM20161 |
*
[alipay.data.dataservice.bill.downloadurl.query](https://opendocs.alipay.com/apis/api_15/alipay.data.dataservice.bill.downloadurl.query)查看更加详细的参数说明。
###
* API
verifyNotify(parameters: map[string]string)
*
| | | | |
|------|--------|----|----|
| parameters | map[string]string | | |
---
## Huabei
###
* API
create(subject: string, outTradeNo: string, totalAmount: string, buyerId: string, extendParams: HuabeiConfig)
*
| | | | |
|------|--------|----|----|
| subject | string | | |
| outTradeNo | string | | 64线 |
| totalAmount | string | | [0.01,100000000] |
| buyerId | string | | IDID |
| extendParams | HuabeiConfig | | |
HuabeiConfig
| | | | |
|------|--------|----|----|
| hbFqNum | string | | 3612 |
| hbFqSellerPercent | string | | 10001000 |
*
[alipay.trade.create](https://docs.open.alipay.com/api_1/alipay.trade.create)查看更加详细的参数说明。
---
<a name="faceToFace"/>
## FaceToFace
###
* API
pay(subject: string, outTradeNo: string, totalAmount: string, authCode: string)
*
| | | | |
|------|--------|----|----|
| subject | string | | |
| outTradeNo | string | | |
| totalAmount | string | | [0.01,100000000] |
| authCode | string | | |
*
[alipay.trade.pay](https://docs.open.alipay.com/api_1/alipay.trade.pay)查看更加详细的参数说明。
*
ISV[](https://opendocs.alipay.com/p/00fc2g)与[合作攻略](https://opendocs.alipay.com/open/300/taphxd)。
**extend_paramssys_service_provider_id PID**Java
```java
Map<String, String> extendParams = new HashMap<>();
extendParams.put("sys_service_provider_id", "<--请填写ISV签约协议的PID比如2088511833207846-->");
AlipayTradePayResponse response = Factory.Payment.FaceToFace()
.agent("<--请填写商户应用授权后获取到的app_auth_token比如ca34ea491e7146cc87d25fca24c4cD11-->")
.optional("extend_params", extendParams)
.pay("iPhone6 16G", "64628156-f784-4572-9540-485b7c91b850", "0.01", "289821051157962364");
```
---
###
* API
precreate(subject: string, outTradeNo: string, totalAmount: string)
*
| | | | |
|------|--------|----|----|
| subject | string | | |
| outTradeNo | string | | |
| totalAmount | string | | [0.01,100000000] |
*
[alipay.trade.precreate](https://docs.open.alipay.com/api_1/alipay.trade.precreate)查看更加详细的参数说明。
*
ISV[](https://opendocs.alipay.com/p/00fc2g)与[合作攻略](https://opendocs.alipay.com/open/300/taphxd)。
**extend_paramssys_service_provider_id PID**Java
```java
Map<String, String> extendParams = new HashMap<>();
extendParams.put("sys_service_provider_id", "<--请填写ISV签约协议的PID比如2088511833207846-->");
AlipayTradePrecreateResponse response = Payment.FaceToFace()
.agent("<--请填写商户应用授权后获取到的app_auth_token比如ca34ea491e7146cc87d25fca24c4cD11-->")
.optional("extend_params", extendParams)
.preCreate("iPhone6 16G", "64628156-f784-4572-9540-485b7c91b850", "0.01");
```
---
## Page
###
* API
pay(subject: string, outTradeNo: string, totalAmount: string, returnUrl: string)
*
| | | | |
|------|--------|----|----|
| subject | string | | |
| outTradeNo | string | | |
| totalAmount | string | | [0.01,100000000] |
| returnUrl | string | | http/https |
*
[alipay.trade.page.pay](https://docs.open.alipay.com/api_1/alipay.trade.page.pay)查看更加详细的参数说明。
---
## Wap
###
* API
pay(subject: string, outTradeNo: string, totalAmount: string, quitUrl: string, returnUrl: string)
*
| | | | |
|------|--------|----|----|
| subject | string | | |
| outTradeNo | string | | |
| totalAmount | string | | [0.01,100000000] |
| quitUrl | string | | 退 |
| returnUrl | string | | http/https |
*
[alipay.trade.wap.pay](https://docs.open.alipay.com/api_1/alipay.trade.wap.pay)查看更加详细的参数说明。
---
## App App
### APP
* API
pay(subject: string, outTradeNo: string, totalAmount: string)
*
| | | | |
|------|--------|----|----|
| subject | string | | |
| outTradeNo | string | | |
| totalAmount | string | | [0.01,100000000] |
*
[alipay.trade.app.pay](https://docs.open.alipay.com/api_1/alipay.trade.app.pay)查看更加详细的参数说明。
---
# Security
## TextRisk
###
* API
detect(content: string)
*
| | | | |
|------|--------|----|----|
| content | string | | |
*
[alipay.security.risk.content.detect](https://docs.open.alipay.com/api_49/alipay.security.risk.content.detect)查看更加详细的参数说明。
---
# Util
## AES
### AES
* API
decrypt(cipherText: string)
*
| | | | |
|------|--------|----|----|
| cipherText | string | | |
*
| | |
|------|----|
| string | |
### AES
* API
encrypt(plainText: string)
*
| | | | |
|------|--------|----|----|
| plainText | string | | |
*
| | |
|------|----|
| string | |
<a name="generic"/>
## Generic
### OpenAPI
* API
execute(method: string, textParams: map[string]string, bizParams: map[string]any): AlipayOpenApiGenericResponse
*
Alipay Easy SDKOpen APIOpenAPI
*
| | | | |
|------|--------|----|----|
| method | string | | OpenAPIalipay.trade.pay |
| textParams | map[string]string | | ****`biz_content``app_auth_token` |
| bizParams | map[string]any | | `biz_content` |
*
| | | | |
|------|--------|----|----|
| httpBody | string | | HTTPJSON{"alipay_trade_create_response":{"code":"10000","msg":"Success","out_trade_no":"4ac9eac...","trade_no":"202003..."},"sign":"AUumfYgGSe7...02MA=="} |
| code | string | | [](https://docs.open.alipay.com/common/105806) |
| msg | string | | [](https://docs.open.alipay.com/common/105806) |
| subCode | string | | API |
| subMsg | string | | API |
---