How to Automatically Update a Connected Field via External API Call in Knack?

Hello

I am working on a Knack app that involves two connected objects, “Orders” & “Customers.” :innocent: I would like to automatically update a field in the “Customers” object whenever a new “Order” is created specifically by pulling data from an external API (like updating loyalty points from a third-party system). :upside_down_face:

I have tried using Knack’s native Zapier integration but it doesn’t offer the level of control I need for conditional logic & connected field updates. :innocent:

What I am aiming for is something like; when a new order is submitted; my external script (hosted via Integromat/Make or custom webhook) should fetch current loyalty points from a third-party API & push that value back into the connected “Customer” record in Knack. :thinking:

I am able to POST and GET to Knack using the API; but updating connected records from an external trigger seems tricky.

Does anyone have a recommended structure for this kind of workflow / best practices for securely authenticating & updating these fields? :thinking:

I have gone through the Knack API docs and played around with PUT requests on record IDs, but I am unsure how to traverse and update a connected object (Customer) using the Order’s record_id alone. :slightly_smiling_face: Checked Connecting Records Together related to this and found it quite informative. I also came across discussions on what is Power Apps and wondered if it could be used similarly to update Knack records through external workflows.

Any guidance or example scripts would be much appreciated!

Thank you !! :slightly_smiling_face:

Hi @tisabib,
You’ll want to set up your automation like so in Make:

  1. Listen for Order being created
  2. GET the Order record - this is because the connection field ID is not returned in step 1
  3. GET the Customer record - using the returned Customer ID in step 2
  4. Do something in your external app with data from step 3’s customer data
  5. PUT the Customer record - use data from step 4

Does that help?

1 Like

I have something really similar to this set up in Zapier, but my Zapier plan is about to expire and I thought I’d give flows within Knack a try. Do you happen to know if this is possible within Flows? I’m trying to make it work, but am running into road blocks, which honestly seems crazy because I feel like this should be a no-brainer for Knack…

Hi Suzanne

Try watching Carl Homes’ video on Flows. After paying careful attention I found the solution in it to get my Flow to run after battling fruitlessly on it for hours and hours.

Personally, I don’t find Flows intuitive to use like Knack, and with it being a fairly new offering there aren’t many examples to help those of us with little experience in this area.

Good luck.

Dean

@Suzanne I agree with Dean that Flows is not as intuitive as Zapier or Make.com unfortunately.

Below is a preview of what the workflow might look like in Flows.
If you’d like some help configuring, feel free to direct message me.