API

Finance APIs

POST finance/general-ledger/{generalLedgerPostingId}/accounting-lines

Resource for creating new general ledger posting line

HTTP method POST
URI https://api.rambase.net/finance/general-ledger/{generalLedgerPostingId}/accounting-lines
Supported formats Xml, Html, Json (ex. $format=json)
- URI parameter {generalLedgerPostingId} General ledger posting identifier
Integer, minimum 100000
Successful HTTP status code 201
API resource identifier 5290, version 5

The following body must be added to the request. Mouse over fieldnames for description and other useful information about the fields. Note that fields in bold are required/mandatory.

Format:
1
<AccountingLine>
2
     <Description
Description

Description of the general ledger posting

This field is optional.

>
{String}</Description>
3
     <Intercompany
Intercompany

This field is optional.

>
4
          <Code
Code

Abbreviation/code to identify the company

This field is optional.

>
{String}</Code>
5
     </Intercompany>
6
     <AccountDimensions>
7
          <GeneralLedgerAccount>
8
               <GeneralLedgerAccountId
GeneralLedgerAccountId

Required/mandatory field

General ledger account identifier

Minimum value: 1000

>
{Integer}</GeneralLedgerAccountId>
9
          </GeneralLedgerAccount>
10
          <Dimensions
Dimensions

This field is optional.

>
11
               <Dimension
Dimension

This field is optional.

>
12
                    <Value
Value

Value for this dimension defintion.

This field is optional.

>
{String}</Value>
13
                    <DimensionDefinition
DimensionDefinition

This field is optional.

>
14
                         <DimensionDefinitionId
DimensionDefinitionId

Dimension identifier

Minimum value: 1

This field is optional.

>
{Integer}</DimensionDefinitionId>
15
                    </DimensionDefinition>
16
               </Dimension>
17
          </Dimensions>
18
     </AccountDimensions>
19
     <VATCodeDefinition
VATCodeDefinition

This field is optional.

>
20
          <VATCode
VATCode

Code that determines VAT rules used for VAT calculations.

This field is optional.

>
{String}</VATCode>
21
     </VATCodeDefinition>
22
     <Location
Location

Location of general ledger posting item.

This field is optional.

>
23
          <LocationId
LocationId

Location identifier

Minimum value: 10000

This field is optional.

>
{Integer}</LocationId>
24
     </Location>
25
     <Totals>
26
          <Currency
Currency

Three character code following the ISO 4217 standard

This field is optional.

>
{String}</Currency>
27
          <Amount
Amount

Required/mandatory field

Total amount.

>
{Decimal}</Amount>
28
     </Totals>
29
     <TotalsConverted
TotalsConverted

This field is optional.

>
30
          <ExchangeRate
ExchangeRate

The exchange rate used in convertion

This field is optional.

>
{Decimal}</ExchangeRate>
31
     </TotalsConverted>
32
</AccountingLine>
1
{
2
     "accountingLine": {
3
          "description
Description

Description of the general ledger posting

This field is optional.

":
"{String}",
4
          "intercompany
Intercompany

This field is optional.

":
{
5
               "code
Code

Abbreviation/code to identify the company

This field is optional.

":
"{String}"
6
          },
7
          "accountDimensions": {
8
               "generalLedgerAccount": {
9
                    "generalLedgerAccountId
GeneralLedgerAccountId

Required/mandatory field

General ledger account identifier

Minimum value: 1000

":
"{Integer}"
10
               },
11
               "dimensions
Dimensions

This field is optional.

":
[
12
                    {
13
                         "value
Value

Value for this dimension defintion.

This field is optional.

":
"{String}",
14
                         "dimensionDefinition
DimensionDefinition

This field is optional.

":
{
15
                              "dimensionDefinitionId
DimensionDefinitionId

Dimension identifier

Minimum value: 1

This field is optional.

":
"{Integer}"
16
                         }
17
                    }
18
               ]
19
          },
20
          "vATCodeDefinition
VATCodeDefinition

This field is optional.

":
{
21
               "vATCode
VATCode

Code that determines VAT rules used for VAT calculations.

This field is optional.

":
"{String}"
22
          },
23
          "location
Location

Location of general ledger posting item.

This field is optional.

":
{
24
               "locationId
LocationId

Location identifier

Minimum value: 10000

This field is optional.

":
"{Integer}"
25
          },
26
          "totals": {
27
               "currency
Currency

Three character code following the ISO 4217 standard

This field is optional.

":
"{String}",
28
               "amount
Amount

Required/mandatory field

Total amount.

":
"{Decimal}"
29
          },
30
          "totalsConverted
TotalsConverted

This field is optional.

":
{
31
               "exchangeRate
ExchangeRate

The exchange rate used in convertion

This field is optional.

":
"{Decimal}"
32
          }
33
     }
34
}

The query string is placed after the resource URL, seperated with a questionmark (?). The query string is composed of a series of query parameters with values. See the page about query parameters on how to use these parameters.

$access_token String, optional After successful login you get an access token which needs to be provided in all API requests. Even though it is possible to pass this token as query parameter, we recommended passing it using the HTTP request header as described in Authorization. Note that all access tokens have an expiration time.
$db String, optional Set the database/company for the request
$useMinimumVersion Integer, optional Used to run a new version of an API resource when your API client is running a deprecated API resource. See the Breaking changes page for more information.
$showDomainDescriptions Boolean, optional Set to "true" to include domain descriptions for fields using domain values. See the Domain values page for more information. Default value is false.
$lang String, optional Specifies the language used in the response, following the 3-letter ISO-639-1 [lll]

Read more about filters and sorting on how to use filter parameters and named filters.

Read more about filters and sorting on how to use sortable parameters

Requesting this resource will yield the following response. Mouse over fieldnames (or fieldgroups) for descriptions and other useful information about the fields.

Please note that some fields may be removed from the response, based on user roles/duties/permissions.

Format:
1
<AccountingLine>
2
     <AccountingLineId
AccountingLineId

Accounting line identifier of the general ledger posting

>
{Integer}</AccountingLineId>
3
     <CreatedAt
CreatedAt

Date and time of creation

>
{Datetime}</CreatedAt>
4
     <VATPercent
VATPercent

Value added tax percent

>
{Decimal}</VATPercent>
5
     <Description
Description

Description of the general ledger posting

>
{String}</Description>
6
     <Intercompany>
7
          <Code
Code

Abbreviation/code to identify the company

>
{String}</Code>
8
     </Intercompany>
9
     <AccountDimensions>
10
          <GeneralLedgerAccount>
11
               <GeneralLedgerAccountId
GeneralLedgerAccountId

General ledger account identifier

>
{Integer}</GeneralLedgerAccountId>
12
               <AccountNumber
AccountNumber

The account number of the general ledger account

>
{String}</AccountNumber>
13
               <Name
Name

Name of general ledger account

>
{String}</Name>
14
               <Type
Type

Type of account

Possible domain values can be found here

>
15
                    <DimensionRequirement>
16
                         <Requirement
Requirement

Specifies how the dimension should be used for the specific account.

Possible domain values can be found here

>
{String}</Requirement>
17
                         <DimensionDefinition>
18
                              <DimensionDefinitionId
DimensionDefinitionId

Dimension identifier

>
{Integer}</DimensionDefinitionId>
19
                              <Name
Name

Name of dimension

>
{String}</Name>
20
                              <ValueSource
ValueSource

Where the value is selected from.

>
21
                                   <Type
Type

Type of source

Possible domain values can be found here

>
{String}</Type>
22
                              </ValueSource>
23
                              <DimensionDefinitionLink
DimensionDefinitionLink

Dimension reference

>
{String}</DimensionDefinitionLink>
24
                         </DimensionDefinition>
25
                    </DimensionRequirement>
26
               </Type>
27
               <GeneralLedgerAccountLink
GeneralLedgerAccountLink

General ledger account reference

>
{String}</GeneralLedgerAccountLink>
28
          </GeneralLedgerAccount>
29
          <Dimensions>
30
               <Dimension>
31
                    <Value
Value

Value for this dimension defintion.

>
{String}</Value>
32
                    <Description
Description

Description of the dimension value.

>
{String}</Description>
33
                    <DimensionDefinition>
34
                         <DimensionDefinitionId
DimensionDefinitionId

Dimension identifier

>
{Integer}</DimensionDefinitionId>
35
                         <Name
Name

Name of dimension

>
{String}</Name>
36
                         <DimensionDefinitionLink
DimensionDefinitionLink

Dimension reference

>
{String}</DimensionDefinitionLink>
37
                    </DimensionDefinition>
38
               </Dimension>
39
          </Dimensions>
40
     </AccountDimensions>
41
     <VATCodeDefinition>
42
          <VATCode
VATCode

Code that determines VAT rules used for VAT calculations.

>
{String}</VATCode>
43
          <Description
Description

Description of VAT Code definition

>
{String}</Description>
44
     </VATCodeDefinition>
45
     <Location
Location

Location of general ledger posting item.

>
46
          <ShortName
ShortName

Unique abbreviation/short name of the location

>
{String}</ShortName>
47
          <Name
Name

Name of warehouse location

>
48
               <CountryCode
CountryCode

Two-character code (ISO 3166) identifying the country.

>
{String}</CountryCode>
49
          </Name>
50
     </Location>
51
     <Totals>
52
          <Currency
Currency

Three character code following the ISO 4217 standard

>
{String}</Currency>
53
          <Amount
Amount

Total amount.

>
{Decimal}</Amount>
54
          <DebitAmount
DebitAmount

Total debit amount.

>
{Decimal}</DebitAmount>
55
          <CreditAmount
CreditAmount

Total credit amount.

>
{Decimal}</CreditAmount>
56
          <Currency
Currency

Three character code following the ISO 4217 standard

>
{String}</Currency>
57
          <ExchangeRate
ExchangeRate

The exchange rate used in convertion

>
{Decimal}</ExchangeRate>
58
          <Amount
Amount

Total amount in company currency.

>
{Decimal}</Amount>
59
          <DebitAmount
DebitAmount

Total debit amount in company currency.

>
{Decimal}</DebitAmount>
60
          <CreditAmount
CreditAmount

Total credit amount in company currency.

>
{Decimal}</CreditAmount>
61
     </Totals>
62
</AccountingLine>
1
{
2
     "accountingLine": {
3
          "accountingLineId
AccountingLineId

Accounting line identifier of the general ledger posting

":
"{Integer}",
4
          "createdAt
CreatedAt

Date and time of creation

":
"{Datetime}",
5
          "vATPercent
VATPercent

Value added tax percent

":
"{Decimal}",
6
          "description
Description

Description of the general ledger posting

":
"{String}",
7
          "intercompany": {
8
               "code
Code

Abbreviation/code to identify the company

":
"{String}"
9
          },
10
          "accountDimensions": {
11
               "generalLedgerAccount": {
12
                    "generalLedgerAccountId
GeneralLedgerAccountId

General ledger account identifier

":
"{Integer}",
13
                    "accountNumber
AccountNumber

The account number of the general ledger account

":
"{String}",
14
                    "name
Name

Name of general ledger account

":
"{String}",
15
                    "type
Type

Type of account

Possible domain values can be found here

":
{
16
                         "dimensionRequirement": {
17
                              "requirement
Requirement

Specifies how the dimension should be used for the specific account.

Possible domain values can be found here

":
"{String}",
18
                              "dimensionDefinition": {
19
                                   "dimensionDefinitionId
DimensionDefinitionId

Dimension identifier

":
"{Integer}",
20
                                   "name
Name

Name of dimension

":
"{String}",
21
                                   "valueSource
ValueSource

Where the value is selected from.

":
{
22
                                        "type
Type

Type of source

Possible domain values can be found here

":
"{String}"
23
                                   },
24
                                   "dimensionDefinitionLink
DimensionDefinitionLink

Dimension reference

":
"{String}"
25
                              }
26
                         }
27
                    },
28
                    "generalLedgerAccountLink
GeneralLedgerAccountLink

General ledger account reference

":
"{String}"
29
               },
30
               "dimensions": [
31
                    {
32
                         "value
Value

Value for this dimension defintion.

":
"{String}",
33
                         "description
Description

Description of the dimension value.

":
"{String}",
34
                         "dimensionDefinition": {
35
                              "dimensionDefinitionId
DimensionDefinitionId

Dimension identifier

":
"{Integer}",
36
                              "name
Name

Name of dimension

":
"{String}",
37
                              "dimensionDefinitionLink
DimensionDefinitionLink

Dimension reference

":
"{String}"
38
                         }
39
                    }
40
               ]
41
          },
42
          "vATCodeDefinition": {
43
               "vATCode
VATCode

Code that determines VAT rules used for VAT calculations.

":
"{String}",
44
               "description
Description

Description of VAT Code definition

":
"{String}"
45
          },
46
          "location
Location

Location of general ledger posting item.

":
{
47
               "shortName
ShortName

Unique abbreviation/short name of the location

":
"{String}",
48
               "name
Name

Name of warehouse location

":
{
49
                    "countryCode
CountryCode

Two-character code (ISO 3166) identifying the country.

":
"{String}"
50
               }
51
          },
52
          "totals": {
53
               "currency
Currency

Three character code following the ISO 4217 standard

":
"{String}",
54
               "amount
Amount

Total amount.

":
"{Decimal}",
55
               "debitAmount
DebitAmount

Total debit amount.

":
"{Decimal}",
56
               "creditAmount
CreditAmount

Total credit amount.

":
"{Decimal}",
57
               "currency
Currency

Three character code following the ISO 4217 standard

":
"{String}",
58
               "exchangeRate
ExchangeRate

The exchange rate used in convertion

":
"{Decimal}",
59
               "amount
Amount

Total amount in company currency.

":
"{Decimal}",
60
               "debitAmount
DebitAmount

Total debit amount in company currency.

":
"{Decimal}",
61
               "creditAmount
CreditAmount

Total credit amount in company currency.

":
"{Decimal}"
62
          }
63
     }
64
}

List of available operations/actions for this resource.
See the operations documentation for more information about API operations.

Possible error codes the response might return:

Error 100169 HTTP 404 General ledger account not found : {0}
Error 100563 HTTP 400 Currency {0} is not supported by the system