Browse the extensions reference

agedReceivables

returns AgedBalances!

Receivables aged at a date: bucket totals, a row per customer, and each entity's tie-out to its receivables accounts.

Arguments

NameTypeDescription
asOfDateThe date to age at. Omit for today.
entityIdStringThe entity whose books to read, or the group parent for a group. Omit for the group parent.
scopeString! = "entity"entity for one entity's books, group for the parent and the members consolidated in full, intercompany items set apart.

Returns AgedBalances

Receivables or payables aged at a date: bucket totals, a row per counterparty, and each entity's tie-out to its control accounts. For a group, the items the members owe each other are set apart, since consolidation eliminates them.

FieldTypeDescription
kindString!receivables or payables.
asOfDate!The date the items are aged at.
scopeString!entity or group.
entityIdStringThe entity read, or the group parent for a group.
memberEntityIds[String!]!The entities summed: one, or the parent and its full members.
bucketsAgingBuckets!The totals by age, intercompany items excluded for a group.
agents[AgedAgentRow!]!A row per counterparty, largest open balance first.
defaultedDueDateCountInt!Open items with no due date of their own, aged as due on receipt.
intercompany[OpenItem!]!For a group: open items with another summed member as counterparty.
pairs[IntercompanyPair!]!For a group: each pair of members, both sides of what they owe each other.
tieOuts[ControlTieOut!]!Each summed entity's open items against its control accounts.

Example

query
{ agedReceivables(scope: "...") { kind asOf scope entityId } }
curl
curl -X POST "https://api.robosystems.ai/extensions/$GRAPH_ID/graphql" \
  -H "X-API-Key: $ROBOSYSTEMS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"query": "{ agedReceivables(scope: \"...\") { kind asOf scope entityId } }"}'