# Neuro-Pay Invoice API # Requests Collection of possible requests # Create [POST] **https://api.neuro-admin.com/invoice/create** \[POST\]
currency\_idStringEUR, SEK, USD… etc
invoice\_date (optional)StringThe invoice date (if not have will get the sending date)
due\_date (optional) StringThe due date
client\_data (optional)object \*The client data as name, address, ... and where to send and how
invoice\_rows (optional)array of object \*\*Array with invoice row object (item, description, quantity, unitCost, tax)
\* client data object structure:
{
"name": "Test client 01", // (string) optional
"address_line1": "Street Nowhere, 3", // (string) optional
"address_line2": null, // (string) optional
"zip_code": "12345", // (string) optional
"city": "My City", // (string) optional
"country": "My Country", // (string) optional
"vat_number": "123456798", // (string) optional
"sendVia": "Email", // (string) optional (only one of the following: "Email" or "Sms")
"sendTo": "johndoe@test.com" // (string) optional
}
\*\* array of object containing the datas for every invoice row { "item": "Item name", // (string) optional but mandatory if not have description "description": "description", // (string) optional but mandatory if not have item "quantity": 3.1, // (float) optional "unitCost": 10.50, // (float) optional "tax": 12 // (float) optional } [![image.png](https://wiki.paiwise.tech/uploads/images/gallery/2023-11/scaled-1680-/Jc5image.png)](https://wiki.paiwise.tech/uploads/images/gallery/2023-11/Jc5image.png) # Retrieve [POST] **https://api.neuro-admin.com/invoice/retrieve** \[POST\] Values
invoice\_idStringThe invoice\_id received when creating a checkout object
[![image.png](https://wiki.paiwise.tech/uploads/images/gallery/2023-11/scaled-1680-/2WWimage.png)](https://wiki.paiwise.tech/uploads/images/gallery/2023-11/2WWimage.png) # Update [POST] **https://api.neuro-admin.com/invoice/update**\[POST\] The update can be used on objects that only have status "draft". Pay attention: datas not passed will be reset or delete in case of invoice rows.
invoice\_idStringThe invoice\_id in the creation response
currency\_idStringEUR, SEK, USD… etc
invoice\_date (optional)StringThe invoice date (if not have will get the sending date)
due\_date (optional) StringThe due date
client\_data (optional)object \*The client data as name, address, ... and where to send and how
invoice\_rows (optional)array of object \*\*Array with invoice row object (item, description, quantity, unitCost, tax)
\* client data object structure:
{
"name": "Test client 01", // (string) optional
"address_line1": "Street Nowhere, 3", // (string) optional
"address_line2": null, // (string) optional
"zip_code": "12345", // (string) optional
"city": "My City", // (string) optional
"country": "My Country", // (string) optional
"vat_number": "123456798", // (string) optional
"sendVia": "Email", // (string) optional (only one of the following: "Email" or "Sms")
"sendTo": "johndoe@test.com" // (string) optional
}
\*\* array of object containing the datas for every invoice row { "invoice\_row\_id": "c24fre56th23.......", // (string) optional but mandatory if you want to change or confirm a row, if not presents means that is a new row "item": "Item name", // (string) optional but mandatory if not have description "description": "description", // (string) optional but mandatory if not have item "quantity": 3.1, // (float) optional "unitCost": 10.50, // (float) optional "tax": 12 // (float) optional } [![image.png](https://wiki.paiwise.tech/uploads/images/gallery/2023-11/scaled-1680-/WgJimage.png)](https://wiki.paiwise.tech/uploads/images/gallery/2023-11/WgJimage.png) This example confirms all the data and add a new row (one without "invoice\_row\_id") # List [GET] **https://api.neuro-admin.com/invoice/index**\[GET\] This EP returns the list of all invoices for the company associated to the api key in form of array of object. # Authentification In order to use the invoice API the company in question needs to generate an API key through the Neuro-Admin platform. Said API key should be sent as a bearer token in each request. [![image.png](https://wiki.paiwise.tech/uploads/images/gallery/2022-07/scaled-1680-/jgfimage.png)](https://wiki.paiwise.tech/uploads/images/gallery/2022-07/jgfimage.png) # Response # The response object For each endpoint the invoice object will be returned in its “new state” Example: Possible statuses are • draft • sent • paid • partialpaid • revoked Every date and time returned are in UTC. [![image.png](https://wiki.paiwise.tech/uploads/images/gallery/2023-11/scaled-1680-/Nppimage.png)](https://wiki.paiwise.tech/uploads/images/gallery/2023-11/Nppimage.png) If the invoice status is "sent" the field "invoice\_no" get value [![image.png](https://wiki.paiwise.tech/uploads/images/gallery/2023-11/scaled-1680-/wIVimage.png)](https://wiki.paiwise.tech/uploads/images/gallery/2023-11/wIVimage.png) # Data format The API currently accepts and returns JSON data in the body # Postman collection attached to this page is a postman collection for testing All requests inherits the authentication from the collection. as the bearer token you add your API key test or live, You can find file attachments in top left corner of this page