{"activeVersionTag":"latest","latestAvailableVersionTag":"latest","collection":{"info":{"_postman_id":"0d282c33-faf6-4c0e-9d75-fad56654a51a","name":"BlueZoo API Suite","description":"## **1\\. Introduction**\n\n**The BlueZoo API suite exposes sensor data for two technologies, Wi-Fi and Bluetooth Low Energy (BLE). Each has a Data Warehouse (DWH) API for historical data and a Real-Time API for current data:**\n\n|  | **Data warehouse APIs  <br>(data available with up to two-hour delay)** | **Real time APIs** |\n| --- | --- | --- |\n| **Wi-Fi measurements / analytics** | Historical Wi-Fi data:   impressions/visits, dwell time, occupancy/visitors, unique visitors and recurrence, flow transitions, flow correlations  <br>  <br>[https://hermes.apollo.bluezoo.io/v2/dwh](https://apollo-api.bluefoxengage.com/v2/dwh) | Live Wi-Fi data: Most recent occupancy (visitor) and visit (impressions) data  <br>  <br>[https://hermes.apollo.bluezoo.io/v2](https://hermes.apollo.bluezoo.io/v2) |\n| **BLE measurements / analytics** | Historical BLE data: visits (impressions), dwell time, visitors (occupancy)  <br>  <br>[https://hermes.apollo.bluezoo.io/v2/dwh](https://hermes.apollo.bluezoo.io/v3/dwh) | Live BLE data: Windowed impressions (for presence-to-play pairing), occupancy  <br>  <br>[https://hermes.apollo.bluezoo.io/v3](https://hermes.apollo.bluezoo.io/v3) |\n\n### **Which endpoint should I use?**\n\n| **I want to know...** | **Use** |\n| --- | --- |\n| Historical data for a Wi-Fi-enabled sensor location | The data warehouse APIs (list_table, desc_table, run_query) for Wi-Fi tables (sensor_visits) |\n| Historical data for a BLE-enabled sensor location | The data warehouse APIs (list_table, desc_table, run_query) for BLE tables (e.g. sensor_ble_visits) |\n| The latest occupancy and visits for a Wi-Fi location | Real-Time API for Wi-Fi (get_occupancy_count, get_visits) |\n| How long BLE devices stay near a sensor | The data warehouse APIs (list_table, desc_table, run_query) for BLE table (sensor_ble_dwell) |\n| How many BLE devices are present at once (min / max / avg) | The data warehouse APIs (list_table, desc_table, run_query) for BLE table (sensor_ble_visitors) |\n| How many BLE devices enter or leave | The data warehouse APIs (list_table, desc_table, run_query) for BLE table (sensor_ble_visits) |\n| How many BLE impressions occurred per period | The data warehouse APIs (list_table, desc_table, run_query) for BLE table  <br>(sensor_ble_Impressions) |\n| The BLE occupancy right now | The real-time BLE API for Live occupancy (get_ble_live_occupancy) |\n| BLE impressions from hh:mm:ss to hh:mm:ss for a specific sensor to establish advertisement presence and pairing for a specific advertisement | The real-time BLE API for impressions (get_ble_impressions) |\n\n## **2\\. Authentication and Access**\n\n**All requests require an Access key and an analyst/admin/Super Admin-level role.**\n\n**Getting your access key:**\n\n**The key is on the Profile screen of the BlueZoo dashboard. There is one per user, and BlueZoo recommends the primary user's key for development. The key string itself starts with AccessKey (with a trailing space) and is sent as the bearer token in the Authorization header (**[<b>BlueZoo support</b>](https://support.bluezoo.io/hc/en-us/articles/11260595031447-How-do-I-access-data-in-the-data-warehouse)**). Both Wi-Fi and BLE API’s use the same access key.**\n\n## **3\\. Conventions**\n\n## **3.1 Common identity fields (DWH)**\n\nEvery DWH row carries the same descriptive fields:\n\n| **Field** | **Type** | **Mode** | **Description** |\n| --- | --- | --- | --- |\n| sensor_id | INTEGER | REQUIRED | Unique sensor identifier |\n| sensor_name | STRING | REQUIRED | Name assigned to the sensor |\n| sensor_mac | STRING | REQUIRED | MAC address of the sensor |\n| account_id | STRING | REQUIRED | Account ID |\n| account_name | STRING | REQUIRED | Account name |\n| timestamp | TIMESTAMP | REQUIRED | Start of the aggregation period stored in UTC |\n| time_zone | STRING | NULLABLE | Local time zone of the sensor |\n\n### **3.2 Terminology**\n\n| **Term** | **Meaning** |\n| --- | --- |\n| Inner detection zone / outer detection zone | Two spatial boundaries around a sensor. Inner is the closer zone; outer is the more distant zone.  The two zones are non-overlapping. |\n| Visits (both dwh and real time analytic) | A device entering or leaving the sensor’s detection zone. Each completed entry-to-exit generates one visit, counted in the 15-minute window where the entry or exit occurs. Aggregations over time should be summed |\n| Visitors (both dwh and real time analytic) | Number of devices concurrently within a boundary/defined detection zone; the analytic is delivered as min / average / max for a 15-minute period. Aggregations over time should be averaged. |\n| Dwell time (dwh analytic) | How long a device remains within the sensor's detection zone. |\n| Windowed impressions (real time analytic) | A count of impressions delivered during an ad's time slot. It counts every visit session that is ongoing at any point during the slot, including visits that started before (and ended after) the slot began.  <br>  <br>As a result “windowed impressions” are not additive over time. Visits recorded in the data warehouse are additive over time because they record the number of visits that start and the number of visits that end. |","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","isPublicCollection":false,"owner":"14323059","team":1619545,"collectionId":"0d282c33-faf6-4c0e-9d75-fad56654a51a","publishedId":"TWDfDDRS","public":true,"publicUrl":"https://api.bluezoo.io","privateUrl":"https://go.postman.co/documentation/14323059-0d282c33-faf6-4c0e-9d75-fad56654a51a","customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"EF5B25"},"documentationLayout":"classic-double-column","customisation":null,"version":"8.12.12","publishDate":"2021-07-27T20:47:29.000Z","activeVersionTag":"latest","documentationTheme":"light","metaTags":{},"logos":{}},"statusCode":200},"environments":[],"user":{"authenticated":false,"permissions":{"publish":false}},"run":{"button":{"js":"https://run.pstmn.io/button.js","css":"https://run.pstmn.io/button.css"}},"web":"https://www.getpostman.com/","team":{"logo":"https://postman-image-service.postman.com/api/cloudinary-proxy/postman/image/upload/t_team_logo_pubdoc/v1/team/cb49d14a4bc9f36556ac3812175e91b92101671f35f99b5ee6b4c040b170901b","favicon":"https://res.cloudinary.com/postman/image/upload/v1614973903/team/xuwhaycpke6rmy6mtiyo.ico"},"isEnvFetchError":false,"languages":"[{\"key\":\"csharp\",\"label\":\"C#\",\"variant\":\"HttpClient\"},{\"key\":\"csharp\",\"label\":\"C#\",\"variant\":\"RestSharp\"},{\"key\":\"curl\",\"label\":\"cURL\",\"variant\":\"cURL\"},{\"key\":\"dart\",\"label\":\"Dart\",\"variant\":\"http\"},{\"key\":\"go\",\"label\":\"Go\",\"variant\":\"Native\"},{\"key\":\"http\",\"label\":\"HTTP\",\"variant\":\"HTTP\"},{\"key\":\"java\",\"label\":\"Java\",\"variant\":\"OkHttp\"},{\"key\":\"java\",\"label\":\"Java\",\"variant\":\"Unirest\"},{\"key\":\"javascript\",\"label\":\"JavaScript\",\"variant\":\"Fetch\"},{\"key\":\"javascript\",\"label\":\"JavaScript\",\"variant\":\"jQuery\"},{\"key\":\"javascript\",\"label\":\"JavaScript\",\"variant\":\"XHR\"},{\"key\":\"c\",\"label\":\"C\",\"variant\":\"libcurl\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Axios\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Native\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Request\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Unirest\"},{\"key\":\"objective-c\",\"label\":\"Objective-C\",\"variant\":\"NSURLSession\"},{\"key\":\"ocaml\",\"label\":\"OCaml\",\"variant\":\"Cohttp\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"cURL\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"Guzzle\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"HTTP_Request2\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"pecl_http\"},{\"key\":\"powershell\",\"label\":\"PowerShell\",\"variant\":\"RestMethod\"},{\"key\":\"python\",\"label\":\"Python\",\"variant\":\"http.client\"},{\"key\":\"python\",\"label\":\"Python\",\"variant\":\"Requests\"},{\"key\":\"r\",\"label\":\"R\",\"variant\":\"httr\"},{\"key\":\"r\",\"label\":\"R\",\"variant\":\"RCurl\"},{\"key\":\"ruby\",\"label\":\"Ruby\",\"variant\":\"Net::HTTP\"},{\"key\":\"shell\",\"label\":\"Shell\",\"variant\":\"Httpie\"},{\"key\":\"shell\",\"label\":\"Shell\",\"variant\":\"wget\"},{\"key\":\"swift\",\"label\":\"Swift\",\"variant\":\"URLSession\"}]","languageSettings":[{"key":"csharp","label":"C#","variant":"HttpClient"},{"key":"csharp","label":"C#","variant":"RestSharp"},{"key":"curl","label":"cURL","variant":"cURL"},{"key":"dart","label":"Dart","variant":"http"},{"key":"go","label":"Go","variant":"Native"},{"key":"http","label":"HTTP","variant":"HTTP"},{"key":"java","label":"Java","variant":"OkHttp"},{"key":"java","label":"Java","variant":"Unirest"},{"key":"javascript","label":"JavaScript","variant":"Fetch"},{"key":"javascript","label":"JavaScript","variant":"jQuery"},{"key":"javascript","label":"JavaScript","variant":"XHR"},{"key":"c","label":"C","variant":"libcurl"},{"key":"nodejs","label":"NodeJs","variant":"Axios"},{"key":"nodejs","label":"NodeJs","variant":"Native"},{"key":"nodejs","label":"NodeJs","variant":"Request"},{"key":"nodejs","label":"NodeJs","variant":"Unirest"},{"key":"objective-c","label":"Objective-C","variant":"NSURLSession"},{"key":"ocaml","label":"OCaml","variant":"Cohttp"},{"key":"php","label":"PHP","variant":"cURL"},{"key":"php","label":"PHP","variant":"Guzzle"},{"key":"php","label":"PHP","variant":"HTTP_Request2"},{"key":"php","label":"PHP","variant":"pecl_http"},{"key":"powershell","label":"PowerShell","variant":"RestMethod"},{"key":"python","label":"Python","variant":"http.client"},{"key":"python","label":"Python","variant":"Requests"},{"key":"r","label":"R","variant":"httr"},{"key":"r","label":"R","variant":"RCurl"},{"key":"ruby","label":"Ruby","variant":"Net::HTTP"},{"key":"shell","label":"Shell","variant":"Httpie"},{"key":"shell","label":"Shell","variant":"wget"},{"key":"swift","label":"Swift","variant":"URLSession"}],"languageOptions":[{"label":"C# - HttpClient","value":"csharp - HttpClient - C#"},{"label":"C# - RestSharp","value":"csharp - RestSharp - C#"},{"label":"cURL - cURL","value":"curl - cURL - cURL"},{"label":"Dart - http","value":"dart - http - Dart"},{"label":"Go - Native","value":"go - Native - Go"},{"label":"HTTP - HTTP","value":"http - HTTP - HTTP"},{"label":"Java - OkHttp","value":"java - OkHttp - Java"},{"label":"Java - Unirest","value":"java - Unirest - Java"},{"label":"JavaScript - Fetch","value":"javascript - Fetch - JavaScript"},{"label":"JavaScript - jQuery","value":"javascript - jQuery - JavaScript"},{"label":"JavaScript - XHR","value":"javascript - XHR - JavaScript"},{"label":"C - libcurl","value":"c - libcurl - C"},{"label":"NodeJs - Axios","value":"nodejs - Axios - NodeJs"},{"label":"NodeJs - Native","value":"nodejs - Native - NodeJs"},{"label":"NodeJs - Request","value":"nodejs - Request - NodeJs"},{"label":"NodeJs - Unirest","value":"nodejs - Unirest - NodeJs"},{"label":"Objective-C - NSURLSession","value":"objective-c - NSURLSession - Objective-C"},{"label":"OCaml - Cohttp","value":"ocaml - Cohttp - OCaml"},{"label":"PHP - cURL","value":"php - cURL - PHP"},{"label":"PHP - Guzzle","value":"php - Guzzle - PHP"},{"label":"PHP - HTTP_Request2","value":"php - HTTP_Request2 - PHP"},{"label":"PHP - pecl_http","value":"php - pecl_http - PHP"},{"label":"PowerShell - RestMethod","value":"powershell - RestMethod - PowerShell"},{"label":"Python - http.client","value":"python - http.client - Python"},{"label":"Python - Requests","value":"python - Requests - Python"},{"label":"R - httr","value":"r - httr - R"},{"label":"R - RCurl","value":"r - RCurl - R"},{"label":"Ruby - Net::HTTP","value":"ruby - Net::HTTP - Ruby"},{"label":"Shell - Httpie","value":"shell - Httpie - Shell"},{"label":"Shell - wget","value":"shell - wget - Shell"},{"label":"Swift - URLSession","value":"swift - URLSession - Swift"}],"layoutOptions":[{"value":"classic-single-column","label":"Single Column"},{"value":"classic-double-column","label":"Double Column"}],"versionOptions":[],"environmentOptions":[{"value":"0","label":"No Environment"}],"canonicalUrl":"https://api.bluezoo.io/view/metadata/TWDfDDRS"}