Skip to content
Developer

Inventory loan

Locations and bookings8 EndpointsEvent / Inventory loan

Every inventory item with stock, lent, overdue and free pieces right now.

GET/api/event/inventory_loan_stock

Responses

200List of {bookable, quantity, lent, overdue, available_now, deposit}

Request
curl --request GET \
  --url https://your-instance.iw-erp.de/api/event/inventory_loan_stock \
  --header 'x-iw-jwt-token: <TOKEN>'

Free pieces of one item between start and end (bookings and loans counted).

GET/api/event/inventory_loan_availability/{bookableId}

Path parameters

bookableIdrequiredstring

Query parameters

startrequiredstring
endrequiredstring

Responses

200{quantity, used, available}

Request
curl --request GET \
  --url 'https://your-instance.iw-erp.de/api/event/inventory_loan_availability/42?start=string&end=string' \
  --header 'x-iw-jwt-token: <TOKEN>'

All loans; default order: due date ascending (state=RETURNED: latest return first). overdue=1 (or state=OVERDUE) lists only lent loans past their due date.

GET/api/event/inventory_loan

Query parameters

idstring
statestring
bookablestring
bookingstringThe booking the item was reserved with (null only once the booking is deleted).
personstring
depositStatestring
issuedAtstring
dueAtstring
returnedAtstring
createdstring
updatedstring
searchStringstringtext to search for in the list
orderFieldNamestringname of the order field
orderFieldSortstringsorting modeAllowed: DESCASC
pageintegerpage of the list
pageSizeintegernumber of entries for each page
withMaxPageNumberstringreturns the number of pages available as a header if this is set

Responses

200Returns a list of EventInventoryLoan objectsarray<EventInventoryLoan>

Show fields (22)
  • overdueboolean
  • deposit_refunded_amountnumber (float)

    Amount paid back on return (deposit minus the retained part).

  • idinteger

    Primary key of the inventory loan. Internal ID.

  • bookable_namestring

    Name of the item at the time of the hand-over.

  • borrower_namestring

    Name of the borrower at the time, or the name typed in for somebody without a person.

  • quantityinteger

    Number of items lent out.

  • statestring

    State of the loan, for example issued or returned.

  • issued_atstring (date-time)

    Time the item was issued.

  • due_atstring (date-time)

    Time the item is due back.

  • returned_atstring (date-time)

    Time the item was returned.

  • deposit_amountnumber (float)

    Deposit paid for the loan.

  • deposit_statestring

    State of the deposit, for example held or refunded.

  • deposit_retained_amountnumber (float)

    Part of the deposit kept on return.

  • condition_on_issuestring

    Condition of the item when it was issued.

  • condition_on_returnstring

    Condition of the item when it was returned.

  • notestring

    Internal note of the office, not shown to the borrower.

  • issued_by_namestring

    Name of the staff member who issued the item.

  • returned_by_namestring

    Name of the staff member who took back the item.

  • last_reminder_atstring (date-time)

    Last reminder (due soon or overdue) sent to the borrower.

  • reminder_countinteger

    Number of reminders sent for the loan.

  • createdstring (date-time)

    Point in time the entity was created.

  • updatedstring (date-time)

    Point in time the entity was last updated.

Request
curl --request GET \
  --url https://your-instance.iw-erp.de/api/event/inventory_loan \
  --header 'x-iw-jwt-token: <TOKEN>'
Response 200 application/json
[
  {
    "id": 42,
    "bookable_name": "Beispiel",
    "borrower_name": "Beispiel",
    "issued_by_name": "Beispiel",
    "returned_by_name": "Beispiel",
    "overdue": true,
    "deposit_refunded_amount": 49.9,
    "quantity": 1,
    "state": "string",
    "issued_at": "2026-10-15T09:30:00+02:00"
  }
]

Hand the item of a booking (Termin) over; item and borrower come from the booking.

POST/api/event/inventory_loan

Without dueAt the loan runs until the end of the booking. The deposit defaults to the deposit of the item times the quantity. force=true skips the stock check.

Request body application/json

  • bookingintegerrequired
  • quantityinteger
  • due_atstring
  • deposit_amountnumber
  • conditionstring
  • notestring
  • forceboolean

Responses

200The new loanEventInventoryLoan

Show fields (22)
  • overdueboolean
  • deposit_refunded_amountnumber (float)

    Amount paid back on return (deposit minus the retained part).

  • idinteger

    Primary key of the inventory loan. Internal ID.

  • bookable_namestring

    Name of the item at the time of the hand-over.

  • borrower_namestring

    Name of the borrower at the time, or the name typed in for somebody without a person.

  • quantityinteger

    Number of items lent out.

  • statestring

    State of the loan, for example issued or returned.

  • issued_atstring (date-time)

    Time the item was issued.

  • due_atstring (date-time)

    Time the item is due back.

  • returned_atstring (date-time)

    Time the item was returned.

  • deposit_amountnumber (float)

    Deposit paid for the loan.

  • deposit_statestring

    State of the deposit, for example held or refunded.

  • deposit_retained_amountnumber (float)

    Part of the deposit kept on return.

  • condition_on_issuestring

    Condition of the item when it was issued.

  • condition_on_returnstring

    Condition of the item when it was returned.

  • notestring

    Internal note of the office, not shown to the borrower.

  • issued_by_namestring

    Name of the staff member who issued the item.

  • returned_by_namestring

    Name of the staff member who took back the item.

  • last_reminder_atstring (date-time)

    Last reminder (due soon or overdue) sent to the borrower.

  • reminder_countinteger

    Number of reminders sent for the loan.

  • createdstring (date-time)

    Point in time the entity was created.

  • updatedstring (date-time)

    Point in time the entity was last updated.

Request
curl --request POST \
  --url https://your-instance.iw-erp.de/api/event/inventory_loan \
  --header 'content-type: application/json' \
  --header 'x-iw-jwt-token: <TOKEN>' \
  --data '
{
  "booking": 1,
  "quantity": 1,
  "due_at": "2026-10-15T09:30:00+02:00",
  "deposit_amount": 49.9,
  "condition": "string",
  "note": "string"
}
'
Response 200 application/json
{
  "id": 42,
  "bookable_name": "Beispiel",
  "borrower_name": "Beispiel",
  "issued_by_name": "Beispiel",
  "returned_by_name": "Beispiel",
  "overdue": true,
  "deposit_refunded_amount": 49.9,
  "quantity": 1,
  "state": "string",
  "issued_at": "2026-10-15T09:30:00+02:00"
}

Returns a single event inventory loan entry.

GET/api/event/inventory_loan/{id}

Path parameters

idrequiredstring

Responses

200Returns a single EventInventoryLoanEventInventoryLoan

Show fields (22)
  • overdueboolean
  • deposit_refunded_amountnumber (float)

    Amount paid back on return (deposit minus the retained part).

  • idinteger

    Primary key of the inventory loan. Internal ID.

  • bookable_namestring

    Name of the item at the time of the hand-over.

  • borrower_namestring

    Name of the borrower at the time, or the name typed in for somebody without a person.

  • quantityinteger

    Number of items lent out.

  • statestring

    State of the loan, for example issued or returned.

  • issued_atstring (date-time)

    Time the item was issued.

  • due_atstring (date-time)

    Time the item is due back.

  • returned_atstring (date-time)

    Time the item was returned.

  • deposit_amountnumber (float)

    Deposit paid for the loan.

  • deposit_statestring

    State of the deposit, for example held or refunded.

  • deposit_retained_amountnumber (float)

    Part of the deposit kept on return.

  • condition_on_issuestring

    Condition of the item when it was issued.

  • condition_on_returnstring

    Condition of the item when it was returned.

  • notestring

    Internal note of the office, not shown to the borrower.

  • issued_by_namestring

    Name of the staff member who issued the item.

  • returned_by_namestring

    Name of the staff member who took back the item.

  • last_reminder_atstring (date-time)

    Last reminder (due soon or overdue) sent to the borrower.

  • reminder_countinteger

    Number of reminders sent for the loan.

  • createdstring (date-time)

    Point in time the entity was created.

  • updatedstring (date-time)

    Point in time the entity was last updated.

Request
curl --request GET \
  --url https://your-instance.iw-erp.de/api/event/inventory_loan/42 \
  --header 'x-iw-jwt-token: <TOKEN>'
Response 200 application/json
{
  "id": 42,
  "bookable_name": "Beispiel",
  "borrower_name": "Beispiel",
  "issued_by_name": "Beispiel",
  "returned_by_name": "Beispiel",
  "overdue": true,
  "deposit_refunded_amount": 49.9,
  "quantity": 1,
  "state": "string",
  "issued_at": "2026-10-15T09:30:00+02:00"
}

return (condition, retained_amount = kept part of the deposit, note, returned_at), extend (due_at, force).

PUT/api/event/inventory_loan/{id}/{action}

Path parameters

idrequiredstring
actionrequiredstring

Request body application/json

  • conditionstring
  • retained_amountnumber
  • notestring
  • returned_atstring
  • due_atstring
  • forceboolean

Responses

200The loan after the actionEventInventoryLoan

Show fields (22)
  • overdueboolean
  • deposit_refunded_amountnumber (float)

    Amount paid back on return (deposit minus the retained part).

  • idinteger

    Primary key of the inventory loan. Internal ID.

  • bookable_namestring

    Name of the item at the time of the hand-over.

  • borrower_namestring

    Name of the borrower at the time, or the name typed in for somebody without a person.

  • quantityinteger

    Number of items lent out.

  • statestring

    State of the loan, for example issued or returned.

  • issued_atstring (date-time)

    Time the item was issued.

  • due_atstring (date-time)

    Time the item is due back.

  • returned_atstring (date-time)

    Time the item was returned.

  • deposit_amountnumber (float)

    Deposit paid for the loan.

  • deposit_statestring

    State of the deposit, for example held or refunded.

  • deposit_retained_amountnumber (float)

    Part of the deposit kept on return.

  • condition_on_issuestring

    Condition of the item when it was issued.

  • condition_on_returnstring

    Condition of the item when it was returned.

  • notestring

    Internal note of the office, not shown to the borrower.

  • issued_by_namestring

    Name of the staff member who issued the item.

  • returned_by_namestring

    Name of the staff member who took back the item.

  • last_reminder_atstring (date-time)

    Last reminder (due soon or overdue) sent to the borrower.

  • reminder_countinteger

    Number of reminders sent for the loan.

  • createdstring (date-time)

    Point in time the entity was created.

  • updatedstring (date-time)

    Point in time the entity was last updated.

Request
curl --request PUT \
  --url https://your-instance.iw-erp.de/api/event/inventory_loan/42/42 \
  --header 'content-type: application/json' \
  --header 'x-iw-jwt-token: <TOKEN>' \
  --data '
{
  "condition": "string",
  "retained_amount": 49.9,
  "note": "string",
  "returned_at": "2026-10-15T09:30:00+02:00",
  "due_at": "2026-10-15T09:30:00+02:00",
  "force": true
}
'
Response 200 application/json
{
  "id": 42,
  "bookable_name": "Beispiel",
  "borrower_name": "Beispiel",
  "issued_by_name": "Beispiel",
  "returned_by_name": "Beispiel",
  "overdue": true,
  "deposit_refunded_amount": 49.9,
  "quantity": 1,
  "state": "string",
  "issued_at": "2026-10-15T09:30:00+02:00"
}

return (condition, retained_amount = kept part of the deposit, note, returned_at), extend (due_at, force).

PATCH/api/event/inventory_loan/{id}/{action}

Path parameters

idrequiredstring
actionrequiredstring

Request body application/json

  • conditionstring
  • retained_amountnumber
  • notestring
  • returned_atstring
  • due_atstring
  • forceboolean

Responses

200The loan after the actionEventInventoryLoan

Show fields (22)
  • overdueboolean
  • deposit_refunded_amountnumber (float)

    Amount paid back on return (deposit minus the retained part).

  • idinteger

    Primary key of the inventory loan. Internal ID.

  • bookable_namestring

    Name of the item at the time of the hand-over.

  • borrower_namestring

    Name of the borrower at the time, or the name typed in for somebody without a person.

  • quantityinteger

    Number of items lent out.

  • statestring

    State of the loan, for example issued or returned.

  • issued_atstring (date-time)

    Time the item was issued.

  • due_atstring (date-time)

    Time the item is due back.

  • returned_atstring (date-time)

    Time the item was returned.

  • deposit_amountnumber (float)

    Deposit paid for the loan.

  • deposit_statestring

    State of the deposit, for example held or refunded.

  • deposit_retained_amountnumber (float)

    Part of the deposit kept on return.

  • condition_on_issuestring

    Condition of the item when it was issued.

  • condition_on_returnstring

    Condition of the item when it was returned.

  • notestring

    Internal note of the office, not shown to the borrower.

  • issued_by_namestring

    Name of the staff member who issued the item.

  • returned_by_namestring

    Name of the staff member who took back the item.

  • last_reminder_atstring (date-time)

    Last reminder (due soon or overdue) sent to the borrower.

  • reminder_countinteger

    Number of reminders sent for the loan.

  • createdstring (date-time)

    Point in time the entity was created.

  • updatedstring (date-time)

    Point in time the entity was last updated.

Request
curl --request PATCH \
  --url https://your-instance.iw-erp.de/api/event/inventory_loan/42/42 \
  --header 'content-type: application/json' \
  --header 'x-iw-jwt-token: <TOKEN>' \
  --data '
{
  "condition": "string",
  "retained_amount": 49.9,
  "note": "string",
  "returned_at": "2026-10-15T09:30:00+02:00",
  "due_at": "2026-10-15T09:30:00+02:00",
  "force": true
}
'
Response 200 application/json
{
  "id": 42,
  "bookable_name": "Beispiel",
  "borrower_name": "Beispiel",
  "issued_by_name": "Beispiel",
  "returned_by_name": "Beispiel",
  "overdue": true,
  "deposit_refunded_amount": 49.9,
  "quantity": 1,
  "state": "string",
  "issued_at": "2026-10-15T09:30:00+02:00"
}

Own loans (all persons of the selected company); onlyLent=1 leaves out returned ones.

GET/api/event/customer/inventory_loan

Query parameters

idstring
statestring
bookablestring
bookingstringThe booking the item was reserved with (null only once the booking is deleted).
personstring
depositStatestring
issuedAtstring
dueAtstring
returnedAtstring
createdstring
updatedstring
searchStringstringtext to search for in the list
orderFieldNamestringname of the order field
orderFieldSortstringsorting modeAllowed: DESCASC
pageintegerpage of the list
pageSizeintegernumber of entries for each page
withMaxPageNumberstringreturns the number of pages available as a header if this is set

Responses

200Returns the own EventInventoryLoan objectsarray<EventInventoryLoan2>

Show fields (17)
  • overdueboolean
  • deposit_refunded_amountnumber (float)

    Amount paid back on return (deposit minus the retained part).

  • idinteger

    Primary key of the inventory loan. Internal ID.

  • bookable_namestring

    Name of the item at the time of the hand-over.

  • borrower_namestring

    Name of the borrower at the time, or the name typed in for somebody without a person.

  • quantityinteger

    Number of items lent out.

  • statestring

    State of the loan, for example issued or returned.

  • issued_atstring (date-time)

    Time the item was issued.

  • due_atstring (date-time)

    Time the item is due back.

  • returned_atstring (date-time)

    Time the item was returned.

  • deposit_amountnumber (float)

    Deposit paid for the loan.

  • deposit_statestring

    State of the deposit, for example held or refunded.

  • deposit_retained_amountnumber (float)

    Part of the deposit kept on return.

  • condition_on_issuestring

    Condition of the item when it was issued.

  • condition_on_returnstring

    Condition of the item when it was returned.

  • createdstring (date-time)

    Point in time the entity was created.

  • updatedstring (date-time)

    Point in time the entity was last updated.

Request
curl --request GET \
  --url https://your-instance.iw-erp.de/api/event/customer/inventory_loan \
  --header 'x-iw-jwt-token: <TOKEN>'
Response 200 application/json
[
  {
    "id": 42,
    "bookable_name": "Beispiel",
    "borrower_name": "Beispiel",
    "overdue": true,
    "deposit_refunded_amount": 49.9,
    "quantity": 1,
    "state": "string",
    "issued_at": "2026-10-15T09:30:00+02:00",
    "due_at": "2026-10-15T09:30:00+02:00",
    "returned_at": "2026-10-15T09:30:00+02:00"
  }
]