Magidoc

Expense
Object

This represents an Expense

Fields

#

id

Non-null

legacyId

Non-null

Legacy ID as returned by API V1. Avoid relying on this field as it may be removed in the future.

description

Non-null

Title/main description for this expense

longDescription

Longer description for this expense

amount

Non-null

Total amount of the expense (sum of the item's amounts).

amountV2

Total amount of the expense

taxes

Non-null

Taxes applied to this expense

accountCurrencyFxRate

Non-null

The exchange rate between the expense currency and the account currency

accountingCategory

The accounting category attached to this expense

valuesByRole

If available, this field will contain a breakdown of the expense values depending on who edited it

createdAt

Non-null

The time of creation

currency

Non-null

Currency that should be used for the payout

type

Non-null

Whether this expense is a receipt or an invoice

status

Non-null

The state of the expense (pending, approved, paid, rejected...etc)

approvedBy

Non-null

The accounts who approved this expense

onHold

Whether this expense is on hold

comments

Returns the list of comments for this expense, or null if user is not allowed to see them

account

Non-null

The account where the expense was submitted

payee

Non-null

The account being paid by this expense

payeeLocation

The address of the payee

createdByAccount

The account who created this expense

host

The account from where the expense was paid

payoutMethod

The payout method to use for this expense

paymentMethod

virtualCard

The virtual card used to pay for this charge

attachedFiles

(Optional) files attached to the expense

items

privateMessage

Additional information about the payment as HTML. Only visible to user and admins.

invoiceInfo

Information to display on the invoice. Only visible to user and admins.

feesPayer

Non-null

The fees payer for this expense

permissions

Non-null

The permissions given to current logged in user for this expense

activities

[ Activity !]!
Non-null

The list of activities (ie. approved, edited, etc) for this expense ordered by date ascending

tags

[ String ]!
Non-null

requiredLegalDocuments

Returns the list of legal documents required from the payee before the expense can be payed. Must be logged in.

draft

Drafted field values that were still not persisted

requestedByAccount

The account that requested this expense to be submitted

validateTransferRequirements

recurringExpense

securityChecks

[Admin only] Security checks for this expense. Only available to expenses under trusted hosts.

customData

Custom data for this expense

merchantId

The merchant ID for this expense

Usages

#

References

#