Getting Started

Get up and running with our API libraries and start developing your Mantle integration.

Get started in 3 steps:

  1. Obtain your API key
  2. Obtain your available product ids
  3. Integrate the API in your app

1. Obtain your API key

You can start integrating Mantle into your app as soon as you have your API key. The API key is needed in the header for all the API requests to Mantle.

Your API key is available in the Administration Panel, in the My API Key page.

If you cannot see your API key, this means an API key has not yet been created for you:

If you have the User Admin role, you can create an API key for yourself in the API Keys page
If you don't have this permission, you will have to contact your Mantle account's administrators and ask them to create the API key for you.
You should be able to make calls to our API. Let's make a call to test your API key.

Let's try it out!

curl https://api.mantleblockchain.com/apikeys \
   -H 'x-api-key: {{YOUR_API_KEY}}'

Usage: Copy this curl request and replace {{YOUR_API_KEY}} by your own API key, then run it in your terminal.

Response: You should receive your own API key as a response.

👍

Congratulations!

You now have a working API key.

2. Obtain your available product ids

To be able to use one of your product, you will need its id. Since you are now able to call the API, a simple call can provide you with a list of all products and their information.

From there, you will be able to specify which product you want to use.

Let's try it out!

curl https://api.mantleblockchain.com/products \
   -H 'x-api-key: {{YOUR_API_KEY}}'

Usage: Copy this curl request and replace {{YOUR_API_KEY}} by your own API key, then run it in your terminal.

Response: You should receive a list of all your products as a response.

👍

Congratulations!

You now have the list of all your available products.

3. Integrate the API in your app

There are two ways to integrate the API into your application:

Rest API requests: Make API requests directly from within your code. Refer to the API documentation.

Mantle Client Libraries: Install one of our Client Libraries.