Skip to main content
GET
/
account
/
virtual
/
transactions
/
{accountNumber}
Transaction History
curl --request GET \
  --url https://devapi.withedge.co/gateway/api/v1/account/virtual/transactions/{accountNumber} \
  --header 'Authorization: Bearer <token>' \
  --header 'requestId: <requestid>'
import requests

url = "https://devapi.withedge.co/gateway/api/v1/account/virtual/transactions/{accountNumber}"

headers = {
"requestId": "<requestid>",
"Authorization": "Bearer <token>"
}

response = requests.get(url, headers=headers)

print(response.text)
const options = {
method: 'GET',
headers: {requestId: '<requestid>', Authorization: 'Bearer <token>'}
};

fetch('https://devapi.withedge.co/gateway/api/v1/account/virtual/transactions/{accountNumber}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://devapi.withedge.co/gateway/api/v1/account/virtual/transactions/{accountNumber}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"requestId: <requestid>"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"net/http"
"io"
)

func main() {

url := "https://devapi.withedge.co/gateway/api/v1/account/virtual/transactions/{accountNumber}"

req, _ := http.NewRequest("GET", url, nil)

req.Header.Add("requestId", "<requestid>")
req.Header.Add("Authorization", "Bearer <token>")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://devapi.withedge.co/gateway/api/v1/account/virtual/transactions/{accountNumber}")
.header("requestId", "<requestid>")
.header("Authorization", "Bearer <token>")
.asString();
require 'uri'
require 'net/http'

url = URI("https://devapi.withedge.co/gateway/api/v1/account/virtual/transactions/{accountNumber}")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["requestId"] = '<requestid>'
request["Authorization"] = 'Bearer <token>'

response = http.request(request)
puts response.read_body
{
	"statusCode": 00,
	"message": "Transaction History Successfully Retrieved",
	"data": [
		{
      "amount": "15,000",
      "accountNumber": "1158745523",
      "accountName": "Bruce Banner",
      "sourceAccountNumber": "1234567890",
      "sourceAccountName": "Steve Rogers",
      "date": "2024-09-10"
    }
	],
	"errors": [],
	"currentPage": 1,
	"pageSize": 10,
	"previousPage": 0,
	"total": 2
}

Transaction History

Use this endpoint to fetch the transaction history of a specific virtual account. Pagination parameters are supported to handle large datasets.

Request Parameters

requestId
string
required
A unique identifier for the request, used for idempotency.
Example: e0b9f8d0-7a57-4a67-a8b2-4d7c7b5a37c9
page
integer
required
The page number to retrieve for paginated results.
Example: 1
pageSize
integer
required
The number of transactions to retrieve per page.
Example: 10
accountNumber
string
required
The account number of the virtual account whose transaction history is being requested.
Example: 1158745523
{
	"statusCode": 00,
	"message": "Transaction History Successfully Retrieved",
	"data": [
		{
      "amount": "15,000",
      "accountNumber": "1158745523",
      "accountName": "Bruce Banner",
      "sourceAccountNumber": "1234567890",
      "sourceAccountName": "Steve Rogers",
      "date": "2024-09-10"
    }
	],
	"errors": [],
	"currentPage": 1,
	"pageSize": 10,
	"previousPage": 0,
	"total": 2
}