Difference between revisions of "Get All Items"

From MyMobileWorkers API
Jump to: navigation, search
(→‎Example curl request)
 
Line 90: Line 90:
 
== Example curl request ==
 
== Example curl request ==
  
−
curl "http://live.mymobileworkers.com:8080/api/1/items/all/?api_key=darrenwebapi"
+
curl "http://api.mymobileworkers.com:8080/api/1/items/all/?api_key=darrenwebapi"

Latest revision as of 12:41, 14 November 2016

Contents

[edit] Summary

Get All Items
URL http://:base_url/:api_path/:version/items/all
Type GET
Params: api_key required
Response JSON

The Get All Items method returns all items corresponding to the company making the method call.

[edit] Response Parameters

Field Description
name Item name
category Contains both category name and id for item
notes Item notes
price Item price
external_id Item external id
product_code Item product code

[edit] Example response

[
   {
      "name":"Bob",
      "category":{
         "external_id":"",
         "name":"Test Numero 1"
      },
      "notes":"\r\n\r\nThe Information Commissioner’s Office has fined Glasgow City Council £150,000 for losing two unencrypted laptops, one with the personal details of more than 20,000 people - just two years after a similar blunder.\r\n\r\nMore than 6,000 bank account details were held one of the stolen computers.\r\n\r\n“To find out that these poor practices have returned some two years later shows a flagrant disregard for the law and the people of Glasgow,” said the ICO’s assistant commissioner for Scotland Ken MacDonald. “The council should be held to account, and the penalty goes some way to achieving that.”\r\n\r\nThe ICO said that the two laptops were pinched from the council’s offices in May last year when the premises were being renovated. One of the machines was locked in a storage drawer, but the key was put in a drawer with the second laptop, which was unlocked.\r\n\r\nThe office was known to be insecure and a number of thefts had already been reported. The employees who were using the laptops had requested encryption without success.\r\n\r\nThe council’s creditor payment history file was stored on one computer, containing the personal information of 20,143 people including at least 6,000 bank account details.\r\n\r\nThe ICO had already warned Glasgow council about security, issuing an enforcement notice three years ago when an unencrypted memory stick with personal data on it was lost. Despite this, the council issued unencrypted laptops to staff when it had problems with its encryption software and 74 unencrypted machines are unaccounted for, with at least six known to have been stolen.\r\n\r\n“How an organisation can fail to notice that 74 unencrypted laptops have gone missing beggars belief,” MacDonald said.\r\n\r\n“The fact that these laptops have never been recovered and no record was made of the information stored on them, means that we will probably never know the true extent of this breach, or how many people’s details have been compromised.”\r\n\r\nA Glasgow City Council spokesman told the BBC: \"This data loss should not have happened and we took immediate steps to ensure it does not happen again. The ICO acknowledges there is no evidence that any bank accounts have been targeted, that the council immediately informed it of the theft and that we carried out significant remedial action.\" ®\r\n",
      "price":0.0,
      "external_id":"fibblewibble_01",
      "product_code":"TestProd"
   },
   {
      "name":"asfasdfasdf",
      "category":{
         "external_id":"",
         "name":"Test Numero 1"
      },
      "notes":null,
      "price":0.0,
      "external_id":null,
      "product_code":null
   },
   {
      "name":"darrenItem",
      "category":{
         "external_id":"",
         "name":"Test1"
      },
      "notes":"notesnotesnotesnotesnotesnotesnotesnotesnotesnotesnotes",
      "price":2.5,
      "external_id":"ss303",
      "product_code":"productCodeTest"
   }
]

[edit] Example curl request

curl "http://api.mymobileworkers.com:8080/api/1/items/all/?api_key=darrenwebapi"

Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox