REST create a group with a parent

Hi there,

I'm trying to create a group with a parent. Here's my request:

{
    "name": "Group Name",
    "parent-groups": {
        "group": [
            { "key": "PARENT_GROUP" }
        ]
    }
}

I'm getting the following error:

Error has occurred during request processing (Bad Request).
Error: jetbrains.buildServer.server.rest.errors.BadRequestException: Only 'key', 'name' and 'description' attributes are supported when creating user groups.
Invalid request. Please check the request URL and data are correct.

Is it possible to do this via REST? Using TeamCity 9.0.4.

0
2 comments

Hi Jan,

Unfortunately, the message is right, there is no way to create hierarchy of user groups via REST API at this time. You are welcome to file a feature resut into our tracker.

BTW, why do you need to create groups automatically? What integration are you implementing?

0

Thanks, I've raised two feature requests:

https://youtrack.jetbrains.com/issue/TW-41163

https://youtrack.jetbrains.com/issue/TW-41165

We're integrating with Atlassian Crowd.

0

Please sign in to leave a comment.