Skip to content

cardanoapi/dbsync-api

Repository files navigation

dbsync-api Service

The dbsync-api service is a Node.js application designed to provide API access to interact with the dbsync database. This service enables efficient data retrieval for Cardano-related operations.

Requirements

Before running the service, ensure the following dependencies are installed:

  • PostgreSQL server

Installation

  1. Run this command for package installation
      yarn install
  2. Create new file .env and copy env variables form .env.example to .env and update the env variables.
  • DATABASE_URL: PostgreSQL database URL for dbsync_sanchonet. For preprod and preview update database instance accordingly.
  • PORT: Port for running the server. Default value is 8080
  • CORS_ENABLE: CORS support for cross-origin requests.
  1. Run the following command to generate the database client and creating the required table mentioned in schema

        yarn prisma generate
  2. Now finally run the below command to start the dbsync-api service:

        yarn dev

Now goto http://localhost:8080/api/docs to see list of api in swaggerDocs.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors 4

  •  
  •  
  •  
  •  

Languages