Connected Account Transactions

Getting one connected account transactions

get
https://api2.ourpass.co/v1/business/subaccounts/478?getWallet=true
Getting a transaction for one connected account
cURL
Node.js
PHP
Ruby
Python
1
curl --location --request GET 'https://user-api2-staging.ourpass.co/v1/api/subaccounts/375/transactions?page=1&limit=10' \
2
--header 'apiKey: {{apiKey}}' \
3
--data-raw ''
Copied!
1
var axios = require('axios');
2
var data = '';
3
4
var config = {
5
method: 'get',
6
url: 'https://user-api2-staging.ourpass.co/v1/api/subaccounts/375/transactions?page=1&limit=10',
7
headers: {
8
'apiKey': '{{apiKey}}'
9
},
10
data : data
11
};
12
13
axios(config)
14
.then(function (response) {
15
console.log(JSON.stringify(response.data));
16
})
17
.catch(function (error) {
18
console.log(error);
19
});
20
Copied!
1
<?php
2
require_once 'HTTP/Request2.php';
3
$request = new HTTP_Request2();
4
$request->setUrl('https://user-api2-staging.ourpass.co/v1/api/subaccounts/375/transactions?page=1&limit=10');
5
$request->setMethod(HTTP_Request2::METHOD_GET);
6
$request->setConfig(array(
7
'follow_redirects' => TRUE
8
));
9
$request->setHeader(array(
10
'apiKey' => '{{apiKey}}'
11
));
12
$request->setBody('');
13
try {
14
$response = $request->send();
15
if ($response->getStatus() == 200) {
16
echo $response->getBody();
17
}
18
else {
19
echo 'Unexpected HTTP status: ' . $response->getStatus() . ' ' .
20
$response->getReasonPhrase();
21
}
22
}
23
catch(HTTP_Request2_Exception $e) {
24
echo 'Error: ' . $e->getMessage();
25
}
Copied!
1
require "uri"
2
require "net/http"
3
4
url = URI("https://user-api2-staging.ourpass.co/v1/api/subaccounts/375/transactions?page=1&limit=10")
5
6
https = Net::HTTP.new(url.host, url.port)
7
https.use_ssl = true
8
9
request = Net::HTTP::Get.new(url)
10
request["apiKey"] = "{{apiKey}}"
11
12
response = https.request(request)
13
puts response.read_body
14
Copied!
1
import requests
2
3
url = "https://user-api2-staging.ourpass.co/v1/api/subaccounts/375/transactions?page=1&limit=10"
4
5
payload = ""
6
headers = {
7
'apiKey': '{{apiKey}}'
8
}
9
10
response = requests.request("GET", url, headers=headers, data=payload)
11
12
print(response.text)
13
Copied!

Getting all connected account transactions

get
https://api2.ourpass.co/v1/business/subaccounts/transactions
Getting all transaction for connected accounts
cURL
Node.js
PHP
Ruby
Python
1
curl --location --request GET 'https://api2.ourpass.co/v1/business/subaccounts/transactions' \
2
--header 'apiKey: pass_sec_live_46PhAGxwjVslPCKSpelAMxTupNmcBJem' \
3
--data-raw ''
Copied!
1
var axios = require('axios');
2
var data = '';
3
4
var config = {
5
method: 'get',
6
url: 'https://api2.ourpass.co/v1/business/subaccounts/transactions',
7
headers: {
8
'apiKey': 'pass_sec_live_46PhAGxwjVslPCKSpelAMxTupNmcBJem'
9
},
10
data : data
11
};
12
13
axios(config)
14
.then(function (response) {
15
console.log(JSON.stringify(response.data));
16
})
17
.catch(function (error) {
18
console.log(error);
19
});
20
Copied!
1
<?php
2
require_once 'HTTP/Request2.php';
3
$request = new HTTP_Request2();
4
$request->setUrl('https://api2.ourpass.co/v1/business/subaccounts/transactions');
5
$request->setMethod(HTTP_Request2::METHOD_GET);
6
$request->setConfig(array(
7
'follow_redirects' => TRUE
8
));
9
$request->setHeader(array(
10
'apiKey' => 'pass_sec_live_46PhAGxwjVslPCKSpelAMxTupNmcBJem'
11
));
12
$request->setBody('');
13
try {
14
$response = $request->send();
15
if ($response->getStatus() == 200) {
16
echo $response->getBody();
17
}
18
else {
19
echo 'Unexpected HTTP status: ' . $response->getStatus() . ' ' .
20
$response->getReasonPhrase();
21
}
22
}
23
catch(HTTP_Request2_Exception $e) {
24
echo 'Error: ' . $e->getMessage();
25
}
Copied!
1
require "uri"
2
require "net/http"
3
4
url = URI("https://api2.ourpass.co/v1/business/subaccounts/transactions")
5
6
https = Net::HTTP.new(url.host, url.port)
7
https.use_ssl = true
8
9
request = Net::HTTP::Get.new(url)
10
request["apiKey"] = "pass_sec_live_46PhAGxwjVslPCKSpelAMxTupNmcBJem"
11
12
response = https.request(request)
13
puts response.read_body
14
Copied!
1
import requests
2
3
url = "https://api2.ourpass.co/v1/business/subaccounts/transactions"
4
5
payload = ""
6
headers = {
7
'apiKey': 'pass_sec_live_46PhAGxwjVslPCKSpelAMxTupNmcBJem'
8
}
9
10
response = requests.request("GET", url, headers=headers, data=payload)
11
12
print(response.text)
13
Copied!