Skip to content

Search for a complete word or an exact phrase.

Credits and contacts

The balance.read permission authorizes GET /api/sms/v2/balance/.

Terminal window
curl 'https://api.befiana.cloud/api/sms/v2/balance/' \
--header "Authorization: Bearer $BEFIANA_SMS_API_KEY"

Scroll horizontally if needed. Keyboard: Tab, then the left and right arrow keys.

FieldPurpose
totalTotal balance reported by the service.
availableCredits available for new submissions.
reservedCredits already reserved.
valid_untilReturned validity date, when present.

Credit usage depends on segments, not only the number of recipients. Scheduled messages and batches can reserve credits before processing. Do not add available and reserved to a locally stored business total to reconstruct the balance: retrieve it from the service.

Reading the balance does not reserve credits. Other submissions can consume credits between your check and your request. Your integration must handle an insufficient-credit rejection even after a favorable balance check.

Purchases and credit management remain in BEFIANA Cloud. This public API does not advertise a purchase operation.

The contacts.manage permission authorizes POST /api/sms/v2/contacts/. The phone_number field identifies the contact within the organization. The operation returns 201 when creating a contact and 200 when updating an existing one.

Terminal window
curl --request POST 'https://api.befiana.cloud/api/sms/v2/contacts/' \
--header "Authorization: Bearer $BEFIANA_SMS_API_KEY" \
--header 'Content-Type: application/json' \
--data '{"phone_number":"+261340000000"}'

See the accepted descriptive fields in the reference. Saving a contact does not send an SMS and is not evidence of consent to receive your communications.