Skip to content

UVerify makes blockchain technology accessible to everyone, regardless of prior experience. Effortlessly secure your file or text hashes on the Cardano blockchain.

License

Notifications You must be signed in to change notification settings

UVerify-io/uverify-backend

πŸ’Ž Welcome to UVerify: Your Gateway to Blockchain Simplicity

Build Workflow Status Test Workflow Status Coverage Release Workflow Status Conventional Commits Join our Discord CLA assistant

UVerify makes blockchain technology accessible to everyone, regardless of prior experience. Effortlessly secure your file or text hashes on the Cardano blockchain. Want to try it out before diving into the code? Visit app.uverify.io to explore the app.

πŸš€ Getting Started

Prerequisites

  • Java 17 or higher
  • Maven 3.8+
  • Git
  • Docker (optional, for containerized setup)

🐳 Running with Docker

You can run the backend as a Docker container without installing Java or Maven locally.

  1. Copy and configure your environment file:

    cp src/main/resources/.env.example .env

    Edit .env as needed.

  2. Run the backend container:

    docker run --env-file .env -p 9090:9090 uverify/uverify-backend:latest

    The backend will be available at http://localhost:9090.

πŸ—οΈ Running Full Stack with Docker Compose

To run the backend, ui, and database together, you can use Docker Compose.
An example docker-compose.yml is available here.

  1. Download the example compose file:

    curl -O https://raw.githubusercontent.com/UVerify-io/.github/main/scripts/docker-compose.yml
  2. Copy and configure your environment file as above.

  3. Start all services:

    docker compose up

    This will start the backend, ui, and database containers. By default, the frontend will be available at http://localhost:3000 and the backend at http://localhost:9090.

Tip: You can customize the services and ports in the docker-compose.yml file as needed.

Installation

  1. Clone the repository:

    git clone https://github.com/UVerify-io/uverify-backend.git
    cd uverify-backend
  2. Configure environment variables:

    • Copy the .env.example file to .env:
      cp src/main/resources/.env.example .env
    • Edit the .env file with your configuration (see Environment Variables section)
  3. Build and run the application:

    mvn clean package
    java -jar target/uverify-backend-1.5.1.jar

πŸ”§ Environment Variables

The application requires a .env file either in the same folder as the JAR file or in the src/main/resources folder when running with IntelliJ.

Variable Description Example Required
SPRING_ACTIVE_PROFILES Active Spring profiles (h2/postgres, mainnet/preprod, https) preprod,h2 Yes
LOG_LEVEL Logging level for the application INFO No
LOG_FILE Log file path (if not set, logs to console) ./logs/uverify.log No
CORS_ALLOWED_ORIGINS Allowed origins for CORS http://localhost:3000 No
KEY_STORE_PASSWORD Password for the keystore (required when https profile is active) password123 No*
DB_URL Database connection URL when using H2 jdbc:h2:./data/db No
SERVICE_USER_ADDRESS The wallet address for the service addr_test1qqgmew8y57fsfc3... Yes
SERVICE_ACCOUNT_MNEMONIC The testnet account mnemonic (for testing purposes) word1 word2 ... word24 No
FACILITATOR_ACCOUNT_MNEMONIC Mnemonic to sign authentication messages for state queries word1 word2 ... word24 No
BLOCKFROST_PROJECT_ID Your Blockfrost project ID preprod123abc Yes**
BLOCKFROST_BASE_URL Blockfrost API base URL https://cardano-preprod.blockfrost.io/api/v0/ Yes**
CARDANO_BACKEND_TYPE Backend type (koios or blockfrost) blockfrost Yes
CARDANO_NETWORK Cardano network to use (PREPROD or MAINNET) PREPROD Yes
CONNECTED_GOODS_EXTENSION_ENABLED Enable Connected Goods extension false No
CONNECTED_GOODS_SERVICE_WALLET_ADDRESS Address for testing Connected Goods extension addr_test1... No
CONNECTED_GOODS_ENCRYPTION_SALT Salt for double encryption of user data randomsalt123 No
TADAMON_EXTENSION_ENABLED Enable Tadamon extension false No
TADAMON_ALLOWED_ADDRESSES Addresses allowed to use Tadamon extension addr1,addr2 No
TADAMON_GOOGLE_SHEETS_PRIVATE_KEY Google Sheets API private key -----BEGIN PRIVATE KEY-----\n... No
TADAMON_GOOGLE_SHEETS_SERVICE_ACCOUNT Google Sheets service account email account@project.iam.gserviceaccount.com No
TADAMON_GOOGLE_SHEETS_ID Google Sheets ID 1FZZA0N...AaaAVe No

* Only required if you use the https profile. ** Only required if you use the blockfrost backend type.

πŸ’™ Contributing

We welcome all contributions! Please read our Contributing Guidelines before getting started.

Important Notes:

  • Use semantic commits for all contributions.
  • Sign the Contributor License Agreement (CLA) before committing. You can review the CLA here and sign it via CLA Assistant. The CLA bot will guide you through the process when you open a pull request.
  • For feature requests or tasks, please open an issue first to align with the project goals.

πŸ“š Additional Documents

πŸ“œ License

This project is licensed under the AGPL. If this license does not match your use case, feel free to reach out to us at hello@uverify.io to discuss alternative licensing options.

About

UVerify makes blockchain technology accessible to everyone, regardless of prior experience. Effortlessly secure your file or text hashes on the Cardano blockchain.

Topics

Resources

License

Code of conduct

Security policy

Stars

Watchers

Forks

Contributors 3

  •  
  •  
  •