Browse the extensions reference

fiscalCalendar

returns FiscalCalendar

An entity's fiscal calendar — pointers, gap, closeable status.

Arguments

NameTypeDescription
entityIdStringThe entity whose calendar to read. Omit for the group parent.

Returns FiscalCalendar

Current fiscal calendar state for one entity of a graph.

FieldTypeDescription
graphIdString!—
entityIdStringThe entity whose calendar this is.
fiscalYearStartMonthInt!—
closedThroughStringLatest closed period (YYYY-MM), or null if nothing closed
closeTargetStringTarget period the user wants closed through (YYYY-MM)
gapPeriodsInt!Number of periods between closed_through and close_target (inclusive of close_target). 0 means caught up.
catchUpSequence[String!]!Ordered list of periods that a close run would process
closeableNowBoolean!Whether the next period in the catch-up sequence passes all closeable gates
blockers[String!]!Structured blocker codes when closeable_now is False: 'sequence_violation', 'period_incomplete', 'sync_stale', 'calendar_not_initialized', 'period_already_closed', 'pending_obligations', 'stranded_obligations', 'reconciling_items', 'unposted_source_events', 'unreconciled_accounts', 'unmapped_accounts', 'held_bank_lines'; on the consolidation entity, whose close is the group's, also 'entity_open', 'adjustments_unposted', 'residual_unexplained', 'consolidated_does_not_foot'
pendingObligationCountInt!Number of pending schedule_entry_due events blocking close. Non-zero only when pending_obligations is in blockers.
pendingObligationSample[PendingObligationDetail!]!Sample of up to 5 pending obligations (schedule_id, schedule_name, period, event_id) ordered by occurred_at. Use list-event-blocks with event_type=schedule_entry_due&status=pending for the full set.
earliestPendingPeriodStringEarliest period (YYYY-MM) with a pending obligation blocking close. Null when no pending_obligations blocker is active.
syncStaleDaysIntDays the most recent sync is stale relative to the period to close. Populated only when sync_stale is in blockers and last_sync_at exists (null when there's a connection but no sync has ever run).
strandedObligationCountInt!Matured schedule_entry_due events already at 'classified' with no drafted closing entry for their (schedule, period) — adjusting entries a close would silently omit. Resolve by running promote-obligations with dispatch_handlers=true (which reaches them) or voiding the obligation.
strandedObligationSample[PendingObligationDetail!]!Sample of up to 5 stranded obligations (schedule_id, schedule_name, period, event_id) ordered by occurred_at.
reconcilingItemCountInt!Posted events in or before this period whose source payload changed afterwards and that nobody has dispositioned — differences between the books and the source system. Resolve each with resolve-reconciling-item, or close over them knowingly with allow_reconciling_items.
reconcilingItemSample[String!]!Source identifiers (or event ids) of up to 5 unresolved reconciling items, so the blocker names what is holding the close.
unpostedSourceEventCountInt!Source events dated in this period that were never committed: bank-feed lines still captured or classified, and QuickBooks transactions whose automatic posting failed. Commit or void each, or close over them knowingly with allow_unposted_source_events.
unpostedSourceEventSample[String!]!Source identifiers (or event ids) of up to 5 unposted source events, so the blocker names what is holding the close.
heldBankLineCountInt!Bank lines a sync held out of an earlier, closed month — dated there, arriving after it closed — that no close has decided on. They block the next close: reopen the month they are dated in, which gives them back to post, or close over them knowingly with allow_held_bank_lines. Listed by list-event-blocks with status='voided' and void_reason 'feed_in_closed_month'.
heldBankLineSample[String!]!Up to 5 held lines, oldest first, as 'date: description amount [event id]', so the blocker names what is holding the close.
unreconciledAccountCountInt!Reconciliations the close waits on that are not reconciled for this period, including any never compared for it. Run refresh-reconciliations and clear what it reports, release one with set-reconciliation-policy, or close over them knowingly with allow_unreconciled_accounts.
unreconciledAccountSample[String!]!Name and status of up to 5 of those reconciliations, so the blocker names what is holding the close.
unmappedAccountCountInt!Accounts in this entity's chart with postings through the period that its mapping does not map to a reporting concept. Their balances are in no statement, so the month cannot be stated until each is mapped: suggest-mapping, then create-mapping-association. No override lifts it.
unmappedAccountSample[String!]!Code and name of up to 5 of those accounts, so the blocker names what is holding the close.
groupOpenEntities[String!]!The group close: the entities the month consolidates, the parent and its equity-method members included, that have not closed it. Close each first.
groupPendingAdjustments[String!]!The group close: the consolidating entries the consolidation entity neither holds nor has drafted, by kind and member, or what the engine left out and why. Run propose-consolidation-entries.
groupUnexplained[String!]!The group close: residuals and intercompany disagreements left unexplained. Correct the books or post the explaining entry, or close over them knowingly with allow_unexplained_residuals.
groupNotFooting[String!]!The group close: the consolidated balance sheet's and equity statement's validation failures for the month.
lastCloseAtDateTime—
initializedAtDateTime—
lastSyncAtDateTimeMost recent QB sync timestamp (if connected)
periods[FiscalPeriodSummary!]!Fiscal period rows for this graph

Example

query
{ fiscalCalendar { graphId entityId fiscalYearStartMonth closedThrough } }
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": "{ fiscalCalendar { graphId entityId fiscalYearStartMonth closedThrough } }"}'