메인 콘텐츠로 건너뛰기
POST
/
send
Send native assets and tokens
curl --request POST \
  --url https://api.afkcrypto.com/v1/send \
  --header 'Content-Type: application/json' \
  --header 'Idempotency-Key: <idempotency-key>' \
  --header 'x-api-key: <api-key>' \
  --data '{
  "chain": "<string>",
  "from": "<string>",
  "to": "<string>",
  "asset": "native",
  "token": "<string>",
  "amount": "<string>"
}'
{ "id": "tx_...", "status": "SUBMITTED", "hash": "0x...", "explorerUrl": "https://basescan.org/tx/0x...", "chainName": "Base" }
Idempotency-Key 헤더가 필요합니다. ERC20는 transfer() 호출; SPL은 필요 시 ATA를 생성할 수 있습니다.
{ "id": "tx_...", "status": "SUBMITTED", "hash": "0x...", "explorerUrl": "https://basescan.org/tx/0x...", "chainName": "Base" }

비고

  • EVM native: value 전송
  • ERC20: 토큰 transfer(address,uint256) 호출
  • SOL native: lamports 전송
  • SPL: SPL 토큰 전송(필요 시 ATA 생성 가능)
  • 멱등성은 단일 제출을 보장하며 동일 본문 반복 시 원래 200 본문을 반환

Authorizations

x-api-key
string
header
required

Headers

Idempotency-Key
string<uuid>
required

Provide a unique Idempotency-Key per user to ensure single submission.

Body

application/json
chain
string
required

Chain slug (e.g., base, base-sepolia, solana-devnet).

to
string
required

Recipient wallet address (owner for token transfers).

asset
enum<string>
required

Asset type to send.

사용 가능한 옵션:
native,
erc20,
spl
amount
string
required

Amount in base units (wei/lamports/token units).

from
string | null

Optional sender wallet; defaults to user's default wallet for the chain.

token
string | null

Token address (EVM) or mint (Solana) when sending tokens.

Response

Submission accepted

id
string
required

AFK transaction id for the submitted action.

status
enum<string>
required

Submission status.

사용 가능한 옵션:
SUBMITTED
hash
string | null
required

On-chain transaction hash/signature (may be null at submission time).

explorerUrl
string | null
required

Direct link to the transaction on a chain explorer. Null until a hash/signature exists.

chainName
string
required

Human-readable chain name for display (e.g., Base, Ethereum, Solana).