Create a project
Changed onCreates a project. Which kind depends on the credential:
- With a project API token, the new project is always a subproject of the authenticated root project, and parent_project_id is ignored. Creating while authenticated as a subproject fails with 422 nested_subprojects_not_allowed, since a subproject cannot contain subprojects.
- With a Personal access token, omit parent_project_id to create a root project, or set it to create a subproject of that project. The parent must be a root project the token holder can reach (invalid_parent_project_id, nested_subprojects_not_allowed).
A new root project has no API token yet. Give it one with Create API token, passing its id as project_id.
The response includes the signing_key. This is the only time it is returned — it cannot be retrieved through the API afterward, so capture it from this response.
Use a subproject to isolate settings and resources beneath a root project. Integrations built around Compatibility API Account SIDs can use Create subprojects instead.
Permissions
With a project API token, the token must have the following scope(s) enabled to make a successful request: Management.
With a Personal access token there are no scopes. The token holder must be an owner or admin of the space, and the request reaches only the projects the holder is enabled for, plus their subprojects.
Learn more about API scopes.
Request
- Base URLhttps://{Your_Space_Name}.signalwire.com
- URLhttps://{Your_Space_Name}.signalwire.com/api/projects
- Auth
- HTTP basic
- or HTTP basic
Request body
Example request
{
"name": "Acme Staging",
"protect_recordings": true,
"force_https_requests": true
}Response
The request has succeeded and a new resource has been created as a result.
Example response
{
"name": "Acme Staging",
"subproject": true,
"region_preference": "us-west",
"force_https_requests": true,
"created_at": "2024-05-06T12:20:00Z",
"updated_at": "2024-05-06T12:20:00Z",
"signing_key": "PSK_4d8c2b1a9f3e7c6d5b4a3e2f1d0c9b8a"
}Changes
- info
the endpoint scheme security
SignalWireBasicAuthwas added to the API - info
the endpoint scheme security
SignalWirePersonalAccessTokenAuthwas added to the API - info
added the new optional request property
- info
- info
added the non-success response with the status
- info
removed the non-success response with the status
- info
Some revisions have not been checked yet.