Skip to content

Finish authenticator enrollment

POST
/api/v1/totp/finish
curl --request POST \
--url https://api.spartanauth.com/api/v1/totp/finish \
--header 'Content-Type: application/json' \
--data '{ "sectorID": "example", "email": "example", "transactionID": "example", "registrationID": "example", "code": "example" }'

Verifies the authenticator code from BeginTOTPRegistration and marks that factor validated. Returns one-time recovery codes the first time the user enrolls. A logged-out enrollment that proved the password also returns a JWT.

Media type application/json
object
sectorID
string
email
string
transactionID
string
registrationID
string
code
string
Example generated
{
"sectorID": "example",
"email": "example",
"transactionID": "example",
"registrationID": "example",
"code": "example"
}

A successful response.

Media type application/json
object
transactionID
string
recoveryCodes
Array<string>
token
string
Example generated
{
"transactionID": "example",
"recoveryCodes": [
"example"
],
"token": "example"
}

An unexpected error response.

Media type application/json
object
code
integer format: int32
message
string
details
Array<object>
object
@type
string
key
additional properties
Example generated
{
"code": 1,
"message": "example",
"details": [
{
"@type": "example"
}
]
}