A reference implementation of a Cardano CIP-26 compliant offchain metadata registry.
This repository contains an implementaiton of a CIP-26 compliant offchain metadata registry for Cardano. It exposes an extended API (see the OpenAPI v3 spec hosted by our staging deployments here) with regards to the one specified in CIP-26 to allow for more querying options and also write access to the registry to get rid of parts of the GitHub based process (but still stick to the known GitHub repository as a single source of truth for now).
Implementation of client tools for metadata creation can be found here and at IOG's reference implementation repository.
For building you need
Clone this repository
$ git clone git@github.com:cardano-foundation/cf-token-metadata-registry.git
cd
into the directory where git
did clone the sources into and build the application via Maven
$ cd cf-token-metadata-registry
$ mvn package
The simplest approach to running the application after having built it is to use the provided Docker Compose setup and Docker containers included in the various sub folders. This is done simply by calling the following command in the root directory of this repository:
$ docker compose up
Note
If you change the code, in order to make the changes visible to docker compose you need to rebuild the local image
with docker compose build
and then docker compose up
will take care to restart containers who have a new image available
The complete Docker Compose setup runs the following services:
- Setup a Postgres database in a docker container and exposes it to
localhost
on port5432
(service namedb
) - Starts the actual Spring application that exposes the CIP-26 REST API and exposes it to
localhost
on port8081
(service nameapi
)
To test if the API is running query its health endpoint by executing:
$ curl http://localhost:8081/actuator/health
Have a look at the .env file for the various configuration options.
At the moment the application needs a PostgreSQL database as a storage layer which might change in the future. Database evolutions
are managed by the api
project using flyway.
Offchain metadata related:
- Expose CIP-26 compliant REST API
WIP:
- Add CIP-88 support
- Expose verification API for offchain metadata based on extended CIP-26 trust concept
- Provide a CLI application for metadata creation and verification
- Implement metadata verification based on public key registries
File an issue or a PR or reach out directly to us if you want to contribute.
When contributing to this project and interacting with others, please follow our Contributing Guidelines and Code of Conduct.
Thanks for visiting and enjoy ❤️!