Invoice
Field guide
The following fields are available in an invoice object
Name | Type | Example | Notes |
---|
id | int | 43 | Invoice id |
number | string | 4633 | Your invoice number |
client_id | int | 1 | Client's id |
client_name | string | Jane Doe | Name of client |
client_address_id | int | 1 | Client's address id |
client_contact_id | int | 0 | Client's contact id |
currency | string | EUR | Three-letter currency code |
title | string | My new invoice | Title of the invoice |
period | string | Period of service | |
date | date | 2012-03-25 | Date of invoice in YYYY-MM-DD format |
due | date | 2012-04-22 | Latest payment date in YYYY-MM-DD format |
account_id | int | 0 | Id for Account Object |
esr | int | 0 | If invoice has ESR |
esr_number | int | 243 | ESR number |
esr_position | int | 0 | Positioning of ESR. 0 = additional page, 1 = first page, 2 = last page |
lsvplus | int | 1 | If LSV+ is active |
dd | int | 1 | If DebitDirect is active |
discount | float | 5 | Discount amount |
discount_type | int | 1 | See Discount Types |
introduction | string | text | Introduction text printed above positions |
conditions | string | text | Text printed below positions |
language | string | de | Two-letter language code |
paypal | int | 0 | PayPal account payment |
paypal_url | string | http://bit.ly/x4geSA | PayPal pay URL |
vat_included | int | 1 | If VAT is included in positions' prices |
totalamount | float | 140.15 | Total sum of all positions |
status | int | 7 | See Status Types |
pages | int | 2 | Number of pages |
positions | collection | | Collection of Position Objects |
Example content of data variable:
{
"error":false,
"item":{
"id":77,
"number":10000,
"client_id":16,
"client_name":"Jane Doe",
"client_address_id":11,
"client_contact_id":0,
"currency":"CHF",
"title":"Rechnung Nr. {1} \/ Kunden Nr. {2}",
"period":"",
"date":"2013-02-25",
"due":"2013-03-27",
"account_id":0,
"esr":0,
"esr_number":"",
"esr_position":0,
"lsvplus":0,
"dd":0,
"discount":0,
"discount_type":0,
"conditions":"",
"introduction":"",
"language":"de",
"paypal":0,
"paypal_url":"",
"vat_included":0,
"totalamount":0,
"status":7,
"pages":1,
"positions":[
{
"type":1,
"number":null,
"name":"Service Y",
"description":"Cleaning house",
"cost":0,
"unit":1,
"amount":1,
"vat":8,
"discount":null
},
{
"type":2,
"number":null,
"name":"Product X",
"description":"Repairing car",
"cost":0,
"unit":7,
"amount":1,
"vat":8,
"discount":null
}
]
}
}
Status
Status | Meaning of status |
---|
1 | Sent / Open |
2 | Paid |
3 | 1st Reminder |
4 | 2nd Reminder |
5 | 3rd Reminder |
6 | Cancelled |
7 | Draft |
11 | Partially paid |
12 | Reminder |
99 | Deleted |
Discount
Discount | Type |
---|
0 | Percent |
1 | Value |