Skip to main content
POST
/
v1
/
donations
/
{network}
/
get-transaction
Create a donation transaction for a specific network
curl --request POST \
  --url http://localhost:3003/v1/donations/{network}/get-transaction \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "amount": "10.00",
  "charity_slug": "red-cross",
  "currency": "USDC",
  "from_address": "0x1234567890abcdef1234567890abcdef12345678",
  "memo": "Thank you for your great work!",
  "tip_bps": 300
}
'
{
  "data": {
    "metadata": {
      "amount": "10.00",
      "charity_bps": 9700,
      "charity_name": "American Red Cross",
      "charity_slug": "red-cross",
      "currency": "USDC",
      "network": "ethereum",
      "platform_bps": 300
    },
    "needs_approval": false,
    "transactions": [
      {
        "chain_id": 1,
        "data": "0x...",
        "gas_limit": 100000,
        "gas_price": "25000000000",
        "to": "0x1234567890abcdef1234567890abcdef12345678",
        "value": "0"
      }
    ]
  },
  "success": true,
  "meta": "<unknown>"
}

Authorizations

Authorization
string
header
required

Developer organization API key

Path Parameters

network
string
required

Blockchain network (ethereum or solana mainnet only)

Body

application/json

Request payload for creating a donation transaction

amount
string
required

The amount to donate as a decimal string (e.g., "10.00")

Example:

"10.00"

charity_slug
string
required

The charity organization's slug (e.g., "save-the-whales")

Example:

"red-cross"

currency
string
required

The currency/token symbol to donate (e.g., "USDC", "SOL", "ETH")

Example:

"USDC"

from_address
string
required

The sender's wallet address

Example:

"0x1234567890abcdef1234567890abcdef12345678"

memo
string | null

Optional memo/message to include with the donation

Example:

"Thank you for your great work!"

tip_bps
integer<int32>

Optional tip amount in basis points (0-10000, where 10000 = 100%) Defaults to 0 if not provided

Required range: x >= 0
Example:

300

Response

Successfully created donation transaction

Standard success response envelope

data
object
required

Union type for donation transaction responses

success
boolean
required

Indicates the request was successful

Example:

true

meta
object

Optional metadata (e.g., pagination info)