lomi.
Payments

Payouts

Withdraw funds from your account balance.

The Payouts API allows you to withdraw funds from your merchant account balance to your bank account or mobile money.

Payouts are processed asynchronously. Use webhooks to track status (payout.completed or payout.failed).

Initiate a payout

Withdraw funds from your account balance.

Request Body

FieldTypeRequiredDescription
amountnumberYesAmount to withdraw
currency_codestringYesCurrency (XOF, USD, etc.)
payout_method_idstringYesYour payout method (bank/mobile money)
descriptionstringNoPayout description
metadataobjectNoCustom key-value pairs
import { LomiSDK } from '@lomi./sdk';

const lomi = new LomiSDK({
  apiKey: process.env.LOMI_API_KEY!,
  environment: 'live',
});

const payout = await lomi.payouts.create({
  amount: 100000,
  currency_code: 'XOF',
  payout_method_id: 'pm_abc123...',
  description: 'Monthly withdrawal',
});

console.log(`Payout initiated: ${payout.id}, Status: ${payout.status}`);
from lomi import LomiClient
import os

client = LomiClient(
    api_key=os.environ["LOMI_API_KEY"],
    environment="test"
)

payout = client.payouts.create({
    "amount": 100000,
    "currency_code": "XOF",
    "payout_method_id": "pm_abc123...",
    "description": "Monthly withdrawal"
})

print(f"Payout initiated: {payout['id']}")
curl -X POST "https://api.lomi.africa/payouts" \
  -H "X-API-KEY: $LOMI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "amount": 100000,
    "currency_code": "XOF",
    "payout_method_id": "pm_abc123...",
    "description": "Monthly withdrawal"
  }'

List payouts

Retrieve all payouts with optional filtering.

Query Parameters

ParameterTypeDescription
statusesstringComma-separated statuses: pending, completed, failed
startDatestringFilter from this date (ISO 8601)
endDatestringFilter up to this date (ISO 8601)
limitnumberResults per page (default: 50)
offsetnumberPagination offset (default: 0)
const payouts = await lomi.payouts.list({
  statuses: 'completed',
  startDate: '2024-01-01T00:00:00Z',
  limit: 20,
});
payouts = client.payouts.list(
    statuses="completed",
    startDate="2024-01-01T00:00:00Z",
    limit=20
)
curl -X GET "https://api.lomi.africa/payouts?statuses=completed&limit=20" \
  -H "X-API-KEY: $LOMI_API_KEY"

Get a payout

Retrieve details of a specific payout.

const payout = await lomi.payouts.get('po_abc123...');
console.log(`Status: ${payout.status}`);
payout = client.payouts.get('po_abc123...')
curl -X GET "https://api.lomi.africa/payouts/po_abc123..." \
  -H "X-API-KEY: $LOMI_API_KEY"

Payout Object

FieldTypeDescription
idstringUnique payout identifier
amountnumberPayout amount
currency_codestringCurrency code
statusstringpending, completed, failed
payout_method_idstringPayout destination
descriptionstringDescription
failure_reasonstringReason for failure (if failed)
provider_codestringPayment provider
metadataobjectCustom metadata
created_atstringCreation timestamp

Webhooks

EventDescription
payout.pendingPayout initiated
payout.completedPayout successfully processed
payout.failedPayout failed

Error Responses

StatusDescription
400Invalid input or insufficient balance
401Invalid or missing API key
404Payout not found

On this page