List emails
curl --request GET \
--url https://api.attention.tech/v2/emails \
--header 'Authorization: <api-key>'import requests
url = "https://api.attention.tech/v2/emails"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://api.attention.tech/v2/emails', 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.attention.tech/v2/emails",
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: <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.attention.tech/v2/emails"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<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.attention.tech/v2/emails")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.attention.tech/v2/emails")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"data": [
{
"messageId": "123e4567-e89b-12d3-a456-426614174000",
"threadId": "thread_789f0123-g45h-67i8-j901-234567890123",
"sendDate": "2024-03-15T14:30:00Z",
"sender": "john.doe@company.com",
"recipients": [
"jane.smith@company.com",
"bob.johnson@company.com"
],
"ccRecipients": [
"manager@company.com",
"team@company.com"
],
"subject": "Project Update - Q1 2024 Report",
"snippet": "Hi team, I wanted to share the latest updates on our Q1 project...",
"bodyUrl": "https://api.company.com/emails/123e4567-e89b-12d3-a456-426614174000/body",
"isInternalUser": false
}
],
"meta": {
"pageCount": 5,
"totalRecords": 100,
"pageNumber": 1,
"pageSize": 20
}
}{
"id": "not_found_error",
"status": "404",
"code": "404",
"title": "Not Found Error",
"detail": "The requested resource was not found",
"source": {
"pointer": "/data/attributes/id"
}
}{
"id": "not_found_error",
"status": "404",
"code": "404",
"title": "Not Found Error",
"detail": "The requested resource was not found",
"source": {
"pointer": "/data/attributes/id"
}
}Email
List emails
Returns a list of emails
GET
/
emails
List emails
curl --request GET \
--url https://api.attention.tech/v2/emails \
--header 'Authorization: <api-key>'import requests
url = "https://api.attention.tech/v2/emails"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://api.attention.tech/v2/emails', 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.attention.tech/v2/emails",
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: <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.attention.tech/v2/emails"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<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.attention.tech/v2/emails")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.attention.tech/v2/emails")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"data": [
{
"messageId": "123e4567-e89b-12d3-a456-426614174000",
"threadId": "thread_789f0123-g45h-67i8-j901-234567890123",
"sendDate": "2024-03-15T14:30:00Z",
"sender": "john.doe@company.com",
"recipients": [
"jane.smith@company.com",
"bob.johnson@company.com"
],
"ccRecipients": [
"manager@company.com",
"team@company.com"
],
"subject": "Project Update - Q1 2024 Report",
"snippet": "Hi team, I wanted to share the latest updates on our Q1 project...",
"bodyUrl": "https://api.company.com/emails/123e4567-e89b-12d3-a456-426614174000/body",
"isInternalUser": false
}
],
"meta": {
"pageCount": 5,
"totalRecords": 100,
"pageNumber": 1,
"pageSize": 20
}
}{
"id": "not_found_error",
"status": "404",
"code": "404",
"title": "Not Found Error",
"detail": "The requested resource was not found",
"source": {
"pointer": "/data/attributes/id"
}
}{
"id": "not_found_error",
"status": "404",
"code": "404",
"title": "Not Found Error",
"detail": "The requested resource was not found",
"source": {
"pointer": "/data/attributes/id"
}
}Authorizations
Query Parameters
Filter emails by subject using case-insensitive partial matching
Filter emails by CRM account id
Filter emails by deal uuid
Start date and time for filtering emails (ISO 8601 format)
End date and time for filtering emails (ISO 8601 format)
Page number for pagination (starts from 1)
Required range:
x >= 1Number of items per page (min 1, max 50)
Required range:
1 <= x <= 50Was this page helpful?
⌘I