If you do not require the policy anymore, you can delete using the command: curl -X DELETE "http://{elastic_ip}:9200/_slm/policy/ nightly-snapshots.
NOTE:The elastic_ip can be either the IP of the node in case you are in dashboard cluster or 127.0.0.1, in case you are not using cluster configuration.
NOTE:Note that this command will not delete snapshots taken, this will only delete the snapshot policy.