Get All Websites
curl --request GET \
--url https://api.aimtell.com/prod/sites/ \
--header 'X-Authorization-Api-Key: <api-key>'import requests
url = "https://api.aimtell.com/prod/sites/"
headers = {"X-Authorization-Api-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-Authorization-Api-Key': '<api-key>'}};
fetch('https://api.aimtell.com/prod/sites/', 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.aimtell.com/prod/sites/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-Authorization-Api-Key: <api-key>"
],
]);
$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.aimtell.com/prod/sites/"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Authorization-Api-Key", "<api-key>")
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.aimtell.com/prod/sites/")
.header("X-Authorization-Api-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aimtell.com/prod/sites/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Authorization-Api-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body[
{
"id": 179,
"uid": "76cedd11b19e",
"url": "https://demo.aimtell.com",
"name": "Demo Website",
"icon": "https://s3.amazonaws.com/siteicons.aimtell.com/icon_40_1443032714..jpg",
"promptId": 0,
"webPushID": null,
"auto_prompt": 1,
"createdAt": "2015-12-28 17:54:42",
"active": 1
},
{
"id": 999,
"uid": "76cedd11b19e",
"url": "https://example.aimtell.com",
"name": "Example Aimtell ",
"icon": "https://s3.amazonaws.com/siteicons.aimtell.com/icon_999_1485981616.png",
"promptId": 200,
"webPushID": "web.20.aimtell.com",
"auto_prompt": 1,
"createdAt": "2016-06-01 21:40:05",
"active": 1
},
{
"id": 2634,
"uid": "76cedd11b19e",
"url": "https://wordpress.aimtell.com",
"name": "wordpress site",
"icon": "https://s3.amazonaws.com/siteicons.aimtell.com/icon_2634_1487894753.png",
"promptId": null,
"webPushID": "web.16.aimtell.com",
"auto_prompt": 1,
"createdAt": "2017-02-24 00:07:25",
"active": 1
}
]{
"result": "error",
"message": "Invalid token.",
"error_code": 71831
}Websites
Get All Websites
Grabs all active websites for account.
GET
/
prod
/
sites
/
Get All Websites
curl --request GET \
--url https://api.aimtell.com/prod/sites/ \
--header 'X-Authorization-Api-Key: <api-key>'import requests
url = "https://api.aimtell.com/prod/sites/"
headers = {"X-Authorization-Api-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-Authorization-Api-Key': '<api-key>'}};
fetch('https://api.aimtell.com/prod/sites/', 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.aimtell.com/prod/sites/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-Authorization-Api-Key: <api-key>"
],
]);
$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.aimtell.com/prod/sites/"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Authorization-Api-Key", "<api-key>")
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.aimtell.com/prod/sites/")
.header("X-Authorization-Api-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aimtell.com/prod/sites/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Authorization-Api-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body[
{
"id": 179,
"uid": "76cedd11b19e",
"url": "https://demo.aimtell.com",
"name": "Demo Website",
"icon": "https://s3.amazonaws.com/siteicons.aimtell.com/icon_40_1443032714..jpg",
"promptId": 0,
"webPushID": null,
"auto_prompt": 1,
"createdAt": "2015-12-28 17:54:42",
"active": 1
},
{
"id": 999,
"uid": "76cedd11b19e",
"url": "https://example.aimtell.com",
"name": "Example Aimtell ",
"icon": "https://s3.amazonaws.com/siteicons.aimtell.com/icon_999_1485981616.png",
"promptId": 200,
"webPushID": "web.20.aimtell.com",
"auto_prompt": 1,
"createdAt": "2016-06-01 21:40:05",
"active": 1
},
{
"id": 2634,
"uid": "76cedd11b19e",
"url": "https://wordpress.aimtell.com",
"name": "wordpress site",
"icon": "https://s3.amazonaws.com/siteicons.aimtell.com/icon_2634_1487894753.png",
"promptId": null,
"webPushID": "web.16.aimtell.com",
"auto_prompt": 1,
"createdAt": "2017-02-24 00:07:25",
"active": 1
}
]{
"result": "error",
"message": "Invalid token.",
"error_code": 71831
}⌘I

