1 Star 1 Fork 0

颜言/gopay

加入 Gitee
与超过 1400万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
consumption.go 621 Bytes
一键复制 编辑 原始数据 按行查看 历史
颜言 提交于 2024-09-12 18:05 +08:00 . 项目地址迁移至gitee.com/ujq/gopay
package apple
import (
"context"
"fmt"
"net/http"
"gitee.com/ujq/gopay"
)
// SendConsumptionInformation Send Consumption Information
// Doc: https://developer.apple.com/documentation/appstoreserverapi/send_consumption_information
func (c *Client) SendConsumptionInformation(ctx context.Context, transactionId string, bm gopay.BodyMap) (err error) {
path := fmt.Sprintf(sendConsumptionInformation, transactionId)
res, _, err := c.doRequestPut(ctx, path, bm)
if err != nil {
return err
}
if res.StatusCode != http.StatusAccepted {
return fmt.Errorf("http.stauts_code = %d", res.StatusCode)
}
return nil
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Go
1
https://gitee.com/ujq/gopay.git
git@gitee.com:ujq/gopay.git
ujq
gopay
gopay
95cb943fb81a

搜索帮助