Skip to content

Latest commit

 

History

5 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

zerox

W3 Gopher

Package zerox is a wrapped 0x Swap API.

This package has a respresentation of:

  • Quote (swap/v1/quote) - Get an easy-to-consume quote for buying or selling any ERC20 token. Returns a transaction that can be submitted to an Ethereum node.
  • Price (swap/v1/price) - /price is nearly identical to /quote, but with a few key differences. /price does not return a transaction that can be submitted on-chain; it simply provides us the same information. Think of it as the "read-only" version of /quote.
  • Source (swap/v1/source) - Returns the liquidity sources enabled for the chain.

Install

go get github.com/fioletxyz/0x-go

Getting Started

Note Check out the examples!

Connect your API Auth key and choose an endpoint.

// Create a new client for interacting with the 0x API
client := zerox.NewClient(
	"YOUR_AUTH_KEY",
	zerox.BinanceSmartChain) //Choose an endpoint from config.go

About

No description, website, or topics provided.

Resources

Stars

6 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages