Payments Payouts Quickstart#
Disburse collected rent payments to landlords and property managers. CasaPay handles payout scheduling, balance management, and bank account verification.
Step 1: Add a Bank Account#
Register the landlord's bank account for payouts:
curl https://api.casapay.com/v1/bank_accounts \
-H "Authorization: Bearer sk_test_4eC39HqLyjWDarjtT1zdp7dc" \
-H "Content-Type: application/json" \
-d '{
"account_holder_name": "Property Management Ltd",
"account_number": "00012345",
"sort_code": "108800",
"currency": "gbp",
"country": "GB",
"metadata": {
"landlord_id": "ll_789"
}
}'Step 2: Check Your Balance#
Before creating a payout, check available funds:
curl https://api.casapay.com/v1/balance \
-H "Authorization: Bearer sk_test_4eC39HqLyjWDarjtT1zdp7dc"{
"object": "balance",
"available": [
{ "amount": 4500000, "currency": "eur" },
{ "amount": 1200000, "currency": "gbp" }
],
"pending": [
{ "amount": 250000, "currency": "eur" }
]
}Step 3: Create a Payout#
curl https://api.casapay.com/v1/payouts \
-H "Authorization: Bearer sk_test_4eC39HqLyjWDarjtT1zdp7dc" \
-H "Content-Type: application/json" \
-d '{
"amount": 1150000,
"currency": "gbp",
"destination": "ba_abc123",
"description": "January 2025 rent disbursement",
"metadata": {
"landlord_id": "ll_789",
"period": "2025-01"
}
}'{
"id": "po_xyz789",
"object": "payout",
"amount": 1150000,
"currency": "gbp",
"status": "pending",
"destination": "ba_abc123",
"arrival_date": 1706572800,
"created": 1706140800
}Step 4: Track the Payout#
app.post('/webhooks/casapay', async (req, res) => {
const event = req.body;
if (event.type === 'payout.paid') {
await notifyLandlord(event.data.object.metadata.landlord_id, 'Payout received');
} else if (event.type === 'payout.failed') {
await investigateFailedPayout(event.data.object);
}
res.status(200).send();
});That's it!
You've created your first payout. Explore payout schedules for automated disbursements and balance transactions for detailed reconciliation.