forked from mayocream/vrchat-go
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathopenapi.yaml
More file actions
9979 lines (9909 loc) · 311 KB
/
openapi.yaml
File metadata and controls
9979 lines (9909 loc) · 311 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
openapi: 3.0.3
info:
title: VRChat API Documentation
version: 1.18.1
contact:
name: Unofficial VRChat API Documentation Project
url: https://github.com/VRChatAPI
email: vrchatapi.lpv0t@aries.fyi
termsOfService: https://vrchat.com/legal/
license:
url: https://github.com/vrchatapi/specification/blob/master/LICENSE
name: MIT
description: |-

# Welcome to the VRChat API
Before we begin, we would like to state this is a **COMMUNITY DRIVEN PROJECT**.
This means that everything you read on here was written by the community itself and is **not** officially supported by VRChat.
The documentation is provided "AS IS", and any action you take towards VRChat is completely your own responsibility.
The documentation and additional libraries SHALL ONLY be used for applications interacting with VRChat's API in accordance
with their [Terms of Service](https://hello.vrchat.com/legal) and [Community Guidelines](https://hello.vrchat.com/community-guidelines), and MUST NOT be used for modifying the client, "avatar ripping", or other illegal activities.
Malicious usage or spamming the API may result in account termination.
Certain parts of the API are also more sensitive than others, for example moderation, so please tread extra carefully and read the warnings when present.

Finally, use of the API using applications other than the approved methods (website, VRChat application, Unity SDK) is not officially supported.
VRChat provides no guarantee or support for external applications using the API. Access to API endpoints may break **at any time, without notice**.
Therefore, please **do not ping** VRChat Staff in the VRChat Discord if you are having API problems, as they do not provide API support.
We will make a best effort in keeping this documentation and associated language libraries up to date, but things might be outdated or missing.
If you find that something is no longer valid, please contact us on Discord or [create an issue](https://github.com/vrchatapi/specification/issues) and tell us so we can fix it.
# Getting Started
The VRChat API can be used to programmatically retrieve or update information regarding your profile, friends, avatars, worlds and more.
The API consists of two parts, "Photon" which is only used in-game, and the "Web API" which is used by both the game and the website.
This documentation focuses only on the Web API.
The API is designed around the REST ideology, providing semi-simple and usually predictable URIs to access and modify objects.
Requests support standard HTTP methods like GET, PUT, POST, and DELETE and standard status codes.
Response bodies are always UTF-8 encoded JSON objects, unless explicitly documented otherwise.
<div class="callout callout-error">
<strong>🛑 Warning! Do not touch Photon!</strong><br>
Photon is only used by the in-game client and should <b>not</b> be touched. Doing so may result in permanent account termination.
</div>
<div class="callout callout-info">
<strong>ℹ️ Authentication</strong><br>
Read <a href="#tag--authentication">Authentication</a> for how to log in.
</div>
# Using the API
For simply exploring what the API can do it is strongly recommended to download [Insomnia](https://insomnia.rest/download), a free and open-source
API client that's great for sending requests to the API in an orderly fashion.
Insomnia allows you to send data in the format that's required for VRChat's API.
It is also possible to try out the API in your browser, by first logging in at [vrchat.com/home](https://vrchat.com/home/) and then going to
[vrchat.com/api/1/auth/user](https://vrchat.com/api/1/auth/user), but the information will be much harder to work with.
For more permanent operation such as software development it is instead recommended to use one of the existing language SDKs.
This community project maintains API libraries in several languages, which allows you to interact with the API with simple function calls
rather than having to implement the HTTP protocol yourself. Most of these libraries are automatically generated from the API specification,
sometimes with additional helpful wrapper code to make usage easier. This allows them to be almost automatically updated and expanded upon
as soon as a new feature is introduced in the specification itself. The libraries can be found on [GitHub](https://github.com/vrchatapi) or following:
* [NodeJS (JavaScript)](https://www.npmjs.com/package/vrchat)
* [Dart](https://pub.dev/packages/vrchat_dart)
* [Rust](https://crates.io/crates/vrchatapi)
* [C#](https://github.com/vrchatapi/vrchatapi-csharp)
* [Python](https://github.com/vrchatapi/vrchatapi-python)
# Pagination
Most endpoints enforce pagination, meaning they will only return 10 entries by default, and never more than 100.<br>
Using both the limit and offset parameters allows you to easily paginate through a large number of objects.
| Query Parameter | Type | Description |
| ----------|--|------- |
| `n` | integer | The number of objects to return. This value often defaults to 10. Highest limit is always 100.|
| `offset` | integer | A zero-based offset from the default object sorting.|
If a request returns fewer objects than the `limit` parameter, there are no more items available to return.
# Contribution
Do you want to get involved in the documentation effort? Do you want to help improve one of the language API libraries?
This project is an [OPEN Open Source Project](https://openopensource.org)! This means that individuals making significant and valuable contributions are given
commit-access to the project. It also means we are very open and welcoming of new people making contributions, unlike some more guarded open-source projects.
[](https://discord.gg/qjZE9C9fkB)
servers:
- url: https://vrchat.com/api/1
tags:
- name: authentication
description: Authentication Docs Here
- name: avatars
description: Avatars Docs Here
- name: economy
description: Economy Docs Here
- name: favorites
description: Favorites Docs Here
- name: files
description: Files Docs Here
- name: friends
description: Friends Docs Here
- name: groups
description: Group Docs Here
- name: invite
description: Invite Docs Here
- name: instances
description: Instances Docs Here
- name: notifications
description: Notifiations Docs
- name: permissions
description: Permissions are a way to individually grant specific access to a user, often through a license such as VRC+ subscription.
- name: playermoderation
description: |-
There are two different moderation API's, "moderation" for Staff actions, and "playermoderation" for players.
PlayerModerations are user-generated actions towards others, such as muting them, blocking, or toggling interaction.
Your global permission settings are stored locally on your computer.
Only player-specific moderations (when you target a player, and allow them specifically to interact with you) are stored in the API.
## Implementation details
There are three different user-targetted permission options:
- Mode 1: interactOn/unmute/unblock
- Mode 2: interactOff/mute/block
- *Default setting*
**Example:**
Force On (`interactOn`) and Force Off (`interactOff`) always or never allow that person to interact with you.
These are stored as PlayerModerations. When you select a player and select "Force On", it creates a playerModeration of type `interactOn`.
**Important order:**
1. When switching between one mode from the other, e.g. "Force On" and "Force Off", **the previous playerModeration MUST first be deleted before creating the second.**
The game sends these in sequence, first delete the old, then create the new. Attempting to create both `interactOn` and `interactOff` is UNDOCUMENTED behavior.
2. "Use Current Setting" **does not have it's own enum**. The game removes any previous playerModeration of same type.
No playerModeration of either type means fallback to the global setting.
## Deprecation notice
As of October 2022, `showAvatar` and `hideAvatar` has been moved to local storage.
Sending these types to the API will result in a 200 OK response, but the API will **not** store them.
More information is avaiable on VRChat's official [documentation on Local Storage](https://docs.vrchat.com/docs/local-vrchat-storage).
- name: system
description: System Docs Here
- name: users
description: Users Docs Here
- name: worlds
description: Worlds Docs Here
paths:
/auth/exists:
get:
summary: Check User Exists
tags:
- authentication
x-codeSamples:
- lang: cURL
source: 'curl -X GET "https://vrchat.com/api/1/auth/exists?email={string}" '
responses:
'200':
$ref: '#/components/responses/UserExistsResponse'
'400':
$ref: '#/components/responses/MissingParameterError'
operationId: checkUserExists
parameters:
- $ref: '#/components/parameters/email'
- $ref: '#/components/parameters/displayName'
- $ref: '#/components/parameters/usernameQuery'
- $ref: '#/components/parameters/excludeUserId'
description: |-
Checks if a user by a given `username`, `displayName` or `email` exist. This is used during registration to check if a username has already been taken, during change of displayName to check if a displayName is available, and during change of email to check if the email is already used. In the later two cases the `excludeUserId` is used to exclude oneself, otherwise the result would always be true.
It is **REQUIRED** to include **AT LEAST** `username`, `displayName` **or** `email` query parameter. Although they can be combined - in addition with `excludeUserId` (generally to exclude yourself) - to further fine-tune the search.
/auth/user:
get:
summary: Login and/or Get Current User Info
tags:
- authentication
x-codeSamples:
- lang: cURL
source: |-
curl -X GET "https://vrchat.com/api/1/auth/user" \
-H "Authorization: Basic {string}"
responses:
'200':
$ref: '#/components/responses/CurrentUserLoginResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
operationId: getCurrentUser
description: |-
This endpoint does the following two operations:
1) Checks if you are already logged in by looking for a valid `auth` cookie. If you are have a valid auth cookie then no additional auth-related actions are taken. If you are **not** logged in then it will log you in with the `Authorization` header and set the `auth` cookie. The `auth` cookie will only be sent once.
2) If logged in, this function will also return the CurrentUser object containing detailed information about the currently logged in user.
The auth string after `Authorization: Basic {string}` is a base64-encoded string of the username and password, both individually url-encoded, and then joined with a colon.
> base64(urlencode(username):urlencode(password))
**WARNING: Session Limit:** Each authentication with login credentials counts as a separate session, out of which you have a limited amount. Make sure to save and reuse the `auth` cookie if you are often restarting the program. The provided API libraries automatically save cookies during runtime, but does not persist during restart. While it can be fine to use username/password during development, expect in production to very fast run into the rate-limit and be temporarily blocked from making new sessions until older ones expire. The exact number of simultaneous sessions is unknown/undisclosed.
parameters: []
security:
- authHeader: []
- authHeader: []
twoFactorAuthCookie: []
- authCookie: []
/auth/twofactorauth/totp/verify:
post:
summary: Verify 2FA code
operationId: verify2FA
x-codeSamples:
- lang: cURL
source: |-
curl -X POST "https://vrchat.com/api/1/auth/twofactorauth/totp/verify" \
-H "Content-Type: application/json" \
-b "auth={authCookie}" \
--data '{"code": "string"}'
responses:
'200':
$ref: '#/components/responses/Verify2FAResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/TwoFactorAuthCode'
examples: {}
description: Finishes the login sequence with a normal 2FA-generated code for accounts with 2FA-protection enabled.
tags:
- authentication
security:
- authCookie: []
parameters: []
/auth/twofactorauth/otp/verify:
post:
summary: Verify 2FA code with Recovery code
operationId: verifyRecoveryCode
x-codeSamples:
- lang: cURL
source: |-
curl -X POST "https://vrchat.com/api/1/auth/twofactorauth/otp/verify" \
-H "Content-Type: application/json" \
-b "auth={authCookie}" \
--data '{"code": "string"}'
responses:
'200':
$ref: '#/components/responses/Verify2FAResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/TwoFactorAuthCode'
examples: {}
description: Finishes the login sequence with an OTP (One Time Password) recovery code for accounts with 2FA-protection enabled.
tags:
- authentication
security:
- authCookie: []
/auth/twofactorauth/emailotp/verify:
post:
summary: Verify 2FA email code
operationId: verify2FAEmailCode
x-codeSamples:
- lang: cURL
source: |-
curl -X POST "https://vrchat.com/api/1/auth/twofactorauth/emailotp/verify" \
-H "Content-Type: application/json" \
-b "auth={authCookie}" \
--data '{"code": "string"}'
responses:
'200':
$ref: '#/components/responses/Verify2FAEmailCodeResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/TwoFactorEmailCode'
examples: {}
description: Finishes the login sequence with an 2FA email code.
tags:
- authentication
security:
- authCookie: []
parameters: []
/auth:
get:
summary: Verify Auth Token
tags:
- authentication
x-codeSamples:
- lang: cURL
source: |-
curl -X GET "https://vrchat.com/api/1/auth" \
-b "amplitude_id_a750df50d11f21f712262cbd4c0bab37vrchat.com={string}; auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/VerifyAuthTokenResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
operationId: verifyAuthToken
parameters: []
description: Verify whether the currently provided Auth Token is valid.
security:
- authCookie: []
/logout:
put:
summary: Logout
operationId: logout
x-codeSamples:
- lang: cURL
source: |-
curl -X PUT "https://vrchat.com/api/1/logout" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/LogoutSuccess'
'401':
$ref: '#/components/responses/MissingCredentialsError'
description: Invalidates the login session.
security:
- authCookie: []
tags:
- authentication
/users/{userId}/delete:
parameters:
- $ref: '#/components/parameters/userId'
put:
summary: Delete User
operationId: deleteUser
x-codeSamples:
- lang: cURL
source: |-
curl -X PUT "https://vrchat.com/api/1/user/{userId}/delete" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/DeleteUserResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
tags:
- authentication
description: |-
Deletes the account with given ID. Normal users only have permission to delete their own account. Account deletion is 14 days from this request, and will be cancelled if you do an authenticated request with the account afterwards.
**VRC+ NOTE:** Despite the 14-days cooldown, any VRC+ subscription will be cancelled **immediately**.
**METHOD NOTE:** Despite this being a Delete action, the method type required is PUT.
security:
- authCookie: []
/users/{userId}/avatar:
get:
summary: Get Own Avatar
tags:
- avatars
responses:
'200':
$ref: '#/components/responses/AvatarResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
'403':
$ref: '#/components/responses/AvatarSeeOtherUserCurrentAvatarError'
operationId: getOwnAvatar
x-codeSamples:
- lang: cURL
source: curl -X GET "https://vrchat.com/api/1/users/{userId}/avatar" -b "auth={authCookie}"
security:
- authCookie: []
description: Get the current avatar for the user. This will return an error for any other user than the one logged in.
parameters:
- $ref: '#/components/parameters/userId'
/avatars:
get:
summary: Search Avatars
tags:
- avatars
x-codeSamples:
- lang: cURL
source: |-
curl -X GET "https://vrchat.com/api/1/avatars?featured=true" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/AvatarListResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
operationId: searchAvatars
security:
- authCookie: []
parameters:
- $ref: '#/components/parameters/featured'
- $ref: '#/components/parameters/sort'
- schema:
type: string
enum:
- me
in: query
required: false
name: user
description: Set to `me` for searching own avatars.
- $ref: '#/components/parameters/userIdQuery'
- $ref: '#/components/parameters/number'
- $ref: '#/components/parameters/order'
- $ref: '#/components/parameters/offset'
- $ref: '#/components/parameters/tag'
- $ref: '#/components/parameters/notag'
- $ref: '#/components/parameters/releaseStatus'
- $ref: '#/components/parameters/maxUnityVersion'
- $ref: '#/components/parameters/minUnityVersion'
- $ref: '#/components/parameters/platform'
description: Search and list avatars by query filters. You can only search your own or featured avatars. It is not possible as a normal user to search other peoples avatars.
post:
summary: Create Avatar
operationId: createAvatar
security:
- authCookie: []
x-codeSamples:
- lang: cURL
source: |-
curl -X POST "https://vrchat.com/api/1/avatars" \
-H "Content-Type: application/json" \
-b "auth={authCookie}" \
--data '{"assetUrl": "string", "id": "{avatarId}", "name": "string", "description": "string", "tags": ["string"], "imageUrl": "string", "releaseStatus": "public", "version": 1, "unityPackageUrl": "string"}'
responses:
'200':
$ref: '#/components/responses/AvatarResponse'
'401':
$ref: '#/components/responses/FeaturedSetNotAdminError'
tags:
- avatars
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/CreateAvatarRequest'
description: Create an avatar. It's possible to optionally specify a ID if you want a custom one. Attempting to create an Avatar with an already claimed ID will result in a DB error.
/avatars/{avatarId}:
parameters:
- $ref: '#/components/parameters/avatarId'
get:
summary: Get Avatar
tags:
- avatars
x-codeSamples:
- lang: cURL
source: |-
curl -X GET "https://vrchat.com/api/1/avatars/{avatarId}" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/AvatarResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
'404':
$ref: '#/components/responses/AvatarNotFoundError'
operationId: getAvatar
security:
- authCookie: []
description: Get information about a specific Avatar.
put:
summary: Update Avatar
operationId: updateAvatar
security:
- authCookie: []
x-codeSamples:
- lang: cURL
source: |-
curl -X PUT "https://vrchat.com/api/1/avatars/{avatarId}" \
-H "Content-Type: application/json" \
-b "auth={authCookie}" \
--data '{"assetUrl": "string", "id": "{avatarId}", "name": "string", "description": "string", "tags": ["string"], "imageUrl": "string", "releaseStatus": "public", "version": 1, "unityPackageUrl": "string"}'
responses:
'200':
$ref: '#/components/responses/AvatarResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
'404':
$ref: '#/components/responses/AvatarNotFoundError'
description: Update information about a specific avatar.
tags:
- avatars
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/UpdateAvatarRequest'
delete:
summary: Delete Avatar
operationId: deleteAvatar
security:
- authCookie: []
x-codeSamples:
- lang: cURL
source: |-
curl -X DELETE "https://vrchat.com/api/1/avatars/{avatarId}" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/AvatarResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
'404':
$ref: '#/components/responses/AvatarNotFoundError'
tags:
- avatars
description: Delete an avatar. Notice an avatar is never fully "deleted", only its ReleaseStatus is set to "hidden" and the linked Files are deleted. The AvatarID is permanently reserved.
/avatars/{avatarId}/select:
parameters:
- $ref: '#/components/parameters/avatarId'
put:
summary: Select Avatar
tags:
- avatars
x-codeSamples:
- lang: cURL
source: |-
curl -X PUT "https://vrchat.com/api/1/avatars/{avatarId}/select" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/CurrentUserResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
'404':
$ref: '#/components/responses/AvatarNotFoundError'
operationId: selectAvatar
security:
- authCookie: []
description: Switches into that avatar.
/avatars/{avatarId}/selectFallback:
parameters:
- $ref: '#/components/parameters/avatarId'
put:
summary: Select Fallback Avatar
tags:
- avatars
x-codeSamples:
- lang: cURL
source: curl -X PUT "https://vrchat.com/api/1/avatars/{avatarId}/selectFallback"
responses:
'200':
$ref: '#/components/responses/CurrentUserResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
'403':
$ref: '#/components/responses/AvatarNotTaggedAsFallbackError'
'404':
$ref: '#/components/responses/AvatarNotFoundError'
operationId: selectFallbackAvatar
security:
- authCookie: []
description: Switches into that avatar as your fallback avatar.
/avatars/favorites:
get:
summary: List Favorited Avatars
tags:
- avatars
x-codeSamples:
- lang: cURL
source: |-
curl -X GET "https://vrchat.com/api/1/avatars/favorites?featured=true" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/AvatarListResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
'403':
$ref: '#/components/responses/AvatarSeeOtherUserFavoritesError'
operationId: getFavoritedAvatars
security:
- authCookie: []
parameters:
- $ref: '#/components/parameters/featured'
- $ref: '#/components/parameters/sort'
- $ref: '#/components/parameters/number'
- $ref: '#/components/parameters/order'
- $ref: '#/components/parameters/offset'
- $ref: '#/components/parameters/search'
- $ref: '#/components/parameters/tag'
- $ref: '#/components/parameters/notag'
- $ref: '#/components/parameters/releaseStatus'
- $ref: '#/components/parameters/maxUnityVersion'
- $ref: '#/components/parameters/minUnityVersion'
- $ref: '#/components/parameters/platform'
- $ref: '#/components/parameters/userIdAdmin'
description: Search and list favorited avatars by query filters.
/Steam/transactions:
get:
summary: List Steam Transactions
operationId: getSteamTransactions
security:
- authCookie: []
x-codeSamples:
- lang: cURL
source: |-
curl -X GET "https://vrchat.com/api/1/Steam/transactions" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/TransactionListResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
tags:
- economy
description: Get all own Steam transactions.
/Steam/transactions/{transactionId}:
parameters:
- $ref: '#/components/parameters/transactionId'
get:
summary: Get Steam Transaction
operationId: getSteamTransaction
security:
- authCookie: []
x-codeSamples:
- lang: cURL
source: |-
curl -X GET "https://vrchat.com/api/1/Steam/transactions/{transactionId}" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/TransactionResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
tags:
- economy
description: Get a single Steam transactions by ID. This returns the exact same information as `getSteamTransactions`, so no point in using this endpoint.
deprecated: true
/Admin/transactions/{transactionId}:
parameters:
- $ref: '#/components/parameters/transactionId'
/auth/user/subscription:
get:
summary: Get Current Subscriptions
operationId: getCurrentSubscriptions
security:
- authCookie: []
x-codeSamples:
- lang: cURL
source: |-
curl -X GET "https://vrchat.com/api/1/auth/user/subscription" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/UserSubscriptionListResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
tags:
- economy
description: Get a list of all current user subscriptions.
/subscriptions:
get:
summary: List Subscriptions
operationId: getSubscriptions
security:
- authCookie: []
x-codeSamples:
- lang: cURL
source: |-
curl -X GET "https://vrchat.com/api/1/subscriptions" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/SubscriptionListResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
tags:
- economy
description: List all existing Subscriptions. For example, "vrchatplus-monthly" and "vrchatplus-yearly".
/licenseGroups/{licenseGroupId}:
parameters:
- $ref: '#/components/parameters/licenseGroupId'
get:
summary: Get License Group
operationId: getLicenseGroup
security:
- authCookie: []
x-codeSamples:
- lang: cURL
source: |-
curl -X GET "https://vrchat.com/api/1/licenseGroups/{licenseGroupId}" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/LicenseGroupResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
tags:
- economy
description: Get a single License Group by given ID.
/favorites:
get:
summary: List Favorites
tags:
- favorites
x-codeSamples:
- lang: cURL
source: |-
curl -X GET "https://vrchat.com/api/1/favorites?type={string}&tag={string}" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/FavoriteListResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
operationId: getFavorites
security:
- authCookie: []
description: Returns a list of favorites.
parameters:
- $ref: '#/components/parameters/number'
- $ref: '#/components/parameters/offset'
- schema:
type: string
in: query
name: type
description: The type of favorites to return, FavoriteType.
- $ref: '#/components/parameters/tag'
post:
summary: Add Favorite
operationId: addFavorite
security:
- authCookie: []
x-codeSamples:
- lang: cURL
source: |-
curl -X POST "https://vrchat.com/api/1/favorites" \
-H "Content-Type: application/json" \
-b "auth={authCookie}" \
--data '{"type": "friend", "favoriteId": "userId", "tags": ["string"]}'
responses:
'200':
$ref: '#/components/responses/FavoriteResponse'
'400':
$ref: '#/components/responses/FavoriteAddAlreadyFavoritedError'
'403':
$ref: '#/components/responses/FavoriteAddNotFriendsError'
description: |-
Add a new favorite.
Friend groups are named `group_0` through `group_3`. Avatar and World groups are named `avatars1` to `avatars4` and `worlds1` to `worlds4`.
You cannot add people whom you are not friends with to your friends list. Destroying a friendship removes the person as favorite on both sides.
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/AddFavoriteRequest'
examples:
Example Favorite Friend:
value:
type: friend
favoriteId: usr_c1644b5b-3ca4-45b4-97c6-a2a0de70d469
tags:
- group_0
Example Favorite Avatar:
value:
type: avatar
favoriteId: avtr_912d66a4-4714-43b8-8407-7de2cafbf55b
tags:
- avatars1
description: ''
tags:
- favorites
/favorites/{favoriteId}:
parameters:
- $ref: '#/components/parameters/favoriteId'
get:
summary: Show Favorite
tags:
- favorites
x-codeSamples:
- lang: cURL
source: |-
curl -X GET "https://vrchat.com/api/1/favorites/{favoriteId}" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/FavoriteResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
'404':
$ref: '#/components/responses/FavoriteNotFoundError'
operationId: getFavorite
security:
- authCookie: []
description: Return information about a specific Favorite.
parameters: []
delete:
summary: Remove Favorite
operationId: removeFavorite
security:
- authCookie: []
x-codeSamples:
- lang: cURL
source: |-
curl -X DELETE "https://vrchat.com/api/1/favorites/{favoriteId}" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/FavoriteRemovedSuccess'
'401':
$ref: '#/components/responses/MissingCredentialsError'
'404':
$ref: '#/components/responses/FavoriteNotFoundError'
description: Remove a favorite from your favorites list.
tags:
- favorites
/favorite/groups:
get:
summary: List Favorite Groups
tags:
- favorites
x-codeSamples:
- lang: cURL
source: |-
curl -X GET "https://vrchat.com/api/1/favorite/groups?ownerId={userId}" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/FavoriteGroupListResponse'
'401':
$ref: '#/components/responses/MissingCredentialsError'
operationId: getFavoriteGroups
security:
- authCookie: []
parameters:
- $ref: '#/components/parameters/number'
- $ref: '#/components/parameters/offset'
- schema:
type: string
in: query
name: ownerId
description: The owner of whoms favorite groups to return. Must be a UserID.
description: Return a list of favorite groups owned by a user. Returns the same information as `getFavoriteGroups`.
/favorite/group/{favoriteGroupType}/{favoriteGroupName}/{userId}:
parameters:
- $ref: '#/components/parameters/favoriteGroupType'
- $ref: '#/components/parameters/favoriteGroupName'
- $ref: '#/components/parameters/userId'
get:
summary: Show Favorite Group
tags:
- favorites
x-codeSamples:
- lang: cURL
source: |-
curl -X GET "https://vrchat.com/api/1/favorite/group/{favoriteGroupType}/{favoriteGroupName}/{userId}" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/FavoriteGroupResponse'
operationId: getFavoriteGroup
security:
- authCookie: []
description: Fetch information about a specific favorite group.
put:
summary: Update Favorite Group
operationId: updateFavoriteGroup
security:
- authCookie: []
x-codeSamples:
- lang: cURL
source: |-
curl -X PUT -H "Content-Type: application/json" "https://vrchat.com/api/1/favorite/group/{favoriteGroupType}/{favoriteGroupName}/{userId}" \
-b "auth={authCookie}" \
--data '{"displayName": "string", "visibility": "private", "tags": ["string"]}'
responses:
'200':
description: OK
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/UpdateFavoriteGroupRequest'
tags:
- favorites
description: Update information about a specific favorite group.
delete:
summary: Clear Favorite Group
operationId: clearFavoriteGroup
security:
- authCookie: []
x-codeSamples:
- lang: cURL
source: |-
curl -X DELETE "https://vrchat.com/api/1/favorite/group/{favoriteGroupType}/{favoriteGroupName}/{userId}" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/FavoriteGroupClearedSuccess'
tags:
- favorites
description: Clear ALL contents of a specific favorite group.
/files:
get:
summary: List Files
x-codeSamples:
- lang: cURL
source: |-
curl -X GET "https://vrchat.com/api/1/files?tag={string}" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/FileListResponse'
operationId: getFiles
security:
- authCookie: []
description: Returns a list of files
parameters:
- schema:
type: string
minLength: 1
in: query
name: tag
description: Tag, for example "icon" or "gallery", not included by default.
- schema:
type: string
in: query
name: userId
deprecated: true
description: UserID, will always generate a 500 permission error.
- $ref: '#/components/parameters/number'
- $ref: '#/components/parameters/offset'
tags:
- files
/file:
post:
summary: Create File
tags:
- files
x-codeSamples:
- lang: cURL
source: |-
curl -X POST "https://vrchat.com/api/1/file" \
-H "Content-Type: application/json" \
-b "auth={authCookie}" \
--data '{"name": "string", "mimeType": "image/jpeg", "extension": "string", "tags": ["string"]}'
responses:
'200':
$ref: '#/components/responses/FileResponse'
operationId: createFile
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/CreateFileRequest'
security:
- authCookie: []
description: Creates a new File object
/file/{fileId}:
parameters:
- $ref: '#/components/parameters/fileId'
get:
summary: Show File
operationId: getFile
tags:
- files
x-codeSamples:
- lang: cURL
source: |-
curl -X GET "https://vrchat.com/api/1/file/{fileId}" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/FileResponse'
'404':
$ref: '#/components/responses/FileNotFoundError'
security:
- authCookie: []
description: Shows general information about the "File" object. Each File can have several "Version"'s, and each Version can have multiple real files or "Data" blobs.
delete:
summary: Delete File
operationId: deleteFile
x-codeSamples:
- lang: cURL
source: |-
curl -X DELETE "https://vrchat.com/api/1/file/{fileId}" \
-b "auth={authCookie}"
responses:
'200':
$ref: '#/components/responses/FileResponse'
'404':
$ref: '#/components/responses/FileDeletedError'
tags:
- files