TIPX API
Integrate TIPX tipping functionality into your applications, websites, and platforms.
Generate API Key
Connect your wallet to generate an API key.
You don't have an API key yet. Generate one to start integrating TIPX into your applications.
API Documentation
Authentication
All API requests require authentication using your API key. Include your API key in the request headers.
X-API-Key: your_api_key_here
Example request:
curl -X GET "https://api.tipx.cash/v1/balance" \
-H "X-API-Key: your_api_key_here"
Get Balance
Retrieve the TIPX balance of a wallet address.
Parameters:
wallet_address
(required) - The wallet address to check
Response:
{
"status": "success",
"data": {
"wallet_address": "0x1234567890abcdef1234567890abcdef12345678",
"balance": "1000.50",
"currency": "TIPX"
}
}
Send Tip
Send a TIPX tip from your wallet to another wallet.
Request Body:
{
"recipient": "0x1234567890abcdef1234567890abcdef12345678",
"amount": "10.5",
"message": "Great content!",
"encrypt_message": false
}
Response:
{
"status": "success",
"data": {
"transaction_id": "0x9876543210fedcba9876543210fedcba98765432",
"sender": "0xabcdef1234567890abcdef1234567890abcdef12",
"recipient": "0x1234567890abcdef1234567890abcdef12345678",
"amount": "10.5",
"fee": "0.00525",
"timestamp": "2025-04-08T22:45:30Z"
}
}
Get Transaction History
Retrieve the transaction history for a wallet address.
Parameters:
wallet_address
(required) - The wallet address to checklimit
(optional) - Number of transactions to return (default: 10, max: 100)offset
(optional) - Offset for pagination (default: 0)
Response:
{
"status": "success",
"data": {
"transactions": [
{
"transaction_id": "0x9876543210fedcba9876543210fedcba98765432",
"type": "sent",
"recipient": "0x1234567890abcdef1234567890abcdef12345678",
"amount": "10.5",
"fee": "0.00525",
"timestamp": "2025-04-08T22:45:30Z"
},
{
"transaction_id": "0x5432109876fedcba5432109876fedcba54321098",
"type": "received",
"sender": "0xfedcba9876543210fedcba9876543210fedcba98",
"amount": "5.25",
"timestamp": "2025-04-07T18:30:15Z"
}
],
"total": 2,
"limit": 10,
"offset": 0
}
}
Integration Examples
JavaScript Widget
Add a TIPX tipping button to your website with this JavaScript widget.
<!-- Add this to your HTML -->
<div id="tipx-button" data-recipient="YOUR_WALLET_ADDRESS"></div>
<!-- Add this script before the closing body tag -->
<script src="https://cdn.tipx.cash/widget.js"></script>
<script>
TIPX.init({
apiKey: 'YOUR_API_KEY',
theme: 'dark', // or 'light'
buttonText: 'Tip with TIPX'
});
</script>
Example of using the TIPX API with fetch:
// Send a tip
async function sendTip(recipientAddress, amount, message) {
try {
const response = await fetch('https://api.tipx.cash/v1/tip', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'X-API-Key': 'YOUR_API_KEY'
},
body: JSON.stringify({
recipient: recipientAddress,
amount: amount,
message: message,
encrypt_message: false
})
});
const data = await response.json();
return data;
} catch (error) {
console.error('Error sending tip:', error);
throw error;
}
}
Rate Limits
To ensure fair usage of the TIPX API, the following rate limits apply:
Endpoint | Rate Limit | Time Window |
---|---|---|
GET /v1/balance/{wallet_address} | 100 requests | 1 minute |
POST /v1/tip | 50 requests | 1 minute |
GET /v1/transactions/{wallet_address} | 60 requests | 1 minute |
If you exceed these rate limits, you will receive a 429 Too Many Requests response. The response will include a Retry-After header indicating how many seconds to wait before making another request.