►  Read Item

curl –H  'X-api_key: {value}'  http://companyid.seasoo.net/api/Item/105

-> Return one JSON object of item.

►  Query Items

curl –H  'X-api_key: {value}'  http://companyid.seasoo.net/api/Item?name.matches{".*Mo.*"}

-> Return array of JSON object of item, its name contains "Mo" word.

name is filter-parameter. Following filter-parameters are supported:

Parameter

Type

Description

name

String

Name/PLU-code of item

description

String

Description of item

unitCost

Double

Cost for one unit of item

defaultQuantity

Double

Default quantity is used when user chooses item from invoice editor.

inventoryQuantity

Double

 

notice

String

 

►  Insert Item

POST/PUT   http://companyid.seasoo.net/api/Item

with api_key and following request body:

{"name":"54521",

  "description":"Monitor 21 inch, Manufacturer  Samsung",

  "unitCost":300.27,

  "defaultQuantity":1,

  "inventoryQuantity":20000

}

-> Response has http status code = 201 if successfully. Otherwise it returns status code 500.

►  Update Item

Like insert item, only URL is different:

POST/PUT http://companyid.seasoo.net/api/Item/{id}

with request body is content of item.

►  Delete Item

DELETE http://companyid.seasoo.net/api/Item/{id}

-> Response has status code = 204 in case of success and 404 in case of not success.