@tg-app/validate-service-client
TypeScript icon, indicating that this package has built-in type declarations

1.0.2 • Public • Published

@tg-app/validate-service-client

Client for tg-app-validate-service for frontend and Node.js.

Install

npm i -S @tg-app/validate-service-client
# or
yarn add @tg-app/validate-service-client

Usage

Frontend

import { WebClient } from '@tg-app/validate-service-client'

const client = new WebClient('https://example.com/validate-service') // or relative or absolute path

client.parseInitData(initData).then(webAppInitData => {
  // do it
})

Node.js

import { NodeClient } from '@tg-app/validate-service-client/node'

const client = new NodeClient('https://example.com/validate-service')

client.parseInitData(initData).then(webAppInitData => {
  // do it
})

Readme

Keywords

none

Package Sidebar

Install

npm i @tg-app/validate-service-client

Weekly Downloads

0

Version

1.0.2

License

none

Unpacked Size

20.9 kB

Total Files

21

Last publish

Collaborators

  • bigslycat