Skip to content

SmartBase-SK/tatrapayplus-node

Repository files navigation

Tatrapay+ Node.js SDK

Release Build status codecov Commit activity License

Node.js SDK for Tatrapay+ payment gateway.

Types of application are generated automatically from swagger structure via openapi-typescript.

Type generation

To generate new types after OpenAPI structure has been changed please run

npx openapi-typescript ./tatrapayplus_api_sandbox.json -o ./src/paths.d.ts

Logging

TBPlusLogger is exported from the package and can be subclassed to customize log output:

import { TBPlusSDK, TBPlusLogger } from "@tatrabanka/tatrapayplus-node";

class ConsoleLogger extends TBPlusLogger {
  protected writeLine(line: string): void {
    console.log("[ConsoleLogger]", line);
  }
}

const logger = new ConsoleLogger();
const sdk = new TBPlusSDK(API_KEY, API_SECRET, {}, logger);

Pass false to the logger constructor to disable masking of sensitive fields:

const logger = new TBPlusLogger(false);

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages