Generate Solana deposit address
curl --request POST \
--url https://deposit-addresses.eco.com/api/v1/depositAddresses/solana \
--header 'Content-Type: application/json' \
--data '
{
"chainId": 2,
"solanaAddress": "2ECrxAiyVBszAjok5isDdTJu4kwwhq9d7kgJqDvEStMq",
"depositor": "0x000000000000000000000000000000000000dEaD"
}
'import requests
url = "https://deposit-addresses.eco.com/api/v1/depositAddresses/solana"
payload = {
"chainId": 2,
"solanaAddress": "2ECrxAiyVBszAjok5isDdTJu4kwwhq9d7kgJqDvEStMq",
"depositor": "0x000000000000000000000000000000000000dEaD"
}
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({
chainId: 2,
solanaAddress: '2ECrxAiyVBszAjok5isDdTJu4kwwhq9d7kgJqDvEStMq',
depositor: '0x000000000000000000000000000000000000dEaD'
})
};
fetch('https://deposit-addresses.eco.com/api/v1/depositAddresses/solana', 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://deposit-addresses.eco.com/api/v1/depositAddresses/solana",
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([
'chainId' => 2,
'solanaAddress' => '2ECrxAiyVBszAjok5isDdTJu4kwwhq9d7kgJqDvEStMq',
'depositor' => '0x000000000000000000000000000000000000dEaD'
]),
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://deposit-addresses.eco.com/api/v1/depositAddresses/solana"
payload := strings.NewReader("{\n \"chainId\": 2,\n \"solanaAddress\": \"2ECrxAiyVBszAjok5isDdTJu4kwwhq9d7kgJqDvEStMq\",\n \"depositor\": \"0x000000000000000000000000000000000000dEaD\"\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://deposit-addresses.eco.com/api/v1/depositAddresses/solana")
.header("Content-Type", "application/json")
.body("{\n \"chainId\": 2,\n \"solanaAddress\": \"2ECrxAiyVBszAjok5isDdTJu4kwwhq9d7kgJqDvEStMq\",\n \"depositor\": \"0x000000000000000000000000000000000000dEaD\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://deposit-addresses.eco.com/api/v1/depositAddresses/solana")
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 \"chainId\": 2,\n \"solanaAddress\": \"2ECrxAiyVBszAjok5isDdTJu4kwwhq9d7kgJqDvEStMq\",\n \"depositor\": \"0x000000000000000000000000000000000000dEaD\"\n}"
response = http.request(request)
puts response.read_body{
"data": {
"addressID": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"depositAddressType": "SOLANA",
"chainId": 123,
"evmDepositAddress": "0x000000000000000000000000000000000000dEaD",
"solanaAddress": "<string>",
"depositor": "0x000000000000000000000000000000000000dEaD",
"factoryAddress": "0x000000000000000000000000000000000000dEaD",
"isDeployed": true,
"lastCheckedBalance": "<string>",
"lastBalanceCheckAt": "2023-11-07T05:31:56Z",
"lastBlockNumber": "<string>",
"deploymentTxHash": "<string>",
"deploymentBlockNumber": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z"
}
}{
"statusCode": 400,
"createdBy": "<string>",
"validationErrors": {},
"details": {
"errorCode": 1014,
"errorDesc": "NoSuchDepositAddress",
"cause": "NoSuchDepositAddress"
}
}Solana Deposit Addresses
Generate Solana deposit address
POST
/
api
/
v1
/
depositAddresses
/
solana
Generate Solana deposit address
curl --request POST \
--url https://deposit-addresses.eco.com/api/v1/depositAddresses/solana \
--header 'Content-Type: application/json' \
--data '
{
"chainId": 2,
"solanaAddress": "2ECrxAiyVBszAjok5isDdTJu4kwwhq9d7kgJqDvEStMq",
"depositor": "0x000000000000000000000000000000000000dEaD"
}
'import requests
url = "https://deposit-addresses.eco.com/api/v1/depositAddresses/solana"
payload = {
"chainId": 2,
"solanaAddress": "2ECrxAiyVBszAjok5isDdTJu4kwwhq9d7kgJqDvEStMq",
"depositor": "0x000000000000000000000000000000000000dEaD"
}
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({
chainId: 2,
solanaAddress: '2ECrxAiyVBszAjok5isDdTJu4kwwhq9d7kgJqDvEStMq',
depositor: '0x000000000000000000000000000000000000dEaD'
})
};
fetch('https://deposit-addresses.eco.com/api/v1/depositAddresses/solana', 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://deposit-addresses.eco.com/api/v1/depositAddresses/solana",
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([
'chainId' => 2,
'solanaAddress' => '2ECrxAiyVBszAjok5isDdTJu4kwwhq9d7kgJqDvEStMq',
'depositor' => '0x000000000000000000000000000000000000dEaD'
]),
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://deposit-addresses.eco.com/api/v1/depositAddresses/solana"
payload := strings.NewReader("{\n \"chainId\": 2,\n \"solanaAddress\": \"2ECrxAiyVBszAjok5isDdTJu4kwwhq9d7kgJqDvEStMq\",\n \"depositor\": \"0x000000000000000000000000000000000000dEaD\"\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://deposit-addresses.eco.com/api/v1/depositAddresses/solana")
.header("Content-Type", "application/json")
.body("{\n \"chainId\": 2,\n \"solanaAddress\": \"2ECrxAiyVBszAjok5isDdTJu4kwwhq9d7kgJqDvEStMq\",\n \"depositor\": \"0x000000000000000000000000000000000000dEaD\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://deposit-addresses.eco.com/api/v1/depositAddresses/solana")
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 \"chainId\": 2,\n \"solanaAddress\": \"2ECrxAiyVBszAjok5isDdTJu4kwwhq9d7kgJqDvEStMq\",\n \"depositor\": \"0x000000000000000000000000000000000000dEaD\"\n}"
response = http.request(request)
puts response.read_body{
"data": {
"addressID": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"depositAddressType": "SOLANA",
"chainId": 123,
"evmDepositAddress": "0x000000000000000000000000000000000000dEaD",
"solanaAddress": "<string>",
"depositor": "0x000000000000000000000000000000000000dEaD",
"factoryAddress": "0x000000000000000000000000000000000000dEaD",
"isDeployed": true,
"lastCheckedBalance": "<string>",
"lastBalanceCheckAt": "2023-11-07T05:31:56Z",
"lastBlockNumber": "<string>",
"deploymentTxHash": "<string>",
"deploymentBlockNumber": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z"
}
}{
"statusCode": 400,
"createdBy": "<string>",
"validationErrors": {},
"details": {
"errorCode": 1014,
"errorDesc": "NoSuchDepositAddress",
"cause": "NoSuchDepositAddress"
}
}Body
application/json
Source chain. Currently Base (8453).
Required range:
x >= 1base58, 32-44 chars
Pattern:
^[1-9A-HJ-NP-Za-km-z]{32,44}$Example:
"2ECrxAiyVBszAjok5isDdTJu4kwwhq9d7kgJqDvEStMq"
Authorized for refunds if the intent expires
Pattern:
^0x[a-fA-F0-9]{40}$Example:
"0x000000000000000000000000000000000000dEaD"
Response
Deposit address (deterministic: same inputs always return the same address)
Show child attributes
Show child attributes
⌘I
