Change the organization's ways in
PUT
/api/settings/sign-in-methods
const url = 'https://forge.example.com/api/settings/sign-in-methods';const options = { method: 'PUT', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"password":true,"microsoft":true,"google":true,"apple":true,"version":1,"passkey":true,"requireSecondStep":true,"apiKeys":true,"apiKeyMaximumDays":1}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PUT \ --url https://forge.example.com/api/settings/sign-in-methods \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "password": true, "microsoft": true, "google": true, "apple": true, "version": 1, "passkey": true, "requireSecondStep": true, "apiKeys": true, "apiKeyMaximumDays": 1 }'A forbidden way stops at the next sign-in. The password can be turned off only once an administrator has an authenticator app. requireSecondStep makes everyone have an authenticator app or a passkey: a session without one may only set one up, from its next renewal. apiKeys off refuses every API key of the organization at once; apiKeyMaximumDays bounds the life of keys made from now on. A field of these three left out keeps what is set. Send the version you read, 0 while nothing was saved. A stale one answers 409 with currentVersion, the version it has now. For administrators.
Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
password
required
boolean
microsoft
required
boolean
google
required
boolean
apple
required
boolean
version
required
null | integer | string format: int32
passkey
boolean
requireSecondStep
null | boolean
apiKeys
null | boolean
apiKeyMaximumDays
null | integer | string format: int32
Responses
Section titled “Responses”OK
Media typeapplication/json
object
password
required
boolean
microsoft
required
boolean
google
required
boolean
apple
required
boolean
passkey
required
boolean
offered
required
Array<string>
requireSecondStep
boolean
withoutSecondStep
integer | string format: int32
apiKeys
boolean
apiKeyMaximumDays
integer | string format: int32
version
integer | string format: int32
Example
{ "requireSecondStep": false, "withoutSecondStep": 0, "apiKeys": false, "apiKeyMaximumDays": 366}default
Section titled “default”A refusal or an error, as a problem document. A model or draft you may not see answers 404, as one that does not exist.
Media typeapplication/problem+json
object
type
string
title
string
status
integer
detail
string
instance
string
Example generated
{ "type": "example", "title": "example", "status": 1, "detail": "example", "instance": "example"}