@mikejerred/points-sdk
TypeScript icon, indicating that this package has built-in type declarations

1.0.1 • Public • Published

Points SDK

A client SDK for interacting with the points REST API.

Installation

Install from npm:

npm install @mikejerred/points-sdk --save

Usage Example

import { createCampaign, createClient } from '@mikejerred/points-sdk';

const { apiKey, campaignId } = await createCampaign();
const client = createClient(apiKey, campaignId);

await client.distributePoints(
  'event_name',
  { points: 1000, address: '0x24e5bec76fa3d750bfa97bdbf16b377f6b13af15' },
);

const points = await client.getPoints('0x24e5bec76fa3d750bfa97bdbf16b377f6b13af15');

Readme

Keywords

none

Package Sidebar

Install

npm i @mikejerred/points-sdk

Weekly Downloads

0

Version

1.0.1

License

none

Unpacked Size

64.6 kB

Total Files

20

Last publish

Collaborators

  • mikejerred