API лавлагаа
Үндсэн URL: https://admin.onepay.tabsystems.tech/api/v1
Бүх endpoint-д Authorization толгой шаардлагатай. Дүн нь бараануудын нийлбэртэй тулгагдаж, төлөвийн шилжилтийг сервер талд хянана — буруу хүсэлт тойм хуудсанд бичсэн алдааны кодуудыг буцаана.
Invoices
Lifecycle: draft → pending (payment link generated) → captured (paid) → fulfilled (confirmed by the merchant). canceled and expired are final. Amounts are always validated against the item sums; every status change is recorded in the invoice status log.
/invoicesList invoices (paginated, optional created-at date range)Paginated by pageIndex/limit (max 100 per page); optionally filtered by a createdAt range via startDate/endDate (ISO strings).
Параметрүүд
| Нэр | Байрлал | Төрөл | Заавал эсэх |
|---|---|---|---|
| pageIndex | query | number | |
| search | query | string | |
| limit | query | number | |
| startDate | query | string | |
| endDate | query | string |
curl -X GET https://admin.onepay.tabsystems.tech/api/v1/invoices \
-H "Authorization: Bearer psk_your_token_here"{
"invoices": [
{
"id": "string",
"title": "string",
"description": "string",
"currency": "MNT",
"language": "en",
"status": "draft",
"customerFallbackEmail": "string",
"customerFallbackName": "string",
"items": [
{
"id": null,
"merchantId": null,
"name": null,
"description": null,
"price": null,
"currency": null,
"taxRate": null,
"isTaxIncluded": null,
"hasQuantity": null,
"quantity": null
}
],
"totalAmount": 0,
"taxAmount": 0,
"createdById": "string",
"createdByFallbackEmail": "string",
"createdBy": {
"id": "string",
"firstname": "string",
"lastname": "string",
"email": "string",
"hashedPassword": "string",
"mustChangePassword": false,
"roleId": "string",
"isActive": false,
"role": {
"id": null,
"name": null,
"description": null,
"merchantId": null
},
"merchantId": "string",
"invoices": [
null
],
"merchant": {
"id": null,
"name": null,
"email": null,
"phone": null,
"description": null,
"address": null,
"website": null,
"logoUrl": null
}
},
"customerId": "string",
"customer": {
"id": "string",
"name": "string",
"email": "email",
"phone": "string",
"merchantId": "string",
"deletedAt": null,
"createdAt": null,
"updatedAt": null
},
"paymentProviderInvoices": [
{
"provider": null,
"merchantReference": null,
"gatewayReference": null,
"redirectUrl": null,
"expiresAt": null,
"providerExtra": null,
"paymentStatus": null,
"paidAmount": null,
"paidAt": null,
"convertedAmount": null
}
],
"merchantId": "string",
"expiresAt": null,
"paymentLink": {
"expiresAt": null,
"url": "string"
},
"createdAt": null,
"updatedAt": null
}
],
"pagination": {
"page": 0,
"limit": 0,
"total": 0,
"totalPages": 0,
"hasNext": false,
"hasPrev": false
}
}/invoicesCreate a draft invoice (registered customer or guest fallback)Creates a DRAFT invoice for a registered customer (customerId) or a guest (customerFallbackEmail / customerFallbackName). expiresAt must be an ISO 8601 datetime string. totalAmount and taxAmount must equal the sums computed from items — otherwise 422 invalidAmount. Catalog items are referenced by id and priced from the database; custom one-off items supply their own price, taxRate and isTaxIncluded.
Хүсэлтийн бие
| Нэр | Төрөл | Заавал эсэх |
|---|---|---|
| title | string | заавал |
| description | string | заавал |
| currency | MNT | USD | JPY | заавал |
| language | en | mn | ja | заавал |
| items | array | заавал |
| totalAmount | number | заавал |
| taxAmount | number | заавал |
| customerId | string | |
| expiresAt | string | заавал |
| customerFallbackEmail | string | |
| customerFallbackName | string |
curl -X POST https://admin.onepay.tabsystems.tech/api/v1/invoices \
-H "Authorization: Bearer psk_your_token_here" \
-H "Content-Type: application/json" \
-d '{ ... }'{
"id": "string",
"title": "string",
"description": "string",
"currency": "MNT",
"language": "en",
"status": "draft",
"customerFallbackEmail": "string",
"customerFallbackName": "string",
"items": [
{
"id": "string",
"merchantId": "string",
"name": "string",
"description": "string",
"price": 0,
"currency": "MNT",
"taxRate": 0,
"isTaxIncluded": false,
"hasQuantity": false,
"quantity": 0
}
],
"totalAmount": 0,
"taxAmount": 0,
"createdById": "string",
"createdByFallbackEmail": "string",
"createdBy": {
"id": "string",
"firstname": "string",
"lastname": "string",
"email": "string",
"hashedPassword": "string",
"mustChangePassword": false,
"roleId": "string",
"isActive": false,
"role": {
"id": "string",
"name": "string",
"description": "string",
"merchantId": "string"
},
"merchantId": "string",
"invoices": [
"string"
],
"merchant": {
"id": "string",
"name": "string",
"email": "string",
"phone": "string",
"description": "string",
"address": "string",
"website": "string",
"logoUrl": "string"
}
},
"customerId": "string",
"customer": {
"id": "string",
"name": "string",
"email": "email",
"phone": "string",
"merchantId": "string",
"deletedAt": null,
"createdAt": null,
"updatedAt": null
},
"paymentProviderInvoices": [
{
"provider": "qpay",
"merchantReference": "string",
"gatewayReference": "string",
"redirectUrl": "string",
"expiresAt": null,
"providerExtra": null,
"paymentStatus": "string",
"paidAmount": 0,
"paidAt": null,
"convertedAmount": 0
}
],
"merchantId": "string",
"expiresAt": null,
"paymentLink": {
"expiresAt": null,
"url": "string"
},
"createdAt": null,
"updatedAt": null
}/invoices/{invoiceId}Get one invoice with customer and merchant detailsПараметрүүд
| Нэр | Байрлал | Төрөл | Заавал эсэх |
|---|---|---|---|
| invoiceId | path | string | заавал |
curl -X GET https://admin.onepay.tabsystems.tech/api/v1/invoices/{invoiceId} \
-H "Authorization: Bearer psk_your_token_here"{
"id": "string",
"title": "string",
"description": "string",
"currency": "MNT",
"language": "en",
"status": "draft",
"customerFallbackEmail": "string",
"customerFallbackName": "string",
"items": [
{
"id": "string",
"merchantId": "string",
"name": "string",
"description": "string",
"price": 0,
"currency": "MNT",
"taxRate": 0,
"isTaxIncluded": false,
"hasQuantity": false,
"quantity": 0
}
],
"totalAmount": 0,
"taxAmount": 0,
"createdById": "string",
"createdByFallbackEmail": "string",
"createdBy": {
"id": "string",
"firstname": "string",
"lastname": "string",
"email": "string",
"hashedPassword": "string",
"mustChangePassword": false,
"roleId": "string",
"isActive": false,
"role": {
"id": "string",
"name": "string",
"description": "string",
"merchantId": "string"
},
"merchantId": "string",
"invoices": [
"string"
],
"merchant": {
"id": "string",
"name": "string",
"email": "string",
"phone": "string",
"description": "string",
"address": "string",
"website": "string",
"logoUrl": "string"
}
},
"customerId": "string",
"customer": {
"id": "string",
"name": "string",
"email": "email",
"phone": "string",
"merchantId": "string",
"deletedAt": null,
"createdAt": null,
"updatedAt": null
},
"paymentProviderInvoices": [
{
"provider": "qpay",
"merchantReference": "string",
"gatewayReference": "string",
"redirectUrl": "string",
"expiresAt": null,
"providerExtra": null,
"paymentStatus": "string",
"paidAmount": 0,
"paidAt": null,
"convertedAmount": 0
}
],
"merchantId": "string",
"expiresAt": null,
"paymentLink": {
"expiresAt": null,
"url": "string"
},
"createdAt": null,
"updatedAt": null
}/invoices/{invoiceId}Delete an invoice (draft/canceled/expired only)Only draft, canceled or expired invoices with no payment link and no status history can be hard-deleted (audit trail) — otherwise 422. Cancel an acted-on invoice via PUT /invoices/{invoiceId}/status instead.
Параметрүүд
| Нэр | Байрлал | Төрөл | Заавал эсэх |
|---|---|---|---|
| invoiceId | path | string | заавал |
curl -X DELETE https://admin.onepay.tabsystems.tech/api/v1/invoices/{invoiceId} \
-H "Authorization: Bearer psk_your_token_here"{
"id": "string",
"title": "string",
"description": "string",
"currency": "MNT",
"language": "en",
"status": "draft",
"customerFallbackEmail": "string",
"customerFallbackName": "string",
"items": [
{
"id": "string",
"merchantId": "string",
"name": "string",
"description": "string",
"price": 0,
"currency": "MNT",
"taxRate": 0,
"isTaxIncluded": false,
"hasQuantity": false,
"quantity": 0
}
],
"totalAmount": 0,
"taxAmount": 0,
"createdById": "string",
"createdByFallbackEmail": "string",
"createdBy": {
"id": "string",
"firstname": "string",
"lastname": "string",
"email": "string",
"hashedPassword": "string",
"mustChangePassword": false,
"roleId": "string",
"isActive": false,
"role": {
"id": "string",
"name": "string",
"description": "string",
"merchantId": "string"
},
"merchantId": "string",
"invoices": [
"string"
],
"merchant": {
"id": "string",
"name": "string",
"email": "string",
"phone": "string",
"description": "string",
"address": "string",
"website": "string",
"logoUrl": "string"
}
},
"customerId": "string",
"customer": {
"id": "string",
"name": "string",
"email": "email",
"phone": "string",
"merchantId": "string",
"deletedAt": null,
"createdAt": null,
"updatedAt": null
},
"paymentProviderInvoices": [
{
"provider": "qpay",
"merchantReference": "string",
"gatewayReference": "string",
"redirectUrl": "string",
"expiresAt": null,
"providerExtra": null,
"paymentStatus": "string",
"paidAmount": 0,
"paidAt": null,
"convertedAmount": 0
}
],
"merchantId": "string",
"expiresAt": null,
"paymentLink": {
"expiresAt": null,
"url": "string"
},
"createdAt": null,
"updatedAt": null
}/invoices/{invoiceId}/statusUpdate invoice status (transitions are service-enforced)Lifecycle: draft → pending → captured → fulfilled. Allowed transitions: captured → fulfilled only; fulfilled → canceled only; canceled and expired are final (422 invoiceNotEditable). Setting fulfilled requires the invoice to be captured first (422 onlyCapturedCanFulfill). Setting captured or fulfilled sends the corresponding notification emails.
Параметрүүд
| Нэр | Байрлал | Төрөл | Заавал эсэх |
|---|---|---|---|
| invoiceId | path | string | заавал |
Хүсэлтийн бие
| Нэр | Төрөл | Заавал эсэх |
|---|---|---|
| status | draft | pending | captured | fulfilled | canceled | expired |
curl -X PUT https://admin.onepay.tabsystems.tech/api/v1/invoices/{invoiceId}/status \
-H "Authorization: Bearer psk_your_token_here" \
-H "Content-Type: application/json" \
-d '{ ... }'{
"id": "string",
"title": "string",
"description": "string",
"currency": "MNT",
"language": "en",
"status": "draft",
"customerFallbackEmail": "string",
"customerFallbackName": "string",
"items": [
{
"id": "string",
"merchantId": "string",
"name": "string",
"description": "string",
"price": 0,
"currency": "MNT",
"taxRate": 0,
"isTaxIncluded": false,
"hasQuantity": false,
"quantity": 0
}
],
"totalAmount": 0,
"taxAmount": 0,
"createdById": "string",
"createdByFallbackEmail": "string",
"createdBy": {
"id": "string",
"firstname": "string",
"lastname": "string",
"email": "string",
"hashedPassword": "string",
"mustChangePassword": false,
"roleId": "string",
"isActive": false,
"role": {
"id": "string",
"name": "string",
"description": "string",
"merchantId": "string"
},
"merchantId": "string",
"invoices": [
"string"
],
"merchant": {
"id": "string",
"name": "string",
"email": "string",
"phone": "string",
"description": "string",
"address": "string",
"website": "string",
"logoUrl": "string"
}
},
"customerId": "string",
"customer": {
"id": "string",
"name": "string",
"email": "email",
"phone": "string",
"merchantId": "string",
"deletedAt": null,
"createdAt": null,
"updatedAt": null
},
"paymentProviderInvoices": [
{
"provider": "qpay",
"merchantReference": "string",
"gatewayReference": "string",
"redirectUrl": "string",
"expiresAt": null,
"providerExtra": null,
"paymentStatus": "string",
"paidAmount": 0,
"paidAt": null,
"convertedAmount": 0
}
],
"merchantId": "string",
"expiresAt": null,
"paymentLink": {
"expiresAt": null,
"url": "string"
},
"createdAt": null,
"updatedAt": null
}/invoices/{invoiceId}/payment-linkGenerate (or return the cached) payment link without sending emailMoves a draft invoice to pending. Requires at least one enabled payment provider (422 noPaymentProvider). Idempotent — returns the cached link unless forceRefresh or expiresInMinutes is passed. Returns { url, expiresAt }.
Параметрүүд
| Нэр | Байрлал | Төрөл | Заавал эсэх |
|---|---|---|---|
| invoiceId | path | string | заавал |
Хүсэлтийн бие
| Нэр | Төрөл | Заавал эсэх |
|---|---|---|
| forceRefresh | boolean | |
| expiresInMinutes | integer |
curl -X POST https://admin.onepay.tabsystems.tech/api/v1/invoices/{invoiceId}/payment-link \
-H "Authorization: Bearer psk_your_token_here" \
-H "Content-Type: application/json" \
-d '{ ... }'{
"expiresAt": null,
"url": "string"
}/invoices/{invoiceId}/sendSend (or resend with isForce) the payment link by emailGenerates the payment link if needed and emails it to the invoice recipient. Pass isForce to resend an already-sent invoice; expiresIn (minutes) overrides the link validity.
Параметрүүд
| Нэр | Байрлал | Төрөл | Заавал эсэх |
|---|---|---|---|
| invoiceId | path | string | заавал |
Хүсэлтийн бие
| Нэр | Төрөл | Заавал эсэх |
|---|---|---|
| isForce | boolean | |
| expiresIn | number |
curl -X POST https://admin.onepay.tabsystems.tech/api/v1/invoices/{invoiceId}/send \
-H "Authorization: Bearer psk_your_token_here" \
-H "Content-Type: application/json" \
-d '{ ... }'{
"success": false,
"message": "string"
}Customers
Customers belong to the merchant that owns the API token. Deleting a customer is a soft delete — invoices keep referencing it.
/customersList customers (paginated, optional search text)search matches customer name and email, case-insensitively.
Параметрүүд
| Нэр | Байрлал | Төрөл | Заавал эсэх |
|---|---|---|---|
| pageIndex | query | number | |
| search | query | string | |
| limit | query | number |
curl -X GET https://admin.onepay.tabsystems.tech/api/v1/customers \
-H "Authorization: Bearer psk_your_token_here"{
"customers": [
{
"id": "string",
"name": "string",
"email": "email",
"phone": "string",
"merchantId": "string",
"deletedAt": null,
"createdAt": null,
"updatedAt": null
}
],
"pagination": {
"pageIndex": 0,
"page": 0,
"limit": 0,
"total": 0,
"totalPages": 0,
"hasNext": false,
"hasPrev": false
}
}/customersCreate a customerХүсэлтийн бие
| Нэр | Төрөл | Заавал эсэх |
|---|---|---|
| name | string | заавал |
| string | заавал | |
| phone | string |
curl -X POST https://admin.onepay.tabsystems.tech/api/v1/customers \
-H "Authorization: Bearer psk_your_token_here" \
-H "Content-Type: application/json" \
-d '{ ... }'{
"id": "string",
"name": "string",
"email": "email",
"phone": "string",
"merchantId": "string",
"deletedAt": null,
"createdAt": null,
"updatedAt": null
}/customers/{customerId}Get one customerПараметрүүд
| Нэр | Байрлал | Төрөл | Заавал эсэх |
|---|---|---|---|
| customerId | path | string | заавал |
curl -X GET https://admin.onepay.tabsystems.tech/api/v1/customers/{customerId} \
-H "Authorization: Bearer psk_your_token_here"{
"id": "string",
"name": "string",
"email": "email",
"phone": "string",
"merchantId": "string",
"deletedAt": null,
"createdAt": null,
"updatedAt": null
}/customers/{customerId}Update a customerПараметрүүд
| Нэр | Байрлал | Төрөл | Заавал эсэх |
|---|---|---|---|
| customerId | path | string | заавал |
Хүсэлтийн бие
| Нэр | Төрөл | Заавал эсэх |
|---|---|---|
| name | string | |
| string | ||
| phone | string |
curl -X PUT https://admin.onepay.tabsystems.tech/api/v1/customers/{customerId} \
-H "Authorization: Bearer psk_your_token_here" \
-H "Content-Type: application/json" \
-d '{ ... }'{
"id": "string",
"name": "string",
"email": "email",
"phone": "string",
"merchantId": "string",
"deletedAt": null,
"createdAt": null,
"updatedAt": null
}/customers/{customerId}Soft-delete a customerThe customer is deactivated, not removed — existing invoices keep referencing it and history stays intact.
Параметрүүд
| Нэр | Байрлал | Төрөл | Заавал эсэх |
|---|---|---|---|
| customerId | path | string | заавал |
curl -X DELETE https://admin.onepay.tabsystems.tech/api/v1/customers/{customerId} \
-H "Authorization: Bearer psk_your_token_here"{
"id": "string",
"name": "string",
"email": "email",
"phone": "string",
"merchantId": "string",
"deletedAt": null,
"createdAt": null,
"updatedAt": null
}Items
Catalog items are priced from the database when invoicing. One-off custom items are supplied inline on the invoice instead and are not stored here.
/itemsList catalog items (paginated, optional active filter)Параметрүүд
| Нэр | Байрлал | Төрөл | Заавал эсэх |
|---|---|---|---|
| pageIndex | query | number | |
| search | query | string | |
| limit | query | number | |
| where | query | object |
curl -X GET https://admin.onepay.tabsystems.tech/api/v1/items \
-H "Authorization: Bearer psk_your_token_here"{
"items": [
{
"id": "string",
"merchantId": "string",
"name": "string",
"description": "string",
"price": 0,
"currency": "MNT",
"taxRate": 0,
"isTaxIncluded": false,
"hasQuantity": false,
"quantity": 0,
"isActive": false,
"createdAt": null,
"updatedAt": null
}
],
"total": 0
}/itemsCreate a catalog itemCatalog items carry their own price, taxRate and isTaxIncluded — invoices referencing the item always read the current values from the database, never from the request.
Хүсэлтийн бие
| Нэр | Төрөл | Заавал эсэх |
|---|---|---|
| name | string | заавал |
| description | string | заавал |
| price | number | заавал |
| currency | MNT | USD | JPY | |
| taxRate | number | заавал |
| isTaxIncluded | boolean | заавал |
| hasQuantity | boolean | |
| quantity | string | |
| isActive | boolean |
curl -X POST https://admin.onepay.tabsystems.tech/api/v1/items \
-H "Authorization: Bearer psk_your_token_here" \
-H "Content-Type: application/json" \
-d '{ ... }'{
"id": "string",
"merchantId": "string",
"name": "string",
"description": "string",
"price": 0,
"currency": "MNT",
"taxRate": 0,
"isTaxIncluded": false,
"hasQuantity": false,
"quantity": 0,
"isActive": false,
"createdAt": null,
"updatedAt": null
}/items/{itemId}Update a catalog itemПараметрүүд
| Нэр | Байрлал | Төрөл | Заавал эсэх |
|---|---|---|---|
| itemId | path | string | заавал |
Хүсэлтийн бие
| Нэр | Төрөл | Заавал эсэх |
|---|---|---|
| name | string | |
| description | string | |
| price | number | |
| currency | MNT | USD | JPY | |
| taxRate | number | |
| isTaxIncluded | boolean | |
| hasQuantity | boolean | |
| quantity | string | |
| isActive | boolean |
curl -X PUT https://admin.onepay.tabsystems.tech/api/v1/items/{itemId} \
-H "Authorization: Bearer psk_your_token_here" \
-H "Content-Type: application/json" \
-d '{ ... }'{
"id": "string",
"merchantId": "string",
"name": "string",
"description": "string",
"price": 0,
"currency": "MNT",
"taxRate": 0,
"isTaxIncluded": false,
"hasQuantity": false,
"quantity": 0,
"isActive": false,
"createdAt": null,
"updatedAt": null
}/items/{itemId}Delete a catalog itemПараметрүүд
| Нэр | Байрлал | Төрөл | Заавал эсэх |
|---|---|---|---|
| itemId | path | string | заавал |
curl -X DELETE https://admin.onepay.tabsystems.tech/api/v1/items/{itemId} \
-H "Authorization: Bearer psk_your_token_here"{
"id": "string",
"merchantId": "string",
"name": "string",
"description": "string",
"price": 0,
"currency": "MNT",
"taxRate": 0,
"isTaxIncluded": false,
"hasQuantity": false,
"quantity": 0,
"isActive": false,
"createdAt": null,
"updatedAt": null
}Users
Users of the merchant dashboard. A token inherits its creator’s role: manager tokens can only act on their own account, admin tokens on any user of the merchant.
/rolesList the merchant's roles (for the roleId field of user endpoints)Returns { id, name, description } per role. Use the id as roleId when creating or updating users.
curl -X GET https://admin.onepay.tabsystems.tech/api/v1/roles \
-H "Authorization: Bearer psk_your_token_here"[
{
"id": "string",
"name": "string",
"description": "string",
"merchantId": "string"
}
]/usersList users (paginated)Параметрүүд
| Нэр | Байрлал | Төрөл | Заавал эсэх |
|---|---|---|---|
| pageIndex | query | number | |
| search | query | string | |
| limit | query | number |
curl -X GET https://admin.onepay.tabsystems.tech/api/v1/users \
-H "Authorization: Bearer psk_your_token_here"{
"users": [
{
"id": "string",
"firstname": "string",
"lastname": "string",
"email": "string",
"mustChangePassword": false,
"roleId": "string",
"isActive": false,
"role": {
"id": "string",
"name": "string",
"description": "string",
"merchantId": "string"
},
"merchantId": "string"
}
],
"pagination": {
"pageIndex": 0,
"page": 0,
"limit": 0,
"total": 0,
"totalPages": 0,
"hasNext": false,
"hasPrev": false
}
}/usersCreate a user (sends a welcome email)The user is always created under the merchant that owns the API token — a merchant can never add users to another merchant. roleId must be an id returned by GET /roles (roles are merchant-scoped too). The new user receives a welcome email with initial credentials.
Хүсэлтийн бие
| Нэр | Төрөл | Заавал эсэх |
|---|---|---|
| firstname | string | заавал |
| lastname | string | |
| string | заавал | |
| roleId | string | заавал |
curl -X POST https://admin.onepay.tabsystems.tech/api/v1/users \
-H "Authorization: Bearer psk_your_token_here" \
-H "Content-Type: application/json" \
-d '{ ... }'{
"id": "string",
"firstname": "string",
"lastname": "string",
"email": "string",
"mustChangePassword": false,
"roleId": "string",
"isActive": false,
"role": {
"id": "string",
"name": "string",
"description": "string",
"merchantId": "string"
},
"merchantId": "string"
}/users/{userId}Update a userManager-role tokens may update only their own account; admin tokens may update any user of the merchant (403 otherwise). A user's merchant cannot be changed. Fields outside the caller's permitted set are ignored rather than applied.
Параметрүүд
| Нэр | Байрлал | Төрөл | Заавал эсэх |
|---|---|---|---|
| userId | path | string | заавал |
Хүсэлтийн бие
| Нэр | Төрөл | Заавал эсэх |
|---|---|---|
| firstname | string | |
| lastname | string | |
| string | ||
| roleId | string | |
| isActive | boolean | |
| password | string |
curl -X PUT https://admin.onepay.tabsystems.tech/api/v1/users/{userId} \
-H "Authorization: Bearer psk_your_token_here" \
-H "Content-Type: application/json" \
-d '{ ... }'{
"id": "string",
"firstname": "string",
"lastname": "string",
"email": "string",
"mustChangePassword": false,
"roleId": "string",
"isActive": false,
"role": {
"id": "string",
"name": "string",
"description": "string",
"merchantId": "string"
},
"merchantId": "string"
}/users/{userId}Delete a userManager-role tokens may delete only their own account; admin tokens any user of the merchant. Deleting the last remaining admin is rejected.
Параметрүүд
| Нэр | Байрлал | Төрөл | Заавал эсэх |
|---|---|---|---|
| userId | path | string | заавал |
curl -X DELETE https://admin.onepay.tabsystems.tech/api/v1/users/{userId} \
-H "Authorization: Bearer psk_your_token_here"{
"id": "string",
"firstname": "string",
"lastname": "string",
"email": "string",
"mustChangePassword": false,
"roleId": "string",
"isActive": false,
"role": {
"id": "string",
"name": "string",
"description": "string",
"merchantId": "string"
},
"merchantId": "string"
}Merchant
Your own merchant profile. Every other payload is already merchant-scoped, so the merchant object is not repeated on individual records — read it here when you need it.
/merchantGet the merchant profile that owns the API tokenName, contact details and logo of your own merchant. User and invoice payloads deliberately omit this object — fetch it here once instead of receiving it on every record.
curl -X GET https://admin.onepay.tabsystems.tech/api/v1/merchant \
-H "Authorization: Bearer psk_your_token_here"{
"id": "string",
"name": "string",
"email": "string",
"phone": "string",
"description": "string",
"address": "string",
"website": "string",
"logoUrl": "string"
}