/** Types generated for queries found in "src/modules/ledger/providers/ledger.provider.ts" */
export type currency = 'AUD' | 'CAD' | 'ETH' | 'EUR' | 'GBP' | 'GRT' | 'ILS' | 'JPY' | 'SEK' | 'USD' | 'USDC';

export type DateOrString = Date | string;

export type NumberOrString = number | string;

/** 'GetLedgerRecordsByIds' parameters type */
export interface IGetLedgerRecordsByIdsParams {
  ids: readonly (string | null | void)[];
  ownerId?: string | null | void;
}

/** 'GetLedgerRecordsByIds' return type */
export interface IGetLedgerRecordsByIdsResult {
  charge_id: string;
  created_at: Date;
  credit_entity1: string | null;
  credit_entity2: string | null;
  credit_foreign_amount1: string | null;
  credit_foreign_amount2: string | null;
  credit_local_amount1: string | null;
  credit_local_amount2: string | null;
  currency: currency;
  debit_entity1: string | null;
  debit_entity2: string | null;
  debit_foreign_amount1: string | null;
  debit_foreign_amount2: string | null;
  debit_local_amount1: string | null;
  debit_local_amount2: string | null;
  description: string | null;
  id: string;
  invoice_date: Date;
  locked: boolean | null;
  owner_id: string;
  reference1: string | null;
  updated_at: Date;
  value_date: Date;
}

/** 'GetLedgerRecordsByIds' query type */
export interface IGetLedgerRecordsByIdsQuery {
  params: IGetLedgerRecordsByIdsParams;
  result: IGetLedgerRecordsByIdsResult;
}

/** 'GetLedgerRecordsByChargesIds' parameters type */
export interface IGetLedgerRecordsByChargesIdsParams {
  chargeIds: readonly (string | null | void)[];
  ownerId?: string | null | void;
}

/** 'GetLedgerRecordsByChargesIds' return type */
export interface IGetLedgerRecordsByChargesIdsResult {
  charge_id: string;
  created_at: Date;
  credit_entity1: string | null;
  credit_entity2: string | null;
  credit_foreign_amount1: string | null;
  credit_foreign_amount2: string | null;
  credit_local_amount1: string | null;
  credit_local_amount2: string | null;
  currency: currency;
  debit_entity1: string | null;
  debit_entity2: string | null;
  debit_foreign_amount1: string | null;
  debit_foreign_amount2: string | null;
  debit_local_amount1: string | null;
  debit_local_amount2: string | null;
  description: string | null;
  id: string;
  invoice_date: Date;
  locked: boolean | null;
  owner_id: string;
  reference1: string | null;
  updated_at: Date;
  value_date: Date;
}

/** 'GetLedgerRecordsByChargesIds' query type */
export interface IGetLedgerRecordsByChargesIdsQuery {
  params: IGetLedgerRecordsByChargesIdsParams;
  result: IGetLedgerRecordsByChargesIdsResult;
}

/** 'GetLedgerRecordsByFinancialEntityIds' parameters type */
export interface IGetLedgerRecordsByFinancialEntityIdsParams {
  financialEntityIds: readonly (string | null | void)[];
  ownerId?: string | null | void;
}

/** 'GetLedgerRecordsByFinancialEntityIds' return type */
export interface IGetLedgerRecordsByFinancialEntityIdsResult {
  charge_id: string;
  created_at: Date;
  credit_entity1: string | null;
  credit_entity2: string | null;
  credit_foreign_amount1: string | null;
  credit_foreign_amount2: string | null;
  credit_local_amount1: string | null;
  credit_local_amount2: string | null;
  currency: currency;
  debit_entity1: string | null;
  debit_entity2: string | null;
  debit_foreign_amount1: string | null;
  debit_foreign_amount2: string | null;
  debit_local_amount1: string | null;
  debit_local_amount2: string | null;
  description: string | null;
  id: string;
  invoice_date: Date;
  locked: boolean | null;
  owner_id: string;
  reference1: string | null;
  updated_at: Date;
  value_date: Date;
}

/** 'GetLedgerRecordsByFinancialEntityIds' query type */
export interface IGetLedgerRecordsByFinancialEntityIdsQuery {
  params: IGetLedgerRecordsByFinancialEntityIdsParams;
  result: IGetLedgerRecordsByFinancialEntityIdsResult;
}

/** 'GetLedgerRecordsByDates' parameters type */
export interface IGetLedgerRecordsByDatesParams {
  fromDate?: DateOrString | null | void;
  ownerId?: string | null | void;
  toDate?: DateOrString | null | void;
}

/** 'GetLedgerRecordsByDates' return type */
export interface IGetLedgerRecordsByDatesResult {
  charge_id: string;
  created_at: Date;
  credit_entity1: string | null;
  credit_entity2: string | null;
  credit_foreign_amount1: string | null;
  credit_foreign_amount2: string | null;
  credit_local_amount1: string | null;
  credit_local_amount2: string | null;
  currency: currency;
  debit_entity1: string | null;
  debit_entity2: string | null;
  debit_foreign_amount1: string | null;
  debit_foreign_amount2: string | null;
  debit_local_amount1: string | null;
  debit_local_amount2: string | null;
  description: string | null;
  id: string;
  invoice_date: Date;
  locked: boolean | null;
  owner_id: string;
  reference1: string | null;
  updated_at: Date;
  value_date: Date;
}

/** 'GetLedgerRecordsByDates' query type */
export interface IGetLedgerRecordsByDatesQuery {
  params: IGetLedgerRecordsByDatesParams;
  result: IGetLedgerRecordsByDatesResult;
}

/** 'GetLedgerBalanceToDate' parameters type */
export interface IGetLedgerBalanceToDateParams {
  date?: DateOrString | null | void;
}

/** 'GetLedgerBalanceToDate' return type */
export interface IGetLedgerBalanceToDateResult {
  entity_id: string | null;
  sum: string | null;
}

/** 'GetLedgerBalanceToDate' query type */
export interface IGetLedgerBalanceToDateQuery {
  params: IGetLedgerBalanceToDateParams;
  result: IGetLedgerBalanceToDateResult;
}

/** 'UpdateLedgerRecord' parameters type */
export interface IUpdateLedgerRecordParams {
  chargeId?: string | null | void;
  creditEntity1?: string | null | void;
  creditEntity2?: string | null | void;
  creditForeignAmount1?: NumberOrString | null | void;
  creditForeignAmount2?: NumberOrString | null | void;
  creditLocalAmount1?: NumberOrString | null | void;
  creditLocalAmount2?: NumberOrString | null | void;
  currency?: currency | null | void;
  debitEntity1?: string | null | void;
  debitEntity2?: string | null | void;
  debitForeignAmount1?: NumberOrString | null | void;
  debitForeignAmount2?: NumberOrString | null | void;
  debitLocalAmount1?: NumberOrString | null | void;
  debitLocalAmount2?: NumberOrString | null | void;
  description?: string | null | void;
  invoiceDate?: DateOrString | null | void;
  ledgerId?: string | null | void;
  ownerId?: string | null | void;
  reference?: string | null | void;
  valueDate?: DateOrString | null | void;
}

/** 'UpdateLedgerRecord' return type */
export interface IUpdateLedgerRecordResult {
  charge_id: string;
  created_at: Date;
  credit_entity1: string | null;
  credit_entity2: string | null;
  credit_foreign_amount1: string | null;
  credit_foreign_amount2: string | null;
  credit_local_amount1: string | null;
  credit_local_amount2: string | null;
  currency: currency;
  debit_entity1: string | null;
  debit_entity2: string | null;
  debit_foreign_amount1: string | null;
  debit_foreign_amount2: string | null;
  debit_local_amount1: string | null;
  debit_local_amount2: string | null;
  description: string | null;
  id: string;
  invoice_date: Date;
  locked: boolean | null;
  owner_id: string;
  reference1: string | null;
  updated_at: Date;
  value_date: Date;
}

/** 'UpdateLedgerRecord' query type */
export interface IUpdateLedgerRecordQuery {
  params: IUpdateLedgerRecordParams;
  result: IUpdateLedgerRecordResult;
}

/** 'InsertLedgerRecords' parameters type */
export interface IInsertLedgerRecordsParams {
  ledgerRecords: readonly ({
    chargeId: string | null | void,
    creditEntity1: string | null | void,
    creditEntity2: string | null | void,
    creditForeignAmount1: NumberOrString | null | void,
    creditForeignAmount2: NumberOrString | null | void,
    creditLocalAmount1: NumberOrString | null | void,
    creditLocalAmount2: NumberOrString | null | void,
    currency: currency | null | void,
    debitEntity1: string | null | void,
    debitEntity2: string | null | void,
    debitForeignAmount1: NumberOrString | null | void,
    debitForeignAmount2: NumberOrString | null | void,
    debitLocalAmount1: NumberOrString | null | void,
    debitLocalAmount2: NumberOrString | null | void,
    description: string | null | void,
    invoiceDate: DateOrString | null | void,
    ownerId: string | null | void,
    reference: string | null | void,
    valueDate: DateOrString | null | void
  })[];
}

/** 'InsertLedgerRecords' return type */
export interface IInsertLedgerRecordsResult {
  charge_id: string;
  created_at: Date;
  credit_entity1: string | null;
  credit_entity2: string | null;
  credit_foreign_amount1: string | null;
  credit_foreign_amount2: string | null;
  credit_local_amount1: string | null;
  credit_local_amount2: string | null;
  currency: currency;
  debit_entity1: string | null;
  debit_entity2: string | null;
  debit_foreign_amount1: string | null;
  debit_foreign_amount2: string | null;
  debit_local_amount1: string | null;
  debit_local_amount2: string | null;
  description: string | null;
  id: string;
  invoice_date: Date;
  locked: boolean | null;
  owner_id: string;
  reference1: string | null;
  updated_at: Date;
  value_date: Date;
}

/** 'InsertLedgerRecords' query type */
export interface IInsertLedgerRecordsQuery {
  params: IInsertLedgerRecordsParams;
  result: IInsertLedgerRecordsResult;
}

/** 'DeleteLedgerRecords' parameters type */
export interface IDeleteLedgerRecordsParams {
  ledgerRecordIds: readonly (string | null | void)[];
  ownerId?: string | null | void;
}

/** 'DeleteLedgerRecords' return type */
export type IDeleteLedgerRecordsResult = void;

/** 'DeleteLedgerRecords' query type */
export interface IDeleteLedgerRecordsQuery {
  params: IDeleteLedgerRecordsParams;
  result: IDeleteLedgerRecordsResult;
}

/** 'DeleteLedgerRecordsByChargeIds' parameters type */
export interface IDeleteLedgerRecordsByChargeIdsParams {
  chargeIds: readonly (string | null | void)[];
  ownerId?: string | null | void;
}

/** 'DeleteLedgerRecordsByChargeIds' return type */
export type IDeleteLedgerRecordsByChargeIdsResult = void;

/** 'DeleteLedgerRecordsByChargeIds' query type */
export interface IDeleteLedgerRecordsByChargeIdsQuery {
  params: IDeleteLedgerRecordsByChargeIdsParams;
  result: IDeleteLedgerRecordsByChargeIdsResult;
}

/** 'ReplaceLedgerRecordsChargeId' parameters type */
export interface IReplaceLedgerRecordsChargeIdParams {
  assertChargeID?: string | null | void;
  replaceChargeID?: string | null | void;
}

/** 'ReplaceLedgerRecordsChargeId' return type */
export interface IReplaceLedgerRecordsChargeIdResult {
  charge_id: string;
  created_at: Date;
  credit_entity1: string | null;
  credit_entity2: string | null;
  credit_foreign_amount1: string | null;
  credit_foreign_amount2: string | null;
  credit_local_amount1: string | null;
  credit_local_amount2: string | null;
  currency: currency;
  debit_entity1: string | null;
  debit_entity2: string | null;
  debit_foreign_amount1: string | null;
  debit_foreign_amount2: string | null;
  debit_local_amount1: string | null;
  debit_local_amount2: string | null;
  description: string | null;
  id: string;
  invoice_date: Date;
  locked: boolean | null;
  owner_id: string;
  reference1: string | null;
  updated_at: Date;
  value_date: Date;
}

/** 'ReplaceLedgerRecordsChargeId' query type */
export interface IReplaceLedgerRecordsChargeIdQuery {
  params: IReplaceLedgerRecordsChargeIdParams;
  result: IReplaceLedgerRecordsChargeIdResult;
}

/** 'LockLedgerRecords' parameters type */
export interface ILockLedgerRecordsParams {
  date?: DateOrString | null | void;
}

/** 'LockLedgerRecords' return type */
export interface ILockLedgerRecordsResult {
  charge_id: string;
  created_at: Date;
  credit_entity1: string | null;
  credit_entity2: string | null;
  credit_foreign_amount1: string | null;
  credit_foreign_amount2: string | null;
  credit_local_amount1: string | null;
  credit_local_amount2: string | null;
  currency: currency;
  debit_entity1: string | null;
  debit_entity2: string | null;
  debit_foreign_amount1: string | null;
  debit_foreign_amount2: string | null;
  debit_local_amount1: string | null;
  debit_local_amount2: string | null;
  description: string | null;
  id: string;
  invoice_date: Date;
  locked: boolean | null;
  owner_id: string;
  reference1: string | null;
  updated_at: Date;
  value_date: Date;
}

/** 'LockLedgerRecords' query type */
export interface ILockLedgerRecordsQuery {
  params: ILockLedgerRecordsParams;
  result: ILockLedgerRecordsResult;
}

