Settings
Verifica o DNS de um domínio personalizado
Verifica a posse (TXT _repass.<hostname>) e o roteamento (CNAME) do domínio. Sucesso marca verified e emite custom_domain.verified; falha não altera o estado. Requer papel owner/admin.
POST
/
settings
/
custom-domains
/
{id}
/
verify
Verifica o DNS de um domínio personalizado
curl --request POST \
--url https://api.userepass.com/settings/custom-domains/{id}/verify \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.userepass.com/settings/custom-domains/{id}/verify"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.userepass.com/settings/custom-domains/{id}/verify', 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.userepass.com/settings/custom-domains/{id}/verify",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
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.userepass.com/settings/custom-domains/{id}/verify"
req, _ := http.NewRequest("POST", 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.post("https://api.userepass.com/settings/custom-domains/{id}/verify")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.userepass.com/settings/custom-domains/{id}/verify")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"domain": {
"id": "cdom_01J9Z3K7Qn8vYwT2bX4cE6dF8g",
"organizationId": "org_01J9Z3K7Qn8vYwT2bX4cE6dF8g",
"hostname": "go.cliente.com",
"kind": "link",
"status": "pending",
"tlsStatus": "pending",
"isPrimary": true,
"verificationToken": "cdom_verify_01J9Z3K7Qn8vYwT2bX4cE6dF8g",
"verifiedAt": "2023-11-07T05:31:56Z",
"tlsIssuedAt": "2023-11-07T05:31:56Z",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z"
},
"verified": true
}Authorizations
bearerAuthapiKeyAuth
Chave de API (prefixo rstr_) enviada como Authorization: Bearer rstr_....
Path Parameters
Identificador do domínio (prefixo cdom_).
Pattern:
^cdom_[0-9A-HJKMNP-TV-Z]{26}$Example:
"cdom_01J9Z3K7Qn8vYwT2bX4cE6dF8g"
⌘I
Verifica o DNS de um domínio personalizado
curl --request POST \
--url https://api.userepass.com/settings/custom-domains/{id}/verify \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.userepass.com/settings/custom-domains/{id}/verify"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.userepass.com/settings/custom-domains/{id}/verify', 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.userepass.com/settings/custom-domains/{id}/verify",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
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.userepass.com/settings/custom-domains/{id}/verify"
req, _ := http.NewRequest("POST", 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.post("https://api.userepass.com/settings/custom-domains/{id}/verify")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.userepass.com/settings/custom-domains/{id}/verify")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"domain": {
"id": "cdom_01J9Z3K7Qn8vYwT2bX4cE6dF8g",
"organizationId": "org_01J9Z3K7Qn8vYwT2bX4cE6dF8g",
"hostname": "go.cliente.com",
"kind": "link",
"status": "pending",
"tlsStatus": "pending",
"isPrimary": true,
"verificationToken": "cdom_verify_01J9Z3K7Qn8vYwT2bX4cE6dF8g",
"verifiedAt": "2023-11-07T05:31:56Z",
"tlsIssuedAt": "2023-11-07T05:31:56Z",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z"
},
"verified": true
}