# Digits

> Read company information, ledger accounts, transactions, invoices, bills, and financial statements.

App · 20 actions. Web page: https://docs.lodol.com/docs/integrations/digits

## Actions

### Get balance sheet

Balance Sheet.

**Inputs**

- Start date (`start_date`, date): The start date of the statement period (inclusive)
- End date (`end_date`, date): The end date of the statement period (inclusive)
- Interval (`interval`, text): The interval for the statement (e.g., Month, Quarter, Year). One of: `Month`, `Year`, `Quarter`.
- Fiscal year start month (`fiscal_year_start_month`, number): Optional the fiscal year start month (1 = January, 12 = December) defaults to January if not provided
- Department IDs (`department_ids`, list): Optional department identifiers to filter statement totals.
- Entity (`entity_id`, text): Entity's Digits-assigned ID, obtained from entity discovery. Required unless external_id is supplied or the token already identifies the entity.
- Entity external ID (`entity_external_id`, text): Entity's caller-assigned ID in the authorizing organization's namespace. Alternative to id for organization-level tokens; not a source or transaction ID.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "rows": []
  }
}
```

### Get company

Get Company Info.

**Inputs**

- Entity (`entity_id`, text): Entity's Digits-assigned ID, obtained from entity discovery. Required unless external_id is supplied or the token already identifies the entity.
- Entity external ID (`entity_external_id`, text): Entity's caller-assigned ID in the authorizing organization's namespace. Alternative to id for organization-level tokens; not a source or transaction ID.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "currency": "example",
    "earliestTransaction": "example",
    "fiscalYearStartMonth": "example",
    "id": "example",
    "name": "example",
    "slug": "example"
  }
}
```

### Get department

Get Department.

**Inputs**

- Id (`id`, text, required): id.
- Entity (`entity_id`, text): Entity's Digits-assigned ID, obtained from entity discovery. Required unless external_id is supplied or the token already identifies the entity.
- Entity external ID (`entity_external_id`, text): Entity's caller-assigned ID in the authorizing organization's namespace. Alternative to id for organization-level tokens; not a source or transaction ID.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "department": {
      "active": false,
      "description": "example",
      "id": {
        "id": "example",
        "issuer": "example"
      },
      "name": "example",
      "parentId": "example"
    }
  }
}
```

### Get ledger category

Get Category.

**Inputs**

- Id (`id`, text, required): id.
- Entity (`entity_id`, text): Entity's Digits-assigned ID, obtained from entity discovery. Required unless external_id is supplied or the token already identifies the entity.
- Entity external ID (`entity_external_id`, text): Entity's caller-assigned ID in the authorizing organization's namespace. Alternative to id for organization-level tokens; not a source or transaction ID.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "active": false,
    "createdAt": "example",
    "displayNumber": "example",
    "id": "example",
    "name": "example",
    "parentId": "example",
    "subtype": "UnknownSubtype",
    "type": "UnknownType",
    "updatedAt": "example"
  }
}
```

### Get ledger party

Get Party.

**Inputs**

- Id (`id`, text, required): id.
- Entity (`entity_id`, text): Entity's Digits-assigned ID, obtained from entity discovery. Required unless external_id is supplied or the token already identifies the entity.
- Entity external ID (`entity_external_id`, text): Entity's caller-assigned ID in the authorizing organization's namespace. Alternative to id for organization-level tokens; not a source or transaction ID.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "party": {
      "createdAt": "example",
      "description": "example",
      "email": "example",
      "id": {
        "id": "example",
        "issuer": "example"
      },
      "kind": "UnknownKind",
      "name": "example",
      "roles": [],
      "updatedAt": "example"
    }
  }
}
```

### Get location

Get Location.

**Inputs**

- Id (`id`, text, required): id.
- Entity (`entity_id`, text): Entity's Digits-assigned ID, obtained from entity discovery. Required unless external_id is supplied or the token already identifies the entity.
- Entity external ID (`entity_external_id`, text): Entity's caller-assigned ID in the authorizing organization's namespace. Alternative to id for organization-level tokens; not a source or transaction ID.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "location": {
      "id": {
        "id": "example",
        "issuer": "example"
      },
      "name": "example",
      "parentId": "example"
    }
  }
}
```

### Get organization

Get Organization.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "displayId": "example",
    "externalId": "example",
    "id": "example",
    "name": "example"
  }
}
```

### Get profit and loss statement

Profit and Loss.

**Inputs**

- Start date (`start_date`, date): The start date of the statement period (inclusive)
- End date (`end_date`, date): The end date of the statement period (inclusive)
- Interval (`interval`, text): The interval for the statement (e.g., Month, Quarter, Year). One of: `Month`, `Year`, `Quarter`.
- Fiscal year start month (`fiscal_year_start_month`, number): Optional the fiscal year start month (1 = January, 12 = December) defaults to January if not provided
- Department IDs (`department_ids`, list): Optional department identifiers to filter statement totals.
- Entity (`entity_id`, text): Entity's Digits-assigned ID, obtained from entity discovery. Required unless external_id is supplied or the token already identifies the entity.
- Entity external ID (`entity_external_id`, text): Entity's caller-assigned ID in the authorizing organization's namespace. Alternative to id for organization-level tokens; not a source or transaction ID.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "rows": []
  }
}
```

### Get project

Get Project.

**Inputs**

- Id (`id`, text, required): id.
- Entity (`entity_id`, text): Entity's Digits-assigned ID, obtained from entity discovery. Required unless external_id is supplied or the token already identifies the entity.
- Entity external ID (`entity_external_id`, text): Entity's caller-assigned ID in the authorizing organization's namespace. Alternative to id for organization-level tokens; not a source or transaction ID.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "project": {
      "id": {
        "id": "example",
        "issuer": "example"
      }
    }
  }
}
```

### Get transaction

Get Transaction.

**Inputs**

- Id (`id`, text, required): The digits ledger transaction id
- Entity (`entity_id`, text): Entity's Digits-assigned ID, obtained from entity discovery. Required unless external_id is supplied or the token already identifies the entity.
- Entity external ID (`entity_external_id`, text): Entity's caller-assigned ID in the authorizing organization's namespace. Alternative to id for organization-level tokens; not a source or transaction ID.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "transaction": {
      "amount": {
        "amount": 1.0,
        "code": "example"
      },
      "bill": {
        "billDate": "example",
        "dueDate": "example",
        "id": "example",
        "invoiceNumber": "example"
      },
      "date": "example",
      "entries": [],
      "invoice": {
        "dueDate": "example",
        "id": "example",
        "invoiceDate": "example",
        "invoiceNumber": "example"
      },
      "memo": "example",
      "referenceNumber": "example",
      "sources": [],
      "transactionId": "example",
      "transactionType": "Unknown"
    }
  }
}
```

### Get trial balance

Trial Balance.

**Inputs**

- Start date (`start_date`, date): The start date of the statement period (inclusive)
- End date (`end_date`, date): The end date of the statement period (inclusive)
- Interval (`interval`, text): The interval for the statement (e.g., Month, Quarter, Year). One of: `Month`, `Year`, `Quarter`.
- Fiscal year start month (`fiscal_year_start_month`, number): Optional the fiscal year start month (1 = January, 12 = December) defaults to January if not provided
- Entity (`entity_id`, text): Entity's Digits-assigned ID, obtained from entity discovery. Required unless external_id is supplied or the token already identifies the entity.
- Entity external ID (`entity_external_id`, text): Entity's caller-assigned ID in the authorizing organization's namespace. Alternative to id for organization-level tokens; not a source or transaction ID.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "rows": []
  }
}
```

### List departments

List Departments.

**Inputs**

- Active (`active`, true/false): Filter by activity. Omitted returns all departments.
- Entity (`entity_id`, text): Entity's Digits-assigned ID, obtained from entity discovery. Required unless external_id is supplied or the token already identifies the entity.
- Entity external ID (`entity_external_id`, text): Entity's caller-assigned ID in the authorizing organization's namespace. Alternative to id for organization-level tokens; not a source or transaction ID.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "departments": []
  }
}
```

### List entities

List Entities.

**Inputs**

- Limit (`limit`, number): The number of items to return per request. Default and max size is 100.
- Cursor (`cursor`, text): Cursor for pagination.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "entities": [],
    "next": {
      "cursor": "example",
      "more": false
    }
  }
}
```

### List ledger categories

List Categories.

**Inputs**

- Created before (`created_before`, date and time): Filter to categories created before this timestamp
- Created after (`created_after`, date and time): Filter to categories created after this timestamp
- Updated before (`updated_before`, date and time): Filter to categories updated before this timestamp
- Updated after (`updated_after`, date and time): Filter to categories updated after this timestamp
- Entity (`entity_id`, text): Entity's Digits-assigned ID, obtained from entity discovery. Required unless external_id is supplied or the token already identifies the entity.
- Entity external ID (`entity_external_id`, text): Entity's caller-assigned ID in the authorizing organization's namespace. Alternative to id for organization-level tokens; not a source or transaction ID.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "categories": []
  }
}
```

### List ledger entries

List Entries.

**Inputs**

- Occurred before (`occurred_before`, date and time): OccurredBefore filters entries to those that occurred before this timestamp
- Occurred after (`occurred_after`, date and time): OccurredAfter filters entries to those that occurred after this timestamp
- Minimum amount (`minimum_amount`, number): Filters entries to those that exceed the specified minimum amount Double formatted for compatibility, only the integer component is used.
- Maximum amount (`maximum_amount`, number): Filters entries to those that are below the specified maximum amount Double formatted for compatibility, only the integer component is used.
- Currency code (`currency_code`, text): Currency code. USD-only.
- Limit (`limit`, number): The number of items to return per request. Default and max size is 100.
- Cursor (`cursor`, text): Cursor for pagination
- Created before (`created_before`, date and time): Filter to entries created before this timestamp
- Created after (`created_after`, date and time): Filter to entries created after this timestamp
- Updated before (`updated_before`, date and time): Filter to entries updated before this timestamp
- Updated after (`updated_after`, date and time): Filter to entries updated after this timestamp
- Entity (`entity_id`, text): Entity's Digits-assigned ID, obtained from entity discovery. Required unless external_id is supplied or the token already identifies the entity.
- Entity external ID (`entity_external_id`, text): Entity's caller-assigned ID in the authorizing organization's namespace. Alternative to id for organization-level tokens; not a source or transaction ID.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "entryDetails": [],
    "next": {
      "cursor": "example",
      "more": false
    }
  }
}
```

### List ledger parties

List Parties.

**Inputs**

- Name (`name`, text): Optional, case-insensitive name filter
- Kinds (`kinds`, list): Party kinds to include, empty returns all kinds. One or more of: `UnknownKind`, `Person`, `Business`.
- Roles (`roles`, list): Filter by accounting role. Parties must match at least one requested role and all other supplied filters. Omit to include parties regardless of role. UnknownRole and unrecognized values are not accepted. Vendors span multiple accounting roles; include all vendor-related roles to retrieve the full vendor list. One or more of: `UnknownRole`, `EntityVendorRole`, `EntityCustomerRole`, `EntitySupplierRole`, `EntityUnspecifiedRole`, `InstitutionDebitRole`, `InstitutionCreditRole`, `PaymentProcessorRole`, `FacilitatorRole`, `OwnerRole`, and 18 more.
- Limit (`limit`, number): The number of items to return per request. Default and max size is 100.
- Cursor (`cursor`, text): Cursor for pagination
- Created before (`created_before`, date and time): Filter to parties created before this timestamp
- Created after (`created_after`, date and time): Filter to parties created after this timestamp
- Updated before (`updated_before`, date and time): Filter to parties updated before this timestamp
- Updated after (`updated_after`, date and time): Filter to parties updated after this timestamp
- Entity (`entity_id`, text): Entity's Digits-assigned ID, obtained from entity discovery. Required unless external_id is supplied or the token already identifies the entity.
- Entity external ID (`entity_external_id`, text): Entity's caller-assigned ID in the authorizing organization's namespace. Alternative to id for organization-level tokens; not a source or transaction ID.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "next": {
      "cursor": "example",
      "more": false
    },
    "parties": []
  }
}
```

### List locations

List Locations.

**Inputs**

- Entity (`entity_id`, text): Entity's Digits-assigned ID, obtained from entity discovery. Required unless external_id is supplied or the token already identifies the entity.
- Entity external ID (`entity_external_id`, text): Entity's caller-assigned ID in the authorizing organization's namespace. Alternative to id for organization-level tokens; not a source or transaction ID.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "locations": []
  }
}
```

### List projects

List Projects.

**Inputs**

- Entity (`entity_id`, text): Entity's Digits-assigned ID, obtained from entity discovery. Required unless external_id is supplied or the token already identifies the entity.
- Entity external ID (`entity_external_id`, text): Entity's caller-assigned ID in the authorizing organization's namespace. Alternative to id for organization-level tokens; not a source or transaction ID.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "projects": []
  }
}
```

### Query bills

Query Bills.

**Inputs**

- Filters (`filters`, object): Values within each ID list use OR; different fields use AND. Balances include all activity in the published view.
- Limit (`limit`, number): Default and maximum page size is 100.
- Cursor (`cursor`, text): Continuations retain the published view and require unchanged filters.
- Entity (`entity_id`, text): Entity ID.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "next": {
      "cursor": "example",
      "more": false
    },
    "summaries": []
  }
}
```

### Query invoices

Query Invoices.

**Inputs**

- Filters (`filters`, object): Values within each ID list use OR; different fields use AND. Balances include all activity in the published view.
- Limit (`limit`, number): Default and maximum page size is 100.
- Cursor (`cursor`, text): Continuations retain the published view and require unchanged filters.
- Entity (`entity_id`, text): Entity ID.

**Outputs**

- `data` (object): The response from Digits.

**Example output**

```json
{
  "data": {
    "next": {
      "cursor": "example",
      "more": false
    },
    "summaries": []
  }
}
```
