admCreateSpace

Syntax

Option 1

admCreateSpace(spaceKey, spaceName, spaceDescription, user)

Option 2

admCreateSpace(cSpaceType)

Description

 Creates a new space, optionally offering support for the category of the space.

Parameters

Parameter name

Type

Required

Description

space key

stringyes (option 1)Key of new space. Required if not using CSpace as the parameter.
space namestringyes (option 1)Name of new space. Required if not using CSpace as the parameter.
space descriptionstringyes (option 1)Description for the new space. Required if not using CSpace as the parameter.
userstringyes (option 1)User who will be listed as the space creator. Required if not using CSpace as the parameter.
space typeCSpaceyes (option 2)Predefined structure that defines the new space.

Return type

boolean (true/false)

Returns true if the key and name aren't already used by another space.

Examples

Example 1

string spaceKey = "TST";
string spaceName = "New Test Space";
string spaceDescription = "New space create by Power Scripts";
string user = "admin";



return admCreateSpace(spaceKey, spaceName, spaceDescription, user);

Example 2

CSpace newSpace;
newSpace.key = "TST";
newSpace.name = "New Test Space";
newSpace.description = "New space create by Power Scripts";
newSpace.creator = "admin";

return admCreateSpace(newSpace);

See also