@anima-protocol/anima
v0.1.7
Published
Anima.js is a JavaScript library for interacting with the Anima Protocol.
Downloads
1,229
Keywords
Readme
Anima protocol implementation in JavaScript
This module implements the anima protocol client side, allowing you to generate issuing and sharing request in the browser or in NodeJS.
Install
Anima.js can be installed through the npm registry:
npm install @anima-protocol/anima
Or with yarn:
yarn add @anima-protocol/anima
Create an issuing request
Creating an issuing request is as simple as:
import { Challenges } from "@anima-protocol/anima";
const challenge = Challenges.GetIssuingRequest(
"anima:schema:your-schema-id",
// The fields you want to issue
{
name: "John Doe",
},
// The owner's information
{
public_address: "0x0000000000000000000000000000000000000000",
chain: "EVM",
},
// The issuer's information
{
id: "your-issuer-id",
public_address: "0x0000000000000000000000000000000000000000",
chain: "EVM",
}
);
console.log(challenge);
The challenge
variable will contain the issuing request, which you can then send to your API.
Examples
You can find more examples in the examples folder.
Documentation
You can find the documentation about the anima protocol here.