Codeunit 102 "Import Consolidation from API"
Base Application · Microsoft.Finance.Consolidation
Across versions
- BC23present
- BC247 procedures added, 6 procedures removed
- BC254 procedures changed, 2 procedures added
- BC26-30unchanged
Neighbourhood 12 connected objects and pages
Base Application · Microsoft.Finance.Consolidation · BC23-30 · source at ea08af5e · facts from BC29
Properties
| Property | Value |
|---|---|
| Permissions | tabledata “General Ledger Setup” = R, tabledata “Gen. Journal Batch” = R |
Events published
OnBeforeGetGLSetup(var IsHandled: Boolean; var Response: Text)(integration): Integration event raised before retrieving General Ledger Setup from external Business Central API. Enables custom G/L setup retrieval or bypassing of standard API calls.OnBeforeGetCurrencyExchangeRates(CurrencyFilter: Text; EndingDate: Date; var IsHandled: Boolean; var Response: Text)(integration): Integration event raised before retrieving currency exchange rates from external Business Central API. Enables custom exchange rate retrieval or modification of API request parameters.OnBeforeGetGLEntries(DateFilter: Text; AccountNoFilter: Text; var IsHandled: Boolean; var Response: Text)(integration): Integration event raised before retrieving G/L entries from external Business Central API. Enables custom G/L entry retrieval or modification of API request filters.OnBeforeGetDimensions(DimensionFilter: Text; var IsHandled: Boolean; var Response: Text)(integration): Integration event raised before retrieving dimensions from external Business Central API. Enables custom dimension retrieval or modification of dimension filter parameters.OnBeforeGetGLEntriesCountAtDate(GLAccountNo: Code[20]; ClosingDate: Date; var IsHandled: Boolean; var Response: Text)(integration): Integration event raised before retrieving G/L entries count at specific date from external Business Central API. Enables custom entry count retrieval or bypassing of standard API calls for closing date entries.OnBeforeGetAccountingPeriods(StartingDate: Date; EndingDate: Date; var IsHandled: Boolean; var Response: Text)(integration): Integration event raised before retrieving accounting periods from external Business Central API. Enables custom accounting period retrieval or modification of date range parameters.OnBeforeGetPostingGLAccounts(var IsHandled: Boolean; var Response: Text)(integration): Integration event raised before retrieving posting G/L accounts from external Business Central API. Enables custom G/L account retrieval for posting account filtering during consolidation.
Procedures
GetPrivacyConsentChoice(): Boolean(internal)GetFeatureTelemetryName(): Text(internal)AcquireTokenAndStoreInIsolatedStorage(BusinessUnit: Record "Business Unit")Δ BC25 (internal)IsStoredTokenValidForBusinessUnit(BusinessUnit: Record "Business Unit"): BooleanΔ BC25 (internal)GetCurrencyFactorFromBusinessUnit(var BusinessUnit: Record "Business Unit"): Decimal(internal)SelectCompanyForBusinessUnit(var BusinessUnit: Record "Business Unit")(internal)GetAADTenantIdFromBCUrl(Url: Text): Text(internal)ValidateBCUrl(Url: Text): Boolean(internal)ImportConsolidationDataForBusinessUnit(ConsolidationProcess: Record "Consolidation Process"; BusinessUnit: Record "Business Unit"; var BusUnitConsolidationData: Record "Bus. Unit Consolidation Data")+ BC24: Imports consolidation data for a specific business unit from external Business Central API. Handles API connection setup, data retrieval, and consolidation processing initialization.
Plus 42 local procedures.
Calls
From the extracted call graph of BC29 (graphify-al on the snapshot checkout): calls whose target is known from a declared type or an Object::"Name" argument. Interface dispatch and calls through events are not counted, so the list is not complete.
- Codeunit 432 “Consolidate” (10 calls:
GetAndSetCurrencyExchangeRates → InsertExchRate,GetAndSetGLEntries → InsertEntryDim,GetAndSetGLEntries → InsertGLEntry, …) - Codeunit 501 “OAuth2” (4 calls:
GetToken → AcquireAuthorizationCodeTokenFromCache,GetToken → AcquireAuthorizationCodeTokenFromCacheWithCertificate,GetToken → AcquireTokensByAuthorizationCode, …) - Codeunit 2200 “Azure Key Vault” (2 calls:
GetToken → GetAzureKeyVaultCertificate,GetToken → GetAzureKeyVaultSecret) - Codeunit 10 “Type Helper” (1 call:
GetAndSetPostingGLAccounts → GetOptionNo) - Codeunit 3960 “Regex” (1 call:
GetAADTenantIdFromBCUrl → Match) - Codeunit 457 “Environment Information” (1 call:
GetToken → IsSaaS) - Codeunit 8703 “Feature Telemetry” (1 call:
SelectCompanyForBusinessUnit → LogUptake)
Called by
- Page 242 “Consolidate Wizard” (3 calls:
GetBusinessUnitAccessGranted → IsStoredTokenValidForBusinessUnit,GetDefaultConsolidateState → IsStoredTokenValidForBusinessUnit,OnOpenPage → GetFeatureTelemetryName) - Codeunit 107 “Import and Consolidate” (1 call:
ImportAndConsolidate → GetFeatureTelemetryName) - Codeunit 110 “Consolidate Business Units” (1 call:
ValidateBusinessUnitsToConsolidate → IsStoredTokenValidForBusinessUnit) - Page 241 “Business Unit Card” (1 call:
OnOpenPage → GetFeatureTelemetryName) - Table 220 “Business Unit” (1 call:
GetCurrencyFactorFromBusinessUnit → GetCurrencyFactorFromBusinessUnit)
Implements
Ask your agent
Procedure bodies are not stored here (D10). The call sections above are our own, per object, from the BC29 call graph. For a procedure body or the calls of one procedure, ask bc-code-atlas (external, by Stefan Maron, MIT; default corpus w1-28), which the bc-observatory plugin connects: bcatlas_resolve_node(object_type: "codeunit", object_name: "Import Consolidation from API"), then bcatlas_get_procedure_body or bcatlas_get_neighbors on the returned id.