Résumé des statistiques d'espace de travail
curl --request GET \
--url https://api.taap.it/v1/stats/workspaces/summary \
--header 'Authorization: <authorization>'import requests
url = "https://api.taap.it/v1/stats/workspaces/summary"
headers = {"Authorization": "<authorization>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<authorization>'}};
fetch('https://api.taap.it/v1/stats/workspaces/summary', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.taap.it/v1/stats/workspaces/summary",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.taap.it/v1/stats/workspaces/summary"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<authorization>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.taap.it/v1/stats/workspaces/summary")
.header("Authorization", "<authorization>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.taap.it/v1/stats/workspaces/summary")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<authorization>'
response = http.request(request)
puts response.read_body{
"total_clicks": 123,
"top_countries": [
{
"name": "<string>",
"count": 123
}
],
"top_devices": [
{
"name": "<string>",
"count": 123
}
],
"top_browsers": [
{
"name": "<string>",
"count": 123
}
],
"qr_code_usage": 123,
"date_range": {
"start": "<string>",
"end": "<string>"
}
}API Statistiques
Résumé des statistiques d'espace de travail
Récupérer un résumé des métriques clés pour votre espace de travail
GET
/
v1
/
stats
/
workspaces
/
summary
Résumé des statistiques d'espace de travail
curl --request GET \
--url https://api.taap.it/v1/stats/workspaces/summary \
--header 'Authorization: <authorization>'import requests
url = "https://api.taap.it/v1/stats/workspaces/summary"
headers = {"Authorization": "<authorization>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<authorization>'}};
fetch('https://api.taap.it/v1/stats/workspaces/summary', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.taap.it/v1/stats/workspaces/summary",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.taap.it/v1/stats/workspaces/summary"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<authorization>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.taap.it/v1/stats/workspaces/summary")
.header("Authorization", "<authorization>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.taap.it/v1/stats/workspaces/summary")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<authorization>'
response = http.request(request)
puts response.read_body{
"total_clicks": 123,
"top_countries": [
{
"name": "<string>",
"count": 123
}
],
"top_devices": [
{
"name": "<string>",
"count": 123
}
],
"top_browsers": [
{
"name": "<string>",
"count": 123
}
],
"qr_code_usage": 123,
"date_range": {
"start": "<string>",
"end": "<string>"
}
}Requête :
Réponse :
cURL
curl -X GET 'https://api.taap.it/v1/stats/workspaces/summary?start_date=2024-01-01&end_date=2024-01-31' \
-H 'Authorization: Bearer taapit_your_api_key_here'
{
"total_clicks": 15750,
"top_countries": [
{"name": "US", "count": 8250},
{"name": "CA", "count": 3150},
{"name": "UK", "count": 2250}
],
"top_devices": [
{"name": "mobile", "count": 9450},
{"name": "desktop", "count": 5250},
{"name": "tablet", "count": 1050}
],
"top_browsers": [
{"name": "Chrome", "count": 10000},
{"name": "Safari", "count": 3750},
{"name": "Firefox", "count": 1500}
],
"qr_code_usage": 525,
"date_range": {
"start": "2024-01-01",
"end": "2024-01-31"
}
}
Autorisation
string
requis
Token Bearer pour l’authentification API. Format :
Bearer YOUR_API_KEYParamètres de requête
string
Date de début pour les statistiques (format YYYY-MM-DD)
string
Date de fin pour les statistiques (format YYYY-MM-DD)
Champs de réponse
integer
requis
Nombre total de clics across all links in the workspace
array
requis
array
requis
array
requis
integer
requis
Nombre total de scans de codes QR sur tous les liens de l’espace de travail