apollo.cannedkeys package

Module contents

Contains possible interactions with the Apollo Canned Keys Module

class apollo.cannedkeys.CannedKeysClient(webapolloinstance, **requestArgs)

Bases: apollo.client.Client

CLIENT_BASE = '/cannedKey/'
add_key(key, metadata='')

Add a canned key

Parameters:
  • key (str) – New canned key
  • metadata (str) – Optional metadata
Return type:

dict

Returns:

A dictionnary containing canned key description

delete_key(id_number)

Update a canned key

Parameters:id_number (int) – canned key ID number
Return type:dict
Returns:an empty dictionary
get_keys()

Get all canned keys available in this Apollo instance

Return type:list of dicts
Returns:list of canned key info dictionaries
show_key(value)

Get a specific canned key

Parameters:value (str) – Canned key to show
Return type:dict
Returns:A dictionnary containing canned key description
update_key(id_number, new_key, metadata=None)

Update a canned key

Parameters:
  • id_number (int) – canned key ID number
  • new_key (str) – New canned key value
  • metadata (str) – Optional metadata
Return type:

dict

Returns:

an empty dictionary