Toggle OAuth Provider
Set the enabled flag on an OAuth provider without touching any other configuration. This is an explicit set, not a flip — you supply the desired boolean in the body. Useful for temporarily disabling a provider during maintenance, an incident, or while migrating credentials.
The provider is preserved in the database with all its config — the only change is the enabled flag. Use PUT /v1/endpoints/{uuid}/oauth/providers/{provider_uuid} if you want to change other fields too.
Path parameters
uuid string (uuid) Req
The endpoint's
uuid.provider_uuid string (uuid) Req
The provider's
uuid. Get it from /oauth/providers. It resolves only under the endpoint in the path.Deprecated: the legacy integer id is still accepted in the path until the sunset, answered with Deprecation and Sunset headers. Use the uuid.
Request body
enabled boolean
Desired state. Strict decoding — any field other than
enabled returns 400. Omitting it defaults to false (disables the provider).Response (204 No Content)
Empty body on success.
Errors
400 Bad Request
Invalid request body / unknown fields, or an integer provider id after the sunset (
integer_id_unsupported).401 Unauthorized
Missing auth.
403 Forbidden
Caller lacks the
endpoints:update permission in the active account.404 Not Found
Endpoint doesn't belong to the calling account, or provider not found / not on this endpoint.
Request — disable
curl -X PUT "https://api.ngris.com/v1/endpoints/<uuid>/oauth/providers/019b407c-8a46-7001-897f-343e36ba8939/toggle" \
-H "X-API-KEY: <your_api_key>" \
-H "Content-Type: application/json" \
-d '{"enabled": false}'
Python
from ngris import Ngris
client = Ngris(api_key="<your_api_key>")
client.endpoint_oauth.toggle_provider(
"<endpoint_uuid>", "019b407c-8a46-7001-897f-343e36ba8939",
)
Response — 204 No Content
Was this helpful?