typingdnaclient-rxjs
TypeScript icon, indicating that this package has built-in type declarations

1.2.0 • Public • Published

typingdnaclient-rxjs

RxJS wrapper for the TypingDna API

npm Infrastructure Tests

Installation

npm install typingdnaclient-rxjs --save

Instantiation and Usage

import { TypingDNAReactiveClient } from 'typingdnaclient-rxjs';

const client = new TypingDNAReactiveClient(apiKey, apiSecret);
client.verify(userId, pattern).subscribe(console.log, console.error);

The default TypingDNA API Server is api.typingdna.com. You can use the alternative server tdna-api.azurewebsites.net.

const server = 'tdna-api.azurewebsites.net';
const client = new TypingDNAReactiveClient(apiKey, apiSecret, server);

Available Methods

class TypingDNAReactiveClient {
  auto(
    userId: string,
    typingPattern: string,
    options?: { customField: any }
  ): Observable<AutoResponse>;

  save(userId: string, typingPattern: string): Observable<any>;

  verify(
    userId: string,
    typingPattern: string,
    quality: number,
    options: { deviceSimilarityOnly: boolean }
  ): Observable<VerifyResponse>;
}

Package Sidebar

Install

npm i typingdnaclient-rxjs

Weekly Downloads

1

Version

1.2.0

License

MIT

Unpacked Size

13.4 kB

Total Files

14

Last publish

Collaborators

  • aerabi