cURL
curl --request GET \
--url https://app.dmarceye.com/api/domains \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.dmarceye.com/api/domains"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.dmarceye.com/api/domains', 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://app.dmarceye.com/api/domains",
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: Bearer <token>"
],
]);
$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://app.dmarceye.com/api/domains"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.dmarceye.com/api/domains")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.dmarceye.com/api/domains")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body[
{
"domain": "<string>",
"active": true,
"dmarc_record": "v=DMARC1; p=reject; rua=mailto:foo@bar.baz;",
"dmarc_policy": "reject",
"domain_usage_purpose": "business",
"created_at": "2024-06-10T19:55:26+00:00",
"updated_at": "2024-06-10T19:55:26+00:00"
}
]{
"message": "Unauthorized"
}{
"message": "Unauthorized"
}Domains
List Domains
Returns all domains from the system that the user has access to
GET
/
domains
cURL
curl --request GET \
--url https://app.dmarceye.com/api/domains \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.dmarceye.com/api/domains"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.dmarceye.com/api/domains', 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://app.dmarceye.com/api/domains",
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: Bearer <token>"
],
]);
$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://app.dmarceye.com/api/domains"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.dmarceye.com/api/domains")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.dmarceye.com/api/domains")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body[
{
"domain": "<string>",
"active": true,
"dmarc_record": "v=DMARC1; p=reject; rua=mailto:foo@bar.baz;",
"dmarc_policy": "reject",
"domain_usage_purpose": "business",
"created_at": "2024-06-10T19:55:26+00:00",
"updated_at": "2024-06-10T19:55:26+00:00"
}
]{
"message": "Unauthorized"
}{
"message": "Unauthorized"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Response
Domains response
Domain name
Indication of active domain
Example:
true
Current DMARC record of the domain
Example:
"v=DMARC1; p=reject; rua=mailto:foo@bar.baz;"
Current DMARC policy
Example:
"reject"
Declared usage purpose of the domain (may be null)
Available options:
business, personal, education, nonprofit, null Example:
"business"
Created at timestamp (RFC3339)
Example:
"2024-06-10T19:55:26+00:00"
Updated at timestamp (RFC3339)
Example:
"2024-06-10T19:55:26+00:00"
Was this page helpful?