Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for Organization MGMT API endpoints [SDK-2439] #261

Merged
merged 11 commits into from
Apr 9, 2021

Conversation

lbalmaceda
Copy link
Contributor

@lbalmaceda lbalmaceda commented Mar 30, 2021

Changes

Adds endpoints to manage Organizations through the MGMT APIs.

Organizations

  • POST Organization
  • PATCH Organization
  • GET Organizations
  • GET Organization
  • GET Organization (by name)
  • DELETE Organization

Connections

  • POST Organization Connection
  • PATCH Organization Connection
  • GET Organization Connections
  • GET Organization Connection
  • DELETE Organization Connection

Members

  • POST Organization Members
  • GET Organization Members
  • DELETE Organization Members

Member Roles

  • POST Organization Member Roles
  • GET Organization Member Roles
  • DELETE Organization Member Roles

Invitations

  • POST Organization Invitations
  • GET Organization Invitations
  • GET Organization Invitation
  • DELETE Organization Invitations

Users

  • GET User Organizations

References

See SDK-2439

Testing

Unit tests were provided. These endpoints have not been manually tested yet.

@lbalmaceda lbalmaceda requested a review from a team as a code owner March 30, 2021 14:55
@lbalmaceda lbalmaceda added CH: Added large Large review labels Mar 30, 2021
@lbalmaceda lbalmaceda force-pushed the mgmt-org branch 2 times, most recently from 8f12d5d to 727a813 Compare March 31, 2021 11:31
per_page (int, optional): The amount of entries per page. When not set,
the default value is up to the server.

See: https://auth0.com/docs/api/management/v2#!/Clients/get_clients
Copy link
Contributor Author

Choose a reason for hiding this comment

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

All these "see" links are wrong and will be updated once the Organizations docs are made available.

stevehobbsdev
stevehobbsdev previously approved these changes Apr 1, 2021
Copy link
Contributor

@stevehobbsdev stevehobbsdev left a comment

Choose a reason for hiding this comment

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

🎉

See: https://auth0.com/docs/api/v2#!/Clients/post_clients
"""

return self.client.post(self._url(id, 'members'), data=body)

Choose a reason for hiding this comment

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

just getting ahead of myself, but do you know what the body can take? I tried it from the UI and it was limited to email, app, roles. But what if I want to send some extra metadata to this for "Invite email template"?
Sorry the docs are still not available so i am trying to read the code. I want to see if we can reuse this instead of custom email from our end inviting user and giving then some links for our app. Links / names are custom to each user so we cannot hardcode it in email template.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@aonamrata the template for the "user invitation" email will be customizable. The docs will go live soon and will hopefully help you clarify this. But the email templates endpoint accepts a type of "user_invitation".

stevehobbsdev
stevehobbsdev previously approved these changes Apr 8, 2021
@lbalmaceda lbalmaceda added this to the v3-Next milestone Apr 9, 2021
@lbalmaceda lbalmaceda merged commit 5c15ac9 into master Apr 9, 2021
@stevehobbsdev stevehobbsdev deleted the mgmt-org branch April 9, 2021 09:33
@lbalmaceda lbalmaceda modified the milestones: v3-Next, 3.16.0 Apr 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CH: Added large Large review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants