Authorize User
curl --request POST \
--url https://api.cnt.ekiden.fi/api/v1/authorize \
--header 'Content-Type: application/json' \
--data '
{
"nonce": "<string>",
"public_key": "<string>",
"signature": "<string>",
"timestamp_ms": 123,
"full_message": "<string>"
}
'import requests
url = "https://api.cnt.ekiden.fi/api/v1/authorize"
payload = {
"nonce": "<string>",
"public_key": "<string>",
"signature": "<string>",
"timestamp_ms": 123,
"full_message": "<string>"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
nonce: '<string>',
public_key: '<string>',
signature: '<string>',
timestamp_ms: 123,
full_message: '<string>'
})
};
fetch('https://api.cnt.ekiden.fi/api/v1/authorize', 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.cnt.ekiden.fi/api/v1/authorize",
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([
'nonce' => '<string>',
'public_key' => '<string>',
'signature' => '<string>',
'timestamp_ms' => 123,
'full_message' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"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://api.cnt.ekiden.fi/api/v1/authorize"
payload := strings.NewReader("{\n \"nonce\": \"<string>\",\n \"public_key\": \"<string>\",\n \"signature\": \"<string>\",\n \"timestamp_ms\": 123,\n \"full_message\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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://api.cnt.ekiden.fi/api/v1/authorize")
.header("Content-Type", "application/json")
.body("{\n \"nonce\": \"<string>\",\n \"public_key\": \"<string>\",\n \"signature\": \"<string>\",\n \"timestamp_ms\": 123,\n \"full_message\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.cnt.ekiden.fi/api/v1/authorize")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"nonce\": \"<string>\",\n \"public_key\": \"<string>\",\n \"signature\": \"<string>\",\n \"timestamp_ms\": 123,\n \"full_message\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"token": "<string>",
"user_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}User
Authorize User
Authorize and obtain an access token
POST
/
api
/
v1
/
authorize
Authorize User
curl --request POST \
--url https://api.cnt.ekiden.fi/api/v1/authorize \
--header 'Content-Type: application/json' \
--data '
{
"nonce": "<string>",
"public_key": "<string>",
"signature": "<string>",
"timestamp_ms": 123,
"full_message": "<string>"
}
'import requests
url = "https://api.cnt.ekiden.fi/api/v1/authorize"
payload = {
"nonce": "<string>",
"public_key": "<string>",
"signature": "<string>",
"timestamp_ms": 123,
"full_message": "<string>"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
nonce: '<string>',
public_key: '<string>',
signature: '<string>',
timestamp_ms: 123,
full_message: '<string>'
})
};
fetch('https://api.cnt.ekiden.fi/api/v1/authorize', 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.cnt.ekiden.fi/api/v1/authorize",
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([
'nonce' => '<string>',
'public_key' => '<string>',
'signature' => '<string>',
'timestamp_ms' => 123,
'full_message' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"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://api.cnt.ekiden.fi/api/v1/authorize"
payload := strings.NewReader("{\n \"nonce\": \"<string>\",\n \"public_key\": \"<string>\",\n \"signature\": \"<string>\",\n \"timestamp_ms\": 123,\n \"full_message\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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://api.cnt.ekiden.fi/api/v1/authorize")
.header("Content-Type", "application/json")
.body("{\n \"nonce\": \"<string>\",\n \"public_key\": \"<string>\",\n \"signature\": \"<string>\",\n \"timestamp_ms\": 123,\n \"full_message\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.cnt.ekiden.fi/api/v1/authorize")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"nonce\": \"<string>\",\n \"public_key\": \"<string>\",\n \"signature\": \"<string>\",\n \"timestamp_ms\": 123,\n \"full_message\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"token": "<string>",
"user_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}Body
application/json
Example: b7d1c2e8f5a94f3db2f8c6a9d1e4
Example: 0xa9d81da788977638194c857b918f12ff2233c7a86e82b44705761b2d02426f6d
Example: 0xf5ec808e52d014f5193eccf680acf84c6256bdddb0159088e7cb18d74b9c590b92eb4381e10307fccc0868612993dfb9a542257aab22d7a3decfda33045fb905
Example: 1731541800000
Optional Aptos Wallet Standard full message (APTOS-prefixed, newline-delimited).
If provided, the backend will verify the signature against this exact string
and also validate that it contains message: AUTHORIZE|{timestamp_ms}|{nonce} and a matching nonce:.
Example:
APTOS\nmessage: AUTHORIZE|1731541800000|b7d1c2e8f5a94f3db2f8c6a9d1e4\nnonce: b7d1c2e8f5a94f3db2f8c6a9d1e4
⌘I