'Retrieve a single key pair.
:param name: ID of the key pair to retrieve.
:type name: ``str``
:rtype: :class:`.KeyPair` object'

def get_key_pair(self, name):

    user_id = self.connection.request('/profile.json').object['user']['id']
    response = self.connection.request(('/users/%s/ssh_keys/%s.json' % (user_id, name)))
    return self._to_key_pair(response.object['ssh_key'])
