Appearance
Create a business account request
Opens a request, as a draft, for MOOKHPay to open a business account for one of your sellers: a sole proprietorship, or a company if MOOKHPay has switched your platform on for companies. The seller is the requester and becomes an owner of the business. Creating the request does not send it: attach the documents with Attach a document, then Submit. MOOKHPay staff decide it. See Business accounts for sellers.
Endpoint
POST /v1/payments/merchant/accounts/{id}/org-requests| Auth | Secret key |
| Scope | accounts:write |
| Platform | Your organisation must be switched on as a platform, and the call must come from an allowed address if MOOKHPay set a list |
| Switched on | With the platform API on that deployment |
The key is checked with authn on every call, with no 60-second cache.
Headers
| Header | Required | Value |
|---|---|---|
Authorization | Yes | Bearer mkp_… |
Idempotency-Key | Yes | 1 to 128 characters. The same key and body return the same request (200); the same key with a different body is 422 and code 3015 |
Content-Type | Yes | application/json |
Parameters
Path
| Name | Type | Required | Constraints |
|---|---|---|---|
id | string | Yes | The seller's account id. A person's account that the seller has claimed (PIN set, phone confirmed) |
Body. Unknown fields are refused.
| Name | Type | Required | Constraints |
|---|---|---|---|
kind | string | Yes | sole_prop or company. company only for a platform MOOKHPay switched on for companies |
name | string | Yes | The business's registered name. 1 to 100 characters, not only spaces |
username | string | Yes | The MOOKHPay ID the business will have. 3 to 50 characters: lower-case letters, digits and _. Must be free |
registration_number | string | Yes | 1 to 64 characters |
tax_pin | string | Yes | KRA PIN in Kenya, TIN in Uganda. 1 to 32 characters. Stored in upper case |
address | string | Yes | 1 to 300 characters |
contact_phone | string | Yes | + and 9 to 15 digits |
contact_email | string | Yes | An email address, up to 254 characters |
directors | array of strings | For company | The other directors' MOOKHPay IDs, each 3 to 50 letters, digits or _. A company needs at least 1 and at most 20. IDs are compared without regard to case, so Wanjiru and wanjiru are the same director and may appear once. Do not include the seller: they are a director already. A sole proprietorship must send none. The schema accepts up to 50 entries, so more than 20 is refused with 409 3032 (too_many), not 400; a repeat is 3032 (duplicate). These checks run before anything is sent to MOOKHPay's account service |
terms | object | When asked | { accepted_at, version }: when the seller accepted MOOKHPay's terms on your platform, and which version. Needed when MOOKHPay holds no terms attestation for the account, which is the case for a linked account. An account you created already carries the attestation you sent with it |
terms.accepted_at | string | With terms | ISO 8601 with a time zone (2026-11-20T08:58:00Z or +03:00), not more than 5 minutes in the future |
terms.version | string | With terms | 1 to 40 characters: letters, digits, ., _ and - |
MOOKHPay records the IP address your request came from with the terms.
The documents each kind needs before it can be sent:
kind | Documents (type values) |
|---|---|
sole_prop | registration_certificate (business name registration) and tax_pin |
company | incorporation_certificate, tax_pin and cr12 |
Example request
sh
curl -X POST https://payments-ke-staging.mookhpay.co/v1/payments/merchant/accounts/acct_ke_9c2f41b07e5d38a6c1f0b294/org-requests \
-H "Authorization: Bearer $MOOKHPAY_SECRET_KEY" \
-H "Idempotency-Key: orgreq-seller-2291" \
-H "Content-Type: application/json" \
-d '{
"kind": "sole_prop",
"name": "Wanjiru Prints",
"username": "wanjiruprints",
"registration_number": "BN-7Q2K8LXA",
"tax_pin": "A012345678Z",
"address": "Ngong Road, Nairobi",
"contact_phone": "+254712345678",
"contact_email": "hello@wanjiruprints.example"
}'js
const account = "acct_ke_9c2f41b07e5d38a6c1f0b294";
const res = await fetch(
`https://payments-ke-staging.mookhpay.co/v1/payments/merchant/accounts/${account}/org-requests`,
{
method: "POST",
headers: {
Authorization: `Bearer ${process.env.MOOKHPAY_SECRET_KEY}`,
"Idempotency-Key": "orgreq-seller-2291",
"Content-Type": "application/json",
},
body: JSON.stringify({
kind: "sole_prop",
name: "Wanjiru Prints",
username: "wanjiruprints",
registration_number: "BN-7Q2K8LXA",
tax_pin: "A012345678Z",
address: "Ngong Road, Nairobi",
contact_phone: "+254712345678",
contact_email: "hello@wanjiruprints.example",
}),
},
);
const answer = await res.json();
if (!answer.ok) throw new Error(`${res.status} ${answer.code}: ${answer.description}`);
console.log(answer.data.request.request_id, answer.data.request.missing_documents);python
import os
import requests
account = "acct_ke_9c2f41b07e5d38a6c1f0b294"
res = requests.post(
f"https://payments-ke-staging.mookhpay.co/v1/payments/merchant/accounts/{account}/org-requests",
headers={
"Authorization": f"Bearer {os.environ['MOOKHPAY_SECRET_KEY']}",
"Idempotency-Key": "orgreq-seller-2291",
},
json={
"kind": "sole_prop",
"name": "Wanjiru Prints",
"username": "wanjiruprints",
"registration_number": "BN-7Q2K8LXA",
"tax_pin": "A012345678Z",
"address": "Ngong Road, Nairobi",
"contact_phone": "+254712345678",
"contact_email": "hello@wanjiruprints.example",
},
timeout=30,
)
answer = res.json()
if not answer["ok"]:
raise RuntimeError(f"{res.status_code} {answer['code']}: {answer['description']}")
request = answer["data"]["request"]
print(request["request_id"], request["missing_documents"])php
<?php
$account = 'acct_ke_9c2f41b07e5d38a6c1f0b294';
$ch = curl_init("https://payments-ke-staging.mookhpay.co/v1/payments/merchant/accounts/{$account}/org-requests");
curl_setopt_array($ch, [
CURLOPT_POST => true,
CURLOPT_POSTFIELDS => json_encode([
'kind' => 'sole_prop',
'name' => 'Wanjiru Prints',
'username' => 'wanjiruprints',
'registration_number' => 'BN-7Q2K8LXA',
'tax_pin' => 'A012345678Z',
'address' => 'Ngong Road, Nairobi',
'contact_phone' => '+254712345678',
'contact_email' => 'hello@wanjiruprints.example',
]),
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . getenv('MOOKHPAY_SECRET_KEY'),
'Idempotency-Key: orgreq-seller-2291',
'Content-Type: application/json',
],
]);
$answer = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if (!$answer['ok']) {
throw new RuntimeException("{$status} {$answer['code']}: {$answer['description']}");
}
echo $answer['data']['request']['request_id'], PHP_EOL;Response
201 Created with description Organisation request when the request is made. 200 OK when the same Idempotency-Key and body already made it, or when the seller already has an open request from your platform with the same kind, name, username, registration_number and tax_pin.
json
{
"ok": true,
"description": "Organisation request",
"data": {
"request": {
"request_id": "orq_3c8e1a9f4b7d20e6c5a1b902",
"account_id": "acct_ke_9c2f41b07e5d38a6c1f0b294",
"kind": "sole_prop",
"name": "Wanjiru Prints",
"username": "wanjiruprints",
"status": "draft",
"decline_reason": null,
"missing_documents": ["registration_certificate", "tax_pin"],
"documents": [],
"directors": [],
"organisation_account_id": null,
"created_at": "2026-11-20T09:00:00.000Z",
"submitted_at": null,
"reviewed_at": null
}
}
}Response fields
data.request is the request object. Retrieve a business account request and Submit return the same object.
| Field | Type | Meaning |
|---|---|---|
request_id | string | orq_ and 24 hex characters |
account_id | string | The seller's account id |
kind | string | sole_prop or company |
name | string | The business's name |
username | string | The MOOKHPay ID the business will have |
status | string | draft, awaiting_directors, pending, approved, declined or withdrawn. See below |
decline_reason | string or null | Why staff declined it, or A director declined. It stays set after the request is sent again |
missing_documents | array of strings | The required document types not yet attached, in the order listed above |
documents | array | [{ id, type, file_name, content_type, size, uploaded_at }]. type is lower case, size is bytes |
directors | array | [{ username, name, status }], the directors named (not the seller). status is invited, accepted or declined |
organisation_account_id | string or null | The business account's id once approved: an account of yours, like any other. null before. It stays null for good, and the business is the seller's but not yours, if the seller disconnected your platform before approval, or if a company was approved after MOOKHPay switched your platform off for companies |
created_at | string | ISO 8601, UTC |
submitted_at | string or null | When it was last sent |
reviewed_at | string or null | When staff decided it |
The request object does not carry registration_number, tax_pin, address or the contacts back.
status | Meaning | You can |
|---|---|---|
draft | Not sent | Attach documents, submit |
awaiting_directors | A company's request, sent. Every director named must accept it in MOOKHPay before staff look at it | Wait |
pending | With MOOKHPay staff | Wait |
approved | The business exists. Read organisation_account_id | Use the new account |
declined | Staff declined it, or a director did | Attach more documents and submit again, under the same request_id |
withdrawn | The seller gave it up in MOOKHPay | Open a new request |
No webhook is sent when a request moves. Poll Retrieve a business account request.
Errors
| HTTP | Code | Name | When | What to do |
|---|---|---|---|---|
400 | 1701 | INVALID_REQUEST_DATA | A field is missing, unknown or malformed (including more than 50 directors or a handle with other characters), Idempotency-Key is missing, or terms.accepted_at is not a real time or is in the future | Fix the request |
400 | 3014 | IDENTITY_HEADER_REFUSED | The request carries a session or identity header | Remove it |
400 | 3038 | PLATFORM_TERMS_REQUIRED | MOOKHPay holds no terms attestation for this account and you sent no terms | Send terms |
401 | 2781 | API_KEY_INVALID | Missing, malformed, unknown or revoked key | Check the key |
403 | 2941 | API_KEY_SCOPE_REQUIRED | The key lacks accounts:write | Issue a key with the scope |
403 | 3042 | API_KEY_IP_NOT_ALLOWED | The account has allowed addresses and the call came from another address | Call from a listed address |
403 | 2942 | PLATFORM_NOT_ENABLED | Your organisation is not a platform, or its platform is suspended | Talk to MOOKHPay |
403 | 3013 | PLATFORM_IP_NOT_ALLOWED | The call came from an address not on your platform's allow-list | Call from a listed address |
403 | 3037 | PLATFORM_COMPANY_ACCOUNTS_OFF | kind is company and your platform is not switched on for companies | Ask MOOKHPay, or send sole_prop |
404 | 2943 | PLATFORM_ACCOUNT_NOT_FOUND | The account is unknown, another platform's, revoked or malformed | Check the id |
409 | 3029 | ORG_REQUEST_ALREADY_OPEN | The seller already has a request open (draft, awaiting directors or pending), from any source, that is not the same request from your platform | Finish or wait for that one |
409 | 3030 | ORG_REQUEST_USERNAME_TAKEN | username is taken or reserved | Choose another |
409 | 3032 | ORG_REQUEST_BAD_DIRECTOR | A director cannot be added. data is { reason } or { username, reason }, reason one of not_allowed (directors on a sole proprietorship), required (a company with none), too_many, self (the seller named), duplicate, not_found or unavailable | Fix directors |
409 | 3035 | PLATFORM_ACCOUNT_UNCLAIMED | The seller has not claimed the account: no PIN, or the phone is not confirmed | Ask the seller to claim it first |
409 | 3036 | PLATFORM_ACCOUNT_NOT_A_PERSON | The account is itself a business account | Use a person's account |
422 | 3015 | IDEMPOTENCY_KEY_REUSED | The key was used with a different body or account | Use a new key |
429 | 1804 | RATE_LIMIT_EXCEEDED | Over the rate limit, or your platform reached its limit of unknown account ids | Wait Retry-After seconds |
503 | 2782 | AUTHN_UNAVAILABLE | The key could not be checked | Retry with the same key and body |
503 | 3016 | PLATFORM_ACCOUNTS_UNAVAILABLE | The request could not be made, including when a name check could not run | Retry with the same key and body |
Rate limit
120 requests a minute, shared by every account, balance, transaction, payout read, account link and business account request route your platform calls. Over it: 429, code 1804, with Retry-After and data.retryAfter in seconds.