/**
 * Invoice Ninja Node - Version 2
 * Discriminator: resource=invoice, operation=create
 */


interface Credentials {
  invoiceNinjaApi: CredentialReference;
}

/** Create a new client */
export type InvoiceNinjaV2InvoiceCreateParams = {
  resource: 'invoice';
  operation: 'create';
/**
 * API Version
 * @default v5
 */
    apiVersion?: 'v4' | 'v5' | Expression<string>;
/**
 * Additional Fields
 * @default {}
 */
    additionalFields?: {
    /** Choose from the list, or specify an ID using an &lt;a href="https://docs.n8n.io/code/expressions/"&gt;expression&lt;/a&gt;
     */
    client?: string | Expression<string>;
    /** Auto Bill
     * @default false
     */
    autoBill?: boolean | Expression<boolean>;
    /** Custom Value 1
     * @default 0
     */
    customValue1?: number | Expression<number>;
    /** Custom Value 2
     * @default 0
     */
    customValue2?: number | Expression<number>;
    /** Discount
     */
    discount?: string | Expression<string> | PlaceholderValue;
    /** Due Date
     */
    dueDate?: string | Expression<string>;
    /** Email
     */
    email?: string | Expression<string> | PlaceholderValue;
    /** Email Invoice
     * @default false
     */
    emailInvoice?: boolean | Expression<boolean>;
    /** Invoice Date
     */
    invoiceDate?: string | Expression<string>;
    /** Invoice Number
     */
    invoiceNumber?: string | Expression<string> | PlaceholderValue;
    /** Invoice Status
     * @default 1
     */
    invoiceStatus?: 1 | 2 | Expression<number>;
    /** Is Amount Discount
     * @default false
     */
    isAmountDiscount?: boolean | Expression<boolean>;
    /** Mark Sent
     * @default false
     */
    markSent?: boolean | Expression<boolean>;
    /** Paid
     * @default 0
     */
    paid?: number | Expression<number>;
    /** Partial
     * @default 0
     */
    partial?: number | Expression<number>;
    /** Partial Due Date
     */
    partialDueDate?: string | Expression<string>;
    /** PO Number
     */
    poNumber?: string | Expression<string> | PlaceholderValue;
    /** Private Notes
     */
    privateNotes?: string | Expression<string> | PlaceholderValue;
    /** Public Notes
     */
    publicNotes?: string | Expression<string> | PlaceholderValue;
    /** Tax Name 1
     */
    taxName1?: string | Expression<string> | PlaceholderValue;
    /** Tax Name 2
     */
    taxName2?: string | Expression<string> | PlaceholderValue;
    /** Tax Rate 1
     * @default 0
     */
    taxRate1?: number | Expression<number>;
    /** Tax Rate 2
     * @default 0
     */
    taxRate2?: number | Expression<number>;
  };
/**
 * Invoice Items
 * @default {}
 */
    invoiceItemsUi?: {
        /** Invoice Item
     */
    invoiceItemsValues?: Array<{
      /** Cost
       * @default 0
       */
      cost?: number | Expression<number>;
      /** Description
       */
      description?: string | Expression<string> | PlaceholderValue;
      /** Service
       */
      service?: string | Expression<string> | PlaceholderValue;
      /** Hours
       * @default 0
       */
      hours?: number | Expression<number>;
      /** Tax Name 1
       */
      taxName1?: string | Expression<string> | PlaceholderValue;
      /** Tax Name 2
       */
      taxName2?: string | Expression<string> | PlaceholderValue;
      /** Tax Rate 1
       * @default 0
       */
      taxRate1?: number | Expression<number>;
      /** Tax Rate 2
       * @default 0
       */
      taxRate2?: number | Expression<number>;
    }>;
  };
};

export type InvoiceNinjaV2InvoiceCreateNode = {
  type: 'n8n-nodes-base.invoiceNinja';
  version: 2;
  credentials?: Credentials;
  config: NodeConfig<InvoiceNinjaV2InvoiceCreateParams>;
};