Help

Can't update records from Parabola - typecast doesn't work with PATCH?

516 0
cancel
Showing results for 
Search instead for 
Did you mean: 
Claire_Conza
6 - Interface Innovator
6 - Interface Innovator

Struggling with parabola ‘send to api’ module while trying to update an airtable table.
I’m doing an update (patch) and I’m trying to send some numerical values.

{
  "records": [
    {
      "id": "{inventory record id}",
 "fields": {
 "sku":"{sku}",
 "in stock":"{in stock}",
 "prev stock":"{prev stock}",
 "updated":"{updated}"
        }
    }
  ]
}

If I send this I get an error stating that the ‘in stock’ and ‘prev stock’ can’t accept the values (because airtable is seeing the values as text trying to be inserted into a number field).

This works fine when creating records (Post) as I use typecast: true. It doesn’t work for Patch though even if I add typecast: true. It throws a different error.

If I change the json to this and remove the quotes from the value fields :-

{
  "records": [
    {
      "id": "{inventory record id}",
 "fields": {
 "sku":"{sku}",
 "in stock":{in stock},
 "prev stock":{prev stock},
 "updated":{updated}
        }
    }
  ]
}

Then it says my json isn’t valid.

Any ideas?

Thanks

Jonathan

0 Replies 0