Virtual Accounts
Simulate deposit
Sandbox only. Pays a virtual account as if the customer had sent money, through the same fees, review rules, settlement and webhooks as a real payment. Refused in production with 403 simulation_unavailable. The account must be active.
POST
/
api
/
v1
/
virtual-accounts
/
{uuid}
/
simulate-deposit
Simulate deposit
curl --request POST \
--url https://pay-api.pagoramp.com/api/v1/virtual-accounts/{uuid}/simulate-deposit \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"amount": 5000,
"senderName": "JOHN DOE"
}
'import requests
url = "https://pay-api.pagoramp.com/api/v1/virtual-accounts/{uuid}/simulate-deposit"
payload = {
"amount": 5000,
"senderName": "JOHN DOE"
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({amount: 5000, senderName: 'JOHN DOE'})
};
fetch('https://pay-api.pagoramp.com/api/v1/virtual-accounts/{uuid}/simulate-deposit', 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://pay-api.pagoramp.com/api/v1/virtual-accounts/{uuid}/simulate-deposit",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'amount' => 5000,
'senderName' => 'JOHN DOE'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://pay-api.pagoramp.com/api/v1/virtual-accounts/{uuid}/simulate-deposit"
payload := strings.NewReader("{\n \"amount\": 5000,\n \"senderName\": \"JOHN DOE\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-api-key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://pay-api.pagoramp.com/api/v1/virtual-accounts/{uuid}/simulate-deposit")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"amount\": 5000,\n \"senderName\": \"JOHN DOE\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://pay-api.pagoramp.com/api/v1/virtual-accounts/{uuid}/simulate-deposit")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"amount\": 5000,\n \"senderName\": \"JOHN DOE\"\n}"
response = http.request(request)
puts response.read_bodyAuthorizations
Path Parameters
Body
application/json
Response
Simulate deposit
curl --request POST \
--url https://pay-api.pagoramp.com/api/v1/virtual-accounts/{uuid}/simulate-deposit \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"amount": 5000,
"senderName": "JOHN DOE"
}
'import requests
url = "https://pay-api.pagoramp.com/api/v1/virtual-accounts/{uuid}/simulate-deposit"
payload = {
"amount": 5000,
"senderName": "JOHN DOE"
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({amount: 5000, senderName: 'JOHN DOE'})
};
fetch('https://pay-api.pagoramp.com/api/v1/virtual-accounts/{uuid}/simulate-deposit', 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://pay-api.pagoramp.com/api/v1/virtual-accounts/{uuid}/simulate-deposit",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'amount' => 5000,
'senderName' => 'JOHN DOE'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://pay-api.pagoramp.com/api/v1/virtual-accounts/{uuid}/simulate-deposit"
payload := strings.NewReader("{\n \"amount\": 5000,\n \"senderName\": \"JOHN DOE\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-api-key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://pay-api.pagoramp.com/api/v1/virtual-accounts/{uuid}/simulate-deposit")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"amount\": 5000,\n \"senderName\": \"JOHN DOE\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://pay-api.pagoramp.com/api/v1/virtual-accounts/{uuid}/simulate-deposit")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"amount\": 5000,\n \"senderName\": \"JOHN DOE\"\n}"
response = http.request(request)
puts response.read_body
