def delete_tag(self, tag): ''' This method delete a tag. @param $tag the name of the tag you want to delete. ''' result = ExternalApiTagRequest(ExternalApiTagRequest.REMOVE_ALL_REQUEST, tag, None) return self.http_post(self.API_TAGS_URL, None, body=result.get_json_encode_dict_for_tag_based_requests())
def remove_tag_for_apps(self, tag, app_keys): ''' This method remove a tag associate with applications. @param $tag the name of the tag to create @param $app_keys Key applications that want to remove with the tag ''' result = ExternalApiTagRequest(ExternalApiTagRequest.REMOVE_REQUEST, tag, app_keys) return self.http_post(self.API_TAGS_URL, None, body=result.get_json_encode_dict_for_tag_based_requests())
def assign_tag(self, tag, app_keys): ''' This method associates a tag created with applications. @param $tag the name of the tag to create @param $app_keys Key applications that want to associate with the tag @return A list of applications associates with a tag. ''' result = ExternalApiTagRequest(ExternalApiTagRequest.CREATE_REQUEST, tag, app_keys) return self.http_post(self.API_TAGS_URL, None, body=result.get_json_encode_dict_for_tag_based_requests())
def list_tags(self): ''' @return A list of tags that have been created. ''' result = ExternalApiTagRequest(ExternalApiTagRequest.LIST_REQUEST, None, None) return self.http_post( self.API_TAGS_URL, None, body=result.get_json_encode_dict_for_tag_based_requests())
def delete_tag(self, tag): ''' This method delete a tag. @param $tag the name of the tag you want to delete. ''' result = ExternalApiTagRequest( ExternalApiTagRequest.REMOVE_ALL_REQUEST, tag, None) return self.http_post( self.API_TAGS_URL, None, body=result.get_json_encode_dict_for_tag_based_requests())
def remove_tag_for_apps(self, tag, app_keys): ''' This method remove a tag associate with applications. @param $tag the name of the tag to create @param $app_keys Key applications that want to remove with the tag ''' result = ExternalApiTagRequest(ExternalApiTagRequest.REMOVE_REQUEST, tag, app_keys) return self.http_post( self.API_TAGS_URL, None, body=result.get_json_encode_dict_for_tag_based_requests())
def assign_tag(self, tag, app_keys): ''' This method associates a tag created with applications. @param $tag the name of the tag to create @param $app_keys Key applications that want to associate with the tag @return A list of applications associates with a tag. ''' result = ExternalApiTagRequest(ExternalApiTagRequest.CREATE_REQUEST, tag, app_keys) return self.http_post( self.API_TAGS_URL, None, body=result.get_json_encode_dict_for_tag_based_requests())
def list_tags(self): ''' @return A list of tags that have been created. ''' result = ExternalApiTagRequest(ExternalApiTagRequest.LIST_REQUEST, None, None) return self.http_post(self.API_TAGS_URL, None, body=result.get_json_encode_dict_for_tag_based_requests())