mixcoatl/admin/api_key.py
def create(self):
        """Call the API to generate an API key from the current instance of `ApiKey`"""

        payload = {
            'generateApiKey': [{'description': self.description, 'name': self.name}]}
        s = self.post(data=json.dumps(payload))
        if self.last_error is None:
            self.__access_key = s['apiKeys'][0]['accessKey']
            self.load()
        else:
            raise ApiKeyGenerationException(self.last_error)
Call the API to generate an API key from the current instance of `ApiKey`
Call the API to generate an API key from the current instance of `ApiKey`
Call the API to generate an API key from the current instance of ` ApiKey `
def create(self):
        payload = {
            'generateApiKey': [{'description': self.description, 'name': self.name}]}
        s = self.post(data=json.dumps(payload))
        if self.last_error is None:
            self.__access_key = s['apiKeys'][0]['accessKey']
            self.load()
        else:
            raise ApiKeyGenerationException(self.last_error)
def create ( self ) : payload = { 'generateApiKey' : [ { 'description' : self . description , 'name' : self . name } ] } s = self . post ( data = json . dumps ( payload ) ) if self . last_error is None : self . __access_key = s [ 'apiKeys' ] [ 0 ] [ 'accessKey' ] self . load ( ) else : raise ApiKeyGenerationException ( self . last_error )
Call the API to generate an API key from the current instance of `ApiKey`
Call the API to generate an API key from the current instance of ` ApiKey `
"""Call the API to generate an API key from the current instance of `ApiKey`"""
self