Ssentezo Developers
Sandbox and production use the same API host. The organization status, SANDBOX or LIVE, is the environment. This portal does not simulate a successful payment when a call fails.

Partner account creation

POST /api/ssentezo/register

Create a sandbox organization. Used by the Ssentezo MFI integration.

This creates a user and returns a new API secret. It is not available in the playground.

Authentication

HTTP Basic, as described in Authentication. No extra scope is checked.

Headers

HeaderRequiredDescription
AuthorizationYesBasic base64(api_user_id:api_key).
Content-TypeYesapplication/json
AcceptNoapplication/json

Body

FieldRequiredRulesDescription
company_name
string
Yes required|unique:organizations,name|max:255 Organization name.
email
string
Yes required|email|unique:users,email Owner email.
password
string
Yes required|string Owner password. Send it only over HTTPS and do not log it.
phone
string
Yes Ugandan number, unique Owner phone.
first_name
string
Yes required|string Owner first name.
last_name
string
Yes required|string Owner last name.
address
string
Yes required|string Organization address.

Behavior

  • Any existing API credential can call this route. The response includes a new API user and key. Store that secret once and do not log it.
  • The new organization starts in SANDBOX.
  • This is not the merchant self-signup page. People creating their own account use the website registration form.

Idempotency. Not supported by a dedicated header.

Rate limit. No rate limit is configured on the API.

Example request

{
    "company_name": "Example Supplies Ltd",
    "email": "owner@example.com",
    "password": "use-a-secret-from-your-environment",
    "phone": "256772123456",
    "first_name": "Ada",
    "last_name": "Lovelace",
    "address": "Kampala"
}

Success ยท HTTP 201

{
    "status": "SUCCESS",
    "response": "OK",
    "data": {
        "USERNAME": "new-api-user-id",
        "API_KEY": "returned-once",
        "message": "Account was created successfully. Save the key; it is the API password."
    }
}

Errors

StatusWhen
401 NO_AUTHORIZATION_HEADERThe Authorization header is missing.
403 INVALID_AUTHORIZATION_HEADERThe header must start with "Basic ".
403 MISSING_USER_OR_KEYThe decoded value must be api_user_id:api_key.
403 INVALID_USER_OR_KEYThe API user or key was not recognized.
403 ORGANIZATION_SUSPENDEDThe organization user is suspended.
422Validation failed. The account was not created.
400The account could not be created.

Code

curl

curl --request POST \
  --url "$SSENTEZO_BASE_URL/api/ssentezo/register" \
  --header "Authorization: Basic $SSENTEZO_BASIC_TOKEN" \
  --header "Accept: application/json" \
  --header "Content-Type: application/json" \
  --data '{
    "company_name": "Example Supplies Ltd",
    "email": "owner@example.com",
    "password": "use-a-secret-from-your-environment",
    "phone": "256772123456",
    "first_name": "Ada",
    "last_name": "Lovelace",
    "address": "Kampala"
}'

php

$client = new Ssentezo\Wallet\SsentezoClient(
    getenv('SSENTEZO_API_USER'),
    getenv('SSENTEZO_API_KEY'),
    getenv('SSENTEZO_BASE_URL')
);

$result = $client->request('POST', '/api/ssentezo/register', json_decode(<<<'JSON'
{
    "company_name": "Example Supplies Ltd",
    "email": "owner@example.com",
    "password": "use-a-secret-from-your-environment",
    "phone": "256772123456",
    "first_name": "Ada",
    "last_name": "Lovelace",
    "address": "Kampala"
}
JSON, true));

javascript

const token = Buffer.from(process.env.SSENTEZO_API_USER + ':' + process.env.SSENTEZO_API_KEY).toString('base64');
const response = await fetch(process.env.SSENTEZO_BASE_URL + '/api/ssentezo/register', {
  method: 'POST',
  headers: {
    Authorization: 'Basic ' + token,
    Accept: 'application/json',
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    "company_name": "Example Supplies Ltd",
    "email": "owner@example.com",
    "password": "use-a-secret-from-your-environment",
    "phone": "256772123456",
    "first_name": "Ada",
    "last_name": "Lovelace",
    "address": "Kampala"
}),
});
const payload = await response.json();

python

import base64, json, os, urllib.request

token = base64.b64encode(f"{os.environ['SSENTEZO_API_USER']}:{os.environ['SSENTEZO_API_KEY']}".encode()).decode()
request = urllib.request.Request(
    os.environ['SSENTEZO_BASE_URL'] + '/api/ssentezo/register',
    data=json.dumps({
    "company_name": "Example Supplies Ltd",
    "email": "owner@example.com",
    "password": "use-a-secret-from-your-environment",
    "phone": "256772123456",
    "first_name": "Ada",
    "last_name": "Lovelace",
    "address": "Kampala"
}).encode(),
    headers={'Authorization': f'Basic {token}', 'Accept': 'application/json', 'Content-Type': 'application/json'},
    method='POST',
)
with urllib.request.urlopen(request, timeout=20) as response:
    payload = json.load(response)

java

HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create(System.getenv("SSENTEZO_BASE_URL") + "/api/ssentezo/register"))
    .timeout(Duration.ofSeconds(20))
    .header("Authorization", "Basic " + Base64.getEncoder().encodeToString((System.getenv("SSENTEZO_API_USER") + ":" + System.getenv("SSENTEZO_API_KEY")).getBytes(StandardCharsets.UTF_8)))
    .header("Accept", "application/json")
    .header("Content-Type", "application/json")
    .POST(HttpRequest.BodyPublishers.ofString("{\"company_name\":\"Example Supplies Ltd\",\"email\":\"owner@example.com\",\"password\":\"use-a-secret-from-your-environment\",\"phone\":\"256772123456\",\"first_name\":\"Ada\",\"last_name\":\"Lovelace\",\"address\":\"Kampala\"}"))
    .build();

Set SSENTEZO_API_USER, SSENTEZO_API_KEY, and SSENTEZO_BASE_URL. SSENTEZO_BASIC_TOKEN is the base64 of user:key.