Support new "delete multiple records" API endpoint
I went looking for multiple-records deletes, rather than single record deletes, when I saw extensions being able to delete 50 records at a time. The Airtable API supports deleting 10 records at a time. Rather than, say, defining new multi_delete functions, I'm extending the existing delete functions to also accept a list of record IDs.
The documentation has the following CURL example, which shows the need to use (rather clumsy) multiple records[] keys as query parameters:
curl -X DELETE "https://api.airtable.com/v0/{baseId}/{tableIdOrName}\
?records[]=rec560UJdUtocSouk&records[]=rec3lbPRG4aVqkeOQ" \
-H "Authorization: Bearer YOUR_TOKEN"
I'm using Enum.into/2 in ExAirtable.Service to permit multiple Keyword entries with the "records[]" key. The use of the Collectable protocol is deprecated in favour of Keyword.merge/2, but Enum.into/2 allows repeated binary keys. There may be a better way of doing this. But according to its Hex documentation (for both v1.6.x and 2.2.x versions) HTTPoison.Request accepts query parameters as a "map, keyword, or orddict", so we do want to use Keyword here.
When playing with the code in the console, TableCache.delete/2 reported failed deletes when the record IDs were malformed or don't exist in the source table, so I added some defensive code to catch these. But it might make sense to elevate more specific error-checking to ExAirtable.Service.perform_request/2.