

本文為英文版的機器翻譯版本，如內容有任何歧義或不一致之處，概以英文版為準。

# 取消和計費調整事件
<a name="cancellation-adjustment-eventbridge"></a>

AWS Marketplace 當賣方針對您的其中一個協議啟動取消請求或帳單調整時， 會向 Amazon EventBridge 傳送通知。您可以使用這些事件來自動化工作流程，並追蹤取消和退款活動。

下表列出 AWS Marketplace 傳送至 EventBridge 以進行取消和帳單調整的買方事件：


| 事件 | Description | 
| --- | --- | 
| 待核准協議取消請求 - 接受者 | 當賣方提交您協議的取消請求時傳送。必要動作：您有 7 天的時間核准或拒絕。 | 
| 協議取消請求已核准 - 接受者 | 當您核准取消請求或在 7 天後自動核准時傳送 | 
| 協議取消請求遭拒 - 接受者 | 當您拒絕取消請求時傳送 | 
| 協議取消請求已取消 - 接受者 | 當賣方撤銷取消請求時傳送 | 
| 購買協議帳單調整已完成 - 接受者 | 在處理您協議的帳單調整 （退款） 時傳送 | 

所有事件都會傳送到 `us-east-1`區域中具有事件來源 的預設 EventBridge 事件匯流排`aws.agreement-marketplace`。

## 取消請求事件類型
<a name="cancellation-event-types"></a>

### 待核准協議取消請求 - 接受者
<a name="cancellation-pending-approval-acceptor"></a>

AWS Marketplace 當賣方提交您其中一個協議的取消請求時， 會傳送此事件。您有 7 天的時間來核准或拒絕請求。如果您未回應，系統會自動核准取消。

**事件結構描述：**

```
{
  "version": "0",
  "id": "01234567-0123-0123-0123-0123456789ab",
  "detail-type": "Agreement Cancellation Request Pending Approval - Acceptor",
  "source": "aws.agreement-marketplace",
  "account": "123456789012",
  "time": "2025-01-01T13:12:22Z",
  "region": "us-east-1",
  "resources": [],
  "detail": {
    "requestId": "3d4c9f9b-b809-4f5e-9fac-a9ae98b05cbb",
    "catalog": "AWSMarketplace",
    "agreement": {
      "id": "agmt-abcdexampleid",
      "proposerId": "123456789012",
      "productId": "prod-exampleid",
      "offerId": "offer-exampleid"
    },
    "agreementCancellationRequest": {
      "id": "acr-abcdexampleid",
      "reasonCode": "INCORRECT_TERMS_ACCEPTED",
      "reasonMessage": "",
      "statusCode": "PENDING_APPROVAL",
      "statusMessage": "",
      "createdAt": "2025-01-01T13:12:22Z",
      "updatedAt": "2025-01-01T13:12:22Z"
    }
  }
}
```

### 協議取消請求已核准 - 接受者
<a name="cancellation-approved-acceptor"></a>

AWS Marketplace 當您其中一個協議的取消請求獲得核准時， 會傳送此事件。當您核准請求或在 7 天後沒有回應自動核准請求時，可能會發生這種情況。

**事件結構描述：**

```
{
  "version": "0",
  "id": "01234567-0123-0123-0123-0123456789ab",
  "detail-type": "Agreement Cancellation Request Approved - Acceptor",
  "source": "aws.agreement-marketplace",
  "account": "123456789012",
  "time": "2025-01-01T13:16:07Z",
  "region": "us-east-1",
  "resources": [],
  "detail": {
    "requestId": "3d4c9f9b-b809-4f5e-9fac-a9ae98b05cbb",
    "catalog": "AWSMarketplace",
    "agreement": {
      "id": "agmt-abcdexampleid",
      "proposerId": "123456789012",
      "productId": "prod-exampleid",
      "offerId": "offer-exampleid"
    },
    "agreementCancellationRequest": {
      "id": "acr-abcdexampleid",
      "reasonCode": "INCORRECT_TERMS_ACCEPTED",
      "reasonMessage": "The terms accepted in agreement had wrong rate",
      "statusCode": "APPROVED",
      "statusMessage": "",
      "createdAt": "2025-01-01T13:12:22Z",
      "updatedAt": "2025-01-01T13:16:07Z"
    }
  }
}
```

### 協議取消請求遭拒 - 接受者
<a name="cancellation-rejected-acceptor"></a>

AWS Marketplace 當您拒絕其中一個協議的取消請求時， 會傳送此事件。

**事件結構描述：**

```
{
  "version": "0",
  "id": "01234567-0123-0123-0123-0123456789ab",
  "detail-type": "Agreement Cancellation Request Rejected - Acceptor",
  "source": "aws.agreement-marketplace",
  "account": "123456789012",
  "time": "2025-01-02T10:30:00Z",
  "region": "us-east-1",
  "resources": [],
  "detail": {
    "requestId": "3d4c9f9b-b809-4f5e-9fac-a9ae98b05cbb",
    "catalog": "AWSMarketplace",
    "agreement": {
      "id": "agmt-abcdexampleid",
      "proposerId": "123456789012",
      "productId": "prod-exampleid",
      "offerId": "offer-exampleid"
    },
    "agreementCancellationRequest": {
      "id": "acr-abcdexampleid",
      "reasonCode": "INCORRECT_TERMS_ACCEPTED",
      "reasonMessage": "",
      "statusCode": "REJECTED",
      "statusMessage": "We still need this product",
      "createdAt": "2025-01-01T13:12:22Z",
      "updatedAt": "2025-01-02T10:30:00Z"
    }
  }
}
```

### 協議取消請求已取消 - 接受者
<a name="cancellation-cancelled-acceptor"></a>

AWS Marketplace 會在賣方在您回應之前撤銷取消請求時傳送此事件。

**事件結構描述：**

```
{
  "version": "0",
  "id": "01234567-0123-0123-0123-0123456789ab",
  "detail-type": "Agreement Cancellation Request Cancelled - Acceptor",
  "source": "aws.agreement-marketplace",
  "account": "123456789012",
  "time": "2025-01-02T08:00:00Z",
  "region": "us-east-1",
  "resources": [],
  "detail": {
    "requestId": "3d4c9f9b-b809-4f5e-9fac-a9ae98b05cbb",
    "catalog": "AWSMarketplace",
    "agreement": {
      "id": "agmt-abcdexampleid",
      "proposerId": "123456789012",
      "productId": "prod-exampleid",
      "offerId": "offer-exampleid"
    },
    "agreementCancellationRequest": {
      "id": "acr-abcdexampleid",
      "reasonCode": "INCORRECT_TERMS_ACCEPTED",
      "reasonMessage": "",
      "statusCode": "CANCELLED",
      "statusMessage": "Seller withdrew the request",
      "createdAt": "2025-01-01T13:12:22Z",
      "updatedAt": "2025-01-02T08:00:00Z"
    }
  }
}
```

## 帳單調整事件類型
<a name="billing-adjustment-event-types"></a>

### 購買協議帳單調整已完成 - 接受者
<a name="billing-adjustment-successful-acceptor"></a>

AWS Marketplace 會在處理您其中一個協議的帳單調整 （退款） 時傳送此事件。

**事件結構描述：**

```
{
  "version": "0",
  "id": "01234567-0123-0123-0123-0123456789ab",
  "detail-type": "Purchase Agreement Billing Adjustment Completed - Acceptor",
  "source": "aws.agreement-marketplace",
  "account": "123456789012",
  "time": "2025-01-01T14:00:00Z",
  "region": "us-east-1",
  "resources": [],
  "detail": {
    "requestId": "3d4c9f9b-b809-4f5e-9fac-a9ae98b05cbb",
    "catalog": "AWSMarketplace",
    "agreement": {
      "id": "agmt-abcdexampleid"
    },
    "billingAdjustmentRequest": {
      "id": "ba-abcdexampleid",
      "adjustmentAmount": "-1000.00",
      "currencyCode": "USD",
      "adjustmentReasonCode": "INCORRECT_TERMS_ACCEPTED"
    },
    "invoice": {
      "originalInvoiceId": "2028746221"
    }
  }
}
```

如需回應取消請求和追蹤帳單調整的詳細資訊，請參閱 [中的退款和取消 AWS Marketplace](buyer-refunds.md)。