Notify URL When Stuff Changes in Xero - Webhooks
I'm requesting "web hooks" for the Xero API.
Here's how they work: Customer provides a URL (http://myserver.com/xero/changed) to Xero, and when something is changed, Xero notifies that URL, perhaps indicating which records have changed.
The Xero API provides methods that you can query and compare with previous results to see what has changed. However, this is not performant for large data sets, and detecting changes involves a lot of code.
The competition has it - web hooks are supported by QuickBooks. Let's get them in Xero - it's a superior product in every other way.
Would it be possible for Xero to push changes made within its system to 3rd party systems.
For example if I push an Invoice from procision+ within Microsoft CRM 4.0 to Xero. If someone then changes one of the invoice lines in Xero, Xero then pushes those changes back out to procision+ via a webservice.
Rather than polling the Xero API to see when invoice payments have been made, could Xero call a URL to let another application know when an invoice is paid
Unfortunately when we looked at this in detail, our existing technical architecture would not support webhooks. We still want to deliver this, but it can only come after some planned architectural enhancement to the Xero platform.
In the mean time, we have a number of options on how we can make the syncing of data more efficient using existing GET API polling methods – we will update this thread when we have more news to share.
We are sorry we can’t do better right now, it is not from lack of desire on our part.
Eliot Slevin commented
I work for Hoist.io, which is an integration platform to make dealing with apis much easier. With a few previous Xero employees in the team, it’s no surprise that over the last five years we’ve worked with the Xero API extensively, and we've been wanting webhooks just as much as everybody else.
That’s why we’re excited to announce our Xero Connector. Now any developer can subscribe to events from their own Xero accounts, or their users accounts. Never poll for new or updated data again! We're currently open for early access, if you're interested we'd love to talk to you
Matthew Schinckel commented
According to the presentations from Xerocon 2014: webhooks are still not on the agenda until at least _after_ 2015.
Is this going to happen or not? really need this for CRM + Chat room
Plus one for Webhooks
Out of a meeting last week and the other devs are pushing for a platform change due to API limitations, mainly lack the of webhooks in xero.
We need near realtime and without webhooks + the API rate limit, there is no real way to achieve this right now.
Please don't make us deal with Quickbooks.
Since November of last year was the last Admin comment about this, it would be nice to get another update. Any sort of ETA would be very helpful. I am currently developing an app that needs this functionality and I love everything else about Xero but this might be the deal breaker for me. If I know it is coming sometime soon I would be willing to deal with the workarounds for awhile but just need some sort of timeframe so I can make an informed decision. Thanks.
Any ETA? This is kind of critical for proper integration especially with the API limits. Any update would really be great.
One of the big pushes from my company to move services is lack of webhook support.
Is there any update on the ETA for webhooks?
My business is eager to migrate to Xero, but without unnecessary re-development for event notifications at a later stage.
Our use case involves the requirement to send invoice notifications via our own mail infrastructure to improve credibility and deliverability.
Adminxero (Admin, Xero) commented
@Chris - why do you need to retrieve each invoice individually? You should be able to do a GET Invoices call to retrieve multiple invoices at once unless you need the line item detail. In addition, you can use the modified-since parameter to only retrieve the changes: http://developer.xero.com/documentation/getting-started/http-requests-and-responses/#title2
All that aside, 18,000 API queries a month is still well inside the average monthly limit of 30,000 (1,000 per day).
That does not mean we should not keep working to make the API more efficient via web hooks etc, just some pointers to keep you going for now. ^RQ
Chris Rutherfurd commented
We are currently in the process of building an in house customer management system to manage all of our customers business with us through a single system, to date we have been using a few dozen. We are currently implementing our link with Xero as one way for creating invoices only and then marking them as paid when the customer pays them but this means that we can not use the web invoice viewer or the invoice payment feature therein because the invoice won't show up as paid in our system unless we query it for an update. Due to the API limits which are set this would be impractical as we are forecasting that within 2 years of our system going into production in our business we would be tracking almost 500 new invoices each month, and some invoices may not be paid for 3-4 months, in addition taking into account that the updates would have to be queries daily so as to ensure our data was up to date, this would mean that conservatively we would be looking at 15'000 API queries per month for new invoices only, and an additional 3'000 queries each month against overdue invoices and invoices with longer terms. Bear in mind that the figure above of 18'000 queries a month is based only on getting payment updates on invoices and not on any other task such as creating a new invoice or marking an invoice as paid if it was paid through one of our other payment sources such as BPay, in store payment, etc.
Web Hooks are definately the way to go, we currently have webhooks into a number of our suppliers to get real time updates when an order we place has a status update, with our freight provider for when a delivery is marked as completed, and with several of our online store systems and online auction systems for when a purchase is placed, an enquiry is made, or an auction is completed.
We do want to use Xero and are currently using it in limited form as we find it to be the best solution for us in accounting, and a far better option than existing solutions such as QuickBooks and MYOB but without webhooks it is of strictly limited value.
Jack Bremer commented
We have a line item "pre paid hours" for clients who wish to obtain an hourly discount by paying in advance. Some require an invoice first, so we invoice them and credit their account with the hours when paid for.
The problem is that reconciling the bank account doesn't give any indication of the contents of an invoice you're reconciling, so these payments against prepaid hours often go amiss - paid for but not credited to their block of hours in our support system.
If we could be alerted of invoices containing that specific line item, when they are marked as paid, that would be excellent. I believe WEBHOOKS will allow this in a far easier fashion than running convoluted API calls to search for possible invoices with no money due, then requerying those to see if the specific line item exists in them, and then alerting us by email if they do, marking it as alerted so it doesn't alert us again in the future.
It would also surely save on the Xero API server resources.
David Bullock commented
STOP! Webhooks are all very well, so long as you can tolerate the possibility of 'missed messages'. A better idea is to provide a 'feed' for each class of logical entity ... where items in the feed are sorted by their 'last modified date', and thus can be queried with a "gimme all the things which have changed since ..." query. The 'webhook' is then a single hook. "Hey, some stuff changed lately in categories X and Z, since the last time you queried them ... better grab the latest stuff". Because this message is issued every time there is a fresh change to stuff, (and possibly on a 'stubborn retry' if the callback doesn't give a 200 response), the impact of missed messages is reduced ... the client can always find the stuff they are after, which has changed since the last timetamp.
It's all in the GData protocol, one way or another (something to reflect on, rather than to copy exactly ... it's multidimensional complexity caused Google to go with a more classic RPC-style interface (for adoption and for ther decreasing quality of their engineers). However, the 'feed of items ordered by last-updated-date' is a cherry worth picking. https://developers.google.com/gdata/docs/2.0/reference#Queries
Adrian Overbury commented
A use-case that would benefit us greatly with this kind of web-hook scenario is keeping our company leave calendar up to date (now that the Australia Payroll API has been released). When leaves are requested or approved we can be notified via a webhook so our calendar is up to date and doesn't run foul of polling request limiting.
Charle Demers commented
Contributing my usecase: I need to keep clients, users and tags (create/update/delete) in sync between multiple applications. More to the point, when I update a client in Xero, Xero warns sync app that take care of propagating the change to the other applications.
In my case it doesn't need to be a rock solid notification system, I could live with a pooling based sync to normalize things a couple of times a day or so.
Jev Bjorsell commented
I'm now integrating invoicing between our order management system. When a Payable invoice has been paid, I want a webhook to fire back to my order management system so that systems status is updated.
Same/similar use case applies for Sales Invoices.
Tim Cull commented
This thread is 2 years old now but I don't see any webhooks in the documentation yet. Are they already here and I'm just missing them?
Jev Bjorsell commented
This feature will have good pay-off for any clients or partners integrating via your APIs. What's the status on this feature? Will we see it in 2012?
David Vandenberg commented
Webhooks are the only way to do truly realtime integrations.
Personally, I won't use a cloud solution that doesn't provide webhooks alongside their API these days. Without them, integrations are always poll-based, relying on cron jobs that run even when nothing has changed, which is extremely inefficient. Polling results in either too many API calls (to achieve a somewhat timely update cycle), or a poor integration with only semi-regular syncronisations.
This is a must-have feature in my books. And it's so simple to implement that I can't understand why any cloud solution provider would not have this on the top of their priority list.
Randall Bennett commented
Usecase: We get notified in chat when invoices are sent out.
Randall Bennett commented
Any progress with this? We'd really like it.