Skip to content

Latest commit

 

History

History
50 lines (41 loc) · 791 Bytes

README.md

File metadata and controls

50 lines (41 loc) · 791 Bytes

Autogram SDK - use Autogram signer from web

Installation

npm install autogram-sdk

Usage

import { FullClient } from ".";

const client = new FullClient();

const { content, issuedBy, signedBy } = await client.sign(
  {
    content: "hello world",
    filename: "hello.txt",
  },
  {
    level: "XAdES_BASELINE_B",
    container: "ASiC_E",
  },
  "text/plain",
  true
);

Usage on web

<script src="dist/index.global.js"></script>
<script>
  const client = new AutogramSDK.FullClient();

  const { content, issuedBy, signedBy } = await client.sign(
    {
      content: "hello world",
      filename: "hello.txt",
    },
    {
      level: "XAdES_BASELINE_B",
      container: "ASiC_E",
    },
    "text/plain",
    true
  );
</script>