Skip to content
This repository has been archived by the owner on Nov 8, 2024. It is now read-only.
/ lifi-issuer Public archive

Script responsible for issuing Li.Fi Loyalty Pass PDAs using the Gateway Protocol

Notifications You must be signed in to change notification settings

GatewayLabs/lifi-issuer

Repository files navigation

LI.FI <> Gateway

Important

Please reference Handover Documentation before spawning this project:

Table of Contents

Getting Started

  1. Install project dependencies

    <!-- npm -->
    npm i
    
    <!-- yarn -->
    yarn
    
    <!-- pnpm -->
    pnpm i
    
  2. (optional) Start local Redis container

    <!-- npm -->
    npm run redis
    
    <!-- yarn -->
    yarn redis
    
    <!-- pnpm -->
    pnpm redis
    
  3. Start Server

    Development:

    <!-- npm -->
    npm run dev
    
    <!-- yarn -->
    yarn dev
    
    <!-- pnpm -->
    pnpm dev
    

    Production:

    <!-- npm -->
    npm start
    
    <!-- yarn -->
    yarn start
    
    <!-- pnpm -->
    pnmp start
    
  4. (optional) Tear down Redis container

    <!-- npm -->
    npm run redis:stop
    
    <!-- yarn -->
    yarn redis:stop
    
    <!-- pnpm -->
    pnpm redis:stop
    

Available Endpoints

POST /stats/wallet

Generates JSON list of GatewayMetrics

Headers:

  • month: reference Month enum
  • (optional) input: absolute path for input JSON file (default: ./data/input.json)
  • (optional) output: absolute path for output (default: ./data/output.json)

POST /issue/credential

Enqueues Credential metadata to be issued by the issue-credential BullMQ Queue.

Headers:

  • credential: Filepath to JSON list of GatewayMetrics for wallets (e.g. ./data/output.json)

POST /issue/loyalty-pass

Enqueues list of wallets to be created or updated by the create_or_update_loyalty_pass BullMQ Queue.

Headers:

  • loyalty-pass: Filepath to JSON list of wallets

About

Script responsible for issuing Li.Fi Loyalty Pass PDAs using the Gateway Protocol

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages