microsoft.dynamics365.finance.mainaccount
Module microsoft.dynamics365.finance.mainaccount
API
Definitions
ballerinax/microsoft.dynamics365.finance.mainaccount Ballerina library
Overview
Microsoft Dynamics 365 Finance is Microsoft's cloud ERP solution for financial management, covering general ledger, accounts receivable and payable, fixed assets, budgeting, cash and bank management, and tax.
The microsoft.dynamics365.finance.mainaccount connector provides access to Microsoft Dynamics 365 Finance Main Account entities via the OData REST API.
Key Features
- Manage main account entities in Microsoft Dynamics 365 Finance
- Support for list, create, read, update, and delete operations
- OAuth2 client credentials authentication
Setup guide
Prerequisites
- A Microsoft Dynamics 365 Finance & Operations environment (cloud-hosted or sandbox)
- An Azure Active Directory (Entra ID) app registration with API permissions for Dynamics 365
Step 1: Register an application in Azure AD
-
Sign in to the Azure portal and navigate to Azure Active Directory → App registrations → New registration.
-
Give the application a name, select the appropriate account type, and click Register.
-
Note the Application (client) ID and Directory (tenant) ID from the overview page.
-
Under Certificates & secrets, create a new client secret and note the value immediately — it is only shown once.
Step 2: Grant Dynamics 365 API permissions
-
In the app registration, go to API permissions → Add a permission → APIs my organization uses.
-
Search for Dynamics 365 (or
Microsoft Dynamics ERP) and add theuser_impersonation(or.default) delegated/application scope. -
Click Grant admin consent for your tenant.
Step 3: Add the app as a D365 user
-
In your D365 Finance environment, go to System administration → Users → New.
-
Set the User ID and User name, then paste the Azure AD Application (client) ID into the Azure AD application field.
-
Assign appropriate security roles and save.
Quickstart
To use the microsoft.dynamics365.finance.mainaccount connector in your Ballerina application, modify the .bal file as follows:
Step 1: Import the module
import ballerinax/microsoft.dynamics365.finance.mainaccount;
Step 2: Instantiate a new connector
configurable string tenantId = ?; configurable string clientId = ?; configurable string clientSecret = ?; configurable string serviceUrl = ?; // e.g. "https://<env>.operations.dynamics.com/data" mainaccount:Client cl = check new ({ config = { auth: { tokenUrl: string `https://login.microsoftonline.com/${tenantId}/oauth2/v2.0/token`, clientId, clientSecret, scopes: [string `${serviceUrl}/.default`] } }, serviceUrl );
Step 3: Invoke the connector operation
mainaccount:LeaseBooksCollection results = check cl->listLeaseBooks();
Step 4: Run the Ballerina application
bal run
Examples
The Dynamics 365 Finance Ballerina connectors provide practical examples illustrating usage in various scenarios. Explore these examples.
Clients
microsoft.dynamics365.finance.mainaccount: Client
Constructor
Gets invoked to initialize the connector.
init (ConnectionConfig config, string serviceUrl)- config ConnectionConfig - The configurations to be used when initializing the
connector
- serviceUrl string "https://your-org.operations.dynamics.com/data" - URL of the target service
listLeaseBooks
function listLeaseBooks(map<string|string[]> headers, *ListLeaseBooksQueries queries) returns LeaseBooksCollection|errorList LeaseBooks
Parameters
- queries *ListLeaseBooksQueries - Queries to be sent with the request
Return Type
- LeaseBooksCollection|error - Collection of LeaseBook
createLeaseBooks
Create LeaseBook
Parameters
- payload LeaseBook - The request body
getLeaseBooks
function getLeaseBooks(string dataAreaId, string leaseId, map<string|string[]> headers, *GetLeaseBooksQueries queries) returns LeaseBook|errorGet LeaseBook by key
Parameters
- dataAreaId string - The company data area identifier
- leaseId string - The lease id key field
- queries *GetLeaseBooksQueries - Queries to be sent with the request
deleteLeaseBooks
function deleteLeaseBooks(string dataAreaId, string leaseId, DeleteLeaseBooksHeaders headers) returns error?Delete LeaseBook
Parameters
- dataAreaId string - The company data area identifier
- leaseId string - The lease id key field
- headers DeleteLeaseBooksHeaders (default {}) - Headers to be sent with the request
Return Type
- error? - LeaseBook deleted
updateLeaseBooks
function updateLeaseBooks(string dataAreaId, string leaseId, LeaseBook payload, UpdateLeaseBooksHeaders headers) returns LeaseBook|errorUpdate LeaseBook
Parameters
- dataAreaId string - The company data area identifier
- leaseId string - The lease id key field
- payload LeaseBook - The request body
- headers UpdateLeaseBooksHeaders (default {}) - Headers to be sent with the request
listLedgerAccountGroups
function listLedgerAccountGroups(map<string|string[]> headers, *ListLedgerAccountGroupsQueries queries) returns LedgerAccountGroupsCollection|errorList LedgerAccountGroups
Parameters
- queries *ListLedgerAccountGroupsQueries - Queries to be sent with the request
Return Type
- LedgerAccountGroupsCollection|error - Collection of LedgerAccountGroup
createLedgerAccountGroups
function createLedgerAccountGroups(LedgerAccountGroup payload, map<string|string[]> headers) returns LedgerAccountGroup|errorCreate LedgerAccountGroup
Parameters
- payload LedgerAccountGroup - The request body
Return Type
- LedgerAccountGroup|error - LedgerAccountGroup created
getLedgerAccountGroups
function getLedgerAccountGroups(string dataAreaId, string ledgerPostingGroup, map<string|string[]> headers, *GetLedgerAccountGroupsQueries queries) returns LedgerAccountGroup|errorGet LedgerAccountGroup by key
Parameters
- dataAreaId string - The company data area identifier
- ledgerPostingGroup string - The ledger posting group key field
- queries *GetLedgerAccountGroupsQueries - Queries to be sent with the request
Return Type
- LedgerAccountGroup|error - LedgerAccountGroup
deleteLedgerAccountGroups
function deleteLedgerAccountGroups(string dataAreaId, string ledgerPostingGroup, DeleteLedgerAccountGroupsHeaders headers) returns error?Delete LedgerAccountGroup
Parameters
- dataAreaId string - The company data area identifier
- ledgerPostingGroup string - The ledger posting group key field
- headers DeleteLedgerAccountGroupsHeaders (default {}) - Headers to be sent with the request
Return Type
- error? - LedgerAccountGroup deleted
updateLedgerAccountGroups
function updateLedgerAccountGroups(string dataAreaId, string ledgerPostingGroup, LedgerAccountGroup payload, UpdateLedgerAccountGroupsHeaders headers) returns LedgerAccountGroup|errorUpdate LedgerAccountGroup
Parameters
- dataAreaId string - The company data area identifier
- ledgerPostingGroup string - The ledger posting group key field
- payload LedgerAccountGroup - The request body
- headers UpdateLedgerAccountGroupsHeaders (default {}) - Headers to be sent with the request
Return Type
- LedgerAccountGroup|error - LedgerAccountGroup updated
listLedgers
function listLedgers(map<string|string[]> headers, *ListLedgersQueries queries) returns LedgersCollection|errorList Ledgers
Parameters
- queries *ListLedgersQueries - Queries to be sent with the request
Return Type
- LedgersCollection|error - Collection of Ledger
createLedgers
Create Ledger
Parameters
- payload Ledger - The request body
getLedgers
function getLedgers(string legalEntityId, map<string|string[]> headers, *GetLedgersQueries queries) returns Ledger|errorGet Ledger by key
Parameters
- legalEntityId string - The legal entity id key field
- queries *GetLedgersQueries - Queries to be sent with the request
deleteLedgers
function deleteLedgers(string legalEntityId, DeleteLedgersHeaders headers) returns error?Delete Ledger
Parameters
- legalEntityId string - The legal entity id key field
- headers DeleteLedgersHeaders (default {}) - Headers to be sent with the request
Return Type
- error? - Ledger deleted
updateLedgers
function updateLedgers(string legalEntityId, Ledger payload, UpdateLedgersHeaders headers) returns Ledger|errorUpdate Ledger
Parameters
- legalEntityId string - The legal entity id key field
- payload Ledger - The request body
- headers UpdateLedgersHeaders (default {}) - Headers to be sent with the request
listMainAccountLegalEntities
function listMainAccountLegalEntities(map<string|string[]> headers, *ListMainAccountLegalEntitiesQueries queries) returns MainAccountLegalEntitiesCollection|errorList MainAccountLegalEntities
Parameters
- queries *ListMainAccountLegalEntitiesQueries - Queries to be sent with the request
Return Type
- MainAccountLegalEntitiesCollection|error - Collection of MainAccountLegalEntity
createMainAccountLegalEntities
function createMainAccountLegalEntities(MainAccountLegalEntity payload, map<string|string[]> headers) returns MainAccountLegalEntity|errorCreate MainAccountLegalEntity
Parameters
- payload MainAccountLegalEntity - The request body
Return Type
- MainAccountLegalEntity|error - MainAccountLegalEntity created
getMainAccountLegalEntities
function getMainAccountLegalEntities(string mainAccountId, string chartOfAccounts, string legalEntityId, map<string|string[]> headers, *GetMainAccountLegalEntitiesQueries queries) returns MainAccountLegalEntity|errorGet MainAccountLegalEntity by key
Parameters
- mainAccountId string - The main account id key field
- chartOfAccounts string - The chart of accounts key field
- legalEntityId string - The legal entity id key field
- queries *GetMainAccountLegalEntitiesQueries - Queries to be sent with the request
Return Type
- MainAccountLegalEntity|error - MainAccountLegalEntity
deleteMainAccountLegalEntities
function deleteMainAccountLegalEntities(string mainAccountId, string chartOfAccounts, string legalEntityId, DeleteMainAccountLegalEntitiesHeaders headers) returns error?Delete MainAccountLegalEntity
Parameters
- mainAccountId string - The main account id key field
- chartOfAccounts string - The chart of accounts key field
- legalEntityId string - The legal entity id key field
- headers DeleteMainAccountLegalEntitiesHeaders (default {}) - Headers to be sent with the request
Return Type
- error? - MainAccountLegalEntity deleted
updateMainAccountLegalEntities
function updateMainAccountLegalEntities(string mainAccountId, string chartOfAccounts, string legalEntityId, MainAccountLegalEntity payload, UpdateMainAccountLegalEntitiesHeaders headers) returns MainAccountLegalEntity|errorUpdate MainAccountLegalEntity
Parameters
- mainAccountId string - The main account id key field
- chartOfAccounts string - The chart of accounts key field
- legalEntityId string - The legal entity id key field
- payload MainAccountLegalEntity - The request body
- headers UpdateMainAccountLegalEntitiesHeaders (default {}) - Headers to be sent with the request
Return Type
- MainAccountLegalEntity|error - MainAccountLegalEntity updated
listMainAccounts
function listMainAccounts(map<string|string[]> headers, *ListMainAccountsQueries queries) returns MainAccountsCollection|errorList MainAccounts
Parameters
- queries *ListMainAccountsQueries - Queries to be sent with the request
Return Type
- MainAccountsCollection|error - Collection of MainAccount
createMainAccounts
function createMainAccounts(MainAccount payload, map<string|string[]> headers) returns MainAccount|errorCreate MainAccount
Parameters
- payload MainAccount - The request body
Return Type
- MainAccount|error - MainAccount created
getMainAccounts
function getMainAccounts(string chartOfAccounts, string mainAccountId, map<string|string[]> headers, *GetMainAccountsQueries queries) returns MainAccount|errorGet MainAccount by key
Parameters
- chartOfAccounts string - The chart of accounts key field
- mainAccountId string - The main account id key field
- queries *GetMainAccountsQueries - Queries to be sent with the request
Return Type
- MainAccount|error - MainAccount
deleteMainAccounts
function deleteMainAccounts(string chartOfAccounts, string mainAccountId, DeleteMainAccountsHeaders headers) returns error?Delete MainAccount
Parameters
- chartOfAccounts string - The chart of accounts key field
- mainAccountId string - The main account id key field
- headers DeleteMainAccountsHeaders (default {}) - Headers to be sent with the request
Return Type
- error? - MainAccount deleted
updateMainAccounts
function updateMainAccounts(string chartOfAccounts, string mainAccountId, MainAccount payload, UpdateMainAccountsHeaders headers) returns MainAccount|errorUpdate MainAccount
Parameters
- chartOfAccounts string - The chart of accounts key field
- mainAccountId string - The main account id key field
- payload MainAccount - The request body
- headers UpdateMainAccountsHeaders (default {}) - Headers to be sent with the request
Return Type
- MainAccount|error - MainAccount updated
Records
microsoft.dynamics365.finance.mainaccount: ConnectionConfig
Fields
- auth? OAuth2ClientCredentialsGrantConfig - Configurations related to client authentication
- httpVersion HttpVersion(default http:HTTP_2_0) - The HTTP version understood by the client
- http1Settings ClientHttp1Settings(default {}) - Configurations related to HTTP/1.x protocol
- http2Settings ClientHttp2Settings(default {}) - Configurations related to HTTP/2 protocol
- timeout decimal(default 30) - The maximum time to wait (in seconds) for a response before closing the connection
- forwarded string(default "disable") - The choice of setting
forwarded/x-forwardedheader
- followRedirects? FollowRedirects - Configurations associated with Redirection
- poolConfig? PoolConfiguration - Configurations associated with request pooling
- cache CacheConfig(default {}) - HTTP caching related configurations
- compression Compression(default http:COMPRESSION_AUTO) - Specifies the way of handling compression (
accept-encoding) header
- circuitBreaker? CircuitBreakerConfig - Configurations associated with the behaviour of the Circuit Breaker
- retryConfig? RetryConfig - Configurations associated with retrying
- cookieConfig? CookieConfig - Configurations associated with cookies
- responseLimits ResponseLimitConfigs(default {}) - Configurations associated with inbound response size limits
- secureSocket? ClientSecureSocket - SSL/TLS-related options
- proxy? ProxyConfig - Proxy server related options
- socketConfig ClientSocketConfig(default {}) - Provides settings related to client socket configuration
- validation boolean(default true) - Enables the inbound payload validation functionality which provided by the constraint package. Enabled by default
- laxDataBinding boolean(default true) - Enables relaxed data binding on the client side. When enabled,
nilvalues are treated as optional, and absent fields are handled asnilabletypes. Enabled by default.
microsoft.dynamics365.finance.mainaccount: DeleteLeaseBooksHeaders
Represents the Headers record for the operation: deleteLeaseBooks
Fields
- ifMatch? string - ETag value for optimistic concurrency; prevents overwriting concurrent modifications
microsoft.dynamics365.finance.mainaccount: DeleteLedgerAccountGroupsHeaders
Represents the Headers record for the operation: deleteLedgerAccountGroups
Fields
- ifMatch? string - ETag value for optimistic concurrency; prevents overwriting concurrent modifications
microsoft.dynamics365.finance.mainaccount: DeleteLedgersHeaders
Represents the Headers record for the operation: deleteLedgers
Fields
- ifMatch? string - ETag value for optimistic concurrency; prevents overwriting concurrent modifications
microsoft.dynamics365.finance.mainaccount: DeleteMainAccountLegalEntitiesHeaders
Represents the Headers record for the operation: deleteMainAccountLegalEntities
Fields
- ifMatch? string - ETag value for optimistic concurrency; prevents overwriting concurrent modifications
microsoft.dynamics365.finance.mainaccount: DeleteMainAccountsHeaders
Represents the Headers record for the operation: deleteMainAccounts
Fields
- ifMatch? string - ETag value for optimistic concurrency; prevents overwriting concurrent modifications
microsoft.dynamics365.finance.mainaccount: FiscalCalendar
Fields
- quarter? FiscalQuarter -
- ledgerRecId? int -
- quarterOffset? Signed32 -
- calendarId? string -
- periodOffset? Signed32 -
- yearName? string -
- calendarRecId? int -
- ledgerGregorianDateId? string -
- yearOffset? Signed32 -
- month? FiscalPeriodMonth -
- gregorianDate? string -
- periodRecId? int -
- periodName? string -
microsoft.dynamics365.finance.mainaccount: GetLeaseBooksQueries
Represents the Queries record for the operation: getLeaseBooks
Fields
- expand? string - OData $expand query parameter - comma-separated list of related entities to include
- 'select? string - OData $select query parameter - comma-separated list of fields to return
microsoft.dynamics365.finance.mainaccount: GetLedgerAccountGroupsQueries
Represents the Queries record for the operation: getLedgerAccountGroups
Fields
- expand? string - OData $expand query parameter - comma-separated list of related entities to include
- 'select? string - OData $select query parameter - comma-separated list of fields to return
microsoft.dynamics365.finance.mainaccount: GetLedgersQueries
Represents the Queries record for the operation: getLedgers
Fields
- expand? string - OData $expand query parameter - comma-separated list of related entities to include
- 'select? string - OData $select query parameter - comma-separated list of fields to return
microsoft.dynamics365.finance.mainaccount: GetMainAccountLegalEntitiesQueries
Represents the Queries record for the operation: getMainAccountLegalEntities
Fields
- expand? string - OData $expand query parameter - comma-separated list of related entities to include
- 'select? string - OData $select query parameter - comma-separated list of fields to return
microsoft.dynamics365.finance.mainaccount: GetMainAccountsQueries
Represents the Queries record for the operation: getMainAccounts
Fields
- expand? string - OData $expand query parameter - comma-separated list of related entities to include
- 'select? string - OData $select query parameter - comma-separated list of fields to return
microsoft.dynamics365.finance.mainaccount: LeaseBook
Fields
- dimensionDefaultDisplayValue? string -
- deferredRentCarryover? decimal -
- percentOfIndexChangeToApply? decimal -
- commencementDate? string -
- costPerMile? decimal -
- indexRateType? string -
- currency? string -
- currentLiabilityBalance? decimal -
- leaseStartDate? string -
- street? string -
- leaseDescription? string -
- unpostedDepreciationJournals? Signed32 -
- presentValueOverFairValue? decimal -
- securityDepositReminderDate? string -
- limitOnRateIncrease? decimal -
- shortTermLease? NoYes -
- previousLeaseType? AssetLeaseType -
- uniqueAsset? NoYes -
- leaseStatus? AssetLeaseLeaseStatus -
- leaseTermMonths? Signed32 -
- currentAssetBalance? decimal -
- taxItemGroup? string -
- rentableArea? decimal -
- transferOfOwnership? NoYesCombo -
- allowDecreases? NoYes -
- leasePrepayments? decimal -
- unpostedInterestJournals? Signed32 -
- residualValueGuarantee? decimal -
- postingLayer? CurrentOperationsTax -
- revaluationDate? string -
- lastDatePaymentJournal? string -
- interestPeriodsRemaining? Signed32 -
- depreciationPeriodsRemaining? Signed32 -
- leaseGroup? string -
- leaseClassification? AssetLeaseAccountingFramework -
- incidentalCost? decimal -
- contractSignatureDate? string -
- leasingConvention? AssetLeaseLeasingConvention -
- masterLeaseId? string -
- expirationDate? string -
- lowValueLease? NoYes -
- leaseModificationDate? string -
- expectedTerminationDate? string -
- bankContractNumber? string -
- company? string -
- latePayment? decimal -
- borrowingRate? decimal -
- deliveryDate? string -
- presentValuePaymentsRemaining? decimal -
- lastDateInterestJournal? string -
- manuallyRevalue? NoYes -
- dataAreaId? string -
- paymentContractModified? NoYes -
- countryRegionID? string -
- annuityType? AssetLeaseAnnuityType -
- leaseIncentives? decimal -
- holdoverFee? decimal -
- unitOfMeasure? string -
- fairValueOfAsset? decimal -
- implicitRate? decimal -
- locationOpeningDate? string -
- vendorAccount? string -
- city? string -
- overrideReason? string -
- minimunLimitsOfLiability? decimal -
- dateEntryToPost? string -
- indexChangeToApply? decimal -
- bookType? string -
- taxGroup? string -
- state? string -
- lastDepreciationDate? string -
- exchangeRate? decimal -
- financialCommercialTerms? string -
- fixedExchangeRate? NoYes -
- fixedAssetNumber? string -
- leaseId? string -
- leasePaymentsRemaining? Signed32 -
- leaseType? AssetLeaseType -
- fixedExchangeRateReporting? NoYes -
- county? string -
- overuseFee? decimal -
- securityDepositRefundable? NoYes -
- mileageLimit? decimal -
- fixedAssetBookId? string -
- monthsBetweenRevaluations? Signed32 -
- locationNumber? string -
- maxCoverage? decimal -
- leaseTermOverUsefulLife? decimal -
- securityDeposit? decimal -
- initialDirectCost? decimal -
- zipCode? string -
- currentMileage? decimal -
- unpostedLeasePayments? Signed32 -
- compoundingInterval? AssetLeaseCompoundingInterval -
- undiscountedPaymentsRemaining? decimal -
- accountingFramework? AssetLeaseAccountingFramework -
- assetUsefulLife? Signed32 -
- percentCommonAreaMaintenance? decimal -
- dismantlingCosts? decimal -
- financingAmount? Signed32 -
- indexRate? decimal -
- exchangeRateReporting? decimal -
microsoft.dynamics365.finance.mainaccount: LeaseBooksCollection
Fields
- Fields Included from *ODataCollection
- Fields Included from *LeaseBooksCollectionAllOf2
- value LeaseBook[]
- anydata...
microsoft.dynamics365.finance.mainaccount: LeaseBooksCollectionAllOf2
Fields
- value? LeaseBook[] -
microsoft.dynamics365.finance.mainaccount: Ledger
Fields
- ledgerRecId? int -
- description? string -
- isBudgetControlEnabled? NoYes -
- accountStructureName18? string -
- accountStructureName19? string -
- accountStructureName16? string -
- accountStructureName17? string -
- accountStructureName14? string -
- accountStructureName15? string -
- mainAccountIdFinancialLoss? string -
- accountStructureName12? string -
- exchangeRateType? string -
- accountStructureName13? string -
- mainAccountIdUnrealizedLoss? string -
- accountStructureName10? string -
- name? string -
- accountStructureName11? string -
- reportingCurrencyExchangeRateType? string -
- legalEntityId? string -
- accountingCurrency? string -
- mainAccountIdUnrealizedGain? string -
- accountStructureName1? string -
- accountStructureName2? string -
- accountStructureName3? string -
- accountStructureName4? string -
- accountStructureName5? string -
- accountStructureName6? string -
- accountStructureName7? string -
- chartOfAccountsRecId? int -
- accountStructureName8? string -
- accountStructureName9? string -
- mainAccountIdFinancialGain? string -
- mainAccountIdRealizedLoss? string -
- balancingFinancialDimension? string -
- accountStructureName20? string -
- fiscalCalendar? string -
- chartOfAccounts? string -
- mainAccountIdRealizedGain? string -
- budgetExchangeRateType? string -
- reportingCurrency? string -
microsoft.dynamics365.finance.mainaccount: LedgerAccountGroup
Fields
- ledgerPostingGroup? string -
- dataAreaId? string -
- dTLDisplayValue? string -
- accountForFATaxesDisplayValue? string -
- writingOffDTLDisplayValue? string -
- cTLDisplayValue? string -
- cTADisplayValue? string -
- writingOffDTADisplayValue? string -
- dTADisplayValue? string -
microsoft.dynamics365.finance.mainaccount: LedgerAccountGroupsCollection
Fields
- Fields Included from *ODataCollection
- Fields Included from *LedgerAccountGroupsCollectionAllOf2
- value LedgerAccountGroup[]
- anydata...
microsoft.dynamics365.finance.mainaccount: LedgerAccountGroupsCollectionAllOf2
Fields
- value? LedgerAccountGroup[] -
microsoft.dynamics365.finance.mainaccount: LedgersCollection
Fields
- Fields Included from *ODataCollection
- Fields Included from *LedgersCollectionAllOf2
- value Ledger[]
- anydata...
microsoft.dynamics365.finance.mainaccount: LedgersCollectionAllOf2
Fields
- value? Ledger[] -
microsoft.dynamics365.finance.mainaccount: ListLeaseBooksQueries
Represents the Queries record for the operation: listLeaseBooks
Fields
- skip? int - OData $skip query parameter - number of records to skip
- top? int - OData $top query parameter - maximum number of records to return
- filter? string - OData $filter query parameter - filter expression
- orderby? string - OData $orderby query parameter - sort order expression
- expand? string - OData $expand query parameter - comma-separated list of related entities to include
- crossCompany? boolean - When true, query results include records from all companies
- count? boolean - When true, the response includes the total count of matching records
- 'select? string - OData $select query parameter - comma-separated list of fields to return
microsoft.dynamics365.finance.mainaccount: ListLedgerAccountGroupsQueries
Represents the Queries record for the operation: listLedgerAccountGroups
Fields
- skip? int - OData $skip query parameter - number of records to skip
- top? int - OData $top query parameter - maximum number of records to return
- filter? string - OData $filter query parameter - filter expression
- orderby? string - OData $orderby query parameter - sort order expression
- expand? string - OData $expand query parameter - comma-separated list of related entities to include
- crossCompany? boolean - When true, query results include records from all companies
- count? boolean - When true, the response includes the total count of matching records
- 'select? string - OData $select query parameter - comma-separated list of fields to return
microsoft.dynamics365.finance.mainaccount: ListLedgersQueries
Represents the Queries record for the operation: listLedgers
Fields
- skip? int - OData $skip query parameter - number of records to skip
- top? int - OData $top query parameter - maximum number of records to return
- filter? string - OData $filter query parameter - filter expression
- orderby? string - OData $orderby query parameter - sort order expression
- expand? string - OData $expand query parameter - comma-separated list of related entities to include
- crossCompany? boolean - When true, query results include records from all companies
- count? boolean - When true, the response includes the total count of matching records
- 'select? string - OData $select query parameter - comma-separated list of fields to return
microsoft.dynamics365.finance.mainaccount: ListMainAccountLegalEntitiesQueries
Represents the Queries record for the operation: listMainAccountLegalEntities
Fields
- skip? int - OData $skip query parameter - number of records to skip
- top? int - OData $top query parameter - maximum number of records to return
- filter? string - OData $filter query parameter - filter expression
- orderby? string - OData $orderby query parameter - sort order expression
- expand? string - OData $expand query parameter - comma-separated list of related entities to include
- crossCompany? boolean - When true, query results include records from all companies
- count? boolean - When true, the response includes the total count of matching records
- 'select? string - OData $select query parameter - comma-separated list of fields to return
microsoft.dynamics365.finance.mainaccount: ListMainAccountsQueries
Represents the Queries record for the operation: listMainAccounts
Fields
- skip? int - OData $skip query parameter - number of records to skip
- top? int - OData $top query parameter - maximum number of records to return
- filter? string - OData $filter query parameter - filter expression
- orderby? string - OData $orderby query parameter - sort order expression
- expand? string - OData $expand query parameter - comma-separated list of related entities to include
- crossCompany? boolean - When true, query results include records from all companies
- count? boolean - When true, the response includes the total count of matching records
- 'select? string - OData $select query parameter - comma-separated list of fields to return
microsoft.dynamics365.finance.mainaccount: MainAccount
Fields
- natureCodeBR? string -
- sRUCode? string -
- user? string -
- validatePostingType? FieldControl -
- inflationAdjustment? NoYes -
- mainAccountType? DimensionLedgerAccountType -
- closing? LedgerClosing -
- validateCurrency? FieldControl -
- debitCreditDefault? DebCredProposal -
- name? string -
- offsetAccountDisplayValue? string -
- exchangeAdjustmentRateType? string -
- foreignCurrencyRevaluation? NoYes -
- defaultConsolidationAccount? string -
- openingAccountId? string -
- parentMainAccountId? string -
- financialReportingCurrencyTranslationType? FinancialReportingTranslationType -
- validateUser? FieldControl -
- reportingExchangeAdjustmentRateType? string -
- mandatoryPaymentReference? NoYes -
- financialReportingExchangeRateType? string -
- defaultCurrency? string -
- monetary? NoYes -
- debitCreditRequirement? DebCredProposal -
- adjustmentMethod? AdjustmentMethodMX -
- chartOfAccountsRecId? int -
- activeTo? string -
- reportingAccountType? DimensionLedgerAccountReportingType -
- isSuspended? NoYes -
- mainAccountId? string -
- repomoType? RepomoTypeMX -
- activeFrom? string -
- postingType? LedgerPostingType -
- mainAccountCategory? string -
- chartOfAccounts? string -
- mainAccountRecId? int -
- accountCategoryDescription? string -
- balanceControl? DebCredProposal -
- doNotAllowManualEntry? NoYes -
microsoft.dynamics365.finance.mainaccount: MainAccountLegalEntitiesCollection
Fields
- Fields Included from *ODataCollection
- Fields Included from *MainAccountLegalEntitiesCollectionAllOf2
- value MainAccountLegalEntity[]
- anydata...
microsoft.dynamics365.finance.mainaccount: MainAccountLegalEntitiesCollectionAllOf2
Fields
- value? MainAccountLegalEntity[] -
microsoft.dynamics365.finance.mainaccount: MainAccountLegalEntity
Fields
- salesTaxGroup? string -
- validateSalesTax? FieldControl -
- reportingExchangeAdjustmentRateType? string -
- isExempt? NoYes -
- salesTaxCode? string -
- itemSalesTaxGroup? string -
- activeTo? string -
- taxTableLegalEntity? string -
- fixedDimensionsDisplayValue? string -
- isSuspended? NoYes -
- mainAccountId? string -
- activeFrom? string -
- exchangeAdjustmentRateType? string -
- itemSalesTaxGroupHeadingLegalEntity? string -
- chartOfAccounts? string -
- legalEntityId? string -
- salesTaxDirection? SalesPurch -
- defaultDimensionDisplayValue? string -
- autoAllocate? NoYes -
- doNotAllowManualEntry? NoYes -
microsoft.dynamics365.finance.mainaccount: MainAccountsCollection
Fields
- Fields Included from *ODataCollection
- Fields Included from *MainAccountsCollectionAllOf2
- value MainAccount[]
- anydata...
microsoft.dynamics365.finance.mainaccount: MainAccountsCollectionAllOf2
Fields
- value? MainAccount[] -
microsoft.dynamics365.finance.mainaccount: OAuth2ClientCredentialsGrantConfig
OAuth2 Client Credentials Grant Configs
Fields
- Fields Included from *OAuth2ClientCredentialsGrantConfig
- tokenUrl string(default "https://login.microsoftonline.com/{tenant}/oauth2/v2.0/token") - Token URL
microsoft.dynamics365.finance.mainaccount: ODataCollection
Fields
- odataNextLink? string -
- odataCount? int -
- odataContext? string -
microsoft.dynamics365.finance.mainaccount: UpdateLeaseBooksHeaders
Represents the Headers record for the operation: updateLeaseBooks
Fields
- ifMatch? string - ETag value for optimistic concurrency; prevents overwriting concurrent modifications
microsoft.dynamics365.finance.mainaccount: UpdateLedgerAccountGroupsHeaders
Represents the Headers record for the operation: updateLedgerAccountGroups
Fields
- ifMatch? string - ETag value for optimistic concurrency; prevents overwriting concurrent modifications
microsoft.dynamics365.finance.mainaccount: UpdateLedgersHeaders
Represents the Headers record for the operation: updateLedgers
Fields
- ifMatch? string - ETag value for optimistic concurrency; prevents overwriting concurrent modifications
microsoft.dynamics365.finance.mainaccount: UpdateMainAccountLegalEntitiesHeaders
Represents the Headers record for the operation: updateMainAccountLegalEntities
Fields
- ifMatch? string - ETag value for optimistic concurrency; prevents overwriting concurrent modifications
microsoft.dynamics365.finance.mainaccount: UpdateMainAccountsHeaders
Represents the Headers record for the operation: updateMainAccounts
Fields
- ifMatch? string - ETag value for optimistic concurrency; prevents overwriting concurrent modifications
Union types
microsoft.dynamics365.finance.mainaccount: AssetLeaseType
AssetLeaseType
microsoft.dynamics365.finance.mainaccount: CurrentOperationsTax
CurrentOperationsTax
microsoft.dynamics365.finance.mainaccount: AssetLeaseLeasingConvention
AssetLeaseLeasingConvention
microsoft.dynamics365.finance.mainaccount: LedgerClosing
LedgerClosing
microsoft.dynamics365.finance.mainaccount: LedgerPostingType
LedgerPostingType
microsoft.dynamics365.finance.mainaccount: FieldControl
FieldControl
microsoft.dynamics365.finance.mainaccount: AdjustmentMethodMX
AdjustmentMethodMX
microsoft.dynamics365.finance.mainaccount: SalesPurch
SalesPurch
microsoft.dynamics365.finance.mainaccount: AssetLeaseLeaseStatus
AssetLeaseLeaseStatus
microsoft.dynamics365.finance.mainaccount: DimensionLedgerAccountType
DimensionLedgerAccountType
microsoft.dynamics365.finance.mainaccount: RepomoTypeMX
RepomoTypeMX
microsoft.dynamics365.finance.mainaccount: DimensionLedgerAccountReportingType
DimensionLedgerAccountReportingType
microsoft.dynamics365.finance.mainaccount: FiscalPeriodMonth
FiscalPeriodMonth
microsoft.dynamics365.finance.mainaccount: AssetLeaseCompoundingInterval
AssetLeaseCompoundingInterval
microsoft.dynamics365.finance.mainaccount: DebCredProposal
DebCredProposal
microsoft.dynamics365.finance.mainaccount: AssetLeaseAccountingFramework
AssetLeaseAccountingFramework
microsoft.dynamics365.finance.mainaccount: FinancialReportingTranslationType
FinancialReportingTranslationType
microsoft.dynamics365.finance.mainaccount: AssetLeaseAnnuityType
AssetLeaseAnnuityType
microsoft.dynamics365.finance.mainaccount: NoYes
NoYes
microsoft.dynamics365.finance.mainaccount: FiscalQuarter
FiscalQuarter
microsoft.dynamics365.finance.mainaccount: NoYesCombo
NoYesCombo
Import
import ballerinax/microsoft.dynamics365.finance.mainaccount;Other versions
0.8.0
Metadata
Released date: 2 days ago
Version: 0.8.0
License: Apache-2.0
Compatibility
Platform: any
Ballerina version: 2201.13.0
GraalVM compatible: Yes
Pull count
Total: 1
Current verison: 1
Weekly downloads
Keywords
Name/Microsoft Dynamics 365 Finance Main Account
Area/Finance & Accounting
Vendor/Microsoft
Dynamics365
Finance
ERP
Type/Connector
Ledger
MainAccount
ChartOfAccounts
Contributors