Skip to content

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
AuthSecret key
Scopeaccounts:write
PlatformYour organisation must be switched on as a platform, and the call must come from an allowed address if MOOKHPay set a list
Switched onWith the platform API on that deployment

The key is checked with authn on every call, with no 60-second cache.

Headers ​

HeaderRequiredValue
AuthorizationYesBearer mkp_…
Idempotency-KeyYes1 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-TypeYesapplication/json

Parameters ​

Path

NameTypeRequiredConstraints
idstringYesThe seller's account id. A person's account that the seller has claimed (PIN set, phone confirmed)

Body. Unknown fields are refused.

NameTypeRequiredConstraints
kindstringYessole_prop or company. company only for a platform MOOKHPay switched on for companies
namestringYesThe business's registered name. 1 to 100 characters, not only spaces
usernamestringYesThe MOOKHPay ID the business will have. 3 to 50 characters: lower-case letters, digits and _. Must be free
registration_numberstringYes1 to 64 characters
tax_pinstringYesKRA PIN in Kenya, TIN in Uganda. 1 to 32 characters. Stored in upper case
addressstringYes1 to 300 characters
contact_phonestringYes+ and 9 to 15 digits
contact_emailstringYesAn email address, up to 254 characters
directorsarray of stringsFor companyThe 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
termsobjectWhen 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_atstringWith termsISO 8601 with a time zone (2026-11-20T08:58:00Z or +03:00), not more than 5 minutes in the future
terms.versionstringWith terms1 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:

kindDocuments (type values)
sole_propregistration_certificate (business name registration) and tax_pin
companyincorporation_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.

FieldTypeMeaning
request_idstringorq_ and 24 hex characters
account_idstringThe seller's account id
kindstringsole_prop or company
namestringThe business's name
usernamestringThe MOOKHPay ID the business will have
statusstringdraft, awaiting_directors, pending, approved, declined or withdrawn. See below
decline_reasonstring or nullWhy staff declined it, or A director declined. It stays set after the request is sent again
missing_documentsarray of stringsThe required document types not yet attached, in the order listed above
documentsarray[{ id, type, file_name, content_type, size, uploaded_at }]. type is lower case, size is bytes
directorsarray[{ username, name, status }], the directors named (not the seller). status is invited, accepted or declined
organisation_account_idstring or nullThe 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_atstringISO 8601, UTC
submitted_atstring or nullWhen it was last sent
reviewed_atstring or nullWhen staff decided it

The request object does not carry registration_number, tax_pin, address or the contacts back.

statusMeaningYou can
draftNot sentAttach documents, submit
awaiting_directorsA company's request, sent. Every director named must accept it in MOOKHPay before staff look at itWait
pendingWith MOOKHPay staffWait
approvedThe business exists. Read organisation_account_idUse the new account
declinedStaff declined it, or a director didAttach more documents and submit again, under the same request_id
withdrawnThe seller gave it up in MOOKHPayOpen a new request

No webhook is sent when a request moves. Poll Retrieve a business account request.

Errors ​

HTTPCodeNameWhenWhat to do
4001701INVALID_REQUEST_DATAA 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 futureFix the request
4003014IDENTITY_HEADER_REFUSEDThe request carries a session or identity headerRemove it
4003038PLATFORM_TERMS_REQUIREDMOOKHPay holds no terms attestation for this account and you sent no termsSend terms
4012781API_KEY_INVALIDMissing, malformed, unknown or revoked keyCheck the key
4032941API_KEY_SCOPE_REQUIREDThe key lacks accounts:writeIssue a key with the scope
4033042API_KEY_IP_NOT_ALLOWEDThe account has allowed addresses and the call came from another addressCall from a listed address
4032942PLATFORM_NOT_ENABLEDYour organisation is not a platform, or its platform is suspendedTalk to MOOKHPay
4033013PLATFORM_IP_NOT_ALLOWEDThe call came from an address not on your platform's allow-listCall from a listed address
4033037PLATFORM_COMPANY_ACCOUNTS_OFFkind is company and your platform is not switched on for companiesAsk MOOKHPay, or send sole_prop
4042943PLATFORM_ACCOUNT_NOT_FOUNDThe account is unknown, another platform's, revoked or malformedCheck the id
4093029ORG_REQUEST_ALREADY_OPENThe seller already has a request open (draft, awaiting directors or pending), from any source, that is not the same request from your platformFinish or wait for that one
4093030ORG_REQUEST_USERNAME_TAKENusername is taken or reservedChoose another
4093032ORG_REQUEST_BAD_DIRECTORA 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 unavailableFix directors
4093035PLATFORM_ACCOUNT_UNCLAIMEDThe seller has not claimed the account: no PIN, or the phone is not confirmedAsk the seller to claim it first
4093036PLATFORM_ACCOUNT_NOT_A_PERSONThe account is itself a business accountUse a person's account
4223015IDEMPOTENCY_KEY_REUSEDThe key was used with a different body or accountUse a new key
4291804RATE_LIMIT_EXCEEDEDOver the rate limit, or your platform reached its limit of unknown account idsWait Retry-After seconds
5032782AUTHN_UNAVAILABLEThe key could not be checkedRetry with the same key and body
5033016PLATFORM_ACCOUNTS_UNAVAILABLEThe request could not be made, including when a name check could not runRetry 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.

Staging documentation. A checkout made with a secret key on staging charges a real phone. See Environments.