Update

View as Markdown

Use this endpoint for the Accounts method to modify the properties of an account.

Path parameters

SidstringRequiredformat: "uuid"
The Project ID that uniquely identifies the Project to retrieve.

Request

FriendlyNamestringRequired<=250 characters
The new name for the Project.

Response

sidstringRequiredformat: "uuid"
The unique identifier for this Project.
friendly_namestringRequired
The name of the Project.
statusenumRequired
The status of the Project. Always 'active'.
Allowed values:
auth_tokenstringRequired
The authorization token for this Project. Always returns 'redacted' for security.
date_createdstringRequired
The date and time this Project was created, in RFC 2822 format.
date_updatedstringRequired
The date and time this Project was last updated, in RFC 2822 format.
typeenumRequired
The type of the Project. Always 'Full'.
Allowed values:
owner_account_sidstringRequiredformat: "uuid"
The Project ID of the parent project. For parent projects, this is the same as sid.
region_preferencestringRequired
The preferred region for the Project.
uristringRequired
The URI for the Project.
subprojectbooleanRequired
Whether this project is a sub-project of another project.
signing_keystring or nullRequired
The signing key for the Project. Only returned once when a subproject is created. Subsequent requests return null.
subresource_urisobjectRequired
A map of URIs for sub-resources linked to this Project.

Request examples

1const { RestClient } = require('@signalwire/compatibility-api')
2const client = RestClient('YourProjectID', 'YourAuthToken', { signalwireSpaceUrl: 'example.signalwire.com' })
3
4client.api.accounts('YourProjectID')
5 .update({FriendlyName: 'Project Skynet'})
6 .then(account => console.log(account.friendlyName))
7 .done();