POST
/
v1
/
workspaces
import Evecloud from '@evecloud/sdk';

const client = new Evecloud({
  token: 'My Token',
});

async function main() {
  const workspace = await client.workspaces.create({ name: 'My Workspace' });

  console.log(workspace.data);
}

main();
{
  "data": {
    "name": "My Workspace",
    "slug": "my-workspace"
  },
  "success": true
}

Authorizations

Authorization
string
header
required

Default authentication mechanism

Body

application/json
name
string
required

The name of the workspace.

Required string length: 4 - 32
Example:

"My Workspace"

slug
string

The unique slug of the workspace. if not provided, it will be generated from the name.

Required string length: 4 - 32
Example:

"my-workspace"

Response

200
application/json
Successful request.
data
object
required
success
boolean
default:true
required

Whether the API call was successful

Was this page helpful?