Get a list of emails of the current user.
curl --request GET \
--url https://{tenant_id}.hanko.io/emails \
--cookie hanko=import requests
url = "https://{tenant_id}.hanko.io/emails"
headers = {"cookie": "hanko="}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {cookie: 'hanko='}};
fetch('https://{tenant_id}.hanko.io/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://{tenant_id}.hanko.io/emails",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_COOKIE => "hanko=",
]);
$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://{tenant_id}.hanko.io/emails"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("cookie", "hanko=")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{tenant_id}.hanko.io/emails")
.header("cookie", "hanko=")
.asString();require 'uri'
require 'net/http'
url = URI("https://{tenant_id}.hanko.io/emails")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["cookie"] = 'hanko='
response = http.request(request)
puts response.read_body[
{
"id": "5333cc5b-c7c4-48cf-8248-9c184ac72b65",
"address": "john.doe@example.com",
"is_verified": true,
"is_primary": false
}
]{
"code": 401,
"message": "Unauthorized"
}{
"code": 500,
"message": "Internal Server Error"
}Email Management
Get a list of emails of the current user.
deprecated
GET
/
emails
Get a list of emails of the current user.
curl --request GET \
--url https://{tenant_id}.hanko.io/emails \
--cookie hanko=import requests
url = "https://{tenant_id}.hanko.io/emails"
headers = {"cookie": "hanko="}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {cookie: 'hanko='}};
fetch('https://{tenant_id}.hanko.io/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://{tenant_id}.hanko.io/emails",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_COOKIE => "hanko=",
]);
$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://{tenant_id}.hanko.io/emails"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("cookie", "hanko=")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{tenant_id}.hanko.io/emails")
.header("cookie", "hanko=")
.asString();require 'uri'
require 'net/http'
url = URI("https://{tenant_id}.hanko.io/emails")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["cookie"] = 'hanko='
response = http.request(request)
puts response.read_body[
{
"id": "5333cc5b-c7c4-48cf-8248-9c184ac72b65",
"address": "john.doe@example.com",
"is_verified": true,
"is_primary": false
}
]{
"code": 401,
"message": "Unauthorized"
}{
"code": 500,
"message": "Internal Server Error"
}Deprecated. Please use the Flow API instead. What’s the Flow API?.
Authorizations
CookieAuthBearerTokenAuth
Response
A list of emails assigned to the current user
The ID of the email address
Example:
"c339547d-e17d-4ba7-8a1d-b3d5a4d17c1c"
The email address
Indicated the email has been verified.
Indicates it's the primary email address.
Deprecated, use user.identities instead.
Show child attributes
Show child attributes
Deprecated, use user.identities instead.
Show child attributes
Show child attributes
Example:
[
{
"id": "5333cc5b-c7c4-48cf-8248-9c184ac72b65",
"address": "john.doe@example.com",
"is_verified": true,
"is_primary": false
}
]
Was this page helpful?
⌘I