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

export type DateOrString = Date | string;

export type DateOrStringArray = (DateOrString)[];

export type Json = null | boolean | number | string | Json[] | { [key: string]: Json };

export type NumberOrString = number | string;

export type numberArray = (number)[];

export type stringArray = (string)[];

/** 'FetchPoalimIlsByKeys' parameters type */
export interface IFetchPoalimIlsByKeysParams {
  accountNumbers: numberArray;
  branchNumbers: numberArray;
  eventDates: DateOrStringArray;
}

/** 'FetchPoalimIlsByKeys' return type */
export interface IFetchPoalimIlsByKeysResult {
  account_number: number;
  activity_description: string;
  activity_type_code: number;
  beneficiary_details_data_message_detail: string | null;
  beneficiary_details_data_message_headline: string | null;
  beneficiary_details_data_party_headline: string | null;
  beneficiary_details_data_party_name: string | null;
  branch_number: number;
  /** Can change and get the same value on existing transaction again if the user added a comment */
  comment: string | null;
  contra_account_number: number;
  contra_account_type_code: number;
  contra_bank_number: number;
  contra_branch_number: number;
  current_balance: string;
  data_group_code: number;
  details: string | null;
  different_date_indication: string;
  event_activity_type_code: number;
  event_amount: string;
  event_date: Date;
  event_id: string;
  executing_branch_number: number;
  id: string;
  internal_link_code: number;
  pfm_details: string | null;
  reference_catenated_number: number;
  reference_number: string;
  rejected_data_event_pertaining_indication: string | null;
  /** Serial number is how we order transactions in the same day, if they have the same amount.
    Lower number is earlier in the day.
    So you can't have multiple rows with the same date, amount and same serial number.
    This is also referenced in the end of the expanded_event_date row */
  serial_number: number;
  text_code: number;
  transaction_type: string;
  value_date: Date;
}

/** 'FetchPoalimIlsByKeys' query type */
export interface IFetchPoalimIlsByKeysQuery {
  params: IFetchPoalimIlsByKeysParams;
  result: IFetchPoalimIlsByKeysResult;
}

/** 'UploadPoalimIlsTransactions' parameters type */
export interface IUploadPoalimIlsTransactionsParams {
  transactions: readonly ({
    eventDate: DateOrString | null | void,
    formattedEventDate: string | null | void,
    serialNumber: number | null | void,
    activityTypeCode: number | null | void,
    activityDescription: string | null | void,
    textCode: number | null | void,
    referenceNumber: NumberOrString | null | void,
    referenceCatenatedNumber: number | null | void,
    valueDate: DateOrString | null | void,
    formattedValueDate: string | null | void,
    eventAmount: NumberOrString | null | void,
    eventActivityTypeCode: number | null | void,
    currentBalance: NumberOrString | null | void,
    internalLinkCode: number | null | void,
    originalEventCreateDate: number | null | void,
    formattedOriginalEventCreateDate: string | null | void,
    transactionType: string | null | void,
    dataGroupCode: number | null | void,
    beneficiaryDetailsData: string | null | void,
    expandedEventDate: NumberOrString | null | void,
    executingBranchNumber: number | null | void,
    eventId: NumberOrString | null | void,
    details: string | null | void,
    pfmDetails: string | null | void,
    differentDateIndication: string | null | void,
    rejectedDataEventPertainingIndication: string | null | void,
    tableNumber: number | null | void,
    recordNumber: number | null | void,
    contraBankNumber: number | null | void,
    contraBranchNumber: number | null | void,
    contraAccountNumber: number | null | void,
    contraAccountTypeCode: number | null | void,
    marketingOfferContext: boolean | null | void,
    commentExistenceSwitch: boolean | null | void,
    englishActionDesc: string | null | void,
    fieldDescDisplaySwitch: boolean | null | void,
    urlAddressNiar: string | null | void,
    offerActivityContext: string | null | void,
    comment: string | null | void,
    beneficiaryDetailsDataPartyName: string | null | void,
    beneficiaryDetailsDataMessageHeadline: string | null | void,
    beneficiaryDetailsDataPartyHeadline: string | null | void,
    beneficiaryDetailsDataMessageDetail: string | null | void,
    beneficiaryDetailsDataTableNumber: number | null | void,
    beneficiaryDetailsDataRecordNumber: number | null | void,
    activityDescriptionIncludeValueDate: string | null | void,
    bankNumber: number | null | void,
    branchNumber: number | null | void,
    accountNumber: number | null | void
  })[];
}

/** 'UploadPoalimIlsTransactions' return type */
export interface IUploadPoalimIlsTransactionsResult {
  account_number: number;
  activity_description: string;
  branch_number: number;
  event_amount: string;
  event_date: Date;
  id: string;
  /** Serial number is how we order transactions in the same day, if they have the same amount.
    Lower number is earlier in the day.
    So you can't have multiple rows with the same date, amount and same serial number.
    This is also referenced in the end of the expanded_event_date row */
  serial_number: number;
}

/** 'UploadPoalimIlsTransactions' query type */
export interface IUploadPoalimIlsTransactionsQuery {
  params: IUploadPoalimIlsTransactionsParams;
  result: IUploadPoalimIlsTransactionsResult;
}

/** 'FetchPoalimForeignByKeys' parameters type */
export interface IFetchPoalimForeignByKeysParams {
  accountNumbers: numberArray;
  branchNumbers: numberArray;
  executingDates: DateOrStringArray;
}

/** 'FetchPoalimForeignByKeys' return type */
export interface IFetchPoalimForeignByKeysResult {
  account_name: string | null;
  account_number: number;
  activity_description: string;
  activity_type_code: number;
  branch_number: number;
  comments: string | null;
  contra_account_field_name_lable: string | null;
  contra_account_number: number;
  contra_bank_number: number;
  contra_branch_number: number;
  contra_currency_code: number;
  currency: currency;
  currency_long_description: string;
  currency_rate: string;
  currency_swift_code: string;
  current_balance: string;
  event_activity_type_code: number;
  event_amount: string;
  event_details: string | null;
  event_number: number;
  executing_date: Date;
  id: string;
  rate_fixing_code: number;
  rate_fixing_description: string | null;
  rate_fixing_short_description: string;
  reference_catenated_number: number;
  reference_number: number;
  transaction_type: string;
}

/** 'FetchPoalimForeignByKeys' query type */
export interface IFetchPoalimForeignByKeysQuery {
  params: IFetchPoalimForeignByKeysParams;
  result: IFetchPoalimForeignByKeysResult;
}

/** 'FetchPoalimSwiftByIds' parameters type */
export interface IFetchPoalimSwiftByIdsParams {
  transferCatenatedIds: stringArray;
}

/** 'FetchPoalimSwiftByIds' return type */
export interface IFetchPoalimSwiftByIdsResult {
  account_number: number | null;
  amount: string | null;
  bank_number: number | null;
  beneficiary_english_city_name: string | null;
  beneficiary_english_country_name: string | null;
  beneficiary_english_street_name: string | null;
  branch_number: number | null;
  charge_party_name: string | null;
  currency_code_catenated_key: string | null;
  currency_long_description: string | null;
  data_origin_code: string | null;
  id: string;
  order_customer_name: string | null;
  reference_number: string | null;
  start_date: string | null;
  swift_details_of_charges_71a: string | null;
  swift_remittance_information_70: string | null;
  swift_senders_charges_71f: string | null;
  swift_status_code: string | null;
  swift_status_desc: string | null;
  transfer_catenated_id: string | null;
}

/** 'FetchPoalimSwiftByIds' query type */
export interface IFetchPoalimSwiftByIdsQuery {
  params: IFetchPoalimSwiftByIdsParams;
  result: IFetchPoalimSwiftByIdsResult;
}

/** 'UploadPoalimForeignTransactions' parameters type */
export interface IUploadPoalimForeignTransactionsParams {
  transactions: readonly ({
    metadataAttributesOriginalEventKey: Json | null | void,
    metadataAttributesContraBranchNumber: Json | null | void,
    metadataAttributesContraAccountNumber: Json | null | void,
    metadataAttributesContraBankNumber: Json | null | void,
    metadataAttributesContraAccountFieldNameLable: Json | null | void,
    metadataAttributesDataGroupCode: Json | null | void,
    metadataAttributesCurrencyRate: Json | null | void,
    metadataAttributesContraCurrencyCode: Json | null | void,
    metadataAttributesRateFixingCode: Json | null | void,
    executingDate: DateOrString | null | void,
    formattedExecutingDate: string | null | void,
    valueDate: DateOrString | null | void,
    formattedValueDate: string | null | void,
    originalSystemId: number | null | void,
    activityDescription: string | null | void,
    eventAmount: NumberOrString | null | void,
    currency: currency | null | void,
    currentBalance: NumberOrString | null | void,
    referenceCatenatedNumber: number | null | void,
    referenceNumber: number | null | void,
    currencyRate: NumberOrString | null | void,
    eventDetails: string | null | void,
    rateFixingCode: number | null | void,
    contraCurrencyCode: number | null | void,
    eventActivityTypeCode: number | null | void,
    transactionType: string | null | void,
    rateFixingShortDescription: string | null | void,
    currencyLongDescription: string | null | void,
    activityTypeCode: number | null | void,
    eventNumber: number | null | void,
    validityDate: DateOrString | null | void,
    comments: string | null | void,
    commentExistenceSwitch: boolean | null | void,
    accountName: string | null | void,
    contraBankNumber: number | null | void,
    contraBranchNumber: number | null | void,
    contraAccountNumber: number | null | void,
    originalEventKey: boolean | null | void,
    contraAccountFieldNameLable: string | null | void,
    dataGroupCode: boolean | null | void,
    rateFixingDescription: string | null | void,
    urlAddressNiar: string | null | void,
    currencySwiftCode: string | null | void,
    urlAddress: string | null | void,
    bankNumber: number | null | void,
    branchNumber: number | null | void,
    accountNumber: number | null | void
  })[];
}

/** 'UploadPoalimForeignTransactions' return type */
export interface IUploadPoalimForeignTransactionsResult {
  account_number: number;
  activity_description: string;
  branch_number: number;
  event_amount: string;
  event_number: number;
  executing_date: Date;
  id: string;
}

/** 'UploadPoalimForeignTransactions' query type */
export interface IUploadPoalimForeignTransactionsQuery {
  params: IUploadPoalimForeignTransactionsParams;
  result: IUploadPoalimForeignTransactionsResult;
}

/** 'UploadPoalimSwiftTransactions' parameters type */
export interface IUploadPoalimSwiftTransactionsParams {
  transactions: readonly ({
    accountNumber: number | null | void,
    branchNumber: number | null | void,
    bankNumber: number | null | void,
    startDate: string | null | void,
    formattedStartDate: string | null | void,
    swiftStatusCode: string | null | void,
    swiftStatusDesc: string | null | void,
    amount: string | null | void,
    currencyCodeCatenatedKey: string | null | void,
    currencyLongDescription: string | null | void,
    chargePartyName: string | null | void,
    referenceNumber: string | null | void,
    transferCatenatedId: string | null | void,
    dataOriginCode: string | null | void,
    swiftIsnSerialNumber: string | null | void,
    swiftBankCode: string | null | void,
    orderCustomerName: string | null | void,
    beneficiaryEnglishStreetName: string | null | void,
    beneficiaryEnglishCityName: string | null | void,
    beneficiaryEnglishCountryName: string | null | void,
    swiftSendersReference20: string | null | void,
    swiftBankOperationCode23B: string | null | void,
    swiftInstructionCode23E: string | null | void,
    swiftValueDateCurrencyAmount32A: string | null | void,
    swiftCurrencyInstructedAmount33B: string | null | void,
    swiftExchangeRate36: string | null | void,
    swiftOrderingCustomer50K: string | null | void,
    swiftOrderingInstitution52A: string | null | void,
    swiftOrderingInstitution52D: string | null | void,
    swiftSendersCorrespondent53A: string | null | void,
    swiftReceiversCorrespondent54A: string | null | void,
    swiftAccountWithInstitution57: string | null | void,
    swiftBeneficiaryCustomer59: string | null | void,
    swiftRemittanceInformation70: string | null | void,
    swiftDetailsOfCharges71A: string | null | void,
    swiftSendersCharges71F: string | null | void,
    swiftSendersToReceiverInformation72: string | null | void,
    swiftRegulatoryReporting77B: string | null | void
  })[];
}

/** 'UploadPoalimSwiftTransactions' return type */
export interface IUploadPoalimSwiftTransactionsResult {
  account_number: number | null;
  amount: string | null;
  charge_party_name: string | null;
  id: string;
  start_date: string | null;
}

/** 'UploadPoalimSwiftTransactions' query type */
export interface IUploadPoalimSwiftTransactionsQuery {
  params: IUploadPoalimSwiftTransactionsParams;
  result: IUploadPoalimSwiftTransactionsResult;
}

