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

Added the ability to look up organizations by external_id #38

Closed
wants to merge 2 commits into from
Closed

Added the ability to look up organizations by external_id #38

wants to merge 2 commits into from

Conversation

mattKaczorowski
Copy link

I admit it is a bit sloppy, but it seems to work. You should be able to execute:

zenpy = Zenpy(**creds)
organization = zenpy.organizations(external_id=777)

#36

endpoint = "organizations/search.json?external_id=" + str(external_id)
url = self._get_url(endpoint=endpoint)
response = self._get(url)
_json = response.json()['organizations'].pop)
Copy link
Author

Choose a reason for hiding this comment

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

.pop) vs .pop()

@mattKaczorowski
Copy link
Author

This needs a little more work..

Sign up for free to 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.

1 participant