@memberjunction/actions-bizapps-accounting
Version:
Accounting system integration actions for MemberJunction
52 lines • 2.1 kB
TypeScript
import { BaseAccountingAction } from '../../base/base-accounting-action';
import { UserInfo } from '@memberjunction/core';
import { CompanyIntegrationEntity } from '@memberjunction/core-entities';
/**
* Base class for all Microsoft Dynamics 365 Business Central actions.
* Handles BC-specific authentication and API interaction patterns.
*/
export declare abstract class BusinessCentralBaseAction extends BaseAccountingAction {
protected accountingProvider: string;
protected integrationName: string;
/**
* Business Central API version
*/
protected apiVersion: string;
/**
* Makes an authenticated request to Business Central API
*/
protected makeBCRequest<T = any>(endpoint: string, method?: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE', body?: any, contextUser?: UserInfo): Promise<T>;
/**
* Handles Business Central OData queries
*/
protected queryBC<T = any>(resource: string, filters?: string[], select?: string[], expand?: string[], orderBy?: string, top?: number, contextUser?: UserInfo): Promise<T>;
/**
* Formats date for Business Central API (ISO 8601)
*/
protected formatBCDate(date: Date): string;
/**
* Parses Business Central date format
*/
protected parseBCDate(dateString: string): Date;
/**
* Maps Business Central account types to standard categories
*/
protected mapAccountType(bcAccountType: string): string;
/**
* Maps Business Central account category to standard type
*/
protected mapAccountCategory(category: string): string;
/**
* Gets the appropriate Business Central API URL
*/
protected getBusinessCentralAPIUrl(integration: CompanyIntegrationEntity, tenantId: string, environment: string): Promise<string>;
/**
* Helper to build OData filter expressions
*/
protected buildFilterExpression(field: string, operator: string, value: any): string;
/**
* Current action parameters (set by the framework)
*/
protected params: any;
}
//# sourceMappingURL=business-central-base.action.d.ts.map