Get All Invoice Metadata by Order

 

This method returns metadata for all invoices for a specified order.

 

HTTP Verb/Method:

GET 

URL Format:

http://server/api/invoices/{OrderID}

Returns:

Metadata for all invoices of the order will return upon a successful request.

An error is returned if the invoice metadata cannot be found.

 

The following table lists the parameter available for this method request.

 

Parameter

Description

OrderID

Enter the primary key (Orders.PriKey) of the requested MoversSuite order. 

 

Request Return

By default, metadata is returned in JSON format as follows:

 

[{

    "Amount": 1704.3600,

    "Created": "2009-12-18T08:36:31",

    "CreatedBy": "Judy Miles",

    "Description": "Invoice: Z17340\/1",

    "ImageUrl": "http:\/\/server\/api\/invoices\/43147\/1?download=true",

    "InvoiceNumber": "1",

    "Invoiced": "2009-12-18T08:36:32",

    "Name": " Z17340(1).pdf",

    "OrderID": 43147,

    "OrderUrl": "http:\/\/server\/api\/orders\/43147",

    "Status": "Void",

    "Type": "MS Invoice"

}, {… }]

 

The following table describes the metadata returned by this method.

 

Property

Description

Amount

The dollar amount of the invoice displays.

Created

Returned here is the creation date of the invoice document.

This date is formatted in “CCYY-MM-DDThh:mm:ss” format (see Document API Date Format).

CreatedBy

The MoversSuite user that created the invoice is returned in this property.

Description

This is the text description of the invoice.

ImageUrl

The URL containing the location of the invoice document.  If this value is null, then no image of the invoice is on file.

InvoiceNumber

The specific number assigned to the invoice for this order is returned.    The sequence is appended to the Order Number following a slash, e.g. “/2” for invoice “2” on an order.

Invoiced

The date and time of the invoice display within this property.

This date is formatted in “CCYY-MM-DDThh:mm:ss” format (see Document API Date Format).

Name

The name of the document or the file name of the document is returned in this property.

OrderID

This is the identification for the order associated to the invoice.  The OrderID is typically the primary key of the order in the Orders table (Order.PriKey).

OrderUrl

This property contains the URL that references the metadata for the order associated to the invoice.

Status

One of the following status values is returned with this property:

“Invoice” indicates a an active, generated invoice

“Void” indicates that the invoice has been voided

“Draft” indicates that the invoice is in a draft state

Type

Invoices will always be assigned to a type of “MS Invoice.”