1.2.0 • Published 6 years ago
@tangleid/credential v1.2.0
@tangleid/credential
Utilities for generating credential.
Installation
Install using npm:
npm install @tangleid/credentialor using yarn:
yarn add @tangleid/credentialAPI Reference
credential~generateCredential(params)
| Param | Type | Default | Description |
|---|---|---|---|
| params | object | Parameters for generating the credential object. | |
| params.subject | object | Subject of the credential. | |
| params.metadata | object | {} | Metadata of the credential. |
| params.context | object | 'https://www.w3.org/2018/credentials/v1' | Context URLs of the credential. |
| params.alias | object | {} | Context alias of the credential. |
Generate credential object.
Returns: object - Credential object in JSON-LD format.