API reference
Add a provider
Stores encrypted provider credentials for the active tenant. Required role: admin or owner.
POST/v1/admin/providers
Request
bash
curl -X POST https://api-raven-cloud.autotribes.app/v1/admin/providers \
-H "Authorization: Bearer eyJ..." \
-H "X-App-Name: raven-cloud" \
-H "X-Tenant-Slug: acme-co" \
-H "Content-Type: application/json" \
-d '{
"provider": "africas_talking",
"label": "AT production",
"publicConfig": {
"username": "acme_prod",
"sender_id": "ACMECO",
"region": "KE"
},
"secretConfig": {
"api_key": "atsk_a1b2c3d4..."
}
}'Body
| Field | Type | Notes |
|---|---|---|
provider | enum · required | One of the provider IDs from the catalog |
label | string · required | Your own label, 2–80 chars |
publicConfig | object · optional | Non-secret fields (sender ID, region, etc.) |
secretConfig | object · required | Secret fields — encrypted at rest with a per-tenant key |
Response
201 Created
json
{
"id": "5f2c8a1d-7b9e-4a3c-91d2-f4a7e8c1b3d6",
"provider": "africas_talking",
"channel": "sms",
"label": "AT production",
"status": "unverified",
"configPublic": { "username": "acme_prod", "sender_id": "ACMECO", "region": "KE" },
"createdAt": "2026-05-01T10:23:18.114Z"
}ENCRYPTED ON WRITE
The
secretConfig values are encrypted with a per-tenant key before they touch the database. The plaintext is decrypted only at send-time, in worker memory, and never written back to disk.