Overview

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

Version

UpdatePurchaseRequest

Status:

Beta

Version:

V2

Product:

ICCP Solutions

UpdatePurchaseRequest

Overview

Update the details of a purchase request, including the controls on the VCN. Include the unchanged data and controls sent in the initial submitPurchaseRequest call along with the details to update. This call does not generate a new VCN, but will update the controls on the existing VCN if appropriate.

https://api-sandbox.network.global

UpdatePurchaseRequest

Status:

Beta

Version:

V2

Product:

ICCP Solutions
/V2/cardservices/UpdatePurchaseRequest
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_UPDATE_PURCHASE_REQUEST
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
bodyupdate_purchase_requestrcn_data* requiredobject
rcn_data/rcn_id* requiredstring
rcn_data/rcn_alias* requiredstring
data_source_id* requiredstring
company_id* requiredstring
valid_for* requiredstring
description* requiredstring
template_details* requiredobject
template_details/template_id* requiredstring
template_details/template_rule_details* requiredobject
template_details/template_rule_details/rule_name* requiredstring
template_details/template_rule_details/rule_type* requiredstring
template_details/template_rule_details/template_control* requiredArray
template_details/template_rule_details/template_control/max_transstring
template_details/template_rule_details/template_control/cumulative_limitstring
template_details/template_rule_details/template_control/periodstring
template_details/template_rule_details/template_control/currency_typestring
template_details/template_rule_details/template_control/currency_codestring
template_details/template_rule_details/template_control/end_datestring
template_details/template_custom_fields* requiredArray
template_details/template_custom_fields/namestring
template_details/template_custom_fields/valuestring
supplier_details* requiredobject
supplier_details/supplier_id* requiredstring
disable_card_image* requiredstring

{
    "NISrvRequest": {
        "request_update_purchase_request": {
            "header": {
                "msg_id": "236001",
                "msg_type": "TRANSACTION",
                "msg_function": "REQ_UPDATE_PURCHASE_REQUEST",
                "src_application": "IVR",
                "target_application": "WAY4",
                "timestamp": "2020-07-20T10:49:02.366+04:00",
                "bank_id": "NIC"
            },
            "body": {
                "update_purchase_request": {
                    "rcn_data": {
                        "rcn_id": "13800",
                        "rcn_alias": "Sandbox Card"
                    },
                    "data_source_id": "4272",
                    "company_id": "427521",
                    "valid_for": "12",
                    "description": "My Purchase Request",
                    "template_details": {
                        "template_id": "21680",
                        "template_rule_details": {
                            "rule_name": "My Rule",
                            "rule_type": "A",
                            "template_control": [
                                {
                                    "max_trans": "1",
                                    "cumulative_limit": "149.54",
                                    "period": "C",
                                    "currency_type": "B",
                                    "currency_code": "840",
                                    "end_date": "2020-12-26-05:00"
                                }
                            ]
                        },
                        "template_custom_fields": [
                            {
                                "name": "Purchase Type",
                                "value": "Airlines"
                            }
                        ]
                    },
                    "supplier_details": {
                        "supplier_id": "14100"
                    },
                    "disable_card_image": "N"
                }
            }
        }
    }
}

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_SUBMIT_PURCHASE_REQUEST
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
bodypurchase_request_detailspurchase_request_id* requiredstring
request_status* requiredstring
template_details* requiredobject
template_details/template_id* requiredstring
template_details/template_rule_details* requiredobject
template_details/template_rule_details/rule_name* requiredstring
template_details/template_rule_details/rule_type* requiredstring
template_details/template_rule_details/template_control* requiredArray
template_details/template_rule_details/template_control/max_transstring
template_details/template_rule_details/template_control/cumulative_limitstring
template_details/template_rule_details/template_control/periodstring
template_details/template_rule_details/template_control/currency_typestring
template_details/template_rule_details/template_control/currency_codestring
template_details/template_rule_details/template_control/end_datestring
template_details/template_custom_fields* requiredArray
template_details/template_custom_fields/namestring
template_details/template_custom_fields/valuestring
vcn_information* requiredobject
vcn_information/id* requiredstring
vcn_information/pan* requiredstring
vcn_information/expiry* requiredstring
vcn_information/AVV* requiredstring
vcn_information/status* requiredstring
vcn_information/evcn_indicator* requiredstring
addenda* requiredArray
addenda/trip_legstring
addenda/rail_detailstring
addenda/travel_agencystring
card_image* requiredstring
supplier_details* requiredobject
supplier_details/supplier_id* requiredstring
supplier_details/notify_supplier* requiredstring
disable_card_image* requiredstring

{
    "NISrvResponse": {
        "response_update_purchase_request": {
            "header": {
                "msg_id": "236001",
                "msg_type": "TRANSACTION",
                "msg_function": "REP_SUBMIT_PURCHASE_REQUEST",
                "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": {
                "purchase_request_details": {
                    "purchase_request_id": "1243255",
                    "request_status": "Approved",
                    "template_details": {
                        "template_id": "55024",
                        "template_rule_details": {
                            "rule_name": "B",
                            "rule_type": "A",
                            "template_control": [
                                {
                                    "max_trans": "4567",
                                    "cumulative_limit": "567.0",
                                    "period": "D",
                                    "currency_type": "B",
                                    "currency_code": "USD",
                                    "end_date": "2023-07-29"
                                }
                            ]
                        },
                        "template_custom_fields": [
                            {
                                "name": "Purchase Type",
                                "value": "1"
                            }
                        ]
                    },
                    "vcn_information": {
                        "id": "1124960",
                        "pan": "541275XXXXXX9999",
                        "expiry": "2111",
                        "AVV": "435",
                        "status": "S",
                        "evcn_indicator": "false"
                    },
                    "addenda": [
                        {
                            "trip_leg": " ",
                            "rail_detail": " ",
                            "travel_agency": " "
                        }
                    ],
                    "card_image": " ",
                    "supplier_details": {
                        "supplier_id": "227613",
                        "notify_supplier": "false"
                    },
                    "disable_card_image": "N"
                }
            }
        }
    }
}

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