Skip to main content

Creating New Profile Folder

Description: This method creates a profile folder. The caller must ensure that the specified workspace ID and location are valid.

Request parameters:

ParameterTypeFormatDefaultDescription
namestringName of the profile folder. Cannot be null or empty.
workspaceIdintegerint64-1ID of the workspace where the profile folder will be created. Defaults to -1 if not specified.
locationstring (enum)LocalThe location where the profile folder will be created. Folder location: "Local" or "Cloud".

Example request:

POST
CURL:

curl 'http://localhost:8160/v1/profile_folders?name=&workspaceId=-1&location=Local' \
--request POST \
--header 'Api-Token: YOUR_SECRET_TOKEN'

C#:

using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("http://localhost:8160/v1/profile_folders?name=&workspaceId=-1&location=Local"),
Headers =
{
{ "Api-Token", "YOUR_SECRET_TOKEN" },
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}

Cube:

http://localhost:8160/v1/profile_folders?name=&workspaceId=-1&location=Local

Additionally:
User-Agent: {-Profile.UserAgent-}
Api-Token: Token from UserArea2.

Response API:

Response codeResult
200 OKSuccess
500 ErrorInternal Server Error

Success Response (200 OK):

Returns the ID of the newly created profile folder:

123e4567-e89b-12d3-a456-426614174000

Error Response (500):

{
"message": null
}