Skip to main content
GET
/
accounts
Get accounts
curl --request GET \
  --url https://sam.aragon.morabaa.com/api/accounts \
  --header 'X-App-Id: <x-app-id>' \
  --header 'X-App-Secret: <x-app-secret>'

Endpoint

GET /accounts Production URL: https://sam.aragon.morabaa.com/api/accounts

Authentication

This endpoint requires app authentication headers:
  • X-App-Id: <APP_ID>
  • X-App-Secret: <APP_SECRET>

Required headers

X-App-Id
string
required
App ID credential.
X-App-Secret
string
required
App secret credential.
Need credentials? Contact info@morabaa.com.
If either is invalid or missing, the response is 401 Unauthorized. Do not send Content-Type: application/json for this GET request. Only include a Content-Type header when the request has a JSON body.

Request example

curl -G "https://sam.aragon.morabaa.com/api/accounts" \
  -H "X-App-Id: <APP_ID>" \
  -H "X-App-Secret: <APP_SECRET>" \
  --data-urlencode "query=ahmed" \
  --data-urlencode "businessId=9c7f3b9d-0809-4f5e-b8f2-b6e46a4eb3af" \
  --data-urlencode "limit=25" \
  --data-urlencode "offset=0"

Query parameters

All query parameters are optional.
query
string
General text search.
businessId
guid
Filter by business ID. If omitted, the first business ID from the authenticated app is used.
limit
int
Page size. Defaults to 25, clamped to 1..100.
offset
int
Skip count. Defaults to 0 and never below 0.
Notes:
  • businessId must belong to the authenticated app if it is supplied.
  • A successful response returns 200 OK.

Response

The response type is an array of accounts:
id
guid
Account ID.
businessId
guid
Business ID associated with the account.
localId
int
Local account ID from MyMorabaa.
name
string
Account name.
phoneNumber
string
Account phone number.
address
string
Account address.
balances
array
Account balances grouped by state and currency.
[
  {
    "id": "7f8f6d3b-2b93-4af3-9f65-7ea7d5ab79f1",
    "businessId": "9c7f3b9d-0809-4f5e-b8f2-b6e46a4eb3af",
    "localId": 1024,
    "name": "Ahmed Ali",
    "phoneNumber": "+9647700000000",
    "address": "Baghdad, Iraq",
    "balances": [
      {
        "state": "active",
        "currencyId": 1,
        "amount": 1250.5
      }
    ]
  }
]

Headers

X-App-Id
string
required

App ID credential.

X-App-Secret
string
required

App secret credential.

Query Parameters

query
string

General text search.

businessId
string<uuid>

Filter by business ID. If omitted, the first business ID from the authenticated app is used.

limit
integer
default:25

Page size. Defaults to 25, clamped to 1..100.

Required range: 1 <= x <= 100
offset
integer
default:0

Skip count. Defaults to 0 and never below 0.

Required range: x >= 0

Response

Accounts returned successfully.