Request form
0x V4
  • DEX
  • Aggregator
  • Governance
  • Protocol
Docs
Source
ChefGPT

Exchange Infrastructure for the Internet

IERC20Token.sol
IEtherToken.sol
LibERC20TokenV06.sol
DefaultPoolOperator.sol
IStaking.sol
IZrxTreasury.sol
ZrxTreasury.sol
AuthorizableV06.sol
LibAuthorizableRichErrorsV06.sol
LibBytesRichErrorsV06.sol
LibMathRichErrorsV06.sol
LibOwnableRichErrorsV06.sol
LibRichErrorsV06.sol
LibSafeMathRichErrorsV06.sol
IAuthorizableV06.sol
IOwnableV06.sol
LibBytesV06.sol
LibMathV06.sol
LibSafeMathV06.sol
OwnableV06.sol
LibCommonRichErrors.sol
LibLiquidityProviderRichErrors.sol
LibMetaTransactionsRichErrors.sol
LibNativeOrdersRichErrors.sol
LibNFTOrdersRichErrors.sol
LibOwnableRichErrors.sol
LibProxyRichErrors.sol
LibSignatureRichErrors.sol
LibSimpleFunctionRegistryRichErrors.sol
LibTransformERC20RichErrors.sol
LibWalletRichErrors.sol
FeeCollector.sol
FeeCollectorController.sol
FlashWallet.sol
IFlashWallet.sol
ILiquidityProviderSandbox.sol
LibFeeCollector.sol
LiquidityProviderSandbox.sol
TransformerDeployer.sol
BatchFillNativeOrdersFeature.sol
BootstrapFeature.sol
ERC165Feature.sol
FundRecoveryFeature.sol
IBatchFillNativeOrdersFeature.sol
IBootstrapFeature.sol
IERC1155OrdersFeature.sol
IERC165Feature.sol
IERC721OrdersFeature.sol
IFeature.sol
IFundRecoveryFeature.sol
ILiquidityProviderFeature.sol
IMetaTransactionsFeature.sol
IMetaTransactionsFeatureV2.sol
IMultiplexFeature.sol
INativeOrdersEvents.sol
INativeOrdersFeature.sol
IOtcOrdersFeature.sol
IOwnableFeature.sol
IPancakeSwapFeature.sol
ISimpleFunctionRegistryFeature.sol
ITokenSpenderFeature.sol
ITransformERC20Feature.sol
IUniswapFeature.sol
IUniswapV3Feature.sol
LibNativeOrder.sol
LibNFTOrder.sol
LibSignature.sol
LiquidityProviderFeature.sol
MetaTransactionsFeature.sol
MetaTransactionsFeatureV2.sol
MultiplexFeature.sol
MultiplexLiquidityProvider.sol
MultiplexOtc.sol
MultiplexRfq.sol
MultiplexTransformERC20.sol
MultiplexUniswapV2.sol
MultiplexUniswapV3.sol
NativeOrdersCancellation.sol
NativeOrdersInfo.sol
NativeOrdersProtocolFees.sol
NativeOrdersSettlement.sol
NativeOrdersFeature.sol
ERC1155OrdersFeature.sol
ERC721OrdersFeature.sol
NFTOrders.sol
OtcOrdersFeature.sol
OwnableFeature.sol
PancakeSwapFeature.sol
SimpleFunctionRegistryFeature.sol
TransformERC20Feature.sol
UniswapFeature.sol
UniswapV3Feature.sol
FixinCommon.sol
FixinEIP712.sol
FixinERC1155Spender.sol
FixinERC721Spender.sol
FixinProtocolFees.sol
FixinReentrancyGuard.sol
FixinTokenSpender.sol
IZeroEx.sol
CurveLiquidityProvider.sol
MooniswapLiquidityProvider.sol
FullMigration.sol
InitialMigration.sol
LibBootstrap.sol
LibMigrate.sol
LibERC1155OrdersStorage.sol
LibERC721OrdersStorage.sol
LibMetaTransactionsStorage.sol
LibMetaTransactionsV2Storage.sol
LibNativeOrdersStorage.sol
LibOtcOrdersStorage.sol
LibOwnableStorage.sol
LibProxyStorage.sol
LibReentrancyGuardStorage.sol
LibSimpleFunctionRegistryStorage.sol
LibStorage.sol
LibTransformERC20Storage.sol
AffiliateFeeTransformer.sol
AbstractBridgeAdapter.sol
ArbitrumBridgeAdapter.sol
AvalancheBridgeAdapter.sol
BaseBridgeAdapter.sol
BaseGoerliBridgeAdapter.sol
BridgeProtocols.sol
BSCBridgeAdapter.sol
CeloBridgeAdapter.sol
EthereumBridgeAdapter.sol
FantomBridgeAdapter.sol
IBridgeAdapter.sol
MixinAaveV2.sol
MixinAaveV3.sol
MixinBalancer.sol
MixinBalancerV2Batch.sol
MixinBancorV3.sol
MixinBarter.sol
MixinCompound.sol
MixinCryptoCom.sol
MixinCurve.sol
MixinCurveV2.sol
MixinDodo.sol
MixinDodoV2.sol
MixinGMX.sol
MixinKyberDmm.sol
MixinKyberElastic.sol
MixinLido.sol
MixinMakerPSM.sol
MixinMaverickV1.sol
MixinMooniswap.sol
MixinMStable.sol
MixinNerve.sol
MixinPlatypus.sol
MixinSolidly.sol
MixinSynthetix.sol
MixinTraderJoeV2.sol
MixinUniswap.sol
MixinUniswapV2.sol
MixinUniswapV3.sol
MixinVelodromeV2.sol
MixinWOOFi.sol
MixinZeroExBridge.sol
OptimismBridgeAdapter.sol
PolygonBridgeAdapter.sol
FillQuoteTransformer.sol
IERC20Transformer.sol
LibERC20Transformer.sol
LogMetadataTransformer.sol
PayTakerTransformer.sol
PositiveSlippageFeeTransformer.sol
Transformer.sol
WethTransformer.sol
IERC1155Token.sol
IERC721Token.sol
IFeeRecipient.sol
ILiquidityProvider.sol
IMooniswapPool.sol
IPropertyValidator.sol
ITakerCallback.sol
IUniswapV2Pair.sol
IUniswapV3Pool.sol
IERC20Bridge.sol
IStaking.sol
ZeroEx.sol
ZeroExOptimized.sol
ZRXToken.sol
WETH9.sol
ISablier.sol
WETH9V06.sol
OwnableUpgradeable.sol
draft-IERC1822Upgradeable.sol
IERC1967Upgradeable.sol
IBeaconUpgradeable.sol
ERC1967UpgradeUpgradeable.sol
Initializable.sol
UUPSUpgradeable.sol
AddressUpgradeable.sol
ContextUpgradeable.sol
StorageSlotUpgradeable.sol
AccessControl.sol
IAccessControl.sol
GovernorCountingSimple.sol
GovernorSettings.sol
GovernorTimelockControl.sol
GovernorVotes.sol
GovernorVotesQuorumFraction.sol
IGovernorTimelock.sol
Governor.sol
IGovernor.sol
TimelockController.sol
IVotes.sol
IERC1155Receiver.sol
ERC20.sol
draft-ERC20Permit.sol
draft-IERC20Permit.sol
ERC20Wrapper.sol
IERC20Metadata.sol
IERC20.sol
SafeERC20.sol
IERC721Receiver.sol
Address.sol
Checkpoints.sol
Context.sol
Counters.sol
ECDSA.sol
EIP712.sol
ERC165.sol
IERC165.sol
Math.sol
SafeCast.sol
Strings.sol
DoubleEndedQueue.sol
Timers.sol
LibERC20TokenV08.sol
CallWithGas.sol
IZeroExGovernor.sol
IZeroExVotes.sol
SecurityCouncil.sol
ZeroExProtocolGovernor.sol
ZeroExTimelock.sol
ZeroExTreasuryGovernor.sol
ZeroExVotes.sol
ZRXWrappedToken.sol
AuthorizableV08.sol
LibAuthorizableRichErrorsV08.sol
LibBytesRichErrorsV08.sol
LibMathRichErrorsV08.sol
LibOwnableRichErrorsV08.sol
LibReentrancyGuardRichErrorsV08.sol
LibRichErrorsV08.sol
LibSafeMathRichErrorsV08.sol
IAuthorizableV08.sol
IOwnableV08.sol
LibBytesV08.sol
LibMathV08.sol
OwnableV08.sol
ReentrancyGuardV08.sol
PermissionlessTransformerDeployer.sol
IOwnable.sol
LibBytes.sol
LibBytesRichErrors.sol
LibOwnableRichErrors.sol
LibReentrancyGuardRichErrors.sol
LibRichErrors.sol
LibSafeMath.sol
LibSafeMathRichErrors.sol
Ownable.sol
ReentrancyGuard.sol
TestLibBytes.sol
TestLibRichErrors.sol
TestLibSafeMath.sol
TestOwnable.sol
TestReentrancyGuard.sol
LibReentrancyGuardRichErrorsV06.sol

117 downloads

Chains

Authors

0x V4
  • DEX
  • Aggregator
  • Governance
  • Protocol
Info
Source
ChefGPT
Expand
Share

Get Cookin'

117 downloads

Chains

Authors


0x is an open protocol that facilitates trustless, low friction exchange of Ethereum-based assets. For more information on how it works, check out the 0x protocol specification.

This repository is a monorepo including the 0x protocol smart contracts and numerous developer tools. Each public sub-package is independently published to NPM.

Coverage Status Discord License

Packages

Visit our developer portal for a comprehensive list of core & community maintained packages. All packages maintained with this monorepo are listed below.

Solidity Packages

These packages are all under development. See /contracts/README.md for a list of deployed packages.

PackageVersionDescription
@0x/contracts-zero-exnpmThe contracts used for settling trades within the protocol
@0x/contracts-erc20npmImplementations of various ERC20 tokens
@0x/contracts-test-utilsnpmTypeScript/Javascript shared utilities used for testing contracts
@0x/contracts-utilsnpmGeneric libraries and utilities used throughout all of the contracts

TypeScript/Javascript Packages

0x-specific packages

PackageVersionDescription
@0x/protocol-utilsnpmA set of utilities for generating, parsing, signing and validating 0x orders
@0x/contract-addressesnpmA tiny utility library for getting known deployed contract addresses for a particular network.
@0x/contract-wrappersnpmJS/TS wrappers for interacting with the 0x smart contracts
@0x/contract-artifactsnpm0x smart contract compilation artifacts

Usage

Node version 6.x or 8.x is required.

Most of the packages require additional typings for external dependencies. You can include those by prepending the @0x/typescript-typings package to your typeRoots config.

"typeRoots": ["node_modules/@0x/typescript-typings/types", "node_modules/@types"],

Contributing

We strongly recommend that the community help us make improvements and determine the future direction of the protocol. To report bugs within this package, please create an issue in this repository.

Read our contribution guidelines.

Install dependencies

Make sure you are using Yarn v1.9.4. To install using brew:

brew install [email protected]

Then install dependencies

yarn install

Build

To build all packages:

yarn build

To build a specific package:

PKG=@0x/protocol-utils yarn build

To build all contracts packages:

yarn build:contracts

Watch

To re-build all packages on change:

yarn watch

To watch a specific package and all it's dependent packages:

PKG=[NPM_PACKAGE_NAME] yarn watch

e.g
PKG=@0x/protocol-utils yarn watch

Clean

Clean all packages:

yarn clean

Clean a specific package

PKG=@0x/protocol-utils yarn clean

Rebuild

To re-build (clean & build) all packages:

yarn rebuild

To re-build (clean & build) a specific package & it's deps:

PKG=@0x/protocol-utils yarn rebuild

Lint

Lint all packages:

yarn lint

Lint a specific package:

PKG=@0x/protocol-utils yarn lint

Run Tests

Run all tests:

yarn test

Run a specific package's test:

PKG=@0x/protocol-utils yarn test

Run all contracts packages tests:

yarn test:contracts
Exchange Infrastructure for the Internet
IERC20Token.sol
IEtherToken.sol
LibERC20TokenV06.sol
DefaultPoolOperator.sol
IStaking.sol
IZrxTreasury.sol
ZrxTreasury.sol
AuthorizableV06.sol
LibAuthorizableRichErrorsV06.sol
LibBytesRichErrorsV06.sol
LibMathRichErrorsV06.sol
LibOwnableRichErrorsV06.sol
LibRichErrorsV06.sol
LibSafeMathRichErrorsV06.sol
IAuthorizableV06.sol
IOwnableV06.sol
LibBytesV06.sol
LibMathV06.sol
LibSafeMathV06.sol
OwnableV06.sol
LibCommonRichErrors.sol
LibLiquidityProviderRichErrors.sol
LibMetaTransactionsRichErrors.sol
LibNativeOrdersRichErrors.sol
LibNFTOrdersRichErrors.sol
LibOwnableRichErrors.sol
LibProxyRichErrors.sol
LibSignatureRichErrors.sol
LibSimpleFunctionRegistryRichErrors.sol
LibTransformERC20RichErrors.sol
LibWalletRichErrors.sol
FeeCollector.sol
FeeCollectorController.sol
FlashWallet.sol
IFlashWallet.sol
ILiquidityProviderSandbox.sol
LibFeeCollector.sol
LiquidityProviderSandbox.sol
TransformerDeployer.sol
BatchFillNativeOrdersFeature.sol
BootstrapFeature.sol
ERC165Feature.sol
FundRecoveryFeature.sol
IBatchFillNativeOrdersFeature.sol
IBootstrapFeature.sol
IERC1155OrdersFeature.sol
IERC165Feature.sol
IERC721OrdersFeature.sol
IFeature.sol
IFundRecoveryFeature.sol
ILiquidityProviderFeature.sol
IMetaTransactionsFeature.sol
IMetaTransactionsFeatureV2.sol
IMultiplexFeature.sol
INativeOrdersEvents.sol
INativeOrdersFeature.sol
IOtcOrdersFeature.sol
IOwnableFeature.sol
IPancakeSwapFeature.sol
ISimpleFunctionRegistryFeature.sol
ITokenSpenderFeature.sol
ITransformERC20Feature.sol
IUniswapFeature.sol
IUniswapV3Feature.sol
LibNativeOrder.sol
LibNFTOrder.sol
LibSignature.sol
LiquidityProviderFeature.sol
MetaTransactionsFeature.sol
MetaTransactionsFeatureV2.sol
MultiplexFeature.sol
MultiplexLiquidityProvider.sol
MultiplexOtc.sol
MultiplexRfq.sol
MultiplexTransformERC20.sol
MultiplexUniswapV2.sol
MultiplexUniswapV3.sol
NativeOrdersCancellation.sol
NativeOrdersInfo.sol
NativeOrdersProtocolFees.sol
NativeOrdersSettlement.sol
NativeOrdersFeature.sol
ERC1155OrdersFeature.sol
ERC721OrdersFeature.sol
NFTOrders.sol
OtcOrdersFeature.sol
OwnableFeature.sol
PancakeSwapFeature.sol
SimpleFunctionRegistryFeature.sol
TransformERC20Feature.sol
UniswapFeature.sol
UniswapV3Feature.sol
FixinCommon.sol
FixinEIP712.sol
FixinERC1155Spender.sol
FixinERC721Spender.sol
FixinProtocolFees.sol
FixinReentrancyGuard.sol
FixinTokenSpender.sol
IZeroEx.sol
CurveLiquidityProvider.sol
MooniswapLiquidityProvider.sol
FullMigration.sol
InitialMigration.sol
LibBootstrap.sol
LibMigrate.sol
LibERC1155OrdersStorage.sol
LibERC721OrdersStorage.sol
LibMetaTransactionsStorage.sol
LibMetaTransactionsV2Storage.sol
LibNativeOrdersStorage.sol
LibOtcOrdersStorage.sol
LibOwnableStorage.sol
LibProxyStorage.sol
LibReentrancyGuardStorage.sol
LibSimpleFunctionRegistryStorage.sol
LibStorage.sol
LibTransformERC20Storage.sol
AffiliateFeeTransformer.sol
AbstractBridgeAdapter.sol
ArbitrumBridgeAdapter.sol
AvalancheBridgeAdapter.sol
BaseBridgeAdapter.sol
BaseGoerliBridgeAdapter.sol
BridgeProtocols.sol
BSCBridgeAdapter.sol
CeloBridgeAdapter.sol
EthereumBridgeAdapter.sol
FantomBridgeAdapter.sol
IBridgeAdapter.sol
MixinAaveV2.sol
MixinAaveV3.sol
MixinBalancer.sol
MixinBalancerV2Batch.sol
MixinBancorV3.sol
MixinBarter.sol
MixinCompound.sol
MixinCryptoCom.sol
MixinCurve.sol
MixinCurveV2.sol
MixinDodo.sol
MixinDodoV2.sol
MixinGMX.sol
MixinKyberDmm.sol
MixinKyberElastic.sol
MixinLido.sol
MixinMakerPSM.sol
MixinMaverickV1.sol
MixinMooniswap.sol
MixinMStable.sol
MixinNerve.sol
MixinPlatypus.sol
MixinSolidly.sol
MixinSynthetix.sol
MixinTraderJoeV2.sol
MixinUniswap.sol
MixinUniswapV2.sol
MixinUniswapV3.sol
MixinVelodromeV2.sol
MixinWOOFi.sol
MixinZeroExBridge.sol
OptimismBridgeAdapter.sol
PolygonBridgeAdapter.sol
FillQuoteTransformer.sol
IERC20Transformer.sol
LibERC20Transformer.sol
LogMetadataTransformer.sol
PayTakerTransformer.sol
PositiveSlippageFeeTransformer.sol
Transformer.sol
WethTransformer.sol
IERC1155Token.sol
IERC721Token.sol
IFeeRecipient.sol
ILiquidityProvider.sol
IMooniswapPool.sol
IPropertyValidator.sol
ITakerCallback.sol
IUniswapV2Pair.sol
IUniswapV3Pool.sol
IERC20Bridge.sol
IStaking.sol
ZeroEx.sol
ZeroExOptimized.sol
ZRXToken.sol
WETH9.sol
ISablier.sol
WETH9V06.sol
OwnableUpgradeable.sol
draft-IERC1822Upgradeable.sol
IERC1967Upgradeable.sol
IBeaconUpgradeable.sol
ERC1967UpgradeUpgradeable.sol
Initializable.sol
UUPSUpgradeable.sol
AddressUpgradeable.sol
ContextUpgradeable.sol
StorageSlotUpgradeable.sol
AccessControl.sol
IAccessControl.sol
GovernorCountingSimple.sol
GovernorSettings.sol
GovernorTimelockControl.sol
GovernorVotes.sol
GovernorVotesQuorumFraction.sol
IGovernorTimelock.sol
Governor.sol
IGovernor.sol
TimelockController.sol
IVotes.sol
IERC1155Receiver.sol
ERC20.sol
draft-ERC20Permit.sol
draft-IERC20Permit.sol
ERC20Wrapper.sol
IERC20Metadata.sol
IERC20.sol
SafeERC20.sol
IERC721Receiver.sol
Address.sol
Checkpoints.sol
Context.sol
Counters.sol
ECDSA.sol
EIP712.sol
ERC165.sol
IERC165.sol
Math.sol
SafeCast.sol
Strings.sol
DoubleEndedQueue.sol
Timers.sol
LibERC20TokenV08.sol
CallWithGas.sol
IZeroExGovernor.sol
IZeroExVotes.sol
SecurityCouncil.sol
ZeroExProtocolGovernor.sol
ZeroExTimelock.sol
ZeroExTreasuryGovernor.sol
ZeroExVotes.sol
ZRXWrappedToken.sol
AuthorizableV08.sol
LibAuthorizableRichErrorsV08.sol
LibBytesRichErrorsV08.sol
LibMathRichErrorsV08.sol
LibOwnableRichErrorsV08.sol
LibReentrancyGuardRichErrorsV08.sol
LibRichErrorsV08.sol
LibSafeMathRichErrorsV08.sol
IAuthorizableV08.sol
IOwnableV08.sol
LibBytesV08.sol
LibMathV08.sol
OwnableV08.sol
ReentrancyGuardV08.sol
PermissionlessTransformerDeployer.sol
IOwnable.sol
LibBytes.sol
LibBytesRichErrors.sol
LibOwnableRichErrors.sol
LibReentrancyGuardRichErrors.sol
LibRichErrors.sol
LibSafeMath.sol
LibSafeMathRichErrors.sol
Ownable.sol
ReentrancyGuard.sol
TestLibBytes.sol
TestLibRichErrors.sol
TestLibSafeMath.sol
TestOwnable.sol
TestReentrancyGuard.sol
LibReentrancyGuardRichErrorsV06.sol