Ordrestyring.dk's API v2

Updated: 02-12-2021 20:07

Version 2 af API'en er markeret forældet.
Brug venligst vores GraphQL API

Ordrestyring's API is a REST API

Being an RESTful API, ordrestyring's API response to the four HTTP methods: GET, PUT, POST, or DELETE

Here is an example querying again tools:

  • GET /tools Retrieve a collection of tools
  • GET /tools/1 Retrieve a single tools with id 1
  • POST /tools create a new tool
  • PUT /tools/1 Update a tool with id information
  • DELETE /tools/1 Delete a single tools with id 1

The base url for ordrestyring.dk's API v2:

https://v2.api.ordrestyring.dk

To access the API you need to request an API key from ordrestyring.dk

The API uses HTTP Basic authentication for all requests. You must pass the API key as a username. The password can be anything, it is not taken into account for authentication. Authentication is based on the API key only

To test if your api key is valid go to this url in your browser (firefox and chrome only)

https://YOUR_API_KEY:x@v2.api.ordrestyring.dk

If valid you will be granted with information about your identity and the ordrestyring.dk customer you are connected to.

The API supports any language/implementation that can communicate though HTTP.
Below is code examples written in PHP using the popular library cURL.
cURL has been adopted by many languages. Either as native code or as extensions.
There is good change you can find an implementation of cURL in the language of your choice and rewrite the PHP code examples to your language of choice.


Retrieving data, GETrequests, can be tested in a webbrowser (firefox and chrome only), by going to the url for the resource you want to test:

https://YOUR_API_KEY:x@v2.api.ordrestyring.dk/debtors/1

A PHP class that can be used to retrieve and send data.

class ConsumeApi
{
    private $baseUrl = 'v2.api.ordrestyring.dk';
    private $apiKey;

    public function __construct($apiKey)
    {
        $this->apiKey = $apiKey;
    }

    public function post(string $urlPart, array $data)
    {
        $jsonEncodedData = json_encode($data);

        $curl = $this->initCurl($this->getFullUrl($urlPart));
        curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
        curl_setopt($curl, CURLOPT_CUSTOMREQUEST, 'POST');
        curl_setopt($curl, CURLOPT_HTTPHEADER, array('Content-Type: application/json'));
        curl_setopt($curl, CURLOPT_POST, true);
        curl_setopt($curl, CURLOPT_POSTFIELDS, $jsonEncodedData);

        return $this->getResponse($curl);
    }

    public function put(string $urlPart, array $data)
    {
        $jsonEncodedData = json_encode($data);

        $curl = $this->initCurl($this->getFullUrl($urlPart));
        curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
        curl_setopt($curl, CURLOPT_CUSTOMREQUEST, 'PUT');
        curl_setopt($curl, CURLOPT_HTTPHEADER, array('Content-Type: application/json'));
        curl_setopt($curl, CURLOPT_POST, true);
        curl_setopt($curl, CURLOPT_POSTFIELDS, $jsonEncodedData);

        return $this->getResponse($curl);
    }

    public function get(string $urlPart, array $params = [])
    {
        $curl = $this->initCurl($this->getFullUrl($urlPart, $params));

        return $this->getResponse($curl);
    }

    private function getResponse($curl)
    {
        $response = curl_exec($curl);
 
        return array(
            'code' => curl_getinfo($curl, CURLINFO_HTTP_CODE),
            'data' => json_decode($response),
        );
    }

    private function getFullUrl(string $urlPart, array $params = []): string
    {
        $urlParams = http_build_query($params);
        if ($urlParams) {
            $urlPart .= '?' . $urlParams;
        }

        return $this->baseUrl . '/' . $urlPart;
    }

    private function initCurl($url)
    {
        $curl = curl_init($url);

        curl_setopt($curl, CURLOPT_HTTPAUTH, CURLAUTH_BASIC);

        curl_setopt($curl, CURLOPT_USERPWD, $this->apiKey . ":x"); //Your credentials goes here
        curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
        return $curl;
    }
}

Here we are initializing the class, the class takes an api key as an argument

$api = new ConsumeApi('MY_API_KEY');

Updating or creating entries POST PUT
Updating or creating a case.

//  to update a case
$result = $api->put('cases/10', $data);

//  or to create a case
$result = $api->post('cases', $data);

Fetching data GET
Here we are executing the function and saving the result in a variable.

$result = $api->get('cases/10');
                                
//  or with params
$result = $api->get('cases/10', ['include' => 'materials']); // cases/10?include=materials

Retrieved response
The get, post and put methods returns a json response with the status code and the response.

{
    "code": 200,
    "data": {
        "yourref": "ref",
        "requestor": "John Doe",
        "creation_date": 1430416536,
        "description": "Some description",
        "main_technician": 118
}

To sort a resource by a field, you use the sortby parameter with a field name

Ascending order
Sorting is by default in ascending order.
To be more implicit adding a plus sign in front of the field also works.

/debtors?sortby=field or /debtors?sortby=+field

Descending order
To sort by descending order add a minus sign in front of the field.

/debtors?sortby=-field

You can include a resource inside another resource if they are in a relation to each other, this resource will be nested in the resource you are retrieving

For example: The resource debtor-invoices are in relationship with debtor-invoice-lines

/debtor-invoices/20?include=lines

This query will return a result, where the invoice lines have been included within the invoice. See below:

{
    "id": 20,
    "invoice_text": "example example",
    "lines": [
      {
        "id": "1",
        "example_column": "3743"
      },
      {
        "id": "2",
        "example_column": "8543"
      },
      {
        "id": "3",
        "example_column": "4543"
      }
    ]
}

Under each resource section the possible includes for a resource is indicated.

Every query parameter, except the params used in sorting, pagination or include is interpreted as a filter

Filtering makes it possible to filter by columns in different ways.


Simple
The most simple way is to just specify a column name.

/debtors?customer_postalcode=2100

This will get you the debtors with the column customer_postalcode set to 2100.


You can also specify that you want more than one column.

/debtors?customer_postalcode=1370|2100

This will get you the debtors with the column customer_postalcode set to either 1370 or 2100.


Advanced
This table specify more advanced filtering, which works by adding a suffix to the column name.

Suffix Meaning
-min Greater than or equal to
-max Smaller than or equal to
-st Smaller than
-gt Greater than
-not Not equal to

This query will get debtors where the customer_number is greater or equal to 1000

/debtors?customer_number-min=1000

All responses that are sent back to you are in the JSON format.

Response statuses

  • 200: The request was successful.
  • 201: The resource was successfully created.
  • 204: The request was successful, but we did not send any content back.
  • 400: The request failed due to an application error, such as a validation error.
  • 401: An API key was either not sent or invalid.
  • 403: The resource does not belong to the authenticated user and is forbidden.
  • 404: The resource was not found.
  • 500: A server error occurred.

You can expect all response statuses between 200-299 to be a succesfull call.

Primary key: customer_number

Property Description Notes Type
due_dates Relation: id in Payment terms int: 10
status Relation: id in Debtor Categories int: 10
currency_id Relation: id in currencies int: 10
customer_name required string: 250
customer_attention string: 250
customer_address required string: 250
customer_postalcode required string: 50
customer_city required string: 250
customer_telephone string: 50
customer_email string: 250
customer_mobile string: 50
invoice_name string: 250
invoice_address required string: 250
invoice_postalcode required string: 50
invoice_city required string: 250
invoice_telephone string: 50
invoice_email string: 250
invoice_mobile string: 50
cvr string: 50
ean string: 50
customer_remarks text
customer_number required, unique string: 50
invoice_attention text
avance_type int: 10
updated_at int: 10
is_blocked boolean: 1
created_at int: 10
pdf_layout_id int: 10
invoice_social_security_number string: 256
invoice_property_designation string: 256
invoice_residence_association_organisation_number string: 256
invoice_vat_number string: 255
  • GET /debtors Retrieve a collection of debtors
  • GET /debtors/1 Retrieve a single debtor with customer_number 1
  • POST /debtors Create a new debtor
  • PUT /debtors/1 Update a debtor
  • PUT /debtors/1/contacts Debtor's contacts
  • PUT /debtors/1/delivery-addresses Debtor's delivery addresses

Primary key: invoice_number

Property Description Notes Type
type 1: Faktura, 2: Kreditnota, 3: Aconto int: 10
customer_number Relation: customer_number in Debtors string: 50
case_number Relation: case_number in cases
department Relation: nr in Department int: 10
currency_code Currency code string: 10
currency_multiplier The value to multiply the amount with to get the locale currency decimal: 10
invoice_name string: 250
invoice_address string: 250
invoice_postalcode string: 250
invoice_city string: 250
cust_name string: 250
cust_address string: 250
cust_postalcode string: 50
cust_city string: 250
del_name string: 250
del_address string: 250
del_city string: 250
del_postalcode string: 50
text text
date int: 10
payment_date int: 10
ref string: 250
rek string: 250
made_by int: 10
amount numeric: 19
vat numeric: 19
amount_vat numeric: 19
fi_number string: 50
header text
status int: 10
del_att string: 250
cust_att string: 250
invoice_att string: 250
payed_date int: 10
payed_amount numeric: 19
invoice_number int: 10
updated_at int: 10
created_at int: 10
cust_cvr string: 100
use_skattered boolean: 1
  • GET /debtor-invoices Retrieve a collection of debtor-invoices
  • GET /debtor-invoices/1 Retrieve a single debtor-invoice with invoice_number 1
  • PUT /debtor-invoices/1/pay Set payment on a debtor-invoice with invoice_number 1

    Requires: payed_date, payed_amount

  • GET /debtor-invoices/1.pdf Outputs the invoice in pdf format

Includes:

Property Description Notes Type
new_cost_price costprice in øre numeric:19
new_list_price listprice in øre numeric:19
new_sales_price costprice in øre numeric:19
account Relation: nr in Account plan bigint:19
id bigint:19
quantity decimal:18
ean string:250
product_number string:250
product_text text:
price string:50
avance decimal:19
supplier text:
type int:10
created_at int:10
vat_percentage decimal:18
Property Description Notes Type
yourref string:250
requestor string:250
creation_date int:10
description text:
main_technician exists:technician,id int:10
status exists:status,id,site,order bigint:19
made_by int:10
offer_number int:10
additional_technicians string:600
remarks text:
work_done text:
delivery_address exists:cust_delivery_addresses,id int:10
contact string:100
case_type exists:status,id,site,case_type int:10
department exists:department,id int:10
no_materials boolean:1
case_number unique string:50
sub_number int:10
upper_case_number int:10
updated_at int:10
created_at int:10
customer_number required, exists:cust_customer,customer_number :
Property Description Notes Type
id int:10
name required string:300
number required, unique string:50
Property Description Notes Type
customer_name required string:250
customer_attention string:250
customer_address required string:250
customer_postalcode required string:50
customer_city required string:250
customer_telephone string:50
customer_email string:250
customer_mobile string:50
invoice_name string:250
invoice_address required string:250
invoice_postalcode required string:50
invoice_city required string:250
invoice_telephone string:50
invoice_email string:250
invoice_mobile string:50
due_dates int:10
cvr string:50
ean string:50
customer_remarks text:
customer_number required, unique string:50
status int:10
invoice_attention text:
avance_type int:10
updated_at int:10
is_blocked boolean:1
created_at int:10
pdf_layout_id int:10
currency_id int:10
invoice_social_security_number string:256
invoice_property_designation string:256
invoice_residence_association_organisation_number string:256
invoice_vat_number string:255

Primary key: ID

Property Description Notes Type
ID Needs to be supplied required, numeric, unique string: 50
Account Relation: nr in Account plan where vat_type is InputPurchase or PurchasedProductsAbroad bigint: 19
IsAccessible Specifies if the customer is active or deactived. The default is 1 (activated) boolean: 1
Name required string: 255
Address string: 255
Postalcode string: 50
City string: 255
CVR string: 50
updated_at int: 10
created_at int: 10
  • GET /creditors Retrieve a collection of creditors
  • GET /creditors/1 Retrieve a single creditor with id 1
  • POST /creditors Create a new creditor
  • PUT /creditors/1 Update a creditor with ID 1

Primary key: id

Property Description Notes Type
approved_status 1 = Approved, 2 = Afvist, NULL = Afventer behandling string: 50
case_number Relation: case_number in cases
account Relation: nr in Account plan where vat_type is InputPurchase or PurchasedProductsAbroad int: 10
id bigint: 19
type string: 50
number string: 50
date bigint: 19
buyer_name text
buyer_address text
buyer_postalcode string: 50
buyer_city text
buyer_id text
del_name text
del_address text
del_postalcode string: 50
del_city text
suplier_name text
suplier_address text
suplier_postalcode string: 50
suplier_city text
suplier_cvr text
suplier_ean text
suplier_ordernumber text
order_date bigint: 19
buyer_contact text
buyer_ordernumber text
currency text
payment_date bigint: 19
payment_type string: 50
payment_typecode text
payment_part_1 text
payment_part_2 text
total numeric: 19
vat numeric: 19
total_vat numeric: 19
creditor_number string: 50
approval_comment string: 500
department string: 50
note text
marking text
updated_at int: 10
  • GET /creditor-invoices Retrieve a collection of creditor-invoices
  • GET /creditor-invoices/{id} Retrieve a single creditor-invoice with number a specific id
  • GET /creditor-invoices/{id}.pdf Outputs the creditor-invoice in pdf format

Includes:

Property Description Notes Type
product_number string:50
quantity string:50
unit string:50
description string:250
LineAmount numeric:19
Property Description Notes Type
tripID required string: 50
StartAddress Textual start address required string: 250
StopAddress Textual start address required string: 250
Distance in meter required string: 50
Driver Name of driver required string: 50
RegNo Car registration number required string: 50
StarDate Format: DD-MM-YYYY HH:MM:SS required string: 50
StopDate Format: DD-MM-YYYY HH:MM:SS required string: 50
id int: 10
Serial string: 50
Purpose text
comment text
StartLat required, numeric string: 50
StartLong required, numeric string: 50
StopLat required, numeric string: 50
StopLong required, numeric string: 50
updated_at int: 10
created_at int: 10
  • GET /gps Retrieves gps data
  • POST /gps Insert gps data
Property Description Notes Type
number required string: 250
description required string: 250
price price in øre required, integer int: 10
costprice costprice in øre required, integer bigint: 19
account bigint: 19
id int: 10
updated_at int: 10
created_at int: 10
  • GET /internal-goods Retrieves internal goods
  • POST /internal-goods Insert an internal good
  • PUT /internal-goods/1 Insert an internal good

Primary key: id

Property Description Notes Type
month_ongoing løbende måned eller ej required, boolean smallint: 5
id int: 10
short_text required string: 100
long_text required string: 100
days required, integer int: 10
  • GET /payment-terms Retrieve a collection of payment-terms
  • GET /payment-terms/1 Retrieve a single payment term with id 1
  • POST /payment-terms Create a new payment term
  • PUT /payment-terms/1 Update a payment term

Primary key: id

Property Description Notes Type
id int: 10
colorcode string: 50
text required text
site required string: 50
show_in_app boolean: 1
show_in_app_status_change boolean: 1
  • GET /debtor-categories Retrieve a collection of debtor-categories
  • GET /debtor-categories/1 Retrieve a single debtor-category with id 1
  • POST /debtor-categories Create a new debtor-category
  • DELETE /debtor-categories delete a debtor-category

Primary key: nr

Property Description Notes Type
type This field needs to have an value of either Heading, Status, ProfitAndLoss, TotalFrom, SumInterval required, in:Heading,Status,ProfitAndLoss,TotalFrom,SumInterval string: 50
moms This field has to match the field vat_code in Vat types. required, exists:vat_types,vat_code string: 50
vattype This field needs to have an value of either OutputSales, InputPurchase, PurchasedProductsAbroad or to be empty in_or_empty:OutputSales,InputPurchase,PurchasedProductsAbroad string: 50
nr Needs to be supplied required, integer, unique int: 10
name required string: 150
  • GET /account-plan Retrieve a collection of account plan
  • GET /account-plan/1 Retrieve a single account plan with id 1
  • POST /account-plan Create a new account plan
  • PUT /account-plan/1 Update a account plan

Primary key: id

Property Description Notes Type
type This field needs to have an value of either OutputSales, InputPurchase, PurchasedProductsAbroad required, in:OutputSales,InputPurchase,PurchasedProductsAbroad text
id int: 10
vat_code required, unique text
name required text
rate_as_percent required, numeric decimal: 18
  • GET /vat-types Retrieve a collection of vat types
  • GET /vat-types/1 Retrieve a single vat type with id 1
  • POST /vat-types Create a new vat type
  • PUT /vat-types/1 Update a vat type

Primary key: id

Property Description Notes Type
id int: 10
name required string: 300
number required, unique string: 50
  • GET /departments Retrieve a collection of departments
  • GET /departments/1 Retrieve a single departments with id 1
  • POST /departments Create a new departments
  • PUT /departments/1 Update a departments

Primary key: case_number

Property Description Notes Type
yourref string: 250
requestor string: 250
creation_date int: 10
description text
main_technician exists:technician,id int: 10
status exists:status,id,site,order bigint: 19
made_by int: 10
offer_number int: 10
additional_technicians string: 600
remarks text
work_done text
delivery_address exists:cust_delivery_addresses,id int: 10
contact string: 100
case_type exists:status,id,site,case_type int: 10
department exists:department,id int: 10
no_materials boolean: 1
case_number unique string: 50
sub_number int: 10
upper_case_number int: 10
updated_at int: 10
created_at int: 10
customer_number required, exists:cust_customer,customer_number
  • GET /cases Retrieve a collection of cases
  • GET /cases/1 Retrieve a single case with id 1
  • GET /cases/1/employees Retrieve employees on case 1
  • POST /cases Create a new case
  • PUT /cases/1 Update a case with 1

Includes:

Property Description Notes Type
cost_price costprice in øre numeric numeric:19
list_price listprice in øre numeric numeric:19
id bigint:19
quantity numeric, required decimal:18
ean string:250
product_number string:250
product_text text:
supplier text:
discount numeric:19
sales_price numeric numeric:19
created_by int:10
added_type string:50
edi_invoice_number text:
updated_at int:10
created_at int:10
case_number required, exists:cases,case_number :
Property Description Notes Type
id int:10
emp_id required, integer int:10
start_time required:integer int:10
stop_time required, integer int:10
remark text:
hour_type required, integer int:10
updated_at int:10
created_at int:10
costprice int:10
exported boolean:1
approval_status int:10
case_id exists_or_null_or_not_set:cases,id :
Property Description Notes Type
id int:10
emp_id required, integer int:10
start_time required:integer int:10
stop_time required, integer int:10
remark text:
hour_type required, integer int:10
updated_at int:10
created_at int:10
costprice int:10
exported boolean:1
approval_status int:10
case_id exists_or_null_or_not_set:cases,id :
Property Description Notes Type
id int:10
text required text:
site required string:50
colorcode string:50
show_in_app boolean:1
show_in_app_status_change boolean:1
Property Description Notes Type
id int:10
text required text:
site required string:50
colorcode string:50
show_in_app boolean:1
show_in_app_status_change boolean:1
Property Description Notes Type
id int:10
name string:250
address string:250
city string:50
postalcode string:50
telephone string:50
mobile string:50
att string:250
ean string:50
email string:50
updated_at int:10
created_at int:10
customer_number required, exists:cust_customer,customer_number :
Property Description Notes Type
id :
type_of_address Can be a customer_address or a delivery_address :
name :
address :
postalcode :
city :
telephone :
mobile :
att :
email :
ean :

Primary key: id

Property Description Notes Type
id int: 10
text required text
site required string: 50
colorcode string: 50
show_in_app boolean: 1
show_in_app_status_change boolean: 1
  • GET /case-statuses Retrieve a collection of case statuses
  • GET /case-statuses/1 Retrieve a single case status with id 1

Primary key: id

Property Description Notes Type
id int: 10
text required text
site required string: 50
colorcode string: 50
show_in_app boolean: 1
show_in_app_status_change boolean: 1
  • GET /case-types Retrieve a collection of case types
  • GET /case-types/1 Retrieve a single case type with id 1

Primary key: id

Property Description Notes Type
id int: 10
status_from int: 10
status_to int: 10
changed_at int: 10
user_id int: 10
updated_at int: 10
created_at int: 10
affected_type string: 300
affected_id int: 10
case_number
  • GET /case-status-history Retrieve a collection of case status histories

Includes:

Property Description Notes Type
id int:10
text required text:
site required string:50
colorcode string:50
show_in_app boolean:1
show_in_app_status_change boolean:1
Property Description Notes Type
id int:10
text required text:
site required string:50
colorcode string:50
show_in_app boolean:1
show_in_app_status_change boolean:1

Primary key: id

Property Description Notes Type
added_type 1 = REGULAR, 2 = MANUAL, 3 = OFFER string: 50
id bigint: 19
quantity numeric, required decimal: 18
ean string: 250
product_number string: 250
product_text text
supplier text
discount numeric: 19
cost_price numeric numeric: 19
list_price numeric numeric: 19
sales_price numeric numeric: 19
created_by int: 10
edi_invoice_number text
updated_at int: 10
created_at int: 10
case_number required, exists:cases,case_number
  • GET /case-materials Retrieve a collection of case materials
  • GET /case-materials/1 Retrieve a single case materials with id 1
  • POST /case-materials Create a new case materials
  • PUT /case-materials/1 Update a case materials with ID 1

Includes:

Property Description Notes Type
init string:50
last_name string:50
tlf string:20
mobil_privat string:50
first_name string:50
id int:10
status int:10
email string:50
department_id int:10
employee_type_id int:10
fullName :

Primary key: id

Property Description Notes Type
file required
case_number required
id int: 10
description text
filetype string: 100
filename text
owner int: 10
date int: 10
updated_at int: 10
  • GET /case-documentation Retrieve a collection of case documentation
  • GET /case-documentation/1 Retrieve a single case documentation with id 1
  • GET /case-documentation/1/file Retrieves the file in case documentation with id 1
  • POST /case-documentation Create a new case documentation
  • PUT /case-documentation/1 Update a case documentation with id 1

Primary key: id

Property Description Notes Type
hour_type Relation: id in Employee types required, integer int: 10
customer_internal_number Relation: number in Internal goods
id int: 10
emp_id required, integer int: 10
start_time required:integer int: 10
stop_time required, integer int: 10
remark text
updated_at int: 10
created_at int: 10
costprice int: 10
exported boolean: 1
approval_status int: 10
case_id exists_or_null_or_not_set:cases,id
  • GET hours Retrieve a collection of hours. Set query-param: includeInternalNumber=true to include customer_internal_number
  • GET hours/1 Retrieve a single hour with id 1
  • POST hours Create a new hour
  • PUT hours/1 Update a hour with id 1
  • DELETE hours/1 delete a hour

Primary key: id

Property Description Notes Type
internal_number Relation: number in Internal goods string: 250
id int: 10
title string: 50
is_personal boolean: 1
color string: 10
updated_at int: 10
created_at int: 10
salary_handle string: 255
sort_order int: 10
  • GET /employee-types Retrieve a collection of employee types
  • GET /employee-types/1 Retrieve a single employee type with id 1
  • POST /employee-types Create a new employee type
  • PUT /employee-types/1 Update a employee type

To filter data use [start] and [stop] to limit results to a time period. [emp_id] to limit to a single employee. [type] to only get a certain types. Ex: type=personal,hours,planned or type=personal

  • GET calendar Retrieve a collection of calendar

To get only active users: users?status=999913

Primary key: id

Property Description Notes Type
init string: 50
last_name string: 50
tlf string: 20
mobil_privat string: 50
first_name string: 50
id int: 10
status int: 10
email string: 50
department_id int: 10
employee_type_id int: 10
fullName
  • GET /users Retrieve a collection of users
  • GET /users/1 Retrieve a single user with id 1

Incoming cases will be shown in the inbox in the tab: Cases in the OS main web system, where it will be possible to for the user to convert incoming cases to real cases

Primary key: id

Property Description Notes Type
id int: 10
external_case_id required string: 255
job_description required string: 2000
customer_name string: 250
customer_email string: 250
customer_phone string: 30
customer_address string: 250
customer_postalcode string: 50
customer_city string: 50
start_unixtime int: 10
end_unixtime int: 10
responsible_user_id int: 10
  • GET /incoming-cases Retrieve a collection of incoming cases
  • GET /incoming-cases/1 Retrieve a single incoming case with id 1

Primary key: id

Property Description Notes Type
id int: 10
invoice_text text
casenumber int: 10
invoice_header text
invoice_date int: 10
is_subscription boolean: 1
ref string: 250
rek string: 250
updated_at int: 10
created_at int: 10
use_skattered boolean: 1
payment_date int: 10
pdf_layout_id int: 10
tax_reduction int: 10
  • GET cases/{case_number}/invoice-draft Retrieve invoice draft for case
  • PUT cases/{case_number}/invoice-draft Update invoice draft for case
  • POST cases/{case_number}/invoice-draft/create-invoice Create invoice from draft

Includes:

Property Description Notes Type
id bigint:19
quantity numeric, required decimal:18
ean string:250
product_number string:250
product_text text:
supplier text:
discount numeric:19
cost_price integer numeric:19
list_price integer numeric:19
sales_price integer numeric:19
created_by int:10
added_type string:50
added_time int:10
edi_invoice_number text:
case_number required, exists:cases,case_number :

Primary key: id

Property Description Notes Type
id bigint: 19
quantity numeric, required decimal: 18
ean string: 250
product_number string: 250
product_text text
supplier text
discount numeric: 19
cost_price integer numeric: 19
list_price integer numeric: 19
sales_price integer numeric: 19
created_by int: 10
added_type string: 50
added_time int: 10
edi_invoice_number text
case_number required, exists:cases,case_number
  • GET /invoice-draft-lines/1 Retrieve a single invoice draft lines with id 1
  • POST /invoice-draft-lines Create a new invoice draft lines
  • PUT /invoice-draft-lines/1 Update a invoice draft lines with 1

Primary key: id

Property Description Notes Type
code ISO 4217 Currency Code required string: 256
id int: 10
  • GET /currencies Retrieve a collection of currencies
  • GET /currencies/1 Retrieve a single currency with id 1
  • POST /currencies Create a new currency
  • DELETE /currencies/1 Delete a currency
Property Description Notes Type
customer_number customer number required, exists:cust_customer,customer_number
id int: 10
name string: 250
address string: 250
city string: 50
postalcode string: 50
telephone string: 50
mobile string: 50
att string: 250
ean string: 50
email string: 50
updated_at int: 10
created_at int: 10
  • GET /delivery-addresses Retrieve a collection of delivery addresses
  • GET /delivery-addresses/1 Retrieve a single delivery address with id 1
  • POST /delivery-addresses Create a new delivery address
  • PUT /delivery-addresses/1 Update a delivery address
Property Description Notes Type
id int: 10
time_start int: 10
time_end int: 10
link string: 250
tech int: 10
updated_at int: 10
created_at int: 10
remark string: 1000
  • GET /planned-time Retrieve a collection of planned times
  • GET /planned-time/1 Retrieve a single planned time with id 1
  • POST /planned-time Create a new planned time
  • PUT /planned-time/1 Update a planned time with id 1