voidPayments

post

/ccagent/v1/payment/void

Void PaymentGroups of an order.

Request

Supported Media Types
Body ()
Root Schema : voidPayments_request
Type: object
Show Source
Example:
{
    "orderId":"o80413",
    "payments":[
        {
            "paymentGroupId":"pg80413",
            "customProperties":{
                "cust-prop2":"cust-prop2",
                "cust-prop1":"cust-prop1"
            },
            "cancelReason":"would like to use another gift card"
        },
        {
            "paymentGroupId":"pg80414",
            "customProperties":{
                "cust-prop2":"cust-prop2",
                "cust-prop1":"cust-prop1"
            },
            "cancelReason":"would like to use another credit card"
        }
    ]
}
Nested Schema : payments
Type: array
The array of Payment groups to be cancelled from the order.
Show Source
Nested Schema : items
Type: object
Show Source
Back to Top

Response

Supported Media Types

200 Response

Following model is returned when operation succeeds.
Body ()
Root Schema : voidPayments_response
Type: object
Show Source
Nested Schema : paymentResponses
Type: array
The array of payment responses from void payment endpoint
Show Source
Nested Schema : items
Type: object
Show Source
Nested Schema : customPaymentProperties
Type: object
Custom Payment Properties
Example Response (application/json)
{
    "orderId":"o50419",
    "paymentResponses":[
        {
            "paymentGroupId":"pg50414",
            "customPaymentProperties":{
                "sample-addnl-property-key2":"sample-payment-property-value2",
                "cust-prop2":"cust-prop2",
                "cust-prop1":"cust-prop1"
            },
            "gatewayName":"PP-A",
            "paymentMethod":"onlinePaymentGroup",
            "paymentState":"REMOVED",
            "message":""
        }
    ]
}

Default Response

The error response. The following are the internal error codes thrown by this API when the request processing fails in Oracle Commerce Cloud: |Error Code|Description| |------------------|------------------| |51176|An error occurred canceling payment groups.| |51177|An error occurred canceling payment groups.| |51178|The cancellation of payment groups is not allowed.| |51179|The Payment Group is invalid and does not belong to order.|
Body ()
Root Schema : errorModel
Type: object
Show Source
Nested Schema : errors
Type: array
An optional list of errors if multiple errors were encountered
Show Source
Nested Schema : items
Type: object
Show Source
Back to Top