Help with Script to delete contact

I wanted to add a script inline in shortcuts (ie in the scriptable action) to delete a contact passed in. Is someone able to provide me with the code to do this as I don’t know Javascript but can see from the API it can be done?