Why am I Still Receiving the 'TOO_MANY_WEBHOOKS_BY_OAUTH_INTEGRATION_IN_BASE' Error even After Airtable Trigger Deletion?

This topic was automatically generated from Slack. You can find the original thread here.

(Probably bug)

I’m struggling with teardown of Airtable triggers

  1. I deploy 2 Airtable triggers per base which is Airtable’s limit, all is good :white_check_mark:
  2. I DELETE the triggers
  3. I try to deployTrigger again and I get TOO_MANY_WEBHOOKS_BY_OAUTH_INTEGRATION_IN_BASE
    For testing I also tried other ways, such as deleting whole connected account or even deleting the whole external user but I still get TOO_MANY_WEBHOOKS_BY_OAUTH_INTEGRATION_IN_BASE as if the registered webhook was not deleted when the trigger was deleted.

I’m trying to reproduce it in UI and partially it’s possible for me:

  1. I create a workflow, set an Airtable trigger (instant ones use webhooks under the hood)
  2. I create a 2nd workflow with an Airtable trigger for the same Airtable base, all good still
  3. I try to create 3rd one - error - which is expected at this point
  4. I delete ALL 3 workflows
  5. I try to create one new workflow again with Airtable trigger, it passes :white_check_mark: so some teardown had to happen
  6. I try to create one more and this one crashes:boom: TOO_MANY_WEBHOOKS_BY_OAUTH_INTEGRATION_IN_BASE
  7. So after all the deletion I am able to create just one Airtable trigger per base, not 2, as if one webhook is still hanging somewhere
    It seems like some cleanup happens, but not always. I also tried again like 1 hour after DELETE and it’s still blocked.

When I re-visit a workflow that previously incorrectly prevented me from adding a new trigger I see two triggers set up:

As if the erroneous one stayed but a new one - which is working - has been added.

Removing a trigger and adding the same trigger again:

I’m seeing the teardown in the code though.

I’ll try to see how the teardown works via direct Airtable API calls, if it’s possible that the issue is on Airtable side

https://github.com/PipedreamHQ/pipedream/blob/3c31a74f7ab997d2b07c8ff08f70d77b9a1c[…]98e/components/airtable_oauth/sources/common/common-webhook.mjs

I can confirm the issue is not on Airtable API side. I can have an endpoint that creates and deletes an Airtable webhook and I can repeatedly call it. So the webhook deletion is instant.