import * as z from "zod/v3";
import { OpenEnum } from "../../types/enums.js";
import { Result as SafeParseResult } from "../../types/fp.js";
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
import { Currency } from "./currency.js";
import { CustomField, CustomField$Outbound } from "./customfield.js";
import { JournalEntryLineItem, JournalEntryLineItemInput, JournalEntryLineItemInput$Outbound } from "./journalentrylineitem.js";
import { LinkedTrackingCategory, LinkedTrackingCategory$Outbound } from "./linkedtrackingcategory.js";
import { PassThroughBody, PassThroughBody$Outbound } from "./passthroughbody.js";
/**
 * Journal entry status
 */
export declare const JournalEntryStatus: {
    readonly Draft: "draft";
    readonly PendingApproval: "pending_approval";
    readonly Approved: "approved";
    readonly Posted: "posted";
    readonly Voided: "voided";
    readonly Rejected: "rejected";
    readonly Deleted: "deleted";
    readonly Other: "other";
};
/**
 * Journal entry status
 */
export type JournalEntryStatus = OpenEnum<typeof JournalEntryStatus>;
export type JournalEntry = {
    /**
     * A unique identifier for an object.
     */
    id?: string | undefined;
    /**
     * The third-party API ID of original entity
     */
    downstreamId?: string | null | undefined;
    /**
     * Display ID of the journal entry
     */
    displayId?: string | null | undefined;
    /**
     * Journal entry title
     */
    title?: string | null | undefined;
    /**
     * Currency Exchange Rate at the time entity was recorded/generated.
     */
    currencyRate?: number | null | undefined;
    /**
     * Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217).
     */
    currency?: Currency | null | undefined;
    /**
     * The company ID the transaction belongs to
     */
    companyId?: string | null | undefined;
    /**
     * Requires a minimum of 2 line items that sum to 0
     */
    lineItems?: Array<JournalEntryLineItem> | undefined;
    /**
     * Journal entry status
     */
    status?: JournalEntryStatus | null | undefined;
    /**
     * Reference for the journal entry.
     */
    memo?: string | null | undefined;
    /**
     * This is the date on which the journal entry was added. This can be different from the creation date and can also be backdated.
     */
    postedAt?: Date | undefined;
    /**
     * Journal symbol of the entry. For example IND for indirect costs
     */
    journalSymbol?: string | null | undefined;
    /**
     * Deprecated — use line_items[].tax_type for per-line tax applicability. Kept as fallback: applies to all lines that do not set their own tax_type.
     *
     * @deprecated field: Deprecated — use line_items[]..
     */
    taxType?: string | null | undefined;
    /**
     * Applicable tax id/code override if tax is not supplied on a line item basis.
     */
    taxCode?: string | null | undefined;
    /**
     * Journal entry number.
     */
    number?: string | null | undefined;
    /**
     * A list of linked tracking categories.
     */
    trackingCategories?: Array<LinkedTrackingCategory | null> | null | undefined;
    /**
     * Accounting period
     */
    accountingPeriod?: string | null | undefined;
    /**
     * Amounts are including tax
     */
    taxInclusive?: boolean | null | undefined;
    /**
     * The source type of the journal entry
     */
    sourceType?: string | null | undefined;
    /**
     * A unique identifier for the source of the journal entry
     */
    sourceId?: string | null | undefined;
    /**
     * When custom mappings are configured on the resource, the result is included here.
     */
    customMappings?: {
        [k: string]: any;
    } | null | undefined;
    /**
     * The user who last updated the object.
     */
    updatedBy?: string | null | undefined;
    /**
     * The user who created the object.
     */
    createdBy?: string | null | undefined;
    /**
     * The date and time when the object was last updated.
     */
    updatedAt?: Date | null | undefined;
    /**
     * The date and time when the object was created.
     */
    createdAt?: Date | null | undefined;
    /**
     * A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object.
     */
    rowVersion?: string | null | undefined;
    customFields?: Array<CustomField> | undefined;
    /**
     * The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources.
     */
    passThrough?: Array<PassThroughBody> | undefined;
};
export type JournalEntryInput = {
    /**
     * Display ID of the journal entry
     */
    displayId?: string | null | undefined;
    /**
     * Journal entry title
     */
    title?: string | null | undefined;
    /**
     * Currency Exchange Rate at the time entity was recorded/generated.
     */
    currencyRate?: number | null | undefined;
    /**
     * Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217).
     */
    currency?: Currency | null | undefined;
    /**
     * The company ID the transaction belongs to
     */
    companyId?: string | null | undefined;
    /**
     * Requires a minimum of 2 line items that sum to 0
     */
    lineItems?: Array<JournalEntryLineItemInput> | undefined;
    /**
     * Journal entry status
     */
    status?: JournalEntryStatus | null | undefined;
    /**
     * Reference for the journal entry.
     */
    memo?: string | null | undefined;
    /**
     * This is the date on which the journal entry was added. This can be different from the creation date and can also be backdated.
     */
    postedAt?: Date | undefined;
    /**
     * Journal symbol of the entry. For example IND for indirect costs
     */
    journalSymbol?: string | null | undefined;
    /**
     * Deprecated — use line_items[].tax_type for per-line tax applicability. Kept as fallback: applies to all lines that do not set their own tax_type.
     *
     * @deprecated field: Deprecated — use line_items[]..
     */
    taxType?: string | null | undefined;
    /**
     * Applicable tax id/code override if tax is not supplied on a line item basis.
     */
    taxCode?: string | null | undefined;
    /**
     * Journal entry number.
     */
    number?: string | null | undefined;
    /**
     * A list of linked tracking categories.
     */
    trackingCategories?: Array<LinkedTrackingCategory | null> | null | undefined;
    /**
     * Accounting period
     */
    accountingPeriod?: string | null | undefined;
    /**
     * Amounts are including tax
     */
    taxInclusive?: boolean | null | undefined;
    /**
     * The source type of the journal entry
     */
    sourceType?: string | null | undefined;
    /**
     * A unique identifier for the source of the journal entry
     */
    sourceId?: string | null | undefined;
    /**
     * A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object.
     */
    rowVersion?: string | null | undefined;
    customFields?: Array<CustomField> | undefined;
    /**
     * The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources.
     */
    passThrough?: Array<PassThroughBody> | undefined;
};
/** @internal */
export declare const JournalEntryStatus$inboundSchema: z.ZodType<JournalEntryStatus, z.ZodTypeDef, unknown>;
/** @internal */
export declare const JournalEntryStatus$outboundSchema: z.ZodType<string, z.ZodTypeDef, JournalEntryStatus>;
/** @internal */
export declare const JournalEntry$inboundSchema: z.ZodType<JournalEntry, z.ZodTypeDef, unknown>;
export declare function journalEntryFromJSON(jsonString: string): SafeParseResult<JournalEntry, SDKValidationError>;
/** @internal */
export type JournalEntryInput$Outbound = {
    display_id?: string | null | undefined;
    title?: string | null | undefined;
    currency_rate?: number | null | undefined;
    currency?: string | null | undefined;
    company_id?: string | null | undefined;
    line_items?: Array<JournalEntryLineItemInput$Outbound> | undefined;
    status?: string | null | undefined;
    memo?: string | null | undefined;
    posted_at?: string | undefined;
    journal_symbol?: string | null | undefined;
    tax_type?: string | null | undefined;
    tax_code?: string | null | undefined;
    number?: string | null | undefined;
    tracking_categories?: Array<LinkedTrackingCategory$Outbound | null> | null | undefined;
    accounting_period?: string | null | undefined;
    tax_inclusive?: boolean | null | undefined;
    source_type?: string | null | undefined;
    source_id?: string | null | undefined;
    row_version?: string | null | undefined;
    custom_fields?: Array<CustomField$Outbound> | undefined;
    pass_through?: Array<PassThroughBody$Outbound> | undefined;
};
/** @internal */
export declare const JournalEntryInput$outboundSchema: z.ZodType<JournalEntryInput$Outbound, z.ZodTypeDef, JournalEntryInput>;
export declare function journalEntryInputToJSON(journalEntryInput: JournalEntryInput): string;
//# sourceMappingURL=journalentry.d.ts.map