Skip to main content

Getting Folder List

Description: This retrieves a list of folders available in the specified workspace.
Optionally, it is possible to limit the number of results, specify filters, or define sorting conditions.

Request parameters:

ParameterTypeFormatDefaultDescription
workspaceIdintegerint64-1ID of the workspace where the profile folder will be created. Defaults to -1 if not specified.
startintegerint320Index of the first folder (starting from zero).
totalintegerint321000Maximum number of folders to retrieve.
idstringuuid(empty)Unique folder identifier (optional filter).
namestring(empty)Folder name (optional filter).
sortingstring(empty)Sorting condition: Id, Name, FolderType, Quantity (optional filter).
locationstring (enum)LocalFolder location: "Local" or "Cloud".

Example request:

GET
CURL:

curl 'http://localhost:8160/v1/profile_folders?workspaceId=-1&start=0&total=1000&id=&name=&sorting=&location=' \
--header 'Api-Token: YOUR_SECRET_TOKEN'

С#:

using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("http://localhost:8160/v1/profile_folders?workspaceId=-1&start=0&total=1000&id=&name=&sorting=&location="),
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?workspaceId=-1&start=0&total=1000&id=&name=&sorting=&location=

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

Response API:

Response codeResult
200 OKSuccess
500 ErrorInternal Server Error

Success Response (200 OK):

{
"totalCount": 1,
"items": [
{
"id": "123e4567-e89b-12d3-a456-426614174000",
"name": null,
"location": "Local",
"quantity": 1
}
]
}

Error Response (500):

{
"message": null
}