/projects/{project_id}/branches/{branch_id}/auth/plugins/phone-numberUpdate phone number plugin configurationUpdates the phone number plugin configuration for Neon Auth. Only the fields provided in the request body are updated; omitted fields retain their current values. The phone number plugin enables phone-based OTP authentication. OTP codes are delivered via the send.otp webhook event with delivery_preference: "sms". A webhook must be configured with the send.otp event enabled for SMS delivery to work.
Parameters
project_idstringpathrequiredThe Neon project ID
branch_idstringpathrequiredThe Neon branch ID
Request body
requiredapplication/json
enabledbooleanWhether the phone number plugin is enabled.
otp_expires_inintegerTime in seconds before the OTP expires
{
"enabled": true,
"otp_expires_in": 0
}Responses
enabledbooleanrequiredWhether the phone number plugin is enabled.
otp_expires_inintegerTime in seconds before the OTP expires
{
"enabled": false,
"otp_expires_in": 300
}codestringrequiredmessagestringrequiredError message
request_idstringUnique identifier for the request, useful for debugging. You can set this value manually by including an `X-Request-ID` header in the request. If not provided, the value will be generated automatically.
{
"code": "",
"message": "string",
"request_id": "string"
}