Create Transaction
post
https://api.synapsefi.com
/v3.1/users/:user_id/nodes/:node_id/trans
Transactions
Please note that RDFI ACH, Wire Transactions, Internal Transactions and Card Transactions are transactions that cannot be created by the API as by the very nature of the transaction, the user accounts receive them vs create them via the API.
Go to Transaction Object Details to see all the required and optional body parameters allowed during transaction creation. Following are a few examples of various types of transactions and how to create them:

Create Transactions between Nodes

Below is an example of how to create a transaction between two nodes that exist in Synapse. If you wish to cover transaction fees, see our transaction fee resource.
HTTP
cURL
Python
JS
PHP
GO
1
POST /v3.1/users/5fe50a777562960078d3a5c6/nodes/5fe50b2dab6ce7004340c43a/trans HTTP/1.1
2
Host: uat-api.synapsefi.com
3
X-SP-USER-IP: 255.127.79.76
4
X-SP-USER: oauth_ohpVj1iwMQgqHR0ATzbGEU4fBuXOJ0FWZk28y7cD|e83cf6ddcf778e37bfe3d48fc78a6502062fc
5
Content-Type: application/json
6
7
{
8
"to": {
9
"type": "DEPOSIT-US",
10
"id": "5fe96562c54d7b7bcda9b9da"
11
},
12
"amount": {
13
"amount": 100.1,
14
"currency": "USD"
15
},
16
"extra": {
17
"ip": "255.127.79.76",
18
"note": "Test transaction"
19
}
20
}
Copied!
1
curl --location --request POST 'https://uat-api.synapsefi.com/v3.1/users/5fe50a777562960078d3a5c6/nodes/5fe50b2dab6ce7004340c43a/trans' \
2
--header 'X-SP-USER-IP: 255.127.79.76' \
3
--header 'X-SP-USER: oauth_ohpVj1iwMQgqHR0ATzbGEU4fBuXOJ0FWZk28y7cD|e83cf6ddcf778e37bfe3d48fc78a6502062fc' \
4
--header 'Content-Type: application/json'
5
--data-raw '{
6
"to": {
7
"type": "DEPOSIT-US",
8
"id": "5fe96562c54d7b7bcda9b9da"
9
},
10
"amount": {
11
"amount": 100.1,
12
"currency": "USD"
13
},
14
"extra": {
15
"ip": "255.127.79.76",
16
"note": "Test transaction"
17
}
18
}'
Copied!
1
//
Copied!
1
//
Copied!
1
//
Copied!
1
//
Copied!

Create RDC Transactions

Unlike Transactions between Nodes, for RDC transactions, both from and to nodes are part of the payload, while from is not really a node, its the RDC data:
HTTP
cURL
Python
JS
PHP
GO
1
POST /v3.1/users/5fe50a777562960078d3a5c6/nodes/5fe96562c54d7b7bcda9b9da/trans HTTP/1.1
2
Host: uat-api.synapsefi.com
3
X-SP-USER-IP: 255.127.79.76
4
X-SP-USER: oauth_ohpVj1iwMQgqHR0ATzbGEU4fBuXOJ0FWZk28y7cD|e83cf6ddcf778e37bfe3d48fc78a6502062fc
5
Content-Type: application/json
6
7
{
8
"from":{
9
"type":"RDC",
10
"meta":{
11
"check_front":"data:image/gif;base64,SUQs==",
12
"check_back":"data:image/gif;base64,SUQs=="
13
}
14
},
15
"to": {
16
"type": "DEPOSIT-US",
17
"id": "5fe96562c54d7b7bcda9b9da"
18
},
19
"amount": {
20
"amount": 500.1,
21
"currency": "USD"
22
},
23
"extra": {
24
"ip": "255.127.79.76",
25
"note": "Test transaction"
26
}
27
}
Copied!
1
curl --location --request POST 'https://uat-api.synapsefi.com/v3.1/users/5fe50a777562960078d3a5c6/nodes/5fe96562c54d7b7bcda9b9da/trans' \
2
--header 'X-SP-USER-IP: 255.127.79.76' \
3
--header 'X-SP-USER: oauth_ohpVj1iwMQgqHR0ATzbGEU4fBuXOJ0FWZk28y7cD|e83cf6ddcf778e37bfe3d48fc78a6502062fc' \
4
--header 'Content-Type: application/json' \
5
--data-raw '{
6
"from":{
7
"type":"RDC",
8
"meta":{
9
"check_front":"data:image/gif;base64,SUQs==",
10
"check_back":"data:image/gif;base64,SUQs=="
11
}
12
},
13
"to": {
14
"type": "DEPOSIT-US",
15
"id": "5fe96562c54d7b7bcda9b9da"
16
},
17
"amount": {
18
"amount": 500.1,
19
"currency": "USD"
20
},
21
"extra": {
22
"ip": "255.127.79.76",
23
"note": "Test transaction"
24
}
25
}'
Copied!
1
//
Copied!
1
//
Copied!
1
//
Copied!
1
//
Copied!

Create Buy/Sell Crypto Transactions

To buy/sell crypto, designate the type of crypto that you want to buy/sell using the asset field. The amount.currency has to be consistent with the currency of the sending node. To perform a limit buy (ex. set a max USD-to-BTC threshold below which you will not buy a given amount of Bitcoin), set extra.rate_limit to that maximum buying threshold. For instance, set your desired rate (extra.rate_limit) to .0002 if you wish to use each $1 of your order to purchase at least .0002 BTC (i.e. only execute the order when BTC-to-USD price is $5000 or less). The buy order will not execute if the prevailing rate is lower than your desired extra.rate_limit. And vice versa for transactions going the other way.
HTTP Request
cURL
1
POST /v3.1/users/6123c2edf8db934abad02c3c/nodes/6123c320ab6ce74acc7d53ec/trans HTTP/1.1
2
Host: uat-api.synapsefi.com
3
X-SP-USER-IP: 255.127.79.76
4
X-SP-USER: oauth_ynb1ajm2lSPhx3uMqXwA9e8dOQcBYktRsiKGTpHg|e83cf6ddcf778e37bfe3d48fc78a6502062fc
5
Content-Type: application/json
6
7
{
8
"to": {
9
"type": "CRYPTO-US",
10
"id": "6123c33a7e08874925b2fc6c"
11
},
12
"amount": {
13
"amount": 100,
14
"currency": "USD"
15
},
16
"extra": {
17
"ip": "255.127.79.76",
18
"note": "Test transaction",
19
"asset": "BTC"
20
}
21
}
Copied!
1
curl --location --request POST 'https://uat-api.synapsefi.com/v3.1/users/6123c2edf8db934abad02c3c/nodes/6123c320ab6ce74acc7d53ec/trans' \
2
--header 'X-SP-USER-IP: 255.127.79.76' \
3
--header 'X-SP-USER: oauth_ynb1ajm2lSPhx3uMqXwA9e8dOQcBYktRsiKGTpHg|e83cf6ddcf778e37bfe3d48fc78a6502062fc' \
4
--header 'Content-Type: application/json' \
5
--data-raw '{
6
"to": {
7
"type": "CRYPTO-US",
8
"id": "6123c33a7e08874925b2fc6c"
9
},
10
"amount": {
11
"amount": 100,
12
"currency": "USD"
13
},
14
"extra": {
15
"ip": "255.127.79.76",
16
"note": "Test transaction",
17
"asset": "BTC"
18
}
19
}'
Copied!

Create SRN Transactions

SRNs allow you to transfer funds from a CRYPTO-US account to an external wallet address. Currently, Synapse only supports bitcoin, ethereum, ethereum_dai and usdc.
SRN stands for System Resource Name. Here it's being used to define an external payment address that is not created or managed by Synapse. Currently it stands for bitcoin and ethereum wallet addresses, but later can be used for payment gateways like PayID.
HTTP
cURL
1
POST /v3.1/users/5fe50a777562960078d3a5c6/nodes/5fe4267d7e08870043683e75/trans HTTP/1.1
2
Host: uat-api.synapsefi.com
3
X-SP-USER-IP: 255.127.79.76
4
X-SP-USER: oauth_ohpVj1iwMQgqHR0ATzbGEU4fBuXOJ0FWZk28y7cD|e83cf6ddcf778e37bfe3d48fc78a6502062fc
5
Content-Type: application/json
6
7
{
8
"to": {
9
"type": "SRN",
10
"meta": {
11
"srn_type": "bitcoin",
12
"srn_address": "1BvBMSEYstWetqTFn5Au4m4GFg7xJaNVN2"
13
}
14
},
15
"amount": {
16
"amount": 100.1,
17
"currency": "SATOSHI"
18
},
19
"extra": {
20
"ip": "255.127.79.76",
21
"note": "Test transaction"
22
}
23
}
Copied!
1
curl --location --request POST 'https://uat-api.synapsefi.com/v3.1/users/5fe50a777562960078d3a5c6/nodes/5fe4267d7e08870043683e75/trans' \
2
--header 'X-SP-USER-IP: 255.127.79.76' \
3
--header 'X-SP-USER: oauth_ohpVj1iwMQgqHR0ATzbGEU4fBuXOJ0FWZk28y7cD|e83cf6ddcf778e37bfe3d48fc78a6502062fc' \
4
--header 'Content-Type: application/json' \
5
--data-raw '{
6
"to": {
7
"type": "SRN",
8
"meta": {
9
"srn_type": "bitcoin",
10
"srn_address": "1BvBMSEYstWetqTFn5Au4m4GFg7xJaNVN2"
11
}
12
},
13
"amount": {
14
"amount": 100.1,
15
"currency": "SATOSHI"
16
},
17
"extra": {
18
"ip": "255.127.79.76",
19
"note": "Test transaction"
20
}
21
}'
Copied!

Executing SRN

Once created, the transaction will move to PROCESSING-DEBIT status, once that happens, you can Execute the transaction. Please note that the balance of the node wont be effected in this state, as the funds are still in the wallet and the transaction has not been booked on the public chain yet. This is an anti-pattern to how PROCESSING-DEBIT status usually works in our system.

Covering Transaction Fees

By default, fees are deducted from the fund recipient. This means if you send $1, the fund recipient will receive $1 minus the transaction fee. If you prefer to cover your user's transaction fees, pre-fund a deposit account from which fees will be deducted. Then set fees.fee to the negative of whatever the transaction fee will be, and fees.to.id to the node ID of the pre-funded deposit account.
HTTP
cURL
1
POST /v3.1/users/61281d15b72f862f1a97e6e2/nodes/61281d22ab6ce721377d53ec/trans HTTP/1.1
2
Host: uat-api.synapsefi.com
3
X-SP-USER-IP: 255.127.79.76
4
X-SP-USER: oauth_qWTA0DPUc5lC4sxjfnd9eYQLhIG8w3motKbE6uOk|e83cf6ddcf778e37bfe3d48fc78a6502062fc
5
Content-Type: application/json
6
Content-Length: 344
7
8
{
9
"to": {
10
"type": "DEPOSIT-US",
11
"id": "61281d317e08873466a0e7b1"
12
},
13
"amount": {
14
"amount": 100.0,
15
"currency": "USD"
16
},
17
"extra": {
18
"ip": "255.127.79.76",
19
"note": "Test Transaction"
20
},
21
"fees": [{
22
"fee":-0.03,
23
"note": "Facilitator Fee",
24
"to": {
25
"id":"60be880b7e08876cd9349cf4"
26
}
27
28
}]
29
}
Copied!
1
curl --location --request POST 'https://uat-api.synapsefi.com/v3.1/users/61281d15b72f862f1a97e6e2/nodes/61281d22ab6ce721377d53ec/trans' \
2
--header 'X-SP-USER-IP: 255.127.79.76' \
3
--header 'X-SP-USER: oauth_qWTA0DPUc5lC4sxjfnd9eYQLhIG8w3motKbE6uOk|e83cf6ddcf778e37bfe3d48fc78a6502062fc' \
4
--header 'Content-Type: application/json' \
5
--data-raw '{
6
"to": {
7
"type": "DEPOSIT-US",
8
"id": "61281d317e08873466a0e7b1"
9
},
10
"amount": {
11
"amount": 100.0,
12
"currency": "USD"
13
},
14
"extra": {
15
"ip": "255.127.79.76",
16
"note": "Test Transaction"
17
},
18
"fees": [{
19
"fee":-0.03,
20
"note": "Facilitator Fee",
21
"to": {
22
"id":"60be880b7e08876cd9349cf4"
23
}
24
25
}]
26
}'
Copied!
In the response, you will see two fees: one positive & one negative (corresponding with our Synapse-owned node & your pre-funded node respectively).
Please note that this payload only applies to transactions initiated via the API. To cover incoming wire fees from an EXTERNAL-US node, update your wire fee preferences in the dashboard.
Last modified 1mo ago