Stork for StarkNet

What is Stork, and how to use it?

Welcome to Stork for StarkNet

Sep 20, 2022: We have put new feature development on hold while we wait for changes affecting StarkNet development to stabilize. The current Stork on-chain oracle will remain available, and we encourage current users to consider our decentralized Off Chain solution for more flexible and frequent price updates on StarkNet and StarkEx.

Stork is an oracle for the StarkNet ecosystem build on StarkWare. At the moment, Stork is available on Testnet. Keep in mind that Stork is still actively being developed, so contract addresses will change regularly. We will make an effort to keep contracts updated for a few weeks, but it is not guaranteed. Check back here for the latest contract address.

Upcoming Milestones

Quick Start Guide

Start using Stork in seconds in Python, Cairo, or the CLI

or learn more about the API.

Who is Stork For?

We encourage everyone on the StarkNet ecosystem looking for asset prices to use Stork. Stork will work great if your application relies on periodic price updates for a wide range of assets. Ultimately, Stork will most benefit applications that rely on highly up-to-date prices covering a wide range of assets, including non-crypto assets.

Contracts

This guide references the following tools:

General Guidelines

Encoding

In general, all assets that are indicated as strings are expected to be converted into Base 10 ASCII encoded strings. Most StarkNet libraries will handle this encoding for you – feel free to experiment.

"ETH/USD".encode('ascii').hex() # String to Hex
int('0x04609',16) # Hex to Int
bytearray.fromhex(hex(1234)[2:]).decode() # Int to Hex

Authentication

All calls are unauthenticated. Writing prices is authenticated using account authentication, meaning publishers need to have their addresses allowlisted.

Timestamps

It's always a good idea to check the timestamp; StarkNet testnet is known for having downtimes, which may delay the update.

Update Frequency

Frequency depends on when oracle publish prices + testnet block time. Right now, it's typically every 5-10 minutes.

New Assets

New assets are easy to support – if you're interested in providing an oracle for your own price, while benefiting from some existing oracle infrastructure, reach out to us and we'll permission you.

Last updated