vrchat-client
TypeScript icon, indicating that this package has built-in type declarations

0.2.3 • Public • Published

vrchat-client

Build Status Maintainability MIT License

Unofficial VRChat API Client for Node.js

Usage

Getting started

npm i vrchat-client
# OR 
yarn add vrchat-client
import vrc from 'vrchat-client'
// or
const vrc = require('vrchat-client')
 
// all methods return Promise
let api = await vrc.login(username, password)

User API

  • User info
api.user.getUserInfo()
  • Update user info
api.user.updateUserInfo({
  email: "example@example.com",
  birthday: "",
  status: "active",
  statusDescription: "comment"
})
  • Get friends list
api.user.getFriends({
  offset: 1,
  n: 1,
  offline: false,
})
  • get friend status
api.user.getFriendStatus('user id')
  • Send friend request
api.user.sendFriendRequest('user id')
  • Unfriend
api.user.unfriend('user id')
  • Accept friend request
api.user.acceptFriend('notification id')
  • Get user by ID
api.user.getById('user id')
  • Get user by name
api.user.getByName('user name')
  • Get user list
// All Users
api.user.search.all({
  search: '',
  n: 1,
  offset: 1,
  developerType: 'none'
})

Favorite API

  • Add Favorite
api.favorite.add('type', 'object id')
// ?
api.favorite.add.avatar('avatar id')
api.favorite.add.world('world id')
api.favorite.add.user('user id')
  • Get favorite
api.favorite.getInfo('favorite id')
  • List Favorite
api.favorite.list('type')
  • Delete favorite
api.favortite.delete('favorite id')

World API

  • Get by id
api.world.getById('world id')
  • List worlds
api.world.search.all({
  options: any
})
  • Delete world
api.world.delete('world id')
  • Get world meta data
api.world.getMetadata('world id')
  • Get instance with tags
api.world.getInstanceWithTags('world id', 'instance id')

Avatar API

  • Get by ID
api.avatar.getById('avatar id')
  • Choose avatar
api.avatar.choose('avatar id')
  • List avatar
api.avatar.search({
  options: any,
})

Moderation API

  • Send moderation
api.moderation.send('user id')
  • Send player moderation
// Block user
api.moderation.block('user id')
// Unblock user
api.moderation.unblock('user id')
// Mute user
api.moderation.mute('user id')
// Unmute
api.moderation.unmute('user id')
  • Delete moderation
api.moderation.delete('moderation id')
  • Clear all moderation
api.moderation.clear('user id')
  • Get against
api.moderation.getAgainstSelf()
  • Get player's
api.moderation.getSentlist()

Notification API

  • Send notification
api.notification.send.friendRequest('user id')
api.notification.send.invite('user id', 'world id', 'message')
  • Mark as read
api.notification.markAsRead('notification id')
  • Delete notification
api.notification.delete('notification id')
  • Get all notification
api.notification.getAll({
  type: 'type',
  send: true,
  after: 'date',
})

Readme

Keywords

Package Sidebar

Install

npm i vrchat-client

Weekly Downloads

10

Version

0.2.3

License

MIT

Unpacked Size

32.8 kB

Total Files

37

Last publish

Collaborators

  • neverclear
  • linatsukusu