Overview

In Control for Commercial Payments (ICCP) streamlines business transactions using configurable spending controls and enhanced data:

Version

CancelPurchaseRequests

Status:

Beta

Version:

V2

Product:

ICCP Solutions

CancelPurchaseRequests

Overview

Cancel a virtual card that’s no longer valid or needed. Cancel up to 50 purchase requests in a single API call.

https://api-sandbox.network.global

CancelPurchaseRequests

Status:

Beta

Version:

V2

Product:

ICCP Solutions
/V2/cardservices/CancelPurchaseRequests
curl --location --request POST '#{PARAM_URL}' --header 'Authorization: Bearer {{ access_token }}' {custom_headers} --data-raw '#{JSON_PAYLOAD}'
curl --location --request GET 'https://api-sandbox.network.global/v1/tokenkc/generate' \--data-raw '#{JSON_PAYLOAD}'
curl --location --request POST 'https://api-sandbox.network.global/v1/tokenkc/generate' \--data-raw '#{JSON_PAYLOAD}'

Node Child Node Type Length Description
Authorization* requiredBearer xxxx* requiredstringAuthorization Header (Bearer Token)
Content-Type* requiredapplication/json* requiredstringContent Type

Node TypeTypeLengthDescription
headermsg_id* requiredstring12Unique Source Message ID
msg_type* requiredstring12Request Type Default TRANSACTION
msg_function* requiredstring50Function name to be used Default REQ_CANCEL_PURCHASE_REQUESTS
src_application* requiredstring10Source requesting channel Ex IVR
target_application* requiredstring10Target application name Ex MC
timestamp* requiredstring30Timestamp of the request Format DD/MM/YYYY HH:MM:SS
bank_id* requiredstring4Source Bank Id Ex bankID
bodypurchase_request_id* requiredarray12

{
    "NISrvRequest": {
        "request_cancel_purchase_requests": {
            "header": {
                "msg_id": "236001",
                "msg_type": "TRANSACTION",
                "msg_function": "REQ_CANCEL_PURCHASE_REQUESTS",
                "src_application": "IVR",
                "target_application": "WAY4",
                "timestamp": "2020-07-20T10:49:02.366+04:00",
                "bank_id": "NIC"
            },
            "body": {
                "purchase_request_id": [
                    "1480449",
                    "1480450"
                ]
            }
        }
    }
}

Node Child Node Type Length Description
Content-Typeapplication/jsonstringContent Type

Node TypeTypeLengthDescription
headermsg_id* requiredstring12The msg_id sent in the request will be sent back in response in this field
msg_type* requiredstring12msg_type sent in the request will be sent back in response in this field
msg_function* requiredstring50Function name to be used default REP_CANCEL_PURCHASE_REQUESTS
src_application* requiredstring10The src_application sent in the request will be sent back in response in this field
target_application* requiredstring10The target_application sent in the request will be sent back in response in this field
timestamp* requiredstring30Timestamp of the request Format DD/MM/YYYY HH:MM:SS
bank_id* requiredstring4The bank_id sent in the request will be sent back in response in this field Eg ABCD
instance_idstring10InstanceID
exception_detailsapplication_namestring20Application Name
date_timestring30Timestamp of the response
statusstring1Status of the request (S/F)
error_codestring4EAI Internal Error Code
error_descriptionstring100Error Description
bodycancel_request_statuspurchase_request_idstring0
approval_successfulstring0
error_messagestring0

{
    "NISrvResponse": {
        "response_cancel_purchase_requests": {
            "header": {
                "msg_id": "236001",
                "msg_type": "TRANSACTION",
                "msg_function": "REP_CANCEL_PURCHASE_REQUESTS",
                "src_application": "IVR",
                "target_application": "CMS",
                "timestamp": "2020-07-20T10:49:02.366+04:00",
                "bank_id": "NIC",
                "instance_id": "InstanceID"
            },
            "exception_details": {
                "application_name": "TCC-ADP",
                "date_time": "2023-02-01T16:39:47.314+04:00",
                "status": "S",
                "error_code": "000",
                "error_description": "Success"
            },
            "body": {
                "cancel_request_status": [
                    {
                        "purchase_request_id": "1480449",
                        "approval_successful": "true",
                        "error_message": " "
                    }
                ]
            }
        }
    }
}

Code Description
200Sample Description
400Bad Request
401Unauthorized
403Forbidden
500Internal Server Error
502Bad gateway
503Scheduled Maintenance
504Gateway Timeout
596Service Not Found