Get pending deposits for specified addresses
curl --request POST \
--url https://gateway-api-testnet.circle.com/v1/deposits \
--header 'Content-Type: application/json' \
--data '
{
"token": "USDC",
"sources": [
{
"depositor": "<string>"
}
]
}
'import requests
url = "https://gateway-api-testnet.circle.com/v1/deposits"
payload = {
"token": "USDC",
"sources": [{ "depositor": "<string>" }]
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({token: 'USDC', sources: [{depositor: '<string>'}]})
};
fetch('https://gateway-api-testnet.circle.com/v1/deposits', 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://gateway-api-testnet.circle.com/v1/deposits",
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([
'token' => 'USDC',
'sources' => [
[
'depositor' => '<string>'
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$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://gateway-api-testnet.circle.com/v1/deposits"
payload := strings.NewReader("{\n \"token\": \"USDC\",\n \"sources\": [\n {\n \"depositor\": \"<string>\"\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
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://gateway-api-testnet.circle.com/v1/deposits")
.header("Content-Type", "application/json")
.body("{\n \"token\": \"USDC\",\n \"sources\": [\n {\n \"depositor\": \"<string>\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://gateway-api-testnet.circle.com/v1/deposits")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"token\": \"USDC\",\n \"sources\": [\n {\n \"depositor\": \"<string>\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"token": "USDC",
"deposits": [
{
"depositor": "<string>",
"transactionHash": "0x2c5f3e4a9e4b1a4b9c8d6a7d5b8e9f0a1b2c3d4e5f6a7b8c9d0e1f2a3b4c5d6e",
"amount": "<string>",
"status": "pending",
"blockHeight": "15000000",
"blockHash": "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
"blockTimestamp": "2023-11-07T05:31:56Z"
}
]
}{
"code": 400,
"message": "Bad request."
}{
"code": 404,
"message": "Not found."
}Returns pending deposits for each specified depositor address across different domains where that address is valid.
POST
/
v1
/
deposits
Get pending deposits for specified addresses
curl --request POST \
--url https://gateway-api-testnet.circle.com/v1/deposits \
--header 'Content-Type: application/json' \
--data '
{
"token": "USDC",
"sources": [
{
"depositor": "<string>"
}
]
}
'import requests
url = "https://gateway-api-testnet.circle.com/v1/deposits"
payload = {
"token": "USDC",
"sources": [{ "depositor": "<string>" }]
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({token: 'USDC', sources: [{depositor: '<string>'}]})
};
fetch('https://gateway-api-testnet.circle.com/v1/deposits', 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://gateway-api-testnet.circle.com/v1/deposits",
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([
'token' => 'USDC',
'sources' => [
[
'depositor' => '<string>'
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$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://gateway-api-testnet.circle.com/v1/deposits"
payload := strings.NewReader("{\n \"token\": \"USDC\",\n \"sources\": [\n {\n \"depositor\": \"<string>\"\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
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://gateway-api-testnet.circle.com/v1/deposits")
.header("Content-Type", "application/json")
.body("{\n \"token\": \"USDC\",\n \"sources\": [\n {\n \"depositor\": \"<string>\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://gateway-api-testnet.circle.com/v1/deposits")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"token\": \"USDC\",\n \"sources\": [\n {\n \"depositor\": \"<string>\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"token": "USDC",
"deposits": [
{
"depositor": "<string>",
"transactionHash": "0x2c5f3e4a9e4b1a4b9c8d6a7d5b8e9f0a1b2c3d4e5f6a7b8c9d0e1f2a3b4c5d6e",
"amount": "<string>",
"status": "pending",
"blockHeight": "15000000",
"blockHash": "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
"blockTimestamp": "2023-11-07T05:31:56Z"
}
]
}{
"code": 400,
"message": "Bad request."
}{
"code": 404,
"message": "Not found."
}Body
application/json
Was this page helpful?
⌘I