List Identities
curl --request GET \
--url https://api.mailofly.com/identities \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.mailofly.com/identities"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.mailofly.com/identities', 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.mailofly.com/identities",
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://api.mailofly.com/identities"
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://api.mailofly.com/identities")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.mailofly.com/identities")
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{
"data": [
{
"id": "<string>",
"name": "<string>",
"provider_type": "<string>",
"smtp_host": {},
"smtp_port": {},
"smtp_username": {},
"google_email": {},
"custom_from_email": {},
"daily_mail_limit": 123,
"daily_mail_used": 123,
"created_at": "<string>"
}
]
}Identities
List Identities
List all configured sending identities / accounts.
GET
/
identities
List Identities
curl --request GET \
--url https://api.mailofly.com/identities \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.mailofly.com/identities"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.mailofly.com/identities', 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.mailofly.com/identities",
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://api.mailofly.com/identities"
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://api.mailofly.com/identities")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.mailofly.com/identities")
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{
"data": [
{
"id": "<string>",
"name": "<string>",
"provider_type": "<string>",
"smtp_host": {},
"smtp_port": {},
"smtp_username": {},
"google_email": {},
"custom_from_email": {},
"daily_mail_limit": 123,
"daily_mail_used": 123,
"created_at": "<string>"
}
]
}Returns all sender identities (SMTP and Google Workspace accounts) configured in your workspace, newest first. Sensitive credentials such as passwords and OAuth refresh tokens are never returned via the Mailofly API.
Dashboard-only creation: Sender identities cannot be created via the API. Connect your sending identities in the Mailofly Dashboard. Legacy compatibility:/v1/accountsis a deprecated alias supported for backward compatibility. Please use/v1/identities.
Response
object[]
Array of identity objects.
Show Identity properties
Show Identity properties
string
Unique identifier for the identity.
string
Display name for the identity.
string
Provider type:
smtp or google.string | null
SMTP server hostname (if SMTP).
number | null
SMTP port number (if SMTP).
string | null
SMTP username (if SMTP).
string | null
Connected Google account email (if Google).
string | null
Custom sender email address.
number
Maximum emails allowed per 24 hours.
number
Emails sent today.
string
ISO timestamp of creation.
⌘I
