Require Second Step

PUT /v1/endpoints/{uuid}/second-step

Require a second step of every user, or stop requiring it. Turning it on:

  • users without one set it up at their next sign-in, after a 6-digit code emailed to them; users without an email need a setup link;
  • browsers signed in without a second step sign in again;
  • a password sent with each request (Authorization: Basic) is refused for users who need one. Access tokens and API keys keep working;
  • users made by ngris http --basic-auth can't have one and are refused.

Read Get Second Step first: its counts say who this affects. Turning it off keeps asking the users who set one up. In the dashboard: Require a second step for everyone in Sign-in & access › Sign-in.

Path parameters

uuid string (uuid) Req
The endpoint's uuid from /endpoints.

An integer id in the path is refused with 400 integer_id_unsupported (see public IDs). Use the uuid.

Request body

required boolean Req
true requires a second step of every user; false stops requiring it.

Response (200 OK)

endpoint_uuid string (uuid)
The endpoint.
required boolean
As saved.

Errors

400 Bad Request
required is missing.
401 Unauthorized
Missing auth.
403 Forbidden
Caller lacks the endpoints:update permission, or the account's plan doesn't include users and roles.
404 Not Found
Endpoint doesn't exist or doesn't belong to the calling account.
409 Conflict
The endpoint has no sign-in yet (Turn on sign-in for this endpoint first.), or it is paused.
503 Service Unavailable
The second step isn't available yet.
Request
curl -X PUT \ "https://api.ngris.com/v1/endpoints/019bb1e4-e785-77d2-9966-c3cff31d0a0e/second-step" \ -H "X-API-KEY: <your_api_key>" \ -H "Content-Type: application/json" \ -d '{"required": true}'
Response
{ "endpoint_uuid": "019bb1e4-e785-77d2-9966-c3cff31d0a0e", "required": true }
Was this helpful?
On this page
Require Second Step
Was this helpful?