0

I'm trying to build an update action in Zapier. In the user field input step, I can display the record fields which currently have a value with ID, plus the remaining fields which don't and let the user add or update these fields.

In the API configuration panel is there a way that I can POST any values to fields which do not have a value in my App and PATCH any fields which did have a value in my app and require updating, all within the same Zap?

From what I can see only one call can be made but thought I would ask if there's a way around this?

Oliver
  • 11
  • 3

1 Answers1

0

I'm going to assume you're using Zapier's visual builder since you mentioned zapier-cli and the API configuration panel. My apologies if that assumption is incorrect!

(If you did mean a Zap that you're creating, you can add additional steps using the plus sign at the bottom of your Zap in progress to add another Webhooks step)

Have you tried writing the POST and PATCH in code mode instead of in form mode?

https://platform.zapier.com/docs/faq#how-does-code-mode-work

This is a more advanced step, so you might want to reach out to the customer support team for advice or code samples.

swrittenb
  • 326
  • 2
  • 13
  • 1
    Thanks Swrittenb. I'm using the code builder in the API configuration part of designing the action. My app api lets you add to custom field without values or update them but not in one method. I was hoping to allow the user to add values to any field and if it's one which already has a value, then PATCH, otherwise POST. I can identify which fields have value in the dynamic field input in the previous tab and pass that on. But can I make both the PATCH and POST in the API request in the final stage? – Oliver Mar 31 '20 at 15:29
  • Thanks for clarifying, Oliver! I believe you can do this conditionally using the code builder, but you should definitely reach out to Zapier's customer support team if you run into trouble here. They offer support to free accounts as well, so no obligation to upgrade to paid if that's what you're on. If you do, would you mind updating this comment thread with the solution that worked for your case? Thanks again! – swrittenb Mar 31 '20 at 16:24
  • 1
    You're right you can do it conditionally, for one or the other. The problem is I wanted it so some fields will use PATCH first before the remainder (without values) to then, in a second call, use POST. I'll try conditions again but couldn't get it working. As this is related to coding, the customer support point you to here to ask coding questions but thanks for the feedback. If I find a solution I'll update here. Thanks again. – Oliver Apr 01 '20 at 12:25