List invoices
Lists on one or more invoices for the authenticated/specified user.
...
Tag | Data type | Example | Description |
---|---|---|---|
invoices |
| <invoices> | root-tag that encloses all invoices |
invoice |
| <invoice> | Invoice |
id | ID | <id>1044</id> | Unique ID |
number | String | <number>796</number> | Invoice number |
prefix | String | <prefix>F</prefix> | Invoice number prefix |
orderedby | String | Acme INC., Homer Simpson | Invoice recipient |
orderid | ID | <orderid>44</orderid> | Order id |
orderedbycustomerid | ID | <orderedbycustomerid>23</orderedbycustomerid> | personID for the customer |
totalamount | Integer | 99900 | The totalt amount of the invoice in cents/ören |
rest | Integer | 50000 | The remaining amount yet to be paid in cents/ören |
invoicedate | Date | 2015-01-01 | Invoice date |
duedate | Date | 2015-01-31 | Due date |
payeddate | Date | 2015-01-28 | Date of final payment |
state |
|
| Status, see below |
number | Integer | <number>2</number> | Status, see below |
value | String | <value>Pending</value> | Reported status, see below |
reminderamount | Integer | <reminderamount>2500</reminderamount> | Reminder fee in cents/ören |
company |
| <company><id>1</id><name>Acme INC.</name></company> | The invoicing company |
Code Block |
---|
<invoices>
<invoice>
<id>1044</id>
<number>796</number>
<prefix>F</prefix>
<orderid>44</orderid>
<orderedby>Homer Simpson</orderedby>
<orderedbycustomerid>23</orderedbycustomerid>
<totalamount>17000</totalamount>
<rest>17000</rest>
<invoicedate>2015-01-11</invoicedate>
<duedate>2015-01-21</duedate>
<payeddate/>
<state>
<number>2</number>
<value>Pending</value>
</state>
<reminderamount>2500</reminderamount>
<company>
<id>1</id>
<name>Acme INC.</name>
</company>
</invoice>
<invoice>
...
</invoice>
</invoices>
|
...
- Create an invoice and set status "Not sent"
- Create an invoice and send it by e-mail
- Create an invoice and send ut by "Central print". See Invoice distribution for more information
Request
...
Important information about invoice distribution
- Read the Invoice distribution documentation to understand what features BRP has support for and how to get up and running with invoice distribution.
- If "distributionmethod" is not specified the invoice will automatically be set to status 1, "Not sent". See invoice status info below.
- If "distributionmethod" is specified BRP will attempt to distribute the invoice using the specified method. If successful the invoice will receive status 9, "Waiting to be sent". If unsuccessful the invoices will retain it's original status, 1, "Not sent".
- The "distributionmethod=email" requires that the customer (or other recipient) has a valid e-mail address and an ID for a specific template, "templateid". The ID can be found in BRP by selection Report templates from the Settings menu.
- The "distributionmethod=centralprint21grams" requires that the customer (or other recipient) has a valid post address.
- The invoice will be sent and managed by the scheduled activity "Invoice distribution". Once sent the status will be modified to "Sent", this is also logged on the History tab for each specific invoice. If BRP is unable to send the invoice the status will be reset to 1, "Not sent", and any error messages will also be found on the History tab for each invoice.
...
The same as "List invoices".
Status
See Invoice status for more detailed information in regards to each specific state.
The "Number" is constant. The "Value" can however vary due to locale and future development. The meaning will however not change over time. "Number=1" will always refer to an invoice this is not sent, irregardless of the contextual lable. Always use "Number" and keep your own list for the values.
...