Oracle Subscription
1 min read
Pronunciation
[awr-uh-kl sub-skrip-shun]
Analogy
Like subscribing to a newspaper delivery service to receive daily news without ordering each issue separately.
Definition
Key Points Intro
Oracle subscriptions automate data delivery and payment through recurring agreements.
Key Points
Register: Consumer calls `subscribe(feedId, frequency)`.
Recurring billing: Escrow debited per update cycle.
Auto-update: Oracle pushes data to subscriber.
Cancellation: Consumer can unsubscribe to stop updates.
Example
A DeFi contract subscribes to a stablecoin price feed at 10‑minute intervals, paying 1 LINK per interval from its escrow.
Technical Deep Dive
Subscription contract stores `subscriptions[consumer][feedId] = { nextDue, interval, fee }`. On each `report()`, contract checks due subscriptions, transfers fees, and schedules nextDue.
Security Warning
Uncanceled subscriptions can drain funds; provide clear unsubscribe mechanisms.
Caveat
Automated updates increase on‑chain transactions; monitor gas usage.
Oracle Subscription - Related Articles
No related articles for this term.