In Square, when we mark an Order as Ready, is there any way to get Square to notify that user via email or text? - square

With the new API, it is great that we are able to push orders to the POS app - now I just need a way to notify customers that the pick-up is ready. I have my own system seperately right now, but is there any way to do this inside of Square. Or even better, is there any way to hook into a square event?
I see webhooks, but only things like payment, refund, dispute events. Is there any way to catch an order status change?

Currently there are webhooks for different order update events:
You could then create some webservice of lambda to process such webhook payload, and submit an email using some 3rd party email sending solution.
There is a challenge that since you will need to query the square api for the rest of order details, you will need to create a square app, implement oauth etc.

Unfortunately, there's currently no Order webhooks at this time. Webhooks are definitely an area Square's APIs have been focusing and improving lately, so I suspect this to be an area we continue to improve. With that said, there is no ETA on if/when this is coming, sadly we do not share public timelines.

Related

How would I go about developing a program that automatically sends an email with the tracking number to a customer using EasyPost API?

I'm a fairly new web developer and I have an ecommerce website that integrates EasyPost to create and print shipping labels.
EasyPost has an API. Also, in each shipping label, I see a JavaScript object (I think) that displays buyer_address... "email": "example#gmail.com",, which tells me that the email information is there.
My question is somewhat general in scope: What steps would I need to take to go about creating this automation? The website is built in Webflow, so I don't really have a "codebase" or "repository" to store whatever code is needed to build the automation.
Since the buyer email is making it into EasyPost with integrations already in place, I feel that I could create a simple program that emails the tracking number to the buyer email every time a label is generated, or perhaps when package is shipped, without the program needing to interact with Webflow or other integrations.
I attempted using Zapier, as well as Make.com. Neither worked, and OrderDesk doesn't have a way to send tracking number emails.
It looks like Webflow has some kind of support for Webhooks (https://webflow.com/feature/create-webhooks-from-project-settings). EasyPost offers webhooks for free as an add-on service. Basically, with webhooks, EasyPost would send tracking events to Webflow proactively, but Webflow (or you) would need to manage the logic for what to do with those tracking events after they are delivered.
EasyPost Webhook Guide
I'm unaware of any off the shelf products that could do this for you without writing any code. We have a guide that details how you might accomplish this with Ruby (you could then follow this as an example for any other language): https://www.easypost.com/email-tracking-tutorial
A few suggestions:
Integrate something into Webflow if possible (I'm unfamiliar with the platform so couldn't say).
Build a simple script that runs on a schedule (cronjob) that retrieves your trackers from EasyPost and sends an email to customers if they have not yet received one. To your point, this approach wouldn't require interacting with Webflow at all and could be done with some local code running on a server and just your EasyPost API key.
I've created a simple UI for EasyPost: https://github.com/Justintime50/easypost-tools-ui, it could be interesting to add this particular use-case as a feature to that project. If you're interested, feel free to open an issue on GitHub for the repo listed here and I'd consider it.
You'd use easypost's API webhooks, to detect when shipment tracking information is provided, or package information is updated.
https://www.easypost.com/docs/api#trackers
It looks like it has a lot of states, so you can keep the client updated regarding the package status from the moment the tracking # is assigned;
EZ1000000001 pre_transit
EZ2000000002 in_transit
EZ3000000003 out_for_delivery
EZ4000000004 delivered
EZ5000000005 return_to_sender
EZ6000000006 failure
EZ7000000007 unknown
You can install webhooks from these docs.
To send the email, you can use an automation service e.g. Make to capture those webhook events, and then compose and send an email to that customer. I like MailJet for that purpose, because it has excellent template support and you can send from your own company domain. But there are many email-sending options.
A bigger challenge, maybe, is getting the email address to send to. I didn't spot it glancing through the Trackers or Shipments data structures, and I am primarily seeing physical address info.
If EasyPost is not tracking the customer's email with the shipment, you may have some challenge in that you'd need to capture the client info through Webflow's order webhooks, and then associate that with EasyPost's shipmentid, and store those in a reference table.
Many automation services offer database-like functionality for this purpose, or you could use e.g. google sheets ( columns webflow OrderID, easypost ShipmentID, customer Email ) or airtable for that purpose.
But you'd have to look into the Easypost integration as well, and you may need to make that integration manual so that you can acquire all 3 of those pieces of information at the same point in your business data flow.

Shopify app for altering the default checkout procedure

I need to create a solution for altering the checkout process.
Better said, I need to add some functionality to it with a remote app (I am not sure if this is the right way to do it).
Mainly, what is needed represents a process that calls an external API, using a private API key from a delivery company, that registers a pick-up from the buyers house and sends the product to our headquarters.The process should be started when the user completes the entire checkout system from shopify, after payment.
After that, some AWB should be returned to the users checkout page, or some response regarding the creation of the pick up.
My question is, let's say, using some language like javascript with node and Koa or express, how one can achieve that? I can't find any tutorials or something that would help me do this.

How can I make a new order/transaction done through the API show on the Square app

Online I allow customers to order, this causes an Order With Line Items to be uploaded and associated with a Transaction - that works great, exactly as I had hoped. The problem is that there is no notification on the Square App to let my operators know that there is a new order that has been paid.
As of right now, I have the workaround of texting the workers, but I feel like there should be an easy way to push this up to the app - what am I missing? Is this possible?
I am not using an online store, just the API. Thank you.
Unfortunately, sending order confirmation to the Point of Sale app from an API payment isn’t currently available for Square’s API.
We are constantly improving the product based on feedback like this, so I’ll be sure to share your thoughts with the API team.

Looking for a way to subscribe to events within my Shopify store

I work with some third party referral systems and I've been looking for a way to trigger some JS off of events like Add To Cart, Add Coupon to Order, and Checkout. I'd like to be able to do this without having to use the id of the button in question as these can change from theme to theme, and become complicated when you're dealing with multiple buttons for the same functionality.
It seems like the built in Google Analytics and Facebook Tracking are using some sort of event system to trigger their data collection, but I can't seem to find anything in the docs or forums explaining how this works or how I can use it without using their services. Ideally I'm looking for some kind of liquid if/then sort of structure or alternatively just a clear event of some kind that I can listen for.
Obviously I could use jquery to accomplish this by listening for different button clicks but that seems like a really brittle way of handling something that is clearly part of the core of how Shopify works.
Any thoughts or suggestions would be really appreciated (At this point I'll name my first born rumplestiltskin)
(Repost from here https://ecommerce.shopify.com/users/554977/posts)
You can subscribe to webhook events through the API:
https://help.shopify.com/api/reference/webhook
There are topics for carts/create and checkouts/create which you might find useful. For coupon codes, you can subscribe to orders/create webhooks and parse the order data to see if it contains a coupon code.
Do what everyone does, including GA and other trackers. Build an App that installs in shops, and that App uses the API to inject JS that triggers onload. You can then program the JS to callback your mothership with the data you are interested in.
Note that your approach of asking for a trigger is far too vague to ever work. Why re-invent the wheel or beat a dead horse. Free up your valuable time and just go with the flow.
https://help.shopify.com/api/reference/scripttag

After I've built a conversation flow in a chatbot, how'd I get the chatbot to actually perform the desired actions?

For example, if I’ve built a full conversational flow in a service like API. AI that results in a booking being made. How do I actually then make that booking sync to a third party calendar?
Can this be done directly between the two? Would I need to build an application to sit between the two?
I’m tech inexperienced, so I’m curious how these things work…
You will need to add "fulfillment" to your API.AI app, and yes, have a custom application (the "webhook") in between.
That is, once you've collected all the information to make that booking, you don't want to just say "Thank you, here's the book information you've provided [...]", you want to do things with it. That's what fulfillment does. API.AI will send a REST call to your webhook with the information the intent has, you do whatever you want with it (e.g.: actually add the booking to the calendar), and also return the response that you want API.AI to give, that'll take the place of the "text response" you normally provide for a given intent.
To set this up on the API.AI side, there are two steps: Find "fulfillment" in the menu for your app, and tell it how to connect to your webhook. Then go to any intent where you want the webhook to be called when it's matched, and select "use webhook" under "fulfillment".
The more involved part may be to actually provide a webhook that API.AI can call - that's where your custom logic goes, it sits between, in your example, the API.AI app and the calendar application and makes things actually happen.
Useful reading: https://docs.api.ai/docs/webhook