---
title: "付款成功通知"
description: "用于接收支付应用付款webhook通知"
doc_type: openapi
doc_category: openapi
doc_version: v20270301
source_url:
  html: 'https://developer.shopline.com/zh-hans-cn/docs/admin-rest-api/payments-app-api/payment-successful-notice'
  md: 'https://developer.shopline.com/zh-hans-cn/docs/admin-rest-api/payments-app-api/payment-successful-notice.md'
---
# 付款成功通知

用于接收支付应用付款webhook通知

- **Base URL:** `https://{handle}.myshopline.com/payments_apps/openapi`
- **Required Scopes:** `write_payment_gateways`
- **API Version:** v20270301
- **API Type:** Admin
- **API Protocol:** RESTful

## Endpoint

```http
POST /payment/notify/:channel_id/:payment_method/pay.json
```

## Base URL

* `https://{handle}.myshopline.com/payments_apps/openapi`

  * `{handle}`: `handle` ：店铺的唯一标识符，值为店铺域名的前缀。例如，域名为 `open001.myshopline.com` 的店铺，其 `handle` 是 `open001` 。

## Required Permissions

* `write_payment_gateways`

## Request

### Path Parameters

* `channel_id`

  string (required)

  渠道id

* `payment_method`

  string (required)

  支付方式

### Request Headers

* `Content-Type`

  string (required)

  字段值固定为 `application/json; charset=utf-8`。

* `Authorization`

  string (required)

  资源的访问令牌。参考 [应用授权](https://developer.shopline.com/zh-hans-cn/docs/apps/api-instructions-for-use/app-authorization.md?lang=zh-hans-cn) 获取访问令牌，然后将获取到的访问令牌以 Bearer 格式传入。

### Request Body

* `channel_order_transaction_id`

  string

  渠道支付单号

* `currency`

  string

  币种。该字段值为三位币种码，遵循ISO 4217 国际标准，例如 CNY。

* `order_transaction_id`

  string

  支付单号

* `status`

  string

  状态

* `amount`

  string

  金额。
  请注意传整数的字符串，不能有小数点，举例：“200” 。

## Response

### Status Codes

* `200`

  更多状态码信息，参考 [HTTP 状态码](https://developer.shopline.com/zh-hans-cn/docs/apps/api-instructions-for-use/http-status-code.md?lang=zh-hans-cn)。

* `401`

  

* `429`

  

### Response Headers

* `traceId`

  请求的全局唯一标识符。用于追踪请求在系统中的流转，以便于问题发生时进行定位和调试。

### Response Body

#### 200

_No response body_

#### 401

* `errors`

  string

  错误描述。


#### 429

* `errors`

  string

  错误描述。


## OpenAPI Definition

```json
{
  "tags": [
    "付款成功通知"
  ],
  "description": "用于接收支付应用付款webhook通知",
  "externalDocs": {
    "description": "接口使用的权限点: `write_payment_gateways` ，更多权限点使用信息，请参考:",
    "url": "ec20/3cv5d7wpfgr6a8z5/xabczf5442284vkq?lang=zh-hans-cn",
    "errorTableDescription": ""
  },
  "operationId": "klsi3GYp",
  "parameters": [
    {
      "name": "channel_id",
      "in": "path",
      "description": "渠道id",
      "required": true,
      "style": "simple",
      "schema": {
        "name": "channel_id",
        "description": "渠道id",
        "type": "string"
      }
    },
    {
      "name": "payment_method",
      "in": "path",
      "description": "支付方式",
      "required": true,
      "style": "simple",
      "schema": {
        "name": "payment_method",
        "description": "支付方式",
        "type": "string"
      }
    },
    {
      "name": "Content-Type",
      "in": "header",
      "description": "字段值固定为 `application/json; charset=utf-8`。",
      "required": true,
      "schema": {
        "name": "Content-Type",
        "type": "string",
        "example": "application/json; charset=utf-8"
      }
    },
    {
      "name": "Authorization",
      "in": "header",
      "description": "资源的访问令牌。参考 [应用授权](https://developer.shopline.com/zh-hans-cn/docs/apps/api-instructions-for-use/app-authorization.md?lang=zh-hans-cn) 获取访问令牌，然后将获取到的访问令牌以 Bearer 格式传入。",
      "required": true,
      "style": "string",
      "schema": {
        "name": "Authorization",
        "description": "资源的访问令牌。参考 [应用授权](https://developer.shopline.com/zh-hans-cn/docs/apps/api-instructions-for-use/app-authorization.md?lang=zh-hans-cn) 获取访问令牌，然后将获取到的访问令牌以 Bearer 格式传入。",
        "type": "string",
        "example": "Bearer eyJhbGciOiJIUzUxMiIsInR5cCI6IkpXVCJ9.eyJhcHBJZCI6MCwiYXBwS2V5IjoiNzU2ZjI1NWE2NjdlZTcwNTk1MzM0ZjVjYzk4NzU5MzBmN2E3NGZjMSIsImV4cCI6MTg3OTQ4MjA3NiwiaXNzIjoieXNvdWwiLCJzZWxsZXJJZCI6IjIwMDAyMzQ4ODAiLCJzdG9yZUlkIjoiMTY3MjM2OTcyOTYwNiIsInRpbWVzdGFtcCI6MTc4NDc4NzY3NjY2MSwidmVyc2lvbiI6IlYyIn0.3ZzbGAH4cLU1QR2VPEvMOQInUDvus-C4amkINSQIPuNVlXsFKj0sAt1c0KnUy9MWUOFV9cHlkf7J90r2y1FzpA"
      },
      "example": "Bearer eyJhbGciOiJIUzUxMiIsInR5cCI6IkpXVCJ9.eyJhcHBJZCI6MCwiYXBwS2V5IjoiNzU2ZjI1NWE2NjdlZTcwNTk1MzM0ZjVjYzk4NzU5MzBmN2E3NGZjMSIsImV4cCI6MTg3OTQ4MjA3NiwiaXNzIjoieXNvdWwiLCJzZWxsZXJJZCI6IjIwMDAyMzQ4ODAiLCJzdG9yZUlkIjoiMTY3MjM2OTcyOTYwNiIsInRpbWVzdGFtcCI6MTc4NDc4NzY3NjY2MSwidmVyc2lvbiI6IlYyIn0.3ZzbGAH4cLU1QR2VPEvMOQInUDvus-C4amkINSQIPuNVlXsFKj0sAt1c0KnUy9MWUOFV9cHlkf7J90r2y1FzpA"
    }
  ],
  "requestBody": {
    "content": {
      "application/json": {
        "schema": {
          "name": "body",
          "description": "body位置参数",
          "type": "object",
          "properties": {
            "channel_order_transaction_id": {
              "name": "channel_order_transaction_id",
              "description": "渠道支付单号",
              "type": "string",
              "example": "string"
            },
            "currency": {
              "name": "currency",
              "description": "币种。该字段值为三位币种码，遵循ISO 4217 国际标准，例如 CNY。",
              "type": "string",
              "example": "For example: USD."
            },
            "order_transaction_id": {
              "name": "order_transaction_id",
              "description": "支付单号",
              "type": "string",
              "example": "string"
            },
            "status": {
              "name": "status",
              "description": "状态",
              "type": "string",
              "example": "string"
            },
            "amount": {
              "name": "amount",
              "description": "金额。\n请注意传整数的字符串，不能有小数点，举例：“200” 。",
              "type": "string",
              "example": "For example, \"200\"."
            }
          },
          "required": [
            "channel_order_transaction_id",
            "amount",
            "currency",
            "order_transaction_id",
            "status"
          ],
          "example": {
            "channel_order_transaction_id": "string",
            "currency": "For example: USD.",
            "order_transaction_id": "string",
            "status": "string",
            "amount": "For example, \"200\"."
          }
        }
      }
    },
    "required": true
  },
  "responses": {
    "200": {
      "description": "更多状态码信息，参考 [HTTP 状态码](https://developer.shopline.com/zh-hans-cn/docs/apps/api-instructions-for-use/http-status-code.md?lang=zh-hans-cn)。",
      "headers": {
        "traceId": {
          "description": "请求的全局唯一标识符。用于追踪请求在系统中的流转，以便于问题发生时进行定位和调试。"
        }
      }
    },
    "401": {
      "headers": {
        "traceId": {
          "description": "请求的全局唯一标识符。用于追踪请求在系统中的流转，以便于问题发生时进行定位和调试。"
        }
      },
      "content": {
        "application/json": {
          "schema": {
            "type": "object",
            "properties": {
              "errors": {
                "description": "错误描述。",
                "type": "string"
              }
            },
            "required": [
              "errors"
            ]
          }
        }
      }
    },
    "429": {
      "headers": {
        "traceId": {
          "description": "请求的全局唯一标识符。用于追踪请求在系统中的流转，以便于问题发生时进行定位和调试。"
        }
      },
      "content": {
        "application/json": {
          "schema": {
            "type": "object",
            "properties": {
              "errors": {
                "description": "错误描述。",
                "type": "string"
              }
            },
            "required": [
              "errors"
            ]
          }
        }
      }
    }
  },
  "security": [
    {
      "oauth2": []
    }
  ],
  "method": "post",
  "path": "/payment/notify/:channel_id/:payment_method/pay.json",
  "servers": [
    {
      "url": "https://{handle}.myshopline.com/payments_apps/openapi",
      "variables": {
        "handle": {
          "default": "openapiceshidianpu",
          "description": "`handle` ：店铺的唯一标识符，值为店铺域名的前缀。例如，域名为 `open001.myshopline.com` 的店铺，其 `handle` 是 `open001` 。"
        }
      }
    }
  ],
  "info": {
    "title": "付款成功通知",
    "version": "v20270301"
  },
  "authIndexes": [
    "write_payment_gateways"
  ]
}
```