DEV Community

Asjad Ahmed Khan for Kalp Studio

Posted on

Generating API Endpoints of your Deployed Smart Contract over Polygon Blockchain using the Kalp API Gateway

API endpoints are essential for integrating and automating various processes in blockchain development. Kalp Studio provides a robust platform that allows developers to efficiently create, manage, and generate API endpoints for their smart contracts.

This tutorial will explore how to generate API endpoints for your deployed smart contract over the Polygon blockchain using the Kalp API Gateway.

Prerequisites

Now that we have the basic set-up ready. Let’s dive into the API Endpoint generation steps right away.

Accessing the Kalp API Gateway

  • On your Kalp Studio dashboard, under the “Our Products” section, you can see the API Gateway card. Under the card, click on the Explore button.

Kalp Studio Dashboard

  • Once you click the Explore button, you will be redirected to the API Gateways page, where all your deployed smart contracts will be listed. You can see the smart contract ID, the name of the smart contract, Category, Status, Network, Blockchain, etc.

Kalp API Gateway Dashboard

The smart contract we deployed in our previous tutorial is also listed as SoliditySmartContract.

  • Choose your desired smart contract (SoliditySmartContract for this tutorial) and scroll towards the right, you can see the section named “Action”. Under this column, click on Generate Endpoints.

Generate API Endpoints

  • Once you click on Generate Endpoints, you’ll get the alert stating that you have successfully and the button will change to “Re-Generate Endpoints”, confirming that the endpoints have been generated.

Re-generate API Endpoints

  • To explore the endpoints, click on the ID of your desired smart contract.

Exploring API Endpoints

  • Here, you can now see that the endpoints are now accessible. Other details include the Method, Function Name, Route, etc. You can also find the Smart Contract Address mentioned above.

API Details

  • Click the Check Params button to explore the Route Details. After clicking on it, you’ll see a pop-up where you can check the Params and the API Auth Key.

Route Details

(Read the documentation here to learn more about API Auth Key.)

Conclusion

Generating API endpoints for your deployed smart contract on the Polygon blockchain using Kalp API Gateway is straightforward. By leveraging this powerful tool, you can simplify the interaction with your smart contract and integrate blockchain functionality into your application without deep blockchain expertise.

Check out our official documentation here to continue exploring what more Kalp Studio can do. If you have any queries, join our Discord server and let’s continue the discussion there.

Until then, stay tuned for the next tutorial.

Top comments (0)