In getting my site working with Workers KV, I’ve found that I need to sometimes batch delete keys that may or may not actually exist in my namespace.
It’s not super clear how Cloudflare will charge for these, other than “$5 per 1 million delete operations”. There are two specific questions here:
- Does using the batch delete API call count as one delete operation, or n? E.g. does calling delete on [“a”, “b”, “c”, “d”, “e”] count as 1 operation, or 5?
- If a key does not exist in the namespace, am I still charged for a delete operation? E.g. does calling delete on [“key_doesn’t_exist”] count as 0 operations, or 1?