List all delivery note items

GET /api/delivery-note-items?delivery_note_id={delivery_note_id}

Delivery note items can only be returned for a particular delivery note.
Therefore delivery_note_id is a mandatory parameter.

<?xml version="1.0" encoding="UTF-8"?>
<delivery-note-items type="array" page="1" per_page="100" total="2">
    <delivery-note-item>
        ...
    <delivery-note-item>
    <delivery-note-item>
        ...
    <delivery-note-item>
</delivery-note-items>

Get a single item

GET /api/delivery-note-items/{id}
<?xml version="1.0" encoding="UTF-8"?>
<delivery-note-item>
    <id type="integer">1</id>
    <article_id type="integer">123</article_id>
    <delivery_note_id type="integer">1</delivery_note_id>
    <position type="integer">1</position>
    <unit>Stück</unit>
    <quantity type="float">5.2</quantity>
    <title>Business cards</title>
    <description>Wonderful 4c business cards</description>
</delivery-note-item>

Create item

POST /api/delivery-note-items

Credit note items can only be created for delivery notes with draft status (DRAFT).

XML element Description Type Default value Mandatory
delivery_note_id ID of the delivery note INT yes (except for creation of a delivery note)
article_id ID of the article, sets additionally the values from the article on creation INT
unit Unit ALNUM
quantity Qunatity FLOAT 0.0
title Title ALNUM
description Description ALNUM

The delivery note item is added to already existing positions.

<delivery-note-item>
    <delivery_note_id>1</delivery_note_id>
    <unit>Piece</unit>
    <quantity>5.2</quantity>
    <title>Business cards</title>
    <description>Wonderful 4c business cards</description>
</delivery-note-item>
<?xml version="1.0" encoding="UTF-8"?>
<delivery-note-item>
    <id type="integer">1</id>
    <article_id />
    <delivery_note_id type="integer">1</delivery_note_id>
    <created>2007-12-13T12:12:00+01:00</created>
    <position type="integer">1</position>
    <unit>Piece</unit>
    <quantity type="float">5.2</quantity>
    <title>Business cards</title>
    <description>Wonderful 4c business cards</description>
</delivery-note-item>

Edit item

PUT /api/delivery-note-items/{id}

Here the same parameters apply as for creating, however, the associated delivery note (delivery_note_id) can not be changed.
Delivery note items can be edited only for delivery notes with draft status (DRAFT).

<delivery-note-item>
    <unit>Mile</unit>
    <quantity>8.5</quantity>
</delivery-note-item>

Delete item

DELETE /api/delivery-note-items/{id}

When deleting an delivery note item, position of the remaining items is reassigned (without changing the sorting) to fill the resulting gap.
Delivery note items can be deleted only for delivery notes with draft status (DRAFT).