vk-ts
v0.22.7
Published
Typesafe lightweight library to make requests to VK api
Downloads
15
Readme
VK TypeScript
Typesafe lightweight library to make requests to VK api
Installation
Using npm:
npm install vk-ts
Using yarn:
yarn add vk-ts
Usage
import VK from 'vk-ts'
// Learn how to get access token here:
// https://vk.com/dev/access_token
const accessToken = 'my_vk_api_token'
const vk = new VK(accessToken)
const info = await vk.accountGetProfileInfo()
console.log(`Hello, ${info.first_name}!`)
Pros
- Typesafe
- Lightweight
Cons
- Small coverage of api
- No built-in authentication
Available api methods
- account.getProfileInfo
- docs.get
- docs.getUploadServer
- docs.save
- docs.upload
- messages.delete
- messages.messagesGetByConversationMessageId
- messages.messagesGetConversationMembers
- messages.messagesRemoveChatUser
- messages.messagesSearch
- messages.messagesSend
- messages.messagesSetActivity
- users.get
- utils.resolveScreenName
- video.save
- video.upload
Haven't found the method you're looking for? Open an issue here