• Stars
    star
    186
  • Rank 207,316 (Top 5 %)
  • Language
    TypeScript
  • License
    Apache License 2.0
  • Created about 3 years ago
  • Updated almost 3 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details



thirdweb Contracts

npm version Build Status Join our Discord!

Collection of smart contracts deployable via the thirdweb SDK, dashboard and CLI


Installation

npm i @thirdweb-dev/contracts

Running Tests

  1. yarn: install contracts dependencies
  2. forge install: install tests dependencies
  3. forge test: run the tests

This repository is a hybrid hardhat and forge project.

First install the relevant dependencies of the project:

yarn

forge install

To compile contracts, run:

forge build

Or, if you prefer hardhat, you can run:

npx hardhat compile

To run tests:

forge test

To export the ABIs of the contracts in the /contracts directory, run:

npx hardhat export-abi

To run any scripts in the /scripts directory, run:

npx hardhat run scripts/{path to the script}

Pre-built Contracts

Pre-built contracts are written by the thirdweb team, and cover the most common use cases for smart contracts.

Release pages for pre-built contracts:

Learn more about pre-built contracts

Extensions

Extensions are building blocks that help enrich smart contracts with features.

Some blocks come packaged together as Base Contracts, which come with a full set of features out of the box that you can modify and extend. These contracts are available at contracts/base/.

Other (smaller) blocks are Features, which provide a way for you to pick and choose which individual pieces you want to put into your contract; with full customization of how those features work. These are available at contracts/extension/.

Learn more about extensions

Deployments

The thirdweb registry (TWRegistry) and factory (TWFactory) have been deployed on the following chains:

TWRegistry is deployed to a common address on all mentioned networks. TWFactory is deployed to a common address on all mentioned networks except Fantom mainnet.

Contract Audits

Bug reports

Found a security issue with our smart contracts? Send bug reports to [email protected] and we'll continue communicating with you from there. We're actively developing a bug bounty program; bug report payouts happen on a case by case basis, for now.

Feedback

If you have any feedback, please reach out to us at [email protected].

Authors

License

Apache 2.0

More Repositories

1

js

Best in class web3 SDKs for Browser, Node and Mobile apps
TypeScript
397
star
2

typescript-sdk

Best in class web3 SDK for Browser, Node and Mobile apps
TypeScript
135
star
3

unity-sdk

Best in class web3 SDK for Unity games
JavaScript
103
star
4

python-sdk

Best in class web3 SDK for Python 3.7+
Python
82
star
5

dynamic-contracts

Architectural pattern for writing dynamic smart contracts in Solidity.
Solidity
69
star
6

go-sdk

Best in class web3 SDK for Go 1.16+
Go
34
star
7

docs

thirdweb docs portal
HTML
33
star
8

thirdweb-cli

Publish and deploy smart contracts without dealing with private keys
TypeScript
27
star
9

nftlabs-sdk-example

TypeScript
25
star
10

nftpacks-contracts

NFT Packs is a tool for NFT giveaways. Bundle ERC 721 NFTs as rewards into packs and airdrop them to an audience.
Solidity
19
star
11

examples

TypeScript
17
star
12

hashlips-to-thirdweb

TypeScript
16
star
13

docs-v2

thirdweb docs
MDX
13
star
14

portal

portal.thirdweb.com
TypeScript
12
star
15

ui

TypeScript
11
star
16

generate-contract-snapshot

Generate a snapshot of owners with quantity for any erc721/erc1155, on any chain.
TypeScript
11
star
17

shopify-thirdweb-theme

thirdweb shopify theme
JavaScript
10
star
18

niftyswap.gg

Trade NFTs.
Solidity
10
star
19

nextjs-membership-lounge

TypeScript
10
star
20

proxy-contract-wallet-example

Example smart contract setup for mapping an end-user wallet to an ownable smart contract as its 'proxy wallet'.
Solidity
9
star
21

modular-contracts

The next iteration of thirdweb smart contracts. Install hooks into core contracts.
Solidity
7
star
22

auth

Best in class wallet authentication for Node backends
TypeScript
6
star
23

ozdefender-autotask

JavaScript
5
star
24

support-discord-bot

A self-hosted dedicated forum-based support Discord bot for the thirdweb community.
JavaScript
5
star
25

web3warriors

Landing page for Web3Warriors
TypeScript
5
star
26

built-on-thirdweb

TypeScript
5
star
27

qr-membership-website

JavaScript
4
star
28

pack-protocol

$PACK Protocol lets anyone create and sell packs filled with rewards. A pack can be opened only once. On opening a pack, a reward from the pack is distributed to the pack opener.
TypeScript
4
star
29

signature-minting-to-qr-code

TypeScript
3
star
30

shopify-demo-store

TypeScript
3
star
31

portal-content

3
star
32

widgets

TypeScript
2
star
33

unity-webgl-template

HTML
2
star
34

unity-webgl-sdk

C#
2
star
35

signature-based-minting-sample-app

TypeScript
2
star
36

chain-icons

TypeScript
2
star
37

cookiedao

The best DAO for cookie lovers
JavaScript
2
star
38

farza-nft

TypeScript
1
star
39

deterministic-deploy-demo

TypeScript
1
star
40

react-unity-webgl-example

Mathematica
1
star
41

hotpotato

TypeScript
1
star
42

nftlabs-python-sdk-example

Python
1
star
43

guides

To keep tracks of guides that go on portal/guides.
1
star
44

bakery.gg

Jake/Nacho/Doug Hackweek project
Solidity
1
star
45

pack-protocol-subgraph

TypeScript
1
star
46

unity-sdk-bridge

TypeScript
1
star
47

contracts-next-scripts

Scripts showing how to interact with hooks architecture using the thirdweb v5 SDK.
JavaScript
1
star