Skip to main content
Deploying a subgraph on Oasis with Mobula’s infrastructure is a simple process. This guide will walk you through the steps to get your subgraph up and running on the Oasis network.

What you’ll need

  • Basic knowledge of The Graph and subgraphs.
  • Your subgraph project files
  • The Graph CLI installed
  • A Mobula API key (for authentication)

Walkthrough

1

Prepare Your Subgraph

Make sure your subgraph is set up for Oasis. Modify your subgraph.yaml file to point to Oasis Emerald specific contracts and events. If you don’t have a subgraph yet, you can clone the Uniswap V2 (YuzuSwap) subgraph template and adjust it for Oasis:
git clone https://github.com/MobulaFi/univ2-subgraph-oasis
2

Install Dependencies

Ensure that The Graph CLI is installed:
npm install -g @graphprotocol/graph-cli
3

Build Your Subgraph

Compile your subgraph prior to deployment:
graph codegen && graph build
4

Create the Subgraph

Use the following command to deploy your subgraph:
graph create --node https://subgraph.mobula.io:8020
5

Deploy to Mobula's Oasis Node

Use the following command to deploy your subgraph:
graph deploy --node https://subgraph.mobula.io:8020 --ipfs https://subgraph.mobula.io:5001 --network oasis
6

Authenticate

When prompted, enter your Mobula API key for authentication. For more information on obtaining and using your API key, refer to the authentication section.
7

Monitor Deployment

Once deployment is complete, you’ll receive a URL to track your subgraph’s indexing progress and status.

Best Practices

  • Keep your subgraph regularly updated to maintain compatibility with the latest Oasis Emerald network changes.
  • Thoroughly test your subgraph on a testnet before deploying to the mainnet.
  • Continuously monitor your subgraph’s performance and optimize queries for better efficiency.

Troubleshooting

If you encounter issues during deployment:
  • Carefully review your subgraph.yaml configuration.
  • Confirm that you’re using the correct network name and Mobula node URLs.
  • Make sure your API key is valid and has the required permissions.
Need Assistance? Our support team is available to assist with any questions or deployment issues you may encounter.

Support

Telegram

Support

Slack

Support

Discord

Email Support

Email