{"_id":"59e70b9ee027ae002e7d2ef2","category":{"_id":"59e70b9ee027ae002e7d2ed6","version":"59e70b9ee027ae002e7d2ed2","project":"5496d393f52a630b00519cdd","__v":0,"sync":{"url":"","isSync":false},"reference":false,"createdAt":"2014-12-21T18:05:46.941Z","from_sync":false,"order":3,"slug":"rest-api","title":"REST API"},"user":"5496d353f52a630b00519cdc","project":"5496d393f52a630b00519cdd","parentDoc":null,"version":{"_id":"59e70b9ee027ae002e7d2ed2","project":"5496d393f52a630b00519cdd","__v":2,"createdAt":"2017-10-18T08:06:54.462Z","releaseDate":"2017-10-18T08:06:54.462Z","categories":["59e70b9ee027ae002e7d2ed3","59e70b9ee027ae002e7d2ed4","59e70b9ee027ae002e7d2ed5","59e70b9ee027ae002e7d2ed6","59e70b9ee027ae002e7d2ed7","59e70b9ee027ae002e7d2ed8","59e70b9ee027ae002e7d2ed9","59e70b9ee027ae002e7d2eda","59e70b9ee027ae002e7d2edb","59e70b9ee027ae002e7d2edc","59e70b9ee027ae002e7d2edd","59e70b9ee027ae002e7d2ede","59e70b9ee027ae002e7d2edf","5b8661ccdd19310003a3fa0b"],"is_deprecated":false,"is_hidden":false,"is_beta":true,"is_stable":true,"codename":"","version_clean":"2.0.10","version":"2.0.10"},"githubsync":"","__v":0,"updates":[],"next":{"pages":[],"description":""},"createdAt":"2015-05-27T14:05:53.204Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"results":{"codes":[]},"settings":"","method":"get","auth":"required","params":[],"url":""},"isReference":false,"order":11,"body":"[block:api-header]\n{\n  \"type\": \"basic\",\n  \"title\": \"Parameters\"\n}\n[/block]\n\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Field\",\n    \"h-1\": \"Description\",\n    \"h-2\": \"Type\",\n    \"h-3\": \"Example\",\n    \"0-0\": \"start_date\\n*(default= one week ago)*\",\n    \"2-0\": \"order\\n(default=\\n*desc)*\",\n    \"0-1\": \"Timeline start date.\",\n    \"0-2\": \"YYYY-MM-DD\",\n    \"0-3\": \"2013-12-25\",\n    \"2-1\": \"The results order:\\n  * **desc** - recent visits and transits will show first.\\n  \\n  * **asc** - older visits and transits will show first.\",\n    \"2-3\": \"desc\",\n    \"2-2\": \"string\",\n    \"1-0\": \"days_span\\n*(default=7)*\",\n    \"1-1\": \"The number of days returned, beginning with the date provided in \\\"start_date\\\".\",\n    \"1-2\": \"int\",\n    \"1-3\": \"7\",\n    \"3-0\": \"event_type\",\n    \"3-1\": \"Filter results:\\n* **visit** - returns only visit events.\\n\\n* **transit** - returns only transit events.\",\n    \"3-2\": \"string\",\n    \"3-3\": \"visit\"\n  },\n  \"cols\": 4,\n  \"rows\": 4\n}\n[/block]\n\n[block:api-header]\n{\n  \"type\": \"basic\",\n  \"title\": \"Response\"\n}\n[/block]\n\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Field\",\n    \"h-1\": \"Description\",\n    \"h-2\": \"Type\",\n    \"h-3\": \"Example\",\n    \"0-3\": \"e0fc05c3478926023\",\n    \"1-1\": \"Total count of objects that match the query.\",\n    \"2-1\": \"A list of timeline data objects. Objects will be sorted based on the chosen order.\",\n    \"2-2\": \"JSON array\\nof [Visit Structure](doc:visit) or [Transit Structure](doc:transit)\",\n    \"1-2\": \"int\",\n    \"1-3\": \"22\",\n    \"0-2\": \"string\",\n    \"0-1\": \"The device_id.\",\n    \"0-0\": \"device_id\",\n    \"1-0\": \"timeline_items_count\",\n    \"2-0\": \"timeline\",\n    \"3-0\": \"places\",\n    \"3-1\": \"A key value dictionary JSON with a the relevant places information.  \\nPlace ID is used as key.\",\n    \"3-2\": \"JSON\"\n  },\n  \"cols\": 4,\n  \"rows\": 4\n}\n[/block]","excerpt":"1 - HTTPS api.placer.io/v2/apps/**APP_KEY**/users/**USER_ID**/timeline\n\n2 - HTTPS api.placer.io/v2/apps/**APP_KEY**/devices/**DEVICE_ID**/timeline\n\n*User’s timeline provides a list of user visits and transits in a chronological order. Timeline is still in BETA and might be changed from time to time. Please contact us if you would like to be part of the BETA testing. *\n\nTimeline is related to device_id. If user_id is used to query (the first query URL template), results will be returned as a list of related device_ids with places for each device. For further information regarding the difference between user ID and device ID, please see [User_ID & Device_ID](doc:user_id--device_id) .","slug":"timeline","type":"endpoint","title":"Timeline"}

getTimeline

1 - HTTPS api.placer.io/v2/apps/**APP_KEY**/users/**USER_ID**/timeline 2 - HTTPS api.placer.io/v2/apps/**APP_KEY**/devices/**DEVICE_ID**/timeline *User’s timeline provides a list of user visits and transits in a chronological order. Timeline is still in BETA and might be changed from time to time. Please contact us if you would like to be part of the BETA testing. * Timeline is related to device_id. If user_id is used to query (the first query URL template), results will be returned as a list of related device_ids with places for each device. For further information regarding the difference between user ID and device ID, please see [User_ID & Device_ID](doc:user_id--device_id) .

[block:api-header] { "type": "basic", "title": "Parameters" } [/block] [block:parameters] { "data": { "h-0": "Field", "h-1": "Description", "h-2": "Type", "h-3": "Example", "0-0": "start_date\n*(default= one week ago)*", "2-0": "order\n(default=\n*desc)*", "0-1": "Timeline start date.", "0-2": "YYYY-MM-DD", "0-3": "2013-12-25", "2-1": "The results order:\n * **desc** - recent visits and transits will show first.\n \n * **asc** - older visits and transits will show first.", "2-3": "desc", "2-2": "string", "1-0": "days_span\n*(default=7)*", "1-1": "The number of days returned, beginning with the date provided in \"start_date\".", "1-2": "int", "1-3": "7", "3-0": "event_type", "3-1": "Filter results:\n* **visit** - returns only visit events.\n\n* **transit** - returns only transit events.", "3-2": "string", "3-3": "visit" }, "cols": 4, "rows": 4 } [/block] [block:api-header] { "type": "basic", "title": "Response" } [/block] [block:parameters] { "data": { "h-0": "Field", "h-1": "Description", "h-2": "Type", "h-3": "Example", "0-3": "e0fc05c3478926023", "1-1": "Total count of objects that match the query.", "2-1": "A list of timeline data objects. Objects will be sorted based on the chosen order.", "2-2": "JSON array\nof [Visit Structure](doc:visit) or [Transit Structure](doc:transit)", "1-2": "int", "1-3": "22", "0-2": "string", "0-1": "The device_id.", "0-0": "device_id", "1-0": "timeline_items_count", "2-0": "timeline", "3-0": "places", "3-1": "A key value dictionary JSON with a the relevant places information. \nPlace ID is used as key.", "3-2": "JSON" }, "cols": 4, "rows": 4 } [/block]