@ughuuu/game_server 1.0.149 → 1.0.155
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +24 -4
- package/dist/api/FriendsApi.js +402 -0
- package/dist/api/LobbiesApi.js +28 -24
- package/dist/api/UsersApi.js +85 -0
- package/dist/index.js +86 -16
- package/dist/model/CreateFriendRequestRequest.js +109 -0
- package/dist/model/ListBlockedFriends200Response.js +124 -0
- package/dist/model/{JoinLobby200Response.js → ListBlockedFriends200ResponseDataInner.js} +33 -23
- package/dist/model/ListBlockedFriends200ResponseDataInnerRequester.js +109 -0
- package/dist/model/ListFriendRequests200Response.js +153 -0
- package/dist/model/ListFriendRequests200ResponseIncomingInner.js +136 -0
- package/dist/model/{KickUser200Response.js → ListFriendRequests200ResponseIncomingInnerRequester.js} +30 -22
- package/dist/model/ListFriendRequests200ResponseMeta.js +125 -0
- package/dist/model/ListFriends200Response.js +124 -0
- package/dist/model/ListFriends200ResponseDataInner.js +121 -0
- package/dist/model/ListLobbies200Response.js +124 -0
- package/dist/model/{ListLobbies200ResponseInner.js → ListLobbies200ResponseDataInner.js} +24 -24
- package/dist/model/{LeaveLobby200Response.js → ListLobbies200ResponseMeta.js} +60 -24
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -156,6 +156,15 @@ Class | Method | HTTP request | Description
|
|
|
156
156
|
*UghuuuGameServer.AuthenticationApi* | [**oauthSessionStatus**](docs/AuthenticationApi.md#oauthSessionStatus) | **GET** /api/v1/auth/session/{session_id} | Get OAuth session status
|
|
157
157
|
*UghuuuGameServer.AuthenticationApi* | [**refreshToken**](docs/AuthenticationApi.md#refreshToken) | **POST** /api/v1/refresh | Refresh access token
|
|
158
158
|
*UghuuuGameServer.AuthenticationApi* | [**unlinkProvider**](docs/AuthenticationApi.md#unlinkProvider) | **DELETE** /api/v1/me/providers/{provider} | Unlink OAuth provider
|
|
159
|
+
*UghuuuGameServer.FriendsApi* | [**acceptFriendRequest**](docs/FriendsApi.md#acceptFriendRequest) | **POST** /api/v1/friends/{id}/accept | Accept a friend request
|
|
160
|
+
*UghuuuGameServer.FriendsApi* | [**blockFriendRequest**](docs/FriendsApi.md#blockFriendRequest) | **POST** /api/v1/friends/{id}/block | Block a friend request / user
|
|
161
|
+
*UghuuuGameServer.FriendsApi* | [**createFriendRequest**](docs/FriendsApi.md#createFriendRequest) | **POST** /api/v1/friends | Send a friend request
|
|
162
|
+
*UghuuuGameServer.FriendsApi* | [**listBlockedFriends**](docs/FriendsApi.md#listBlockedFriends) | **GET** /api/v1/me/blocked | List users you've blocked
|
|
163
|
+
*UghuuuGameServer.FriendsApi* | [**listFriendRequests**](docs/FriendsApi.md#listFriendRequests) | **GET** /api/v1/me/friend-requests | List pending friend requests (incoming and outgoing)
|
|
164
|
+
*UghuuuGameServer.FriendsApi* | [**listFriends**](docs/FriendsApi.md#listFriends) | **GET** /api/v1/me/friends | List current user's friends (returns a paginated set of user objects)
|
|
165
|
+
*UghuuuGameServer.FriendsApi* | [**rejectFriendRequest**](docs/FriendsApi.md#rejectFriendRequest) | **POST** /api/v1/friends/{id}/reject | Reject a friend request
|
|
166
|
+
*UghuuuGameServer.FriendsApi* | [**removeFriendship**](docs/FriendsApi.md#removeFriendship) | **DELETE** /api/v1/friends/{id} | Remove/cancel a friendship or request
|
|
167
|
+
*UghuuuGameServer.FriendsApi* | [**unblockFriend**](docs/FriendsApi.md#unblockFriend) | **POST** /api/v1/friends/{id}/unblock | Unblock a previously-blocked friendship
|
|
159
168
|
*UghuuuGameServer.HealthApi* | [**index**](docs/HealthApi.md#index) | **GET** /api/v1/health | Health check
|
|
160
169
|
*UghuuuGameServer.LobbiesApi* | [**createLobby**](docs/LobbiesApi.md#createLobby) | **POST** /api/v1/lobbies | Create a lobby
|
|
161
170
|
*UghuuuGameServer.LobbiesApi* | [**joinLobby**](docs/LobbiesApi.md#joinLobby) | **POST** /api/v1/lobbies/{id}/join | Join a lobby
|
|
@@ -164,22 +173,33 @@ Class | Method | HTTP request | Description
|
|
|
164
173
|
*UghuuuGameServer.LobbiesApi* | [**listLobbies**](docs/LobbiesApi.md#listLobbies) | **GET** /api/v1/lobbies | List lobbies
|
|
165
174
|
*UghuuuGameServer.LobbiesApi* | [**updateLobby**](docs/LobbiesApi.md#updateLobby) | **PATCH** /api/v1/lobbies/{id} | Update lobby (host only)
|
|
166
175
|
*UghuuuGameServer.UsersApi* | [**getCurrentUser**](docs/UsersApi.md#getCurrentUser) | **GET** /api/v1/me | Return current user info
|
|
176
|
+
*UghuuuGameServer.UsersApi* | [**getUser**](docs/UsersApi.md#getUser) | **GET** /api/v1/users/{id} | Get a user by id (public)
|
|
177
|
+
*UghuuuGameServer.UsersApi* | [**searchUsers**](docs/UsersApi.md#searchUsers) | **GET** /api/v1/users | Search users by id/email/display_name (public)
|
|
167
178
|
*UghuuuGameServer.UsersApi* | [**updateCurrentUserDisplayName**](docs/UsersApi.md#updateCurrentUserDisplayName) | **PATCH** /api/v1/me/display_name | Update current user's display name
|
|
168
179
|
*UghuuuGameServer.UsersApi* | [**updateCurrentUserPassword**](docs/UsersApi.md#updateCurrentUserPassword) | **PATCH** /api/v1/me/password | Update current user password
|
|
169
180
|
|
|
170
181
|
|
|
171
182
|
## Documentation for Models
|
|
172
183
|
|
|
184
|
+
- [UghuuuGameServer.CreateFriendRequestRequest](docs/CreateFriendRequestRequest.md)
|
|
173
185
|
- [UghuuuGameServer.CreateLobby401Response](docs/CreateLobby401Response.md)
|
|
174
186
|
- [UghuuuGameServer.CreateLobbyRequest](docs/CreateLobbyRequest.md)
|
|
175
187
|
- [UghuuuGameServer.GetCurrentUser200Response](docs/GetCurrentUser200Response.md)
|
|
176
188
|
- [UghuuuGameServer.HealthResponse](docs/HealthResponse.md)
|
|
177
|
-
- [UghuuuGameServer.JoinLobby200Response](docs/JoinLobby200Response.md)
|
|
178
189
|
- [UghuuuGameServer.JoinLobbyRequest](docs/JoinLobbyRequest.md)
|
|
179
|
-
- [UghuuuGameServer.KickUser200Response](docs/KickUser200Response.md)
|
|
180
190
|
- [UghuuuGameServer.KickUserRequest](docs/KickUserRequest.md)
|
|
181
|
-
- [UghuuuGameServer.
|
|
182
|
-
- [UghuuuGameServer.
|
|
191
|
+
- [UghuuuGameServer.ListBlockedFriends200Response](docs/ListBlockedFriends200Response.md)
|
|
192
|
+
- [UghuuuGameServer.ListBlockedFriends200ResponseDataInner](docs/ListBlockedFriends200ResponseDataInner.md)
|
|
193
|
+
- [UghuuuGameServer.ListBlockedFriends200ResponseDataInnerRequester](docs/ListBlockedFriends200ResponseDataInnerRequester.md)
|
|
194
|
+
- [UghuuuGameServer.ListFriendRequests200Response](docs/ListFriendRequests200Response.md)
|
|
195
|
+
- [UghuuuGameServer.ListFriendRequests200ResponseIncomingInner](docs/ListFriendRequests200ResponseIncomingInner.md)
|
|
196
|
+
- [UghuuuGameServer.ListFriendRequests200ResponseIncomingInnerRequester](docs/ListFriendRequests200ResponseIncomingInnerRequester.md)
|
|
197
|
+
- [UghuuuGameServer.ListFriendRequests200ResponseMeta](docs/ListFriendRequests200ResponseMeta.md)
|
|
198
|
+
- [UghuuuGameServer.ListFriends200Response](docs/ListFriends200Response.md)
|
|
199
|
+
- [UghuuuGameServer.ListFriends200ResponseDataInner](docs/ListFriends200ResponseDataInner.md)
|
|
200
|
+
- [UghuuuGameServer.ListLobbies200Response](docs/ListLobbies200Response.md)
|
|
201
|
+
- [UghuuuGameServer.ListLobbies200ResponseDataInner](docs/ListLobbies200ResponseDataInner.md)
|
|
202
|
+
- [UghuuuGameServer.ListLobbies200ResponseMeta](docs/ListLobbies200ResponseMeta.md)
|
|
183
203
|
- [UghuuuGameServer.Login200Response](docs/Login200Response.md)
|
|
184
204
|
- [UghuuuGameServer.Login200ResponseData](docs/Login200ResponseData.md)
|
|
185
205
|
- [UghuuuGameServer.Login200ResponseDataUser](docs/Login200ResponseDataUser.md)
|
|
@@ -0,0 +1,402 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports["default"] = void 0;
|
|
7
|
+
var _ApiClient = _interopRequireDefault(require("../ApiClient"));
|
|
8
|
+
var _CreateFriendRequestRequest = _interopRequireDefault(require("../model/CreateFriendRequestRequest"));
|
|
9
|
+
var _ListBlockedFriends200Response = _interopRequireDefault(require("../model/ListBlockedFriends200Response"));
|
|
10
|
+
var _ListFriendRequests200Response = _interopRequireDefault(require("../model/ListFriendRequests200Response"));
|
|
11
|
+
var _ListFriends200Response = _interopRequireDefault(require("../model/ListFriends200Response"));
|
|
12
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
|
|
13
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
14
|
+
function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
|
|
15
|
+
function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }
|
|
16
|
+
function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
|
|
17
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
18
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); } /**
|
|
19
|
+
* Game Server API
|
|
20
|
+
* API for Game Server application ## Authentication This API uses JWT (JSON Web Tokens) with access and refresh tokens: ### Getting Tokens - **Email/Password**: POST to `/api/v1/login` with email and password - **Discord OAuth**: Use `/api/v1/auth/discord` flow - **Google OAuth**: Use `/api/v1/auth/google` flow - **Facebook OAuth**: Use `/api/v1/auth/facebook` flow - **Apple Sign In**: Use `/auth/apple` browser flow (API flow not yet implemented) Both methods return: - `access_token` - Short-lived (15 min), use for API requests - `refresh_token` - Long-lived (30 days), use to get new access tokens ### Using Tokens Include the access token in the Authorization header: ``` Authorization: Bearer <access_token> ``` ### Refreshing Tokens When your access token expires, use POST `/api/v1/refresh` with your refresh token to get a new access token. ## Endpoints All API endpoints are under `/api/v1`
|
|
21
|
+
*
|
|
22
|
+
* The version of the OpenAPI document: 1.0.0
|
|
23
|
+
*
|
|
24
|
+
*
|
|
25
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
26
|
+
* https://openapi-generator.tech
|
|
27
|
+
* Do not edit the class manually.
|
|
28
|
+
*
|
|
29
|
+
*/
|
|
30
|
+
/**
|
|
31
|
+
* Friends service.
|
|
32
|
+
* @module api/FriendsApi
|
|
33
|
+
* @version 1.0.0
|
|
34
|
+
*/
|
|
35
|
+
var FriendsApi = exports["default"] = /*#__PURE__*/function () {
|
|
36
|
+
/**
|
|
37
|
+
* Constructs a new FriendsApi.
|
|
38
|
+
* @alias module:api/FriendsApi
|
|
39
|
+
* @class
|
|
40
|
+
* @param {module:ApiClient} [apiClient] Optional API client implementation to use,
|
|
41
|
+
* default to {@link module:ApiClient#instance} if unspecified.
|
|
42
|
+
*/
|
|
43
|
+
function FriendsApi(apiClient) {
|
|
44
|
+
_classCallCheck(this, FriendsApi);
|
|
45
|
+
this.apiClient = apiClient || _ApiClient["default"].instance;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
/**
|
|
49
|
+
* Accept a friend request
|
|
50
|
+
* @param {Number} id Friendship record id (friendship_id) — the id of the friendship row, not a user id
|
|
51
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
52
|
+
*/
|
|
53
|
+
return _createClass(FriendsApi, [{
|
|
54
|
+
key: "acceptFriendRequestWithHttpInfo",
|
|
55
|
+
value: function acceptFriendRequestWithHttpInfo(id) {
|
|
56
|
+
var postBody = null;
|
|
57
|
+
// verify the required parameter 'id' is set
|
|
58
|
+
if (id === undefined || id === null) {
|
|
59
|
+
throw new Error("Missing the required parameter 'id' when calling acceptFriendRequest");
|
|
60
|
+
}
|
|
61
|
+
var pathParams = {
|
|
62
|
+
'id': id
|
|
63
|
+
};
|
|
64
|
+
var queryParams = {};
|
|
65
|
+
var headerParams = {};
|
|
66
|
+
var formParams = {};
|
|
67
|
+
var authNames = ['authorization'];
|
|
68
|
+
var contentTypes = [];
|
|
69
|
+
var accepts = ['application/json'];
|
|
70
|
+
var returnType = null;
|
|
71
|
+
return this.apiClient.callApi('/api/v1/friends/{id}/accept', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
/**
|
|
75
|
+
* Accept a friend request
|
|
76
|
+
* @param {Number} id Friendship record id (friendship_id) — the id of the friendship row, not a user id
|
|
77
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
78
|
+
*/
|
|
79
|
+
}, {
|
|
80
|
+
key: "acceptFriendRequest",
|
|
81
|
+
value: function acceptFriendRequest(id) {
|
|
82
|
+
return this.acceptFriendRequestWithHttpInfo(id).then(function (response_and_data) {
|
|
83
|
+
return response_and_data.data;
|
|
84
|
+
});
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
/**
|
|
88
|
+
* Block a friend request / user
|
|
89
|
+
* @param {Number} id Friendship record id (friendship_id) — the id of the friendship row, not a user id
|
|
90
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
91
|
+
*/
|
|
92
|
+
}, {
|
|
93
|
+
key: "blockFriendRequestWithHttpInfo",
|
|
94
|
+
value: function blockFriendRequestWithHttpInfo(id) {
|
|
95
|
+
var postBody = null;
|
|
96
|
+
// verify the required parameter 'id' is set
|
|
97
|
+
if (id === undefined || id === null) {
|
|
98
|
+
throw new Error("Missing the required parameter 'id' when calling blockFriendRequest");
|
|
99
|
+
}
|
|
100
|
+
var pathParams = {
|
|
101
|
+
'id': id
|
|
102
|
+
};
|
|
103
|
+
var queryParams = {};
|
|
104
|
+
var headerParams = {};
|
|
105
|
+
var formParams = {};
|
|
106
|
+
var authNames = ['authorization'];
|
|
107
|
+
var contentTypes = [];
|
|
108
|
+
var accepts = ['application/json'];
|
|
109
|
+
var returnType = null;
|
|
110
|
+
return this.apiClient.callApi('/api/v1/friends/{id}/block', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
/**
|
|
114
|
+
* Block a friend request / user
|
|
115
|
+
* @param {Number} id Friendship record id (friendship_id) — the id of the friendship row, not a user id
|
|
116
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
117
|
+
*/
|
|
118
|
+
}, {
|
|
119
|
+
key: "blockFriendRequest",
|
|
120
|
+
value: function blockFriendRequest(id) {
|
|
121
|
+
return this.blockFriendRequestWithHttpInfo(id).then(function (response_and_data) {
|
|
122
|
+
return response_and_data.data;
|
|
123
|
+
});
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
/**
|
|
127
|
+
* Send a friend request
|
|
128
|
+
* @param {Object} opts Optional parameters
|
|
129
|
+
* @param {module:model/CreateFriendRequestRequest} [createFriendRequestRequest] Friend request
|
|
130
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
131
|
+
*/
|
|
132
|
+
}, {
|
|
133
|
+
key: "createFriendRequestWithHttpInfo",
|
|
134
|
+
value: function createFriendRequestWithHttpInfo(opts) {
|
|
135
|
+
opts = opts || {};
|
|
136
|
+
var postBody = opts['createFriendRequestRequest'];
|
|
137
|
+
var pathParams = {};
|
|
138
|
+
var queryParams = {};
|
|
139
|
+
var headerParams = {};
|
|
140
|
+
var formParams = {};
|
|
141
|
+
var authNames = ['authorization'];
|
|
142
|
+
var contentTypes = ['application/json'];
|
|
143
|
+
var accepts = ['application/json'];
|
|
144
|
+
var returnType = null;
|
|
145
|
+
return this.apiClient.callApi('/api/v1/friends', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
/**
|
|
149
|
+
* Send a friend request
|
|
150
|
+
* @param {Object} opts Optional parameters
|
|
151
|
+
* @param {module:model/CreateFriendRequestRequest} opts.createFriendRequestRequest Friend request
|
|
152
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
153
|
+
*/
|
|
154
|
+
}, {
|
|
155
|
+
key: "createFriendRequest",
|
|
156
|
+
value: function createFriendRequest(opts) {
|
|
157
|
+
return this.createFriendRequestWithHttpInfo(opts).then(function (response_and_data) {
|
|
158
|
+
return response_and_data.data;
|
|
159
|
+
});
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
/**
|
|
163
|
+
* List users you've blocked
|
|
164
|
+
* @param {Object} opts Optional parameters
|
|
165
|
+
* @param {Number} [page] Page number (1-based)
|
|
166
|
+
* @param {Number} [pageSize] Page size (max results per page)
|
|
167
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/ListBlockedFriends200Response} and HTTP response
|
|
168
|
+
*/
|
|
169
|
+
}, {
|
|
170
|
+
key: "listBlockedFriendsWithHttpInfo",
|
|
171
|
+
value: function listBlockedFriendsWithHttpInfo(opts) {
|
|
172
|
+
opts = opts || {};
|
|
173
|
+
var postBody = null;
|
|
174
|
+
var pathParams = {};
|
|
175
|
+
var queryParams = {
|
|
176
|
+
'page': opts['page'],
|
|
177
|
+
'page_size': opts['pageSize']
|
|
178
|
+
};
|
|
179
|
+
var headerParams = {};
|
|
180
|
+
var formParams = {};
|
|
181
|
+
var authNames = ['authorization'];
|
|
182
|
+
var contentTypes = [];
|
|
183
|
+
var accepts = ['application/json'];
|
|
184
|
+
var returnType = _ListBlockedFriends200Response["default"];
|
|
185
|
+
return this.apiClient.callApi('/api/v1/me/blocked', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
/**
|
|
189
|
+
* List users you've blocked
|
|
190
|
+
* @param {Object} opts Optional parameters
|
|
191
|
+
* @param {Number} opts.page Page number (1-based)
|
|
192
|
+
* @param {Number} opts.pageSize Page size (max results per page)
|
|
193
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/ListBlockedFriends200Response}
|
|
194
|
+
*/
|
|
195
|
+
}, {
|
|
196
|
+
key: "listBlockedFriends",
|
|
197
|
+
value: function listBlockedFriends(opts) {
|
|
198
|
+
return this.listBlockedFriendsWithHttpInfo(opts).then(function (response_and_data) {
|
|
199
|
+
return response_and_data.data;
|
|
200
|
+
});
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
/**
|
|
204
|
+
* List pending friend requests (incoming and outgoing)
|
|
205
|
+
* @param {Object} opts Optional parameters
|
|
206
|
+
* @param {Number} [page] Page number (1-based, applied to both lists)
|
|
207
|
+
* @param {Number} [pageSize] Page size (applied to both lists)
|
|
208
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/ListFriendRequests200Response} and HTTP response
|
|
209
|
+
*/
|
|
210
|
+
}, {
|
|
211
|
+
key: "listFriendRequestsWithHttpInfo",
|
|
212
|
+
value: function listFriendRequestsWithHttpInfo(opts) {
|
|
213
|
+
opts = opts || {};
|
|
214
|
+
var postBody = null;
|
|
215
|
+
var pathParams = {};
|
|
216
|
+
var queryParams = {
|
|
217
|
+
'page': opts['page'],
|
|
218
|
+
'page_size': opts['pageSize']
|
|
219
|
+
};
|
|
220
|
+
var headerParams = {};
|
|
221
|
+
var formParams = {};
|
|
222
|
+
var authNames = ['authorization'];
|
|
223
|
+
var contentTypes = [];
|
|
224
|
+
var accepts = ['application/json'];
|
|
225
|
+
var returnType = _ListFriendRequests200Response["default"];
|
|
226
|
+
return this.apiClient.callApi('/api/v1/me/friend-requests', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
227
|
+
}
|
|
228
|
+
|
|
229
|
+
/**
|
|
230
|
+
* List pending friend requests (incoming and outgoing)
|
|
231
|
+
* @param {Object} opts Optional parameters
|
|
232
|
+
* @param {Number} opts.page Page number (1-based, applied to both lists)
|
|
233
|
+
* @param {Number} opts.pageSize Page size (applied to both lists)
|
|
234
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/ListFriendRequests200Response}
|
|
235
|
+
*/
|
|
236
|
+
}, {
|
|
237
|
+
key: "listFriendRequests",
|
|
238
|
+
value: function listFriendRequests(opts) {
|
|
239
|
+
return this.listFriendRequestsWithHttpInfo(opts).then(function (response_and_data) {
|
|
240
|
+
return response_and_data.data;
|
|
241
|
+
});
|
|
242
|
+
}
|
|
243
|
+
|
|
244
|
+
/**
|
|
245
|
+
* List current user's friends (returns a paginated set of user objects)
|
|
246
|
+
* @param {Object} opts Optional parameters
|
|
247
|
+
* @param {Number} [page] Page number (1-based)
|
|
248
|
+
* @param {Number} [pageSize] Page size (max results per page)
|
|
249
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/ListFriends200Response} and HTTP response
|
|
250
|
+
*/
|
|
251
|
+
}, {
|
|
252
|
+
key: "listFriendsWithHttpInfo",
|
|
253
|
+
value: function listFriendsWithHttpInfo(opts) {
|
|
254
|
+
opts = opts || {};
|
|
255
|
+
var postBody = null;
|
|
256
|
+
var pathParams = {};
|
|
257
|
+
var queryParams = {
|
|
258
|
+
'page': opts['page'],
|
|
259
|
+
'page_size': opts['pageSize']
|
|
260
|
+
};
|
|
261
|
+
var headerParams = {};
|
|
262
|
+
var formParams = {};
|
|
263
|
+
var authNames = ['authorization'];
|
|
264
|
+
var contentTypes = [];
|
|
265
|
+
var accepts = ['application/json'];
|
|
266
|
+
var returnType = _ListFriends200Response["default"];
|
|
267
|
+
return this.apiClient.callApi('/api/v1/me/friends', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
/**
|
|
271
|
+
* List current user's friends (returns a paginated set of user objects)
|
|
272
|
+
* @param {Object} opts Optional parameters
|
|
273
|
+
* @param {Number} opts.page Page number (1-based)
|
|
274
|
+
* @param {Number} opts.pageSize Page size (max results per page)
|
|
275
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/ListFriends200Response}
|
|
276
|
+
*/
|
|
277
|
+
}, {
|
|
278
|
+
key: "listFriends",
|
|
279
|
+
value: function listFriends(opts) {
|
|
280
|
+
return this.listFriendsWithHttpInfo(opts).then(function (response_and_data) {
|
|
281
|
+
return response_and_data.data;
|
|
282
|
+
});
|
|
283
|
+
}
|
|
284
|
+
|
|
285
|
+
/**
|
|
286
|
+
* Reject a friend request
|
|
287
|
+
* @param {Number} id Friendship record id (friendship_id) — the id of the friendship row, not a user id
|
|
288
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
289
|
+
*/
|
|
290
|
+
}, {
|
|
291
|
+
key: "rejectFriendRequestWithHttpInfo",
|
|
292
|
+
value: function rejectFriendRequestWithHttpInfo(id) {
|
|
293
|
+
var postBody = null;
|
|
294
|
+
// verify the required parameter 'id' is set
|
|
295
|
+
if (id === undefined || id === null) {
|
|
296
|
+
throw new Error("Missing the required parameter 'id' when calling rejectFriendRequest");
|
|
297
|
+
}
|
|
298
|
+
var pathParams = {
|
|
299
|
+
'id': id
|
|
300
|
+
};
|
|
301
|
+
var queryParams = {};
|
|
302
|
+
var headerParams = {};
|
|
303
|
+
var formParams = {};
|
|
304
|
+
var authNames = ['authorization'];
|
|
305
|
+
var contentTypes = [];
|
|
306
|
+
var accepts = ['application/json'];
|
|
307
|
+
var returnType = null;
|
|
308
|
+
return this.apiClient.callApi('/api/v1/friends/{id}/reject', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
309
|
+
}
|
|
310
|
+
|
|
311
|
+
/**
|
|
312
|
+
* Reject a friend request
|
|
313
|
+
* @param {Number} id Friendship record id (friendship_id) — the id of the friendship row, not a user id
|
|
314
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
315
|
+
*/
|
|
316
|
+
}, {
|
|
317
|
+
key: "rejectFriendRequest",
|
|
318
|
+
value: function rejectFriendRequest(id) {
|
|
319
|
+
return this.rejectFriendRequestWithHttpInfo(id).then(function (response_and_data) {
|
|
320
|
+
return response_and_data.data;
|
|
321
|
+
});
|
|
322
|
+
}
|
|
323
|
+
|
|
324
|
+
/**
|
|
325
|
+
* Remove/cancel a friendship or request
|
|
326
|
+
* @param {Number} id
|
|
327
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
328
|
+
*/
|
|
329
|
+
}, {
|
|
330
|
+
key: "removeFriendshipWithHttpInfo",
|
|
331
|
+
value: function removeFriendshipWithHttpInfo(id) {
|
|
332
|
+
var postBody = null;
|
|
333
|
+
// verify the required parameter 'id' is set
|
|
334
|
+
if (id === undefined || id === null) {
|
|
335
|
+
throw new Error("Missing the required parameter 'id' when calling removeFriendship");
|
|
336
|
+
}
|
|
337
|
+
var pathParams = {
|
|
338
|
+
'id': id
|
|
339
|
+
};
|
|
340
|
+
var queryParams = {};
|
|
341
|
+
var headerParams = {};
|
|
342
|
+
var formParams = {};
|
|
343
|
+
var authNames = ['authorization'];
|
|
344
|
+
var contentTypes = [];
|
|
345
|
+
var accepts = ['application/json'];
|
|
346
|
+
var returnType = null;
|
|
347
|
+
return this.apiClient.callApi('/api/v1/friends/{id}', 'DELETE', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
348
|
+
}
|
|
349
|
+
|
|
350
|
+
/**
|
|
351
|
+
* Remove/cancel a friendship or request
|
|
352
|
+
* @param {Number} id
|
|
353
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
354
|
+
*/
|
|
355
|
+
}, {
|
|
356
|
+
key: "removeFriendship",
|
|
357
|
+
value: function removeFriendship(id) {
|
|
358
|
+
return this.removeFriendshipWithHttpInfo(id).then(function (response_and_data) {
|
|
359
|
+
return response_and_data.data;
|
|
360
|
+
});
|
|
361
|
+
}
|
|
362
|
+
|
|
363
|
+
/**
|
|
364
|
+
* Unblock a previously-blocked friendship
|
|
365
|
+
* @param {Number} id Friendship record id (friendship_id) — the id of the friendship row, not a user id
|
|
366
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
367
|
+
*/
|
|
368
|
+
}, {
|
|
369
|
+
key: "unblockFriendWithHttpInfo",
|
|
370
|
+
value: function unblockFriendWithHttpInfo(id) {
|
|
371
|
+
var postBody = null;
|
|
372
|
+
// verify the required parameter 'id' is set
|
|
373
|
+
if (id === undefined || id === null) {
|
|
374
|
+
throw new Error("Missing the required parameter 'id' when calling unblockFriend");
|
|
375
|
+
}
|
|
376
|
+
var pathParams = {
|
|
377
|
+
'id': id
|
|
378
|
+
};
|
|
379
|
+
var queryParams = {};
|
|
380
|
+
var headerParams = {};
|
|
381
|
+
var formParams = {};
|
|
382
|
+
var authNames = ['authorization'];
|
|
383
|
+
var contentTypes = [];
|
|
384
|
+
var accepts = ['application/json'];
|
|
385
|
+
var returnType = null;
|
|
386
|
+
return this.apiClient.callApi('/api/v1/friends/{id}/unblock', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
387
|
+
}
|
|
388
|
+
|
|
389
|
+
/**
|
|
390
|
+
* Unblock a previously-blocked friendship
|
|
391
|
+
* @param {Number} id Friendship record id (friendship_id) — the id of the friendship row, not a user id
|
|
392
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
393
|
+
*/
|
|
394
|
+
}, {
|
|
395
|
+
key: "unblockFriend",
|
|
396
|
+
value: function unblockFriend(id) {
|
|
397
|
+
return this.unblockFriendWithHttpInfo(id).then(function (response_and_data) {
|
|
398
|
+
return response_and_data.data;
|
|
399
|
+
});
|
|
400
|
+
}
|
|
401
|
+
}]);
|
|
402
|
+
}();
|
package/dist/api/LobbiesApi.js
CHANGED
|
@@ -7,12 +7,10 @@ exports["default"] = void 0;
|
|
|
7
7
|
var _ApiClient = _interopRequireDefault(require("../ApiClient"));
|
|
8
8
|
var _CreateLobby401Response = _interopRequireDefault(require("../model/CreateLobby401Response"));
|
|
9
9
|
var _CreateLobbyRequest = _interopRequireDefault(require("../model/CreateLobbyRequest"));
|
|
10
|
-
var _JoinLobby200Response = _interopRequireDefault(require("../model/JoinLobby200Response"));
|
|
11
10
|
var _JoinLobbyRequest = _interopRequireDefault(require("../model/JoinLobbyRequest"));
|
|
12
|
-
var _KickUser200Response = _interopRequireDefault(require("../model/KickUser200Response"));
|
|
13
11
|
var _KickUserRequest = _interopRequireDefault(require("../model/KickUserRequest"));
|
|
14
|
-
var
|
|
15
|
-
var
|
|
12
|
+
var _ListLobbies200Response = _interopRequireDefault(require("../model/ListLobbies200Response"));
|
|
13
|
+
var _ListLobbies200ResponseDataInner = _interopRequireDefault(require("../model/ListLobbies200ResponseDataInner"));
|
|
16
14
|
var _UpdateLobbyRequest = _interopRequireDefault(require("../model/UpdateLobbyRequest"));
|
|
17
15
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
|
|
18
16
|
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
@@ -55,7 +53,7 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
55
53
|
* Create a new lobby. The authenticated user becomes the host and is automatically joined.
|
|
56
54
|
* @param {Object} opts Optional parameters
|
|
57
55
|
* @param {module:model/CreateLobbyRequest} [createLobbyRequest] Lobby creation parameters
|
|
58
|
-
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/
|
|
56
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/ListLobbies200ResponseDataInner} and HTTP response
|
|
59
57
|
*/
|
|
60
58
|
return _createClass(LobbiesApi, [{
|
|
61
59
|
key: "createLobbyWithHttpInfo",
|
|
@@ -69,7 +67,7 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
69
67
|
var authNames = ['authorization'];
|
|
70
68
|
var contentTypes = ['application/json'];
|
|
71
69
|
var accepts = ['application/json'];
|
|
72
|
-
var returnType =
|
|
70
|
+
var returnType = _ListLobbies200ResponseDataInner["default"];
|
|
73
71
|
return this.apiClient.callApi('/api/v1/lobbies', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
74
72
|
}
|
|
75
73
|
|
|
@@ -78,7 +76,7 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
78
76
|
* Create a new lobby. The authenticated user becomes the host and is automatically joined.
|
|
79
77
|
* @param {Object} opts Optional parameters
|
|
80
78
|
* @param {module:model/CreateLobbyRequest} opts.createLobbyRequest Lobby creation parameters
|
|
81
|
-
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/
|
|
79
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/ListLobbies200ResponseDataInner}
|
|
82
80
|
*/
|
|
83
81
|
}, {
|
|
84
82
|
key: "createLobby",
|
|
@@ -94,7 +92,7 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
94
92
|
* @param {Number} id Lobby ID
|
|
95
93
|
* @param {Object} opts Optional parameters
|
|
96
94
|
* @param {module:model/JoinLobbyRequest} [joinLobbyRequest] Join parameters (optional)
|
|
97
|
-
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing
|
|
95
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
98
96
|
*/
|
|
99
97
|
}, {
|
|
100
98
|
key: "joinLobbyWithHttpInfo",
|
|
@@ -114,7 +112,7 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
114
112
|
var authNames = ['authorization'];
|
|
115
113
|
var contentTypes = ['application/json'];
|
|
116
114
|
var accepts = ['application/json'];
|
|
117
|
-
var returnType =
|
|
115
|
+
var returnType = null;
|
|
118
116
|
return this.apiClient.callApi('/api/v1/lobbies/{id}/join', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
119
117
|
}
|
|
120
118
|
|
|
@@ -124,7 +122,7 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
124
122
|
* @param {Number} id Lobby ID
|
|
125
123
|
* @param {Object} opts Optional parameters
|
|
126
124
|
* @param {module:model/JoinLobbyRequest} opts.joinLobbyRequest Join parameters (optional)
|
|
127
|
-
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
125
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
128
126
|
*/
|
|
129
127
|
}, {
|
|
130
128
|
key: "joinLobby",
|
|
@@ -140,7 +138,7 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
140
138
|
* @param {Number} id Lobby ID
|
|
141
139
|
* @param {Object} opts Optional parameters
|
|
142
140
|
* @param {module:model/KickUserRequest} [kickUserRequest] Kick parameters
|
|
143
|
-
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing
|
|
141
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
144
142
|
*/
|
|
145
143
|
}, {
|
|
146
144
|
key: "kickUserWithHttpInfo",
|
|
@@ -160,7 +158,7 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
160
158
|
var authNames = ['authorization'];
|
|
161
159
|
var contentTypes = ['application/json'];
|
|
162
160
|
var accepts = ['application/json'];
|
|
163
|
-
var returnType =
|
|
161
|
+
var returnType = null;
|
|
164
162
|
return this.apiClient.callApi('/api/v1/lobbies/{id}/kick', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
165
163
|
}
|
|
166
164
|
|
|
@@ -170,7 +168,7 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
170
168
|
* @param {Number} id Lobby ID
|
|
171
169
|
* @param {Object} opts Optional parameters
|
|
172
170
|
* @param {module:model/KickUserRequest} opts.kickUserRequest Kick parameters
|
|
173
|
-
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
171
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
174
172
|
*/
|
|
175
173
|
}, {
|
|
176
174
|
key: "kickUser",
|
|
@@ -184,7 +182,7 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
184
182
|
* Leave the current lobby
|
|
185
183
|
* Leave the lobby you are currently in.
|
|
186
184
|
* @param {Number} id Lobby ID
|
|
187
|
-
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing
|
|
185
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
188
186
|
*/
|
|
189
187
|
}, {
|
|
190
188
|
key: "leaveLobbyWithHttpInfo",
|
|
@@ -203,7 +201,7 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
203
201
|
var authNames = ['authorization'];
|
|
204
202
|
var contentTypes = [];
|
|
205
203
|
var accepts = ['application/json'];
|
|
206
|
-
var returnType =
|
|
204
|
+
var returnType = null;
|
|
207
205
|
return this.apiClient.callApi('/api/v1/lobbies/{id}/leave', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
208
206
|
}
|
|
209
207
|
|
|
@@ -211,7 +209,7 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
211
209
|
* Leave the current lobby
|
|
212
210
|
* Leave the lobby you are currently in.
|
|
213
211
|
* @param {Number} id Lobby ID
|
|
214
|
-
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
212
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
215
213
|
*/
|
|
216
214
|
}, {
|
|
217
215
|
key: "leaveLobby",
|
|
@@ -226,9 +224,11 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
226
224
|
* Return all non-hidden lobbies. Supports optional text search via 'q' and metadata filters.
|
|
227
225
|
* @param {Object} opts Optional parameters
|
|
228
226
|
* @param {String} [q] Search term for name or title
|
|
227
|
+
* @param {Number} [page] Page number (1-based)
|
|
228
|
+
* @param {Number} [pageSize] Page size (max results per page)
|
|
229
229
|
* @param {String} [metadataKey] Optional metadata key to filter by
|
|
230
230
|
* @param {String} [metadataValue] Optional metadata value to match (used with metadata_key)
|
|
231
|
-
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link
|
|
231
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/ListLobbies200Response} and HTTP response
|
|
232
232
|
*/
|
|
233
233
|
}, {
|
|
234
234
|
key: "listLobbiesWithHttpInfo",
|
|
@@ -238,6 +238,8 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
238
238
|
var pathParams = {};
|
|
239
239
|
var queryParams = {
|
|
240
240
|
'q': opts['q'],
|
|
241
|
+
'page': opts['page'],
|
|
242
|
+
'page_size': opts['pageSize'],
|
|
241
243
|
'metadata_key': opts['metadataKey'],
|
|
242
244
|
'metadata_value': opts['metadataValue']
|
|
243
245
|
};
|
|
@@ -246,7 +248,7 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
246
248
|
var authNames = [];
|
|
247
249
|
var contentTypes = [];
|
|
248
250
|
var accepts = ['application/json'];
|
|
249
|
-
var returnType = [
|
|
251
|
+
var returnType = _ListLobbies200Response["default"];
|
|
250
252
|
return this.apiClient.callApi('/api/v1/lobbies', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
251
253
|
}
|
|
252
254
|
|
|
@@ -255,9 +257,11 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
255
257
|
* Return all non-hidden lobbies. Supports optional text search via 'q' and metadata filters.
|
|
256
258
|
* @param {Object} opts Optional parameters
|
|
257
259
|
* @param {String} opts.q Search term for name or title
|
|
260
|
+
* @param {Number} opts.page Page number (1-based)
|
|
261
|
+
* @param {Number} opts.pageSize Page size (max results per page)
|
|
258
262
|
* @param {String} opts.metadataKey Optional metadata key to filter by
|
|
259
263
|
* @param {String} opts.metadataValue Optional metadata value to match (used with metadata_key)
|
|
260
|
-
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link
|
|
264
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/ListLobbies200Response}
|
|
261
265
|
*/
|
|
262
266
|
}, {
|
|
263
267
|
key: "listLobbies",
|
|
@@ -269,11 +273,11 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
269
273
|
|
|
270
274
|
/**
|
|
271
275
|
* Update lobby (host only)
|
|
272
|
-
* Update lobby settings. Only the host can update the lobby via the API (returns 403 if not host). Admins can still modify lobbies from the admin console
|
|
276
|
+
* Update lobby settings. Only the host can update the lobby via the API (returns 403 if not host). Admins can still modify lobbies from the admin console - those changes are broadcast to viewers.
|
|
273
277
|
* @param {Number} id Lobby ID
|
|
274
278
|
* @param {Object} opts Optional parameters
|
|
275
279
|
* @param {module:model/UpdateLobbyRequest} [updateLobbyRequest] Lobby update parameters
|
|
276
|
-
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/
|
|
280
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/ListLobbies200ResponseDataInner} and HTTP response
|
|
277
281
|
*/
|
|
278
282
|
}, {
|
|
279
283
|
key: "updateLobbyWithHttpInfo",
|
|
@@ -293,17 +297,17 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
293
297
|
var authNames = ['authorization'];
|
|
294
298
|
var contentTypes = ['application/json'];
|
|
295
299
|
var accepts = ['application/json'];
|
|
296
|
-
var returnType =
|
|
300
|
+
var returnType = _ListLobbies200ResponseDataInner["default"];
|
|
297
301
|
return this.apiClient.callApi('/api/v1/lobbies/{id}', 'PATCH', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
298
302
|
}
|
|
299
303
|
|
|
300
304
|
/**
|
|
301
305
|
* Update lobby (host only)
|
|
302
|
-
* Update lobby settings. Only the host can update the lobby via the API (returns 403 if not host). Admins can still modify lobbies from the admin console
|
|
306
|
+
* Update lobby settings. Only the host can update the lobby via the API (returns 403 if not host). Admins can still modify lobbies from the admin console - those changes are broadcast to viewers.
|
|
303
307
|
* @param {Number} id Lobby ID
|
|
304
308
|
* @param {Object} opts Optional parameters
|
|
305
309
|
* @param {module:model/UpdateLobbyRequest} opts.updateLobbyRequest Lobby update parameters
|
|
306
|
-
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/
|
|
310
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/ListLobbies200ResponseDataInner}
|
|
307
311
|
*/
|
|
308
312
|
}, {
|
|
309
313
|
key: "updateLobby",
|