@apideck/node
Version:
Apideck Node.js SDK
258 lines (257 loc) • 7.26 kB
TypeScript
/**
* Apideck
* The Apideck OpenAPI Spec: SDK Optimized
*
* The version of the OpenAPI document: 10.13.0
* Contact: support@apideck.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
import { Address } from './Address';
import { BankAccount } from './BankAccount';
import { Currency } from './Currency';
import { InvoiceLineItem } from './InvoiceLineItem';
import { LinkedLedgerAccount } from './LinkedLedgerAccount';
import { LinkedSupplier } from './LinkedSupplier';
import { LinkedTrackingCategories } from './LinkedTrackingCategories';
import { PassThroughBody } from './PassThroughBody';
/**
*
* @export
* @interface PurchaseOrder
*/
export interface PurchaseOrder {
/**
* A unique identifier for an object.
* @type {string}
* @memberof PurchaseOrder
*/
readonly id?: string;
/**
* The third-party API ID of original entity
* @type {string}
* @memberof PurchaseOrder
*/
readonly downstream_id?: string | null;
/**
* A PO Number uniquely identifies a purchase order and is generally defined by the buyer.
* @type {string}
* @memberof PurchaseOrder
*/
po_number?: string | null;
/**
* Optional purchase order reference.
* @type {string}
* @memberof PurchaseOrder
*/
reference?: string | null;
/**
*
* @type {LinkedSupplier}
* @memberof PurchaseOrder
*/
supplier?: LinkedSupplier | null;
/**
* The company or subsidiary id the transaction belongs to
* @type {string}
* @memberof PurchaseOrder
*/
company_id?: string | null;
/**
*
* @type {string}
* @memberof PurchaseOrder
*/
status?: PurchaseOrderStatus;
/**
* Date purchase order was issued - YYYY-MM-DD.
* @type {Date}
* @memberof PurchaseOrder
*/
issued_date?: Date | null;
/**
* The date on which the purchase order is to be delivered - YYYY-MM-DD.
* @type {Date}
* @memberof PurchaseOrder
*/
delivery_date?: Date | null;
/**
* The date on which the order is expected to arrive - YYYY-MM-DD.
* @type {Date}
* @memberof PurchaseOrder
*/
expected_arrival_date?: Date | null;
/**
*
* @type {Currency}
* @memberof PurchaseOrder
*/
currency?: Currency | null;
/**
* Currency Exchange Rate at the time entity was recorded/generated.
* @type {number}
* @memberof PurchaseOrder
*/
currency_rate?: number | null;
/**
* Sub-total amount, normally before tax.
* @type {number}
* @memberof PurchaseOrder
*/
sub_total?: number | null;
/**
* Total tax amount applied to this invoice.
* @type {number}
* @memberof PurchaseOrder
*/
total_tax?: number | null;
/**
* Total amount of invoice, including tax.
* @type {number}
* @memberof PurchaseOrder
*/
total?: number | null;
/**
* Amounts are including tax
* @type {boolean}
* @memberof PurchaseOrder
*/
tax_inclusive?: boolean | null;
/**
*
* @type {Array<InvoiceLineItem>}
* @memberof PurchaseOrder
*/
line_items?: Array<InvoiceLineItem>;
/**
*
* @type {Address}
* @memberof PurchaseOrder
*/
shipping_address?: Address;
/**
*
* @type {LinkedLedgerAccount}
* @memberof PurchaseOrder
*/
ledger_account?: LinkedLedgerAccount | null;
/**
* Optional purchase order template
* @type {string}
* @memberof PurchaseOrder
*/
template_id?: string | null;
/**
* Discount percentage applied to this transaction.
* @type {number}
* @memberof PurchaseOrder
*/
discount_percentage?: number | null;
/**
*
* @type {BankAccount}
* @memberof PurchaseOrder
*/
bank_account?: BankAccount;
/**
* Indicates if accounting by row is used (true) or not (false). Accounting by row means that a separate ledger transaction is created for each row.
* @type {boolean}
* @memberof PurchaseOrder
*/
accounting_by_row?: boolean | null;
/**
* The due date is the date on which a payment is scheduled to be received - YYYY-MM-DD.
* @type {Date}
* @memberof PurchaseOrder
*/
due_date?: Date | null;
/**
* Payment method used for the transaction, such as cash, credit card, bank transfer, or check
* @type {string}
* @memberof PurchaseOrder
*/
payment_method?: string | null;
/**
* Applicable tax id/code override if tax is not supplied on a line item basis.
* @type {string}
* @memberof PurchaseOrder
*/
tax_code?: string | null;
/**
* The channel through which the transaction is processed.
* @type {string}
* @memberof PurchaseOrder
*/
channel?: string | null;
/**
* Message for the supplier. This text appears on the Purchase Order.
* @type {string}
* @memberof PurchaseOrder
*/
memo?: string | null;
/**
*
* @type {LinkedTrackingCategories}
* @memberof PurchaseOrder
*/
tracking_categories?: LinkedTrackingCategories | null;
/**
* When custom mappings are configured on the resource, the result is included here.
* @type {object}
* @memberof PurchaseOrder
*/
readonly custom_mappings?: object | null;
/**
* 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.
* @type {string}
* @memberof PurchaseOrder
*/
row_version?: string | null;
/**
* The user who last updated the object.
* @type {string}
* @memberof PurchaseOrder
*/
readonly updated_by?: string | null;
/**
* The user who created the object.
* @type {string}
* @memberof PurchaseOrder
*/
readonly created_by?: string | null;
/**
* The date and time when the object was last updated.
* @type {Date}
* @memberof PurchaseOrder
*/
readonly updated_at?: Date | null;
/**
* The date and time when the object was created.
* @type {Date}
* @memberof PurchaseOrder
*/
readonly created_at?: Date | null;
/**
*
* @type {PassThroughBody}
* @memberof PurchaseOrder
*/
pass_through?: PassThroughBody;
}
/**
* @export
* @enum {string}
*/
export declare enum PurchaseOrderStatus {
draft = "draft",
open = "open",
closed = "closed",
deleted = "deleted",
billed = "billed",
other = "other"
}
export declare function PurchaseOrderFromJSON(json: any): PurchaseOrder;
export declare function PurchaseOrderFromJSONTyped(json: any, ignoreDiscriminator: boolean): PurchaseOrder;
export declare function PurchaseOrderToJSON(value?: PurchaseOrder | null): any;