How To Delete Permissions

To delete permissions, submit a transaction to the deleteauth action of the eosio account.

In the example shown below useraaaaaaaa deletes the permission my_new_permission on the account useraaaaaaaa.

const deleteauth_input = {
  account: 'useraaaaaaaa',
  permission: 'my_new_permission',
};

(async () => {
  await api.transact({
    actions: [
    {
      account: 'eosio',
      name: 'deleteauth',
      authorization: [{
        actor: 'useraaaaaaaa',
        permission: 'active',
      }],
      data: delete_auth_data,
    }]
  }, {
    blocksBehind: 3,
    expireSeconds: 30,
  });
})();