JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 5
  • Score
    100M100P100Q40724F
  • License MIT

This module provides a TypeScript class, Seon, to interact with Seon's Fraud API. The Seon class allows you to send fraud detection requests using the provided API key and endpoint URL.

Package Exports

  • seon-sdk

Readme

seon-sdk

This module provides a TypeScript class, Seon, to interact with Seon's Fraud API. The Seon class allows you to send fraud detection requests using the provided API key and endpoint URL.

https://docs.seon.io/api-reference/fraud-api

Installation

You can install the package using npm, yarn, or pnpm.

pnpm add seon-sdk

yarn install seon-sdk

npm install seon-sdk

Usage

import { Seon, FraudApiRequest, FraudApiResponse } from "seon-sdk";

const seon = new Seon(process.env.SEON_KEY, process.env.SEON_URL);

const request: FraudApiRequest = {
  /* PARAMETERS */
};

const response: FraudApiResponse = await seon.fraud(request);

console.log(response);

tsup

Bundle your TypeScript library with no config, powered by esbuild.

https://tsup.egoist.dev/

How to use this

  1. install dependencies
# pnpm
$ pnpm install

# yarn
$ yarn install

# npm
$ npm install
  1. Add your code to src
  2. Add export statement to src/index.ts
  3. Test build command to build src. Once the command works properly, you will see dist folder.
# pnpm
$ pnpm run build

# yarn
$ yarn run build

# npm
$ npm run build
  1. Publish your package
$ npm publish

test package

https://www.npmjs.com/package/seon-sdk