Method: asynchronousCancelFundsReservation
Stay organized with collections
Save and categorize content based on your preferences.
Initiates canceling the funds that were previously reserved in a call to reserveFunds
.
This cancels the pending transaction by freeing the reserved funds. The reservationRequestId
identifies which funds reservation is being canceled. When this is used, there is no money movement from a customer's account for this transaction. The final result of the cancel is supplied by a call to cancelFundsReservationResultNotification
. The requestId
within the header is the idempotency key and uniquely identifies this transaction.
If the reservation of funds has expired or the payment integrator has automatically canceled the reservation, consider it a successful cancel rather than an error. Therefore, return an ACKNOWLEDGED
response code and call cancelFundsReservationResultNotification
.
If the endpoint encounters an error while processing the request, the response body from this endpoint should be of type ErrorResponse
.
An example request looks like:
{
"requestHeader": {
"protocolVersion": {
"major": 1,
"minor": 0,
"revision": 0
},
"requestId": "G1NMPDFX4AW395L",
"requestTimestamp": "1481907920000"
},
"paymentIntegratorAccountId": "SpeedyPaymentsIndia_INR",
"reservationRequestId": "G1MQ0YERJ0Q7LPM"
}
An example response looks like:
{
"responseHeader": {
"responseTimestamp": "1481907920760"
},
"result": "ACKNOWLEDGED"
}
HTTP request
POST https://www.integratorhost.example.com/integrator-base-path/v1/payment-integrator-korea-cards-api/asynchronousCancelFundsReservation
Request body
The request body contains data with the following structure:
JSON representation |
{
"requestHeader": {
object (RequestHeader )
},
"paymentIntegratorAccountId": string,
"reservationRequestId": string
} |
Fields |
requestHeader |
object (RequestHeader )
REQUIRED: Common header for all requests.
|
paymentIntegratorAccountId |
string
REQUIRED: This is the payment integrator account identifier that identifies contractual constraints around this transaction.
|
reservationRequestId |
string
REQUIRED: A unique identifier for this transaction. This is the requestId generated by Google during the reserveFunds or verifyCardWithMinimumReservation calls which this request is associated with.
|
Response body
This method supports multiple return types. For additional information about what 4XX or 5XX HTTP status code to return with an ErrorResponse
, consult the ErrorResponse
object and HTTP status codes documentation.
Possible response messages |
HTTP 200 Status |
object (AsynchronousCancelFundsReservationResponse )
|
HTTP 4XX / 5XX Status |
object (ErrorResponse )
|
AsynchronousCancelFundsReservationResponse
Response object for the payment integrator hosted korea-cards-v1.asynchronousCancelFundsReservation method.
AsynchronousCancelFundsReservationResultCode
Result codes for asynchronousCancelFundsReservation
.
Enums |
ASYNCHRONOUS_CANCEL_FUNDS_RESERVATION_RESULT_CODE_UNSPECIFIED |
Do not ever set this default value! |
ACKNOWLEDGED |
The cancel has been requested and the integrator will do additional steps to determine if the cancel was successful. Once the integrator knows the result of the cancel, they must inform Google of the result by calling the cancelFundsReservationNotification API. |
All rights reserved. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-07-17 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-07-17 UTC."],[[["\u003cp\u003e\u003ccode\u003easynchronousCancelFundsReservation\u003c/code\u003e initiates the cancellation of previously reserved funds, freeing them without any money movement.\u003c/p\u003e\n"],["\u003cp\u003eThe final result of the cancellation is determined asynchronously and communicated to Google via the \u003ccode\u003ecancelFundsReservationResultNotification\u003c/code\u003e API.\u003c/p\u003e\n"],["\u003cp\u003eAn \u003ccode\u003eACKNOWLEDGED\u003c/code\u003e response signifies that the cancellation request has been received and further processing will occur.\u003c/p\u003e\n"],["\u003cp\u003eThis API uses the combination of \u003ccode\u003erequestId\u003c/code\u003e and \u003ccode\u003epaymentIntegratorAccountId\u003c/code\u003e as an idempotency key for unique transaction identification.\u003c/p\u003e\n"],["\u003cp\u003eIf the reservation has already expired or been canceled, it is considered a successful cancellation, and an \u003ccode\u003eACKNOWLEDGED\u003c/code\u003e response should be returned.\u003c/p\u003e\n"]]],["This documentation details how to asynchronously cancel previously reserved funds. Key actions include sending a `POST` request to the specified endpoint with a JSON body containing a `requestHeader`, `paymentIntegratorAccountId`, and `reservationRequestId`. This initiates canceling the funds. The response can be either `ACKNOWLEDGED`, signifying the request was received and will be processed or an `ErrorResponse`. The final cancel result will be provided through a call to `cancelFundsReservationResultNotification`.\n"],null,["# Method: asynchronousCancelFundsReservation\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Request body](#body.request_body)\n - [JSON representation](#body.request_body.SCHEMA_REPRESENTATION)\n- [Response body](#body.response_body)\n- [AsynchronousCancelFundsReservationResponse](#AsynchronousCancelFundsReservationResponse)\n - [JSON representation](#AsynchronousCancelFundsReservationResponse.SCHEMA_REPRESENTATION)\n- [AsynchronousCancelFundsReservationResultCode](#AsynchronousCancelFundsReservationResultCode)\n\nInitiates canceling the funds that were previously reserved in a call to [`reserveFunds`](/pay/korea-cards-v1/payment-integrator-korea-cards-api/reserveFunds#google.standardpayments.flows.card_fop_reserve_capture.v1.PaymentIntegratorCardReserveCaptureService.ReserveFunds).\n\nThis cancels the pending transaction by freeing the reserved funds. The `reservationRequestId` identifies which funds reservation is being canceled. When this is used, there is no money movement from a customer's account for this transaction. The final result of the cancel is supplied by a call to `cancelFundsReservationResultNotification`. The `requestId` within the header is the idempotency key and uniquely identifies this transaction.\n\nIf the reservation of funds has expired or the payment integrator has automatically canceled the reservation, consider it a successful cancel rather than an error. Therefore, return an `ACKNOWLEDGED` response code and call `cancelFundsReservationResultNotification`.\n\nIf the endpoint encounters an error while processing the request, the response body from this endpoint should be of type [`ErrorResponse`](/pay/korea-cards-v1/payment-integrator-korea-cards-api/ErrorResponse).\n\nAn example request looks like: \n\n\n {\n \"requestHeader\": {\n \"protocolVersion\": {\n \"major\": 1,\n \"minor\": 0,\n \"revision\": 0\n },\n \"requestId\": \"G1NMPDFX4AW395L\",\n \"requestTimestamp\": \"1481907920000\"\n },\n \"paymentIntegratorAccountId\": \"SpeedyPaymentsIndia_INR\",\n \"reservationRequestId\": \"G1MQ0YERJ0Q7LPM\"\n }\n\nAn example response looks like: \n\n\n {\n \"responseHeader\": {\n \"responseTimestamp\": \"1481907920760\"\n },\n \"result\": \"ACKNOWLEDGED\"\n }\n\n### HTTP request\n\n`POST https://www.integratorhost.example.com/integrator-base-path/v1/payment-integrator-korea-cards-api/asynchronousCancelFundsReservation`\n\n### Request body\n\nThe request body contains data with the following structure:\n\n| JSON representation |\n|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"requestHeader\": { object (/pay/korea-cards-v1/payment-integrator-korea-cards-api/RequestHeader) }, \"paymentIntegratorAccountId\": string, \"reservationRequestId\": string } ``` |\n\n| Fields ||\n|------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `requestHeader` | `object (`[RequestHeader](/pay/korea-cards-v1/payment-integrator-korea-cards-api/RequestHeader)`)` **REQUIRED**: Common header for all requests. |\n| `paymentIntegratorAccountId` | `string` **REQUIRED**: This is the payment integrator account identifier that identifies contractual constraints around this transaction. |\n| `reservationRequestId` | `string` **REQUIRED** : A unique identifier for this transaction. This is the `requestId` generated by Google during the `reserveFunds` or `verifyCardWithMinimumReservation` calls which this request is associated with. |\n\n### Response body\n\nThis method supports multiple return types. For additional information about what 4XX or 5XX HTTP status code to return with an `ErrorResponse`, consult the `ErrorResponse` object and [HTTP status codes documentation](/pay/korea-cards-v1/guides/connectivity/protocol-standards#http_status_codes).\n\n| Possible response messages ||\n|-----------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| HTTP 200 Status | `object (`[AsynchronousCancelFundsReservationResponse](/pay/korea-cards-v1/payment-integrator-korea-cards-api/asynchronousCancelFundsReservation#AsynchronousCancelFundsReservationResponse)`)` |\n| HTTP 4XX / 5XX Status | `object (`[ErrorResponse](/pay/korea-cards-v1/payment-integrator-korea-cards-api/ErrorResponse)`)` |\n\nAsynchronousCancelFundsReservationResponse\n------------------------------------------\n\nResponse object for the payment integrator hosted korea-cards-v1.asynchronousCancelFundsReservation method.\n\n| JSON representation |\n|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"responseHeader\": { object (/pay/korea-cards-v1/payment-integrator-korea-cards-api/ResponseHeader) }, \"result\": enum (/pay/korea-cards-v1/payment-integrator-korea-cards-api/asynchronousCancelFundsReservation#AsynchronousCancelFundsReservationResultCode) } ``` |\n\n| Fields ||\n|------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `responseHeader` | `object (`[ResponseHeader](/pay/korea-cards-v1/payment-integrator-korea-cards-api/ResponseHeader)`)` **REQUIRED**: Common header for all responses. |\n| `result` | `enum (`[AsynchronousCancelFundsReservationResultCode](/pay/korea-cards-v1/payment-integrator-korea-cards-api/asynchronousCancelFundsReservation#AsynchronousCancelFundsReservationResultCode)`)` **REQUIRED** : The result of the `asynchronousCancelFundsReservation` call. |\n\nAsynchronousCancelFundsReservationResultCode\n--------------------------------------------\n\nResult codes for `asynchronousCancelFundsReservation`.\n\n| Enums ||\n|-----------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `ASYNCHRONOUS_CANCEL_FUNDS_RESERVATION_RESULT_CODE_UNSPECIFIED` | Do not ever set this default value! |\n| `ACKNOWLEDGED` | The cancel has been requested and the integrator will do additional steps to determine if the cancel was successful. Once the integrator knows the result of the cancel, they must inform Google of the result by calling the `cancelFundsReservationNotification` API. |"]]