AccountingReportPositions
Quick Links
Accounts Accounting Entries Products Customers Sales quotes Sales invoices Suppliers Purchase invoices| HTTP | Operation | Type | Object | DTO Why-DTOs? |
|---|---|---|---|---|
| (Query) | accountingReportPositions |
AccountingReportPositionGLDtoInput |
Description
Functionality
- Retrieve Account Positions: Returns the location of accounts in the balance sheet or Profit & Loss report.
- Legislation-Based Categorization: Account positioning depends on the applicable legislation and accounting model.
- Balance Type Consideration: Only accounts classified as Balance Sheet (1) or Profit & Loss (2) are included.
- Detailed or Summary View: Allows filtering results to include only summary lines or detailed lines.
- Account Filtering: Can return all accounts or a specific account based on
accountId. - Multiple Position Handling: Identifies the main position of an account, supports alternative positions, and excludes details by default unless requested.
- Undefined Accounts: If an account is not found in the balance guide, it is labeled as “undefined”.
Input Parameters
-
Account Identifier (
accountId) (Optional):
If provided, returns the positions for a specific account; otherwise, retrieves all accounts. -
Detail Filter (
isDetail) (Boolean, Optional, Default:false):false: Returns only main balance guide positions.true: Includes detailed positions where applicable.
Response
The service returns an array of AccountingReportPositionOutputGLDto objects, each representing an account with the following fields:
- Account Details:
id: Account idcode: Account codedescription: Account descriptionname: Account nameaccountType: Type of the account (e.g., Balance Sheet, Profit & Loss)subAccountType: Subcategory of the accountaccountLevel: Account hierarchy level
- Additional Properties:
deactivated: Whether the account is deactivatedrequestedAction: Indicates if any action is required on the accounttaxTreatmentId: ID of the applicable tax treatmentdefaultType: Default type of the accountdatevAutomaticAccount: Whether the account is automatically managed in DATEVdatevAccountNumber: The account number used in the DATEV systemcollectiveAccount: Whether the account is collectiveapplyVat: Whether VAT should be applied to the account
- Balance Position Information (
reportPositions):balanceGuideLineId: Unique identifier of the balance guide linebalanceGuideLineCode: Code representing the balance guide linebalanceGuideLineDescription: Description of the balance guide lineisDetail: Indicates if the line is a detailed breakdown (true= detailed)isMain: Indicates if this is the main position of the account (true= main position)alternativePositionIfNegative: Indicates if the account has an alternative position when its balance is negative
Header
| Key | Value |
|---|---|
Authorization |
Bearer Current access Token How to find? |
X-TenantId |
Current tenant id Why deprecated ? |
X-OrganizationId |
Current organization Id How to find? |
x-api-key |
Primary or secondary subscription key of your app How to find? |
How to use the Accounting Report Positions service?
Example GraphQL Query
- Here, an account ID is provided, so the request retrieves the positions for this specific account. If no ID were mentioned, the response would include positions for all accounts.
- Here, isDetail = true, meaning that if the account has multiple positions, all details for each position are included.
If isDetail = false, only the first position would be returned.
query($input: AccountingReportPositionGLDtoInput!) {
accountingReportPositions(input: $input) {
id
code
description
accountType
accountLevel
subAccountType
taxTreatmentId
deactivated
collectiveAccount
datevAutomaticAccount
datevAccountNumber
applyVat
reportPositions {
balanceGuideLineId
balanceGuideLineCode
balanceGuideLineDescription
isDetail
isMain
alternativePositionIfNegative
}
}
}
Example GraphQL Variables
{
"input": {
"accountId": "57dc1e99-652e-48ca-b1ef-2e5b233e988d",
"isDetail": true
}
}
Example Response
{
"data": {
"accountingReportPositions": [
{
"id": "3cff68b5-e785-4b2b-95a6-1fae95af9f2c",
"code": "612200",
"description": "612200 - Redevance crédit-bail mobilier",
"accountType": "BALANCE_SHEET",
"accountLevel": "SUB_ACCOUNT",
"subAccountType": "CHARGE",
"taxTreatmentId": "40904303-5c02-4784-a505-9c0325b7a40f",
"deactivated": false,
"collectiveAccount": false,
"datevAutomaticAccount": false,
"datevAccountNumber": null,
"applyVat":false,
"reportPositions": [
{
"balanceGuideLineId": "e3e4fc20-bcb4-419c-bb09-b4ee39e61dac",
"balanceGuideLineCode": "C00203",
"balanceGuideLineDescription": "Autres achats et charges externes (1)",
"isDetail": false,
"isMain": false,
"alternativePositionIfNegative": false
},
{
"balanceGuideLineId": "ae51dc12-f108-41a6-9583-6b45b6979c40",
"balanceGuideLineCode": "C0020301",
"balanceGuideLineDescription": "Redevances de crédit-bail mobilier",
"isDetail": true,
"isMain": false,
"alternativePositionIfNegative": false
}
]
}
]
}
}
accountingReportPositions Input Parameters
| Fields | Type | Description | Required |
|---|---|---|---|
| accountId | UUID | ID of the specific account to retrieve | No |
| isDetail | Boolean | Whether to include detailed positions | No (Default: false) |
accountingReportPositions Response
| Fields | Type | Description |
|---|---|---|
| id |
UUID | AccountId |
| code | String | Account code |
| description | String | Account description |
| name | String | Account name |
| accountLevel |
|
Account hierarchy level |
| accountType |
|
Account type (e.g., Balance Sheet, P&L) |
| subAccountType |
|
Subcategory of the account |
| taxTreatmentId | UUID | ID of the applicable tax treatment |
| deactivated | Boolean | Whether the account is deactivated |
| collectiveAccount | Boolean | Whether the account is collective |
| datevAutomaticAccount | Boolean | Whether the account is automatically managed in DATEV |
| datevAccountNumber | String | The account number used in the DATEV system |
| applyVat | Boolean | Whether VAT should be applied to the account |
| reportPositions[] | Array | List of positions where the account appears |
accountingReportPositions/reportPositions Response
| Fields | Type | Description |
|---|---|---|
| balanceGuideLineId | UUID | Unique identifier of the balance guide line |
| balanceGuideLineCode | String | Code representing the balance guide line |
| balanceGuideLineDescription | String | Description of the balance guide line |
| isDetail | Boolean | Whether this is a detailed breakdown (true) |
| isMain | Boolean | Whether this is the main position (true) |
| alternativePositionIfNegative | Boolean | Whether there is an alternative position when negative |
Info
- isMain:
trueindicates the main position of the account. - alternativePositionIfNegative: If
true, the account has a different position when the balance is negative.