Skip to content

HTTP Documentation of groups.create doesn't reflect the required "members" attribute #18

@skamensky

Description

@skamensky

Running
group = client.groups.create('groupname')
raises an error. After debugging, the content of the request is:

'{"formErrors":[],"inputErrors":{"members":[{"code":"MEMBERS_FIELD_IS_REQUIRED","msg":"Members field is required."}]}}'

Even though the HTTP documentation shows that members is optional.
This makes using the groups.create impossible without modifying the source code.

The code below is a workaround.

client._session.post(
    '{prfx}pubapi/v2/groups'.format(prfx=client._url_prefix),
    json = {'displayName' : 'test3','members' : [{"value": 1}]}
    )

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions