curl --request POST \
--url https://dev.namify.host/api/v1/customers/auto-login \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"email": "john.doe@example.com"
}
'import requests
url = "https://dev.namify.host/api/v1/customers/auto-login"
payload = { "email": "john.doe@example.com" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({email: 'john.doe@example.com'})
};
fetch('https://dev.namify.host/api/v1/customers/auto-login', 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://dev.namify.host/api/v1/customers/auto-login",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'email' => 'john.doe@example.com'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://dev.namify.host/api/v1/customers/auto-login"
payload := strings.NewReader("{\n \"email\": \"john.doe@example.com\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://dev.namify.host/api/v1/customers/auto-login")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"email\": \"john.doe@example.com\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://dev.namify.host/api/v1/customers/auto-login")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"email\": \"john.doe@example.com\"\n}"
response = http.request(request)
puts response.read_body{
"status": "SUCCESS",
"email": "john.doe@example.com",
"token": "214844e15411d2f6e72b274ca199760656218b57e5329243ce23e6ad7c2e1c97",
"expires_at": "2026-04-24 09:48:34"
}{
"message": "Unauthorized"
}{
"status": "ERROR",
"message": "Invalid customer email"
}Auto-Login
Generates a short-lived authentication token for an existing customer account, identified by their email address.
Use case: Pass the returned token as a query parameter in the auto-login redirect URL to log the customer into their account without requiring a password. This is intended for partner-initiated flows — for example, redirecting a customer from your platform directly into their Namify control panel.
Token expiry: Tokens are valid for a short window. Redirect the customer immediately after calling this endpoint — do not store or reuse the token.
Customer requirement: The email must match an account previously created via POST /api/v1/customers/signup. Submitting an unregistered email returns a 422 error.
curl --request POST \
--url https://dev.namify.host/api/v1/customers/auto-login \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"email": "john.doe@example.com"
}
'import requests
url = "https://dev.namify.host/api/v1/customers/auto-login"
payload = { "email": "john.doe@example.com" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({email: 'john.doe@example.com'})
};
fetch('https://dev.namify.host/api/v1/customers/auto-login', 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://dev.namify.host/api/v1/customers/auto-login",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'email' => 'john.doe@example.com'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://dev.namify.host/api/v1/customers/auto-login"
payload := strings.NewReader("{\n \"email\": \"john.doe@example.com\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://dev.namify.host/api/v1/customers/auto-login")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"email\": \"john.doe@example.com\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://dev.namify.host/api/v1/customers/auto-login")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"email\": \"john.doe@example.com\"\n}"
response = http.request(request)
puts response.read_body{
"status": "SUCCESS",
"email": "john.doe@example.com",
"token": "214844e15411d2f6e72b274ca199760656218b57e5329243ce23e6ad7c2e1c97",
"expires_at": "2026-04-24 09:48:34"
}{
"message": "Unauthorized"
}{
"status": "ERROR",
"message": "Invalid customer email"
}https://[your-subdomain].namify.tech/auto-login?token=[token]
Authorizations
A personal access token. Obtain one from the dashboard under Settings > API Key. Include it in the Authorization header as Bearer <token>. Unauthenticated requests to protected routes return 401 Unauthorized.
Body
Email address of the customer to generate a token for. Must match an existing customer account created via POST /api/v1/customers/signup.
"john.doe@example.com"
Response
Token generated successfully. Use the returned token in the auto-login redirect URL immediately — it expires shortly after issuance.
"SUCCESS"
The customer email address the token was issued for.
"john.doe@example.com"
Authentication token to be passed as a query parameter in the auto-login redirect URL. Valid for a short window — redirect the customer immediately.
"214844e15411d2f6e72b274ca199760656218b57e5329243ce23e6ad7c2e1c97"
UTC datetime when the token expires, formatted as YYYY-MM-DD HH:MM:SS. The customer must be redirected before this time.
"2026-04-24 09:48:34"