Expensereport data model

View field support, webhooks, and list parameters for each integration on the Supported Integrations page.

FieldTypeRequiredDescription
idstringNo
created_atstring (date-time)No(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
updated_atstring (date-time)No(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
namestringNo
user_idstringNoreferences a HR employee/user (reference to HrisEmployee)
approver_user_idstringNoreferences HR employee/user (reference to HrisEmployee)
approver_usersAccountingReference[]Noexpense approver(s); id is HR employee/user when resolved
approver_users[].idstringNo
approver_users[].namestringNo
statusenumNoValues: DRAFT, SUBMITTED, PENDING, APPROVED, REJECTED, PAID
total_amountnumberNo
currencystringNo
tax_amountnumberNo
reimbursed_amountnumberNo
reimbursed_atstring (date-time)No(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
approved_atstring (date-time)No(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
posted_atstring (date-time)No(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
external_numberstringNo
lineitemsAccountingLineitem[]No
lineitems[].idstringNo
lineitems[].created_atstring (date-time)No(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
lineitems[].updated_atstring (date-time)No(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
lineitems[].refunded_atstring (date-time)No(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
lineitems[].total_amountnumberNounit_quantity * unit_amount + tax_amount
lineitems[].refund_amountnumberNo
lineitems[].discount_amountnumberNo
lineitems[].tax_amountnumberNo
lineitems[].item_idstringNo(reference to CommerceItem)
lineitems[].unit_amountnumberNo
lineitems[].unit_quantitynumberNo
lineitems[].item_skustringNo
lineitems[].item_namestringNo
lineitems[].item_descriptionstringNo
lineitems[].notesstringNo
lineitems[].taxrate_idstringNo
lineitems[].account_idstringNo(reference to AccountingAccount)
lineitems[].category_idsstring[]No(reference to AccountingCategory)
lineitems[].locationsAccountingReference[]No
lineitems[].locations[].idstringNo
lineitems[].locations[].namestringNo
lineitems[].item_variantsAccountingReference[]No
lineitems[].item_variants[].idstringNo
lineitems[].item_variants[].namestringNo
lineitems[].feesAccountingFee[]No
lineitems[].fees[].typeenumYesUnified fee category Values: TAX, DISCOUNT, PROMOTION, SHIPPING, GIFT_WRAP, COD, SURCHARGE, TIP, SERVICE_CHARGE, OTHER
lineitems[].fees[].original_typestringNoThe provider's original fee label, e.g. "VAT" or a shipping carrier name
lineitems[].fees[].amountnumberYes
lineitems[].fees[].currencystringNoISO 4217 currency code, e.g. USD
lineitems[].contact_idstringNo(reference to AccountingContact)
lineitems[].project_idstringNoref -> AccountingProject; the project this line is coded to (reference to TaskProject)
lineitems[].exchange_ratenumberNoThe exchange rate applied to this line, for multi-currency documents
lineitems[].is_billablebooleanNoTrue when the line is rebillable to a customer
attachmentsAccountingAttachment[]No
attachments[].idstringNo
attachments[].download_urlstringNo
attachments[].namestringNo
attachments[].mime_typestringNo
category_idsstring[]No(reference to AccountingCategory)
project_idstringNo(reference to TaskProject)
usersAccountingReference[]No
users[].idstringNo
users[].namestringNo
organization_idstringNo
metadataAccountingMetadata[]No
metadata[].idstringNo
metadata[].slugstringNo
metadata[].valueobjectNo
metadata[].namespacestringNo
metadata[].formatenumNoValues: TEXT, NUMBER, DATE, BOOLEAN, FILE, TEXTAREA, SINGLE_SELECT, MULTIPLE_SELECT, MEASUREMENT, PRICE, YES_NO, CURRENCY, URL
metadata[].extra_dataobjectNo

TypeScript

TypeScript
export type AccountingExpensereport = {
	id?: string;
	created_at?: string-time; // (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
	updated_at?: string-time; // (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
	name?: string;
	user_id?: string; // references a HR employee/user (reference to HrisEmployee)
	approver_user_id?: string; // references HR employee/user (reference to HrisEmployee)
	approver_users?: []; // expense approver(s); id is HR employee/user when resolved
	status?: 'DRAFT' | 'SUBMITTED' | 'PENDING' | 'APPROVED' | 'REJECTED' | 'PAID';
	total_amount?: number;
	currency?: string;
	tax_amount?: number;
	reimbursed_amount?: number;
	reimbursed_at?: string-time; // (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
	approved_at?: string-time; // (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
	posted_at?: string-time; // (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
	external_number?: string;
	lineitems?: [];
	attachments?: [];
	category_ids?: string[]; // (reference to AccountingCategory)
	project_id?: string; // (reference to TaskProject)
	users?: [];
	organization_id?: string;
	metadata?: [];
	raw?: any;
} 

Zod

Zod
import { z } from 'zod';

export const ZodAccountingExpensereport = z.object({
	id: z.string().optional(),
	created_at: z.string-time().optional().describe("(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"),
	updated_at: z.string-time().optional().describe("(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"),
	name: z.string().optional(),
	user_id: z.string().optional().describe("references a HR employee/user (reference to HrisEmployee)"),
	approver_user_id: z.string().optional().describe("references HR employee/user (reference to HrisEmployee)"),
	approver_users: z.array().optional().describe("expense approver(s); id is HR employee/user when resolved"),
	status: z.enum("DRAFT", "SUBMITTED", "PENDING", "APPROVED", "REJECTED", "PAID").optional(),
	total_amount: z.number().optional(),
	currency: z.string().optional(),
	tax_amount: z.number().optional(),
	reimbursed_amount: z.number().optional(),
	reimbursed_at: z.string-time().optional().describe("(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"),
	approved_at: z.string-time().optional().describe("(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"),
	posted_at: z.string-time().optional().describe("(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"),
	external_number: z.string().optional(),
	lineitems: z.array().optional(),
	attachments: z.array().optional(),
	category_ids: z.array().optional().describe("(reference to AccountingCategory)"),
	project_id: z.string().optional().describe("(reference to TaskProject)"),
	users: z.array().optional(),
	organization_id: z.string().optional(),
	metadata: z.array().optional(),

});

Python

Python
import dataclasses

@dataclasses.dataclass
class AccountingExpensereportStatus(str, Enum):
	DRAFT = 'DRAFT'
	SUBMITTED = 'SUBMITTED'
	PENDING = 'PENDING'
	APPROVED = 'APPROVED'
	REJECTED = 'REJECTED'
	PAID = 'PAID'

@dataclasses.dataclass
class AccountingExpensereport:
	id: Optional[str]
	"""(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"""
	created_at: Optional[str]
	"""(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"""
	updated_at: Optional[str]
	name: Optional[str]
	"""references a HR employee/user (reference to HrisEmployee)"""
	user_id: Optional[str]
	"""references HR employee/user (reference to HrisEmployee)"""
	approver_user_id: Optional[str]
	"""expense approver(s); id is HR employee/user when resolved"""
	approver_users: Optional[PropertyAccountingExpensereportApprover_users]
	status: Optional[AccountingExpensereportStatus]
	total_amount: Optional[int]
	currency: Optional[str]
	tax_amount: Optional[int]
	reimbursed_amount: Optional[int]
	"""(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"""
	reimbursed_at: Optional[str]
	"""(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"""
	approved_at: Optional[str]
	"""(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"""
	posted_at: Optional[str]
	external_number: Optional[str]
	lineitems: Optional[PropertyAccountingExpensereportLineitems]
	attachments: Optional[PropertyAccountingExpensereportAttachments]
	"""(reference to AccountingCategory)"""
	category_ids: Optional[List[List[str]]]
	"""(reference to TaskProject)"""
	project_id: Optional[str]
	users: Optional[PropertyAccountingExpensereportUsers]
	organization_id: Optional[str]
	metadata: Optional[PropertyAccountingExpensereportMetadata]
Are we missing anything? Let us know
Was this page helpful?