Skip to content

Add folder, user and group management - #23

Open
mabihan wants to merge 2 commits into
shubhamdipt:masterfrom
mabihan:feature/folder-and-user-management
Open

Add folder, user and group management#23
mabihan wants to merge 2 commits into
shubhamdipt:masterfrom
mabihan:feature/folder-and-user-management

Conversation

@mabihan

Copy link
Copy Markdown

I added functions to create folders, users and user groups.

See test.py


API Reference : https://help.passbolt.com/api/users/read-index
"""
response = self.get(f"/users.json", params={f"filter[search]": username})

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
response=self.get(f"/users.json", params={f"filter[search]": username})
response=self.get("/users.json", params={"filter[search]": username})

Comment threadtest.py

parent_folder_id = "5b024c98-211c-487e-86f1-0bf75de3f685"

new_user_name = f"passbolt-py-user-%s@atexo.com"%(now.strftime("%Y-%m-%d-T%H%M%S"))

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please avoid adding any personal info.

Suggested change
new_user_name=f"passbolt-py-user-%s@atexo.com"%(now.strftime("%Y-%m-%d-T%H%M%S"))
new_user_name=f"passbolt-py-user-%s@xyz.xyz"%(now.strftime("%Y-%m-%d-T%H%M%S"))

Comment threadtest.py

with passboltapi.PassboltAPI(config_path="config.ini", new_keys=True) as passbolt:

new_group = passbolt.create_group(new_group_name, "jean-rene.robin@atexo.com")

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
new_group=passbolt.create_group(new_group_name, "jean-rene.robin@atexo.com")
new_group=passbolt.create_group(new_group_name, "xyz@xyz.xyz")

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@mabihan@shubhamdipt