cURL
curl --request POST \
--url https://api.litlyx.com/api/v1/events \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"rows": [
"<string>"
],
"limit": 100,
"from": "`2024-01-01T00:00:00+0000`",
"to": "`current date as ISO`"
}
'import requests
url = "https://api.litlyx.com/api/v1/events"
payload = {
"rows": ["<string>"],
"limit": 100,
"from": "`2024-01-01T00:00:00+0000`",
"to": "`current date as ISO`"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
rows: ['<string>'],
limit: 100,
from: '`2024-01-01T00:00:00+0000`',
to: '`current date as ISO`'
})
};
fetch('https://api.litlyx.com/api/v1/events', 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.litlyx.com/api/v1/events",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'rows' => [
'<string>'
],
'limit' => 100,
'from' => '`2024-01-01T00:00:00+0000`',
'to' => '`current date as ISO`'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.litlyx.com/api/v1/events"
payload := strings.NewReader("{\n \"rows\": [\n \"<string>\"\n ],\n \"limit\": 100,\n \"from\": \"`2024-01-01T00:00:00+0000`\",\n \"to\": \"`current date as ISO`\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.litlyx.com/api/v1/events")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"rows\": [\n \"<string>\"\n ],\n \"limit\": 100,\n \"from\": \"`2024-01-01T00:00:00+0000`\",\n \"to\": \"`current date as ISO`\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.litlyx.com/api/v1/events")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"rows\": [\n \"<string>\"\n ],\n \"limit\": 100,\n \"from\": \"`2024-01-01T00:00:00+0000`\",\n \"to\": \"`current date as ISO`\"\n}"
response = http.request(request)
puts response.read_body[
{}
]{
"error": 123,
"message": "<string>"
}Events
Retrieve raw data for events collected with Litlyx.
cURL
curl --request POST \
--url https://api.litlyx.com/api/v1/events \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"rows": [
"<string>"
],
"limit": 100,
"from": "`2024-01-01T00:00:00+0000`",
"to": "`current date as ISO`"
}
'import requests
url = "https://api.litlyx.com/api/v1/events"
payload = {
"rows": ["<string>"],
"limit": 100,
"from": "`2024-01-01T00:00:00+0000`",
"to": "`current date as ISO`"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
rows: ['<string>'],
limit: 100,
from: '`2024-01-01T00:00:00+0000`',
to: '`current date as ISO`'
})
};
fetch('https://api.litlyx.com/api/v1/events', 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.litlyx.com/api/v1/events",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'rows' => [
'<string>'
],
'limit' => 100,
'from' => '`2024-01-01T00:00:00+0000`',
'to' => '`current date as ISO`'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.litlyx.com/api/v1/events"
payload := strings.NewReader("{\n \"rows\": [\n \"<string>\"\n ],\n \"limit\": 100,\n \"from\": \"`2024-01-01T00:00:00+0000`\",\n \"to\": \"`current date as ISO`\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.litlyx.com/api/v1/events")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"rows\": [\n \"<string>\"\n ],\n \"limit\": 100,\n \"from\": \"`2024-01-01T00:00:00+0000`\",\n \"to\": \"`current date as ISO`\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.litlyx.com/api/v1/events")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"rows\": [\n \"<string>\"\n ],\n \"limit\": 100,\n \"from\": \"`2024-01-01T00:00:00+0000`\",\n \"to\": \"`current date as ISO`\"\n}"
response = http.request(request)
puts response.read_body[
{}
]{
"error": 123,
"message": "<string>"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
application/json
Array of strings selecting the rows you want the API to return. Possible values: name,metadata,created_at,session.
How many element the API should return.
From what day the API will return the data. Format: ISO.
To what day the API will return the data. Format: ISO.
Response
API response