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 gets for custom_branding queries #269

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions duo_client/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -3176,6 +3176,39 @@ def update_logo(self, logo):
def delete_logo(self):
return self.json_api_call('DELETE', '/admin/v1/logo', params={})

def get_custom_branding(self):
"""
Returns current live custom branding.

Raises RuntimeError on error.
"""
response, data = self.api_call('GET',
'/admin/v1/branding',
params={})
return self.parse_json_response(response, data)

def get_draft_custom_branding(self):
"""
Returns current draft custom branding.

Raises RuntimeError on error.
"""
response, data = self.api_call('GET',
'/admin/v1/branding/draft',
params={})
return self.parse_json_response(response, data)

def get_custom_messaging(self):
"""
Returns current messaging.

Raises RuntimeError on error.
"""
response, data = self.api_call('GET',
'/admin/v1/branding/custom_messaging',
params={})
return self.parse_json_response(response, data)

def get_u2ftokens(self, limit=None, offset=0):
"""
Retrieves a list of u2ftokens
Expand Down