Rename the tenant named by the owner's console token.
PUT
/console/tenant
const url = 'https://api.canopyhq.dev/console/tenant';const options = { method: 'PUT', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"name":"example"}'};
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://api.canopyhq.dev/console/tenant \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "name": "example" }'Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
name
required
Trimmed, nonempty, at most 100 characters, with no control characters.
string
Examplegenerated
{ "name": "example"}Responses
Section titled “Responses”The tenant’s display name was saved.
Invalid name or body; parse errors identify the field and reason when available.
No valid console token.
Only an owner may rename the tenant.