This article covers steps to delete the repository and GPG Key On Ubuntu. All packages are signed with a pair of keys consisting of a private key and a public key, by the package maintainer.
A user's private key is kept secret and the public key may be given to anyone the user wants to communicate.
Whenever you add a new repository to your system, you must also add a repository key so that the APT Package Manager trusts the newly added repository.
Once you've added the repository keys, you can make sure you get the packages from the correct source.
To remove Repository keys:
You can remove the repository key if it is no longer needed or if the repository has already been removed from the system.
It can be deleted by entering the full key with quotes as follows (which has a hex value of 40 characters):
$ sudo apt-key del "D320 D0C3 0B02 E64C 5B2B B274 3766 2239 8999 3A70"
Alternatively, you can delete a key by entering only the last 8 characters:
$ sudo apt-key del 89993A70
Once you have removed the repository key, run the apt command to refresh the repository index:
$ sudo apt update
You can verify that the above GPG key has been removed by running the following command:
$ sudo apt-key list