Data update notifications
Last updated
Last updated
Once an Account has been linked to the Open Utilities API there are two methods for your application to discover new data being available from the Provider: periodic polling and webhook callbacks.
The appropriate method will depend on the Account access level, use case and application architecture.
For Quick Check level use it is usually sufficient to poll for data for a period of time. It may also be sufficient for retrieving and initial set of data for Full Check level.
If Ongoing access is granted it is typically better to use the webhook callback mechanism.
Polling will usually entail repeat calls to getAccount()
, getAccounts()
or getProvisions()
queries.
The application chooses the schedule on which data is requested. This may be triggered by End User activity or on a periodic basis.
An alternative mechanism is that the Open Utilities API makes HTTP POST requests to your application when new data is available.
We can enable this so that you are notified when an Account has changed or if there is a new Document available.
After accepting the webhook you can then trigger an appropriate query to getAccount()
or getDocument()
.