Cancel a Transaction

Stops a transaction from being processed

This API call changes the transaction status to CANCELED but the transaction record will still show up in results. Only transactions with CREATED or QUEUED status can be canceled, except in case of CHECK-US.

In case of CHECK-US to stop checks from cashing, you can "Delete" transactions even when they are on PROCESSING-DEBIT or PROCESSING-CREDIT.

API ENDPOINT

https://uat-api.synapsefi.com/v3.1/users/:user_id/nodes/:node_id/trans/:trans_id

PATH PARAMETER

user_id :
required
string

The user ID of the user

node_id :
required
string

The node ID of the node

trans_id :
required
string

The transaction ID

EXAMPLE REQUEST

DELETE /v3.1/users/594e6da41acea2002e666987/nodes/594e6e6c12e17a002f2e39e4/trans/594e73854599e8002fe62e53 HTTP/1.1
Host: uat-api.synapsefi.com
X-SP-USER-IP: 127.0.0.1
X-SP-USER: oauth_fyBaT5kswdlme0xQI6gSCPYKDG1Zrv8Ftj9NboJc|e83cf6ddcf778e37bfe3d48fc78a6502062fc
node_id = '594e606212e17a002f2e3251'
trans_id = '594e72124599e8002fe62e4f'

user.cancel_trans(node_id, trans_id)
const nodeID = '594e606212e17a002f2e3251';
const trxnID = '594e72124599e8002fe62e4f';

user.deleteTransaction(nodeID, trxnID);
node_id= "594e6e6c12e17a002f2e39e4"
transaction_id= "594e73854599e8002fe62e53"

user.cancel_transaction(node_id: node_id, trans_id: transaction_id)
nodeID := "594e606212e17a002f2e3251"
transactionID := "594e72124599e8002fe62e4f"

data, err := user.CancelTransaction(nodeID, transactionID)
$node_id= "594e6e6c12e17a002f2e39e4"
$transaction_id= "594e73854599e8002fe62e53"
$user->cancel_trans($nodeid, $transid)

EXAMPLE RESPONSE

{
    "_id": "594e73854599e8002fe62e53",
    "_links": {
        "self": {
            "href": "https://uat-api.synapsefi.com/v3.1/users/594e6da41acea2002e666987/nodes/594e6e6c12e17a002f2e39e4/trans/594e73854599e8002fe62e53"
        }
    },
    "_v": 2,
    "amount": {
        "amount": 20.1,
        "currency": "USD"
    },
    "client": {
        "id": "589acd9ecb3cd400fa75ac06",
        "name": "SynapseFI"
    },
    "extra": {
        "created_on": 1498313605558,
        "ip": "192.168.0.1",
        "latlon": "0,0",
        "note": "",
        "process_on": 1498313605558,
        "supp_id": ""
    },
    "fees": [
        {
            "fee": 0.2,
            "note": "Synapse Facilitator Fee",
            "to": {
                "id": "55b3f8c686c2732b4c4e9df6"
            }
        }
    ],
    "from": {
        "id": "594e6e6c12e17a002f2e39e4",
        "nickname": "Fake Account",
        "type": "ACH-US",
        "user": {
            "_id": "594e6da41acea2002e666987",
            "legal_names": [
                "Test User"
            ]
        }
    },
    "recent_status": {
        "date": 1498313614928,
        "note": "Transaction Cancled.",
        "status": "CANCELED",
        "status_id": "5"
    },
    "timeline": [
        {
            "date": 1498313605558,
            "note": "Transaction Created.",
            "status": "CREATED",
            "status_id": "1"
        },
        {
            "date": 1498313614928,
            "note": "Transaction Cancled.",
            "status": "CANCELED",
            "status_id": "5"
        }
    ],
    "to": {
        "id": "594e6e6c12e17a002f2e39e4",
        "nickname": "Fake Account",
        "type": "ACH-US",
        "user": {
            "_id": "594e6da41acea2002e666987",
            "legal_names": [
                "Test User"
            ]
        }
    }
}