{"activeVersionTag":"latest","latestAvailableVersionTag":"latest","collection":{"info":{"_postman_id":"615c8bb6-7b9b-4c87-bf16-0206cb371af7","name":"ViaCustomerApi Docs","description":"This collection describes the endpoints which allow Viametrics Customers to fetch their counter data via a REST API.\n\nThe consumer of the API contacts Viametric Support to receive a `ClientID` and `apiKey`. The `ClientID` is a **one to four-digit number** which corresponds to the customer's **company id** in the Viametrics Platform. Upon authenticating with the API the consumer receives a JSON Web Token which must be added to the `Authorization Header` of subsequent requests. The JSON Web Token is active for `10 minutes`. Once the token expires the consumer must re-authenticate with the API to receive a new ten-minute token.\n\n**NOTE:** The ClientID must always be present in the request header for rate limiting purposes. The limit is set to 500 requests per hour.\n\n## Keywords\n\n**Counter:** A counter and its corresponding id are what contains the counter data that is sent into the Viametrics Platform at customizable intervals. Counter data is presented as in-count (`I`) and out-count (`O`) once per export interval which is usually between 15 minutes and one hour.\n\n**CounterGroup:** CounterGroups are groupings of counters installed in a store, area or square, etc. The REST API currently only shares the CounterGroups that have been marked with the flag `FACILITY`.\n\n**CID/CustomerId/CompanyId:** This is a unique identifier for Viametics Clients. A `CID` contains all the counters and CounterGroups of a client. The API allows for access to several `CIDs`. This is particularly useful for consumers of the API which manages counter data for several customers (eg. Shopping Malls which usually have one `CID` per mall).\n\n## Fetching pattern\n\nDepending on your data delivery settings and use cases, you may want to fetch daily, hourly or sub-hourly to always have the latest updates. For these fetches, fetching the current day on every fetch is recommended. Data delivery usually happens with even period, for instance on full hour. Processing the data takes up to a few minutes, so fetching a few minutes later will increase the likelihood that the latest data is available.\n\nThere may be changes that happen outside the current day. To make sure that these updates reach you, a periodic historical fetch is recommended. Fetching the full last 2 weeks once or twice per week will collect almost all late data deliveries.\n\nIf you want to ensure data integrity going back even further, use `GetDailyDataForAllCounters` and compare daily totals. If there is a discrepancy, do a targeted refetch for that Counter and Date.","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","isPublicCollection":false,"owner":"10093925","team":655452,"collectionId":"615c8bb6-7b9b-4c87-bf16-0206cb371af7","publishedId":"SWLk4kiR","public":true,"publicUrl":"https://apidocs.viametrics.com","privateUrl":"https://go.postman.co/documentation/10093925-615c8bb6-7b9b-4c87-bf16-0206cb371af7","customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"C0087F"},"documentationLayout":"classic-double-column","customisation":null,"version":"8.11.6","publishDate":"2025-06-11T11:38:06.000Z","activeVersionTag":"latest","documentationTheme":"light","metaTags":{},"logos":{}},"statusCode":200},"environments":[{"name":"live","id":"f8703165-36ad-4d6b-9109-adf8aa5778a0","owner":"10093925","values":[{"key":"viafrontend","value":"https://api.viametrics.com","enabled":true},{"key":"viabackend","value":"http://ec2-34-245-220-140.eu-west-1.compute.amazonaws.com:8080/FrontControllerServlet","enabled":true},{"key":"via_estate_endpoint","value":"https://api2.viametrics.com","enabled":true},{"key":"viaestate","value":"https://estate.api.viametrics.com","enabled":true},{"key":"apiKey","value":"","enabled":true},{"key":"userId","value":"3366","enabled":true},{"key":"userToken","value":"221227D0C28A435D67C79ACD1D0834DB820357FF","enabled":true},{"key":"excelOutput","value":null,"enabled":true},{"key":"viamatrix","value":"https://matrix.api.viametrics.com","enabled":true},{"key":"viavisma","value":"http://r.viavisma.viabackend.com","enabled":true},{"key":"apcoa_token","value":"","enabled":true},{"key":"matrixJwt","value":"","enabled":true},{"key":"matrixRefresh","value":"","enabled":true},{"key":"viaPlatformToken","value":"","enabled":true},{"key":"email","value":"","enabled":false},{"key":"password","value":"","enabled":false},{"key":"currentMatrixUser","value":"","enabled":true},{"key":"viaApiTempToken","value":"","enabled":true},{"key":"viaadmin","value":"https://admin.viabackend.com","enabled":true},{"key":"vialink","value":"https://link.api.viametrics.com","enabled":true,"type":"default"},{"key":"viamatrixws","value":"wss://matrix.api.viametrics.com","enabled":true,"type":"default"},{"key":"viapns","value":"https://pns.api.viametrics.com","enabled":true,"type":"default"},{"key":"viaswitch","value":"https://switch.api.viametrics.com/","enabled":true,"type":"default"},{"key":"viaAuth","value":"https://auth.api.viametrics.com","enabled":true,"type":"default"},{"key":"trinity","value":"https://trinity.api.viametrics.com","enabled":true,"type":"default"},{"key":"trinityws","value":"wss://trinity.api.viametrics.com","enabled":true,"type":"default"},{"key":"trinityMatrix","value":"https://trinity.api.viametrics.com","enabled":true,"type":"default"},{"key":"viasubway","value":"https://subway.api.viametrics.com","enabled":true,"type":"default"},{"key":"viasubwayws","value":"wss://subway.api.viametrics.com","enabled":true,"type":"default"},{"key":"matrixRest","value":"","enabled":false,"type":"default"},{"key":"customerJwt","value":"","enabled":true,"type":"default"},{"key":"customerApiHeader","value":"","enabled":true,"type":"any"},{"key":"currentIP","value":"","enabled":true,"type":"any"},{"key":"lastIP","value":"","enabled":true,"type":"any"},{"key":"viamatrixws","value":"wss://matrix.api.viametrics.com","enabled":true,"type":"default"}],"published":true}],"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://res.cloudinary.com/postman/image/upload/t_team_logo_pubdoc/v1/team/60b3c1e95557fecb64498b060b3590631a7127e7e8bd48e09d43515b53259519","favicon":"https://viametrics.com/favicon.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"},{"label":"live","value":"10093925-f8703165-36ad-4d6b-9109-adf8aa5778a0"}],"canonicalUrl":"https://apidocs.viametrics.com/view/metadata/SWLk4kiR"}