Warning! Construction underway! Amatino is in an 'alpha' state. Not all features are operational. See roadmap

Primary
Object
Create
Retrieve
Update
Delete
Restore
Entity
Transaction
Derived
Balance
Ledger
Performance
Position
Recursive Balance
Recursive Ledger
Tree
Ancillary
Custom Unit
Entry
Global Unit
Global Unit List
Ledger Row
Session
Side
Tx Version List
Tree Node
Type
User

Account

An Account is collection of related economic activity. For example, an Account might represent a bank account, income from a particular client, or entity equity. Many Accounts together compose an Entity.

Accounts themselves are composed of Transactions, and the sum of constituent transactions yield an Account Balance.

The Accounts that compose an Entity may be viewed together as part of the Tree.

The Account Object

When returning an Account to you, Amatino uses the following JSON object structure.

Root Type

JSON Array

Object Structure

description An identifier for this account, unique within an entity
key "account_id"
example 42
type JSON Number
description A friendly name for this account
key "name"
example "Subscription Income"
type JSON String
description The type id of the account, one of asset, liability, income, expense, or equity.
key "type"
example 2
type JSON numbwe
description Identifier for this account's parent, unique within an entity.
key "parent_account_id"
example 69
type JSON Number
description Identifier of this account's denominating global unit, if one exists
key "global_unit_id"
example 5
type JSON Number or JSON Null
description Identifier of this account's denominating custom unit, if one exists
key "custom_unit_id"
example 42
type JSON Number or JSON Null
description Universally unique identifier of a counterparty entity, if one exists
key "counterparty_entity_id"
example "oB3cjSNKXklkJ4Tb"
type JSON String or JSON Null
description Friendly description of this account
key "description"
example "Revenue from sale of double-entry accounting services"
type JSON String
description Hex-color value for this account
key "color"
example "#42f4df"
type JSON String

Create Account

API Path /accounts
HTTP Method POST
Description Descr. Create a new account or account

Required Headers

Key X-Signature
Value Your Session signature
Example "yxATCPRKAAXHNiPctNQPHEGGVJF"...
Key X-Session-ID
Value An an integer Session ID
Example 7449059267091272858

Required URL Parameters

Key entity_id
Type string
Description Descr. The entity_id of the Entity in which to create the account(s)
Example oB3cjSNKXklkJ4Tb
Repeatable No

Required JSON Data

Root type

JSON Array

Max Array Length

10

Object Structure

max char length 1024
description Friendly name for the new account
key "name"
example "Subscription Income"
type string
description The fundamental account Type, i.e asset, liability, income, expense, or equity
key "type"
example 1
source /constants/account_types
type JSON Number
description The parent of this new account
key "parent_account_id"
example 42
note Specify null to add a top-level account
type JSON Number or JSON Null
description The global unit denomination of this new account, if desired
example 5
note An account must either either specify a global unit or a custom unit, but not both
key "global_unit_id"
source /unit/list
type JSON Number or JSON Null
description The custom unit denomination of this new account, if desired
example 23
note An account must either either specify a global unit or a custom unit, but not both
key "custom_unit_id"
source /custom_unit/list
type JSON Number or JSON Null
description An entity id of an entity that is counterparty of this new account, if desired
key "counterparty_entity_id"
example "oB3cjSNKXklkJ4Tb"
type JSON String or JSON Null
max char length 1024
description Friendly description of the new account
key "description"
example "Revenue from sale of double-entry accounting services"
type JSON String
description Hex-color value for this account
key "color"
example "#42f4df"
note Accounts created with a null color value will default to #FFFFFF
type JSON String or JSON Null

Returns

Root Type

JSON Array

Object

Account

Retrieve Account

API Path /accounts
HTTP Method GET
Description Descr. Retrieve metadata describing an account or accounts

Required Headers

Key X-Signature
Value Your Session signature
Example "yxATCPRKAAXHNiPctNQPHEGGVJF"...
Key X-Session-ID
Value An an integer Session ID
Example 7449059267091272858

Required URL Parameters

Key entity_id
Type string
Description Descr. An Amatino entity id
Example oB3cjSNKXklkJ4Tb
Repeatable No
Key account_id
Type integer
Description Descr. The ID of the account(s) you wish to retrieve
Example 42
Repeatable Yes

Required JSON Data

None.

Returns

Root Type

JSON Array

Object

Account

Update Account

API Path /accounts
HTTP Method PUT
Description Descr. Update metadata of an existing account or accounts

Required Headers

Key X-Signature
Value Your Session signature
Example "yxATCPRKAAXHNiPctNQPHEGGVJF"...
Key X-Session-ID
Value An an integer Session ID
Example 7449059267091272858

Required URL Parameters

Key entity_id
Type string
Description Descr. The entity_id of the entity in which to update an account or accounts
Example oB3cjSNKXklkJ4Tb
Repeatable No

Required JSON Data

Root type

JSON Array

Max Array Length

10

Object Structure

description The ID of the account you wish to update
key "account_id"
example 42
type integer
max char length 1024
description Friendly name for the account
key "name"
example "Subscription Income"
type string
description The account Type
key "type"
example 1
source /constants/account_types
type JSON Number
description The parent of this account
key "parent_account_id"
example 42
note Specify null to add a top-level account
type JSON Number or JSON Null
description The global unit denomination of this account, if desired
example 5
note An account must either either specify a global unit or a custom unit, but not both
key "global_unit_id"
source /unit/list
type JSON Number or JSON Null
description The custom unit denomination of this account, if desired
example 32
note An account must either either specify a global unit or a custom unit, but not both
key "custom_unit_id"
source /custom_unit/list
type JSON Number or JSON Null
description An entity id of an entity that is counterparty of this account, if desired
key "counterparty_entity_id"
example "oB3cjSNKXklkJ4Tb"
type JSON String or JSON Null
max char length 1024
description Friendly description of the account
key "description"
example "Revenue from sale of double-entry accounting services"
type JSON String
description Hex-color value for this account
key "color"
example "#42f4df"
note Accounts updated with a null color value will default to #FFFFFF
type JSON String or JSON Null

Returns

Root Type

JSON Array

Object

Account

Delete Account

API Path /accounts
HTTP Method DELETE
Description Descr. Delete an account or accounts

Required Headers

Key X-Signature
Value Your Session signature
Example "yxATCPRKAAXHNiPctNQPHEGGVJF"...
Key X-Session-ID
Value An an integer Session ID
Example 7449059267091272858

Required URL Parameters

Key entity_id
Type string
Description Descr. The entity_id of the entity in which to delete an account or accounts
Example oB3cjSNKXklkJ4Tb
Repeatable No

Required JSON Data

Root type

JSON Array

Max Array Length

10

Object Structure

description The ID of the account you wish to delete
key "target_account_id"
example 42
type JSON Number
description The ID of the account into which entries party to the target should be moved
key "entry_replacement_account_id"
example 99
type JSON Number
description Specify true to recursively delete all child accounts of the target account
key "delete_children"
example False
type JSON Boolean
description Specify the new parent of any immediate child accounts of the target account, if desired
key "new_parent_account_id"
example 99
note Specify null to cause immediate child accounts to become top-level accounts
type JSON Number or JSON Null

Returns

Root Type

JSON Array

Object Structure

description The ID of a deleted account
key "account_id"
example 42
type JSON Number

Restore Account

API Path /accounts
HTTP Method PATCH
Description Descr. Restore a deleted account or accounts

Required Headers

Key X-Signature
Value Your Session signature
Example "yxATCPRKAAXHNiPctNQPHEGGVJF"...
Key X-Session-ID
Value An an integer Session ID
Example 7449059267091272858

Required URL Parameters

Key entity_id
Type string
Description Descr. The ID of the entity in which to restore accounts
Example oB3cjSNKXklkJ4Tb
Repeatable No
Key account_id
Type integer
Description Descr. The ID of the account(s) you wish to restore
Example 42
Repeatable Yes

Required JSON Data

None.

Returns

Root Type

JSON Array

Object

Account