auth.link.complete
curl --request POST \
--url https://platform.trylath.com/auth/link/complete \
--header 'Content-Type: application/json' \
--data '
{
"challengeId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"token": "<string>",
"userAgent": "<string>"
}
'const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
challengeId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
token: '<string>',
userAgent: '<string>'
})
};
fetch('https://platform.trylath.com/auth/link/complete', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://platform.trylath.com/auth/link/complete"
payload = {
"challengeId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"token": "<string>",
"userAgent": "<string>"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://platform.trylath.com/auth/link/complete"
payload := strings.NewReader("{\n \"challengeId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"token\": \"<string>\",\n \"userAgent\": \"<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))
}{
"activityId": "<string>",
"result": {
"activityId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"redirectTo": "<string>",
"environmentId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"expiresInSeconds": 0
}
}auth.link.complete
Completes a magic-link sign-in from the hosted landing page using the link token as the credential. Returns where to send the user and a one-time code appended to it as lath_code, which their app exchanges for the session with auth.session.exchange; or, when a second factor is owed, an mfaToken the landing page finishes with auth.mfa.verify.
POST
/
auth
/
link
/
complete
auth.link.complete
curl --request POST \
--url https://platform.trylath.com/auth/link/complete \
--header 'Content-Type: application/json' \
--data '
{
"challengeId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"token": "<string>",
"userAgent": "<string>"
}
'const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
challengeId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
token: '<string>',
userAgent: '<string>'
})
};
fetch('https://platform.trylath.com/auth/link/complete', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://platform.trylath.com/auth/link/complete"
payload = {
"challengeId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"token": "<string>",
"userAgent": "<string>"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://platform.trylath.com/auth/link/complete"
payload := strings.NewReader("{\n \"challengeId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"token\": \"<string>\",\n \"userAgent\": \"<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))
}{
"activityId": "<string>",
"result": {
"activityId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"redirectTo": "<string>",
"environmentId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"expiresInSeconds": 0
}
}Headers
Replays the stored response for the same key and input; refuses different input.
Body
application/json
Pattern:
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$Required string length:
20 - 64Maximum string length:
400Last modified on September 13, 2026
Was this page helpful?

