Web API: Faucet
The Faucet API provides endpoints for requesting testnet VFX tokens for development and testing purposes.
Base URL
/api/faucet/
Endpoints
Request Faucet Funds
POST /api/faucet/request/
Requests testnet VFX tokens to be sent to a specified address.
Request:
{
"address": "Rx1234567890abcdef...",
"amount": "100.0",
"captcha_response": "03AGdBq26...",
"email": "user@example.com"
}
Response:
{
"success": true,
"message": "Faucet request submitted successfully",
"transaction_hash": "tx123...",
"amount": "100.0",
"estimated_arrival": "2024-01-01T12:05:00Z"
}
Error Response:
{
"success": false,
"message": "Daily limit exceeded. Please try again in 24 hours.",
"retry_after": "2024-01-02T12:00:00Z"
}
Verify Faucet Funds
POST /api/faucet/verify/
Verifies the status of a faucet request and confirms delivery.
Request:
{
"transaction_hash": "tx123...",
"address": "Rx1234567890abcdef..."
}
Response:
{
"success": true,
"status": "completed",
"transaction_hash": "tx123...",
"amount": "100.0",
"sent_at": "2024-01-01T12:03:00Z",
"confirmations": 6,
"block_height": 12345
}
Status Values:
pending
: Request is being processedcompleted
: Tokens have been sent successfullyfailed
: Request failed to processrate_limited
: Request was rate limited
Request Parameters
Faucet Request
address
(string): Valid VFX testnet address to receive fundsamount
(string): Amount of VFX tokens requested (subject to limits)captcha_response
(string): CAPTCHA validation tokenemail
(string, optional): Email address for notifications
Verification Request
transaction_hash
(string): Hash returned from the faucet requestaddress
(string): Address that was funded
Response Fields
Request Response
success
: Whether the request was acceptedmessage
: Human-readable status messagetransaction_hash
: Unique identifier for tracking the requestamount
: Amount of tokens that will be sentestimated_arrival
: Expected time when tokens will arrive
Verification Response
status
: Current status of the faucet transactionsent_at
: Timestamp when tokens were sentconfirmations
: Number of blockchain confirmationsblock_height
: Block height where the transaction was included
Usage Limits
- Daily Limit: Maximum 100 VFX per address per 24 hours
- Rate Limiting: Maximum 1 request per 10 minutes per IP
- CAPTCHA Required: All requests must include valid CAPTCHA
- Testnet Only: Faucet only works on testnet networks
Error Codes
400 Bad Request
: Invalid address format or missing parameters429 Too Many Requests
: Rate limit exceeded503 Service Unavailable
: Faucet is temporarily out of funds
Notes
- Faucet is only available on testnet environments
- Tokens are sent automatically upon successful request validation
- CAPTCHA verification prevents automated abuse
- IP-based rate limiting applies in addition to address limits
- Email notifications are optional but recommended for tracking