Create account

Examples

{
  "account": {
    "name": "Blaname",
    "code": "1234",
    "accountable_type": "AssetAccount",
    "assignee_ids": [1, 2, 55]
  }
}
    

Params

Param name Description
account
required

Validations:

  • Must be a Hash

account[name]
required

Account name.

Validations:

  • Must be a String

account[code]
required

Account code.

Validations:

  • Must be a String

account[deactivated]
optional , nil allowed

Whether account should be hidden from transaction form. Default: false. Possible values: either 1 or 0.

Validations:

  • Must be a Integer

account[accountable_type]
required

Accepts string with the type of account: either “AssetAccount” or “ExpenseAccount”.

Validations:

  • Must be one of: AssetAccount, ExpenseAccount.

account[default_vat_id]
optional , nil allowed

Validations:

  • Must be a Integer

account[assignee_ids]
optional , nil allowed

Ids of users assigned to this account. Passing nil here will remove all assignees.

Validations:

  • Must be an array of Integer

account[netsuite]
optional , nil allowed

NetSuite settings in free form hash

Validations:

  • Must be a Hash

account[limit]
optional , nil allowed

For Expense Account only. Combined receipts total amount limit in company currency per user for this Expense Account.

Validations:

  • Must be a Integer

account[limit_type]
optional , nil allowed

For Expense Account only.

Validations:

  • Must be one of: yearly, monthly, daily.

account[show_participants_field]
optional , nil allowed

For Expense Account only. Show participants field (with label Participants) on Receipt form when that Expense Account is selected. Defaults to false

Validations:

  • Must be one of: true, false, 1, 0.

account[show_on_receipt_form]
optional , nil allowed

For Expense Account only. Allow selecting the account as Purchase type on Receipt form. Default: true.

Validations:

  • Must be one of: true, false, 1, 0.