POST

ExpensesCategories.Get

Return one expense category by id from expenses_categories. Use category_id from ExpensesCategories.List. category_id=0 returns the synthetic Other option.

Permissions

  • User must be logged in with a valid bearer token.
  • Returned or changed records are limited by the user permissions, team access, folder access, and account settings.

Action

  • Returns ExpensesCategories information as JSON for the UI.

Push Service

No push is sent because this function only reads data or returns helper information.

Automation

No automation is run for this function.

Special Instructions

  • Send the bearer token on protected calls with Authorization: Bearer YOUR TOKEN.
  • Send parameters as POST body fields exactly as documented.

Required Parameters

NameTypeSampleExplanation
category_id
post
int12Expense category id. Aliases: expense_category_id, expenses_category_id, id, data_id.

Optional Parameters

No optional body parameters are defined for this function.

Authentication

Send the bearer token returned by Login in the request header.

Authorization: Bearer YOUR TOKEN

Sample Request

{
    "url": "\/app\/ExpensesCategories.Get",
    "method": "POST",
    "headers": {
        "Authorization": "Bearer YOUR TOKEN"
    },
    "body": {
        "category_id": "12"
    },
    "url_user": "https:\/\/{user}.bull36.com\/app\/ExpensesCategories.Get",
    "url_domain": "https:\/\/{domain}\/app\/ExpensesCategories.Get"
}

Endpoint

POST /app/ExpensesCategories.Get
POST https://{user}.bull36.com/app/ExpensesCategories.Get
POST https://{domain}/app/ExpensesCategories.Get

Sample Output

{
    "success": 1,
    "data": {
        "id": 12,
        "category_id": 12,
        "name": "new expense",
        "name_en": "new expense",
        "name_he": "new expense",
        "parent_id": 0,
        "is_parent": true,
        "is_other": false
    }
}

JavaScript Example

const token = 'YOUR TOKEN';
const body = new URLSearchParams({ category_id: '12' });
const res = await fetch('/app/ExpensesCategories.Get', {
  method: 'POST',
  headers: { Authorization: 'Bearer ' + token },
  body
});
console.log(await res.json());

Error Example

{
    "success": 0,
    "message": "Missing required parameter: category_id"
}