Update the Verify settings

PATCH
/v1/verify/settings

Changes the fields given; the others keep their values. sms_from must be one of the organization's numbers, and a live key's email_from must be on one of its verified domains.

Authorization

bearerAuth
headerAuthorizationBearer <token>

A secret API key from the dashboard: coss_live_… for production environments, coss_test_… for sandbox environments.

Header Parameters

Coss-Version?"2026-10-10"

The API version (a date) to use for this request. Defaults to your organization's version, pinned to the latest one when it first used the API and upgraded from the dashboard. The SDK always sends the version it was built for.

Value in"2026-10-10"

Request Body

application/json
  1. body

Only the fields given change.

app_name?|

The name codes are sent for; null: the project's.

Length1 <= length <= 40
code_length?integer

Digits in a code, 4-10.

Range4 <= value <= 10
ttl_seconds?integer

How long a code works, 60-1800 s.

Range60 <= value <= 1800
max_attempts?integer

Wrong codes before a verification fails, 1-10.

Range1 <= value <= 10
sms_from?|

One of the organization's numbers; null: coss.com's shared numbers.

Match^\+[1-9]\d{6,14}$
email_from?|

An address on one of the organization's verified domains (live keys); null: coss.com's.

Formatemail
allowed_countries?array<>

ISO 3166 countries SMS codes may go to.

Itemsitems <= 250

Response Body

The settings.

application/json
  1. response

An environment's Verify settings.

object*"verify_settings"
Value in"verify_settings"
app_name*string

The name codes are sent for.

app_name_is_default*boolean

Whether app_name is the project's: no name of its own is set.

code_length*integer

Digits in a code.

ttl_seconds*integer

How long a code works.

max_attempts*integer

Wrong codes before a verification fails.

sms_from*|

One of the organization's numbers; null: coss.com's shared numbers.

email_from*|

An address on one of the organization's verified domains; null: coss.com's.

allowed_countries*array<string>

ISO 3166 countries SMS codes may go to.

import { Coss } from "coss";const coss = new Coss({  apiKey: process.env.COSS_API_KEY,  baseUrl: "https://api.coss.com",});const { data, error } = await coss.verify.settings.update({  sms_from: "+14155550100",  allowed_countries: [    "CA",    "GB",    "US",  ],});
{  "object": "verify_settings",  "app_name": "Acme",  "app_name_is_default": false,  "code_length": 6,  "ttl_seconds": 600,  "max_attempts": 5,  "sms_from": "+14155550100",  "email_from": "codes@acme.com",  "allowed_countries": [    "CA",    "US"  ]}