npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

credo-ts-indy-vdr-proxy-server

v0.2.0

Published

Indy VDR Proxy server based on credo-ts

Downloads

11

Readme

Credo Indy VDR Proxy Server

A server that exposes a REST API to resolve objects in Indy networks. It is built in NestJs and based on Credo.

Although it can be used as a general gateway to multiple Indy networks (much in the same way Universal Resolver does), this server was developed to reduce the workload needed by a mobile application, as multiple ZMQ sockets must be opened when supporting multiple Indy networks and there might be issues in some mobile OS and Mobile Network Operators.

Usage

In order to run the server in standalone mode, you just need to install all dependencies by doing:

yarn install

and then go to server directory and execute:

cd packages/server
yarn run start

By default, Indy VDR Proxy Server runs at port 3000 and supports only BCovrin Test network. This can be overriden by either updating the configuration file located at res/app.config.json or providing your own by setting the environment variable INDY_VDR_PROXY_CONFIG_PATH. E.g.:

INDY_VDR_PROXY_CONFIG_PATH=/my-directory/my-config.file.json yarn run start

If you want to integrate Indy VDR Proxy in your own NestJS-based project, you can by importing IndyVdrProxyServerModule. You'll need to call register method passing an IndyVdrProxyAgent instance (which could be your own Credo-based Agent as long as it contains all required modules):

import { setupAgent } from "credo-ts-indy-vdr-proxy-server"

IndyVdrProxyModule.register(setupAgent({ networks }))

Endpoints

All endpoints use HTTP GET method.

  • /did/{fully qualified or legacy Indy did}: resolve a DID Document
  • /schema/{fully qualified AnonCreds schema ID}: resolve an AnonCreds Schema
  • /credential-definition/{fully qualified or legacy AnonCreds credential definition ID}: resolve an AnonCreds Credential Definition
  • /revocation-registry-definition/{fully qualified or legacy AnonCreds revocation registry definition ID}: resolve an AnonCreds Revocation Registry Definition
  • /revocation-status-list/{fully qualified or legacy AnonCreds revocation registry definition ID}/{timestamp}: resolve an AnonCreds Revocation Status List

The response for each follows the format used in @credo-ts/anoncreds module. It's a JSON containing three elements:

{
  objectTypeInCamelCase: { ... },
  objectTypeInCamelCaseMetadata: { ... };
  resolutionMetadata: { error?: 'invalid' | 'notFound' | 'unsupportedAnonCredsMethod' | string;
    message?: string;};
}