'Delete an existing key pair.
:param key_pair: Key pair object.
:type key_pair: :class:`libcloud.compute.base.KeyPair`
:param     projectid: The project associated with keypair
:type      projectid: ``str``
:param     domainid: The domain ID associated with the keypair
:type      domainid: ``str``
:param     account: The account associated with the keypair.
Must be used with the domainId parameter.
:type      account: ``str``
:return:   True of False based on success of Keypair deletion
:rtype:    ``bool``'

def delete_key_pair(self, key_pair, **kwargs):

    extra_args = kwargs.copy()
    params = {'name': key_pair.name}
    params.update(extra_args)
    res = self._sync_request(command='deleteSSHKeyPair', params=params, method='GET')
    return (res['success'] == 'true')
