Complete TOTP login
curl --request POST \
--url https://aropay.aro.media/api/v1/auth/login/totp \
--header 'Content-Type: application/json' \
--data '
{
"pendingToken": "eyJhbGciOi…",
"code": "123456"
}
'const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({pendingToken: 'eyJhbGciOi…', code: '123456'})
};
fetch('https://aropay.aro.media/api/v1/auth/login/totp', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://aropay.aro.media/api/v1/auth/login/totp"
payload = {
"pendingToken": "eyJhbGciOi…",
"code": "123456"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"ok": "<unknown>",
"data": {
"user": {
"id": "<string>",
"email": "jsmith@example.com",
"name": "<string>",
"company": "<string>",
"mustChangePassword": true,
"totpEnabled": true,
"lastLoginAt": "2023-11-07T05:31:56Z",
"createdAt": "2023-11-07T05:31:56Z"
}
}
}{
"ok": false,
"error": {
"code": "validation_error",
"message": "Request validation failed.",
"details": [
{
"path": "amount",
"message": "Required"
}
]
}
}{
"ok": false,
"error": {
"code": "invalid_totp_code",
"message": "Invalid or expired code."
}
}{
"ok": false,
"error": {
"code": "rate_limited",
"message": "Too many requests. Try again shortly."
}
}{
"ok": false,
"error": {
"code": "internal_error",
"message": "An unexpected error occurred."
}
}Auth
Complete TOTP login
Second step for accounts with two-factor authentication. Exchange the
pendingToken from POST /auth/login plus a live 6-digit
authenticator code for a session. Codes are single-use within their
30-second window.
POST
/
auth
/
login
/
totp
Complete TOTP login
curl --request POST \
--url https://aropay.aro.media/api/v1/auth/login/totp \
--header 'Content-Type: application/json' \
--data '
{
"pendingToken": "eyJhbGciOi…",
"code": "123456"
}
'const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({pendingToken: 'eyJhbGciOi…', code: '123456'})
};
fetch('https://aropay.aro.media/api/v1/auth/login/totp', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://aropay.aro.media/api/v1/auth/login/totp"
payload = {
"pendingToken": "eyJhbGciOi…",
"code": "123456"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"ok": "<unknown>",
"data": {
"user": {
"id": "<string>",
"email": "jsmith@example.com",
"name": "<string>",
"company": "<string>",
"mustChangePassword": true,
"totpEnabled": true,
"lastLoginAt": "2023-11-07T05:31:56Z",
"createdAt": "2023-11-07T05:31:56Z"
}
}
}{
"ok": false,
"error": {
"code": "validation_error",
"message": "Request validation failed.",
"details": [
{
"path": "amount",
"message": "Required"
}
]
}
}{
"ok": false,
"error": {
"code": "invalid_totp_code",
"message": "Invalid or expired code."
}
}{
"ok": false,
"error": {
"code": "rate_limited",
"message": "Too many requests. Try again shortly."
}
}{
"ok": false,
"error": {
"code": "internal_error",
"message": "An unexpected error occurred."
}
}⌘I