@ughuuu/game_server 1.0.206 → 1.0.220
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 +37 -11
- package/dist/ApiClient.js +2 -2
- package/dist/api/AuthenticationApi.js +27 -29
- package/dist/api/FriendsApi.js +2 -2
- package/dist/api/HealthApi.js +2 -2
- package/dist/api/LobbiesApi.js +19 -43
- package/dist/api/UsersApi.js +64 -19
- package/dist/index.js +21 -0
- package/dist/model/CreateFriendRequestRequest.js +2 -2
- package/dist/model/CreateLobby401Response.js +2 -2
- package/dist/model/CreateLobbyRequest.js +2 -2
- package/dist/model/DeviceLoginRequest.js +2 -2
- package/dist/model/GetCurrentUser200Response.js +2 -2
- package/dist/model/HealthResponse.js +2 -2
- package/dist/model/JoinLobbyRequest.js +2 -2
- package/dist/model/KickUserRequest.js +2 -2
- package/dist/model/ListBlockedFriends200Response.js +2 -2
- package/dist/model/ListBlockedFriends200ResponseDataInner.js +2 -2
- package/dist/model/ListBlockedFriends200ResponseDataInnerRequester.js +2 -2
- package/dist/model/ListFriendRequests200Response.js +2 -2
- package/dist/model/ListFriendRequests200ResponseIncomingInner.js +2 -2
- package/dist/model/ListFriendRequests200ResponseIncomingInnerRequester.js +2 -2
- package/dist/model/ListFriendRequests200ResponseMeta.js +2 -2
- package/dist/model/ListFriends200Response.js +2 -2
- package/dist/model/ListFriends200ResponseDataInner.js +2 -2
- package/dist/model/ListLobbies200Response.js +2 -2
- package/dist/model/ListLobbies200ResponseDataInner.js +2 -2
- package/dist/model/ListLobbies200ResponseMeta.js +2 -2
- package/dist/model/Login200Response.js +2 -2
- package/dist/model/Login200ResponseData.js +2 -2
- package/dist/model/Login200ResponseDataUser.js +2 -2
- package/dist/model/LoginRequest.js +2 -2
- package/dist/model/OAuthSessionData.js +2 -2
- package/dist/model/OAuthSessionDataDetails.js +2 -2
- package/dist/model/OAuthSessionStatus.js +2 -2
- package/dist/model/OauthApiCallbackRequest.js +90 -0
- package/dist/model/OauthRequest200Response.js +2 -2
- package/dist/model/RefreshToken200Response.js +2 -2
- package/dist/model/RefreshTokenRequest.js +2 -2
- package/dist/model/UpdateCurrentUserDisplayNameRequest.js +112 -0
- package/dist/model/UpdateCurrentUserPasswordRequest.js +112 -0
- package/dist/model/UpdateLobbyRequest.js +2 -2
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -13,7 +13,8 @@ This API uses JWT (JSON Web Tokens) with access and refresh tokens:
|
|
|
13
13
|
- **Discord OAuth**: Use `/api/v1/auth/discord` flow
|
|
14
14
|
- **Google OAuth**: Use `/api/v1/auth/google` flow
|
|
15
15
|
- **Facebook OAuth**: Use `/api/v1/auth/facebook` flow
|
|
16
|
-
- **Apple Sign In**: Use `/auth/apple` browser flow
|
|
16
|
+
- **Apple Sign In**: Use `/auth/apple` browser flow or apple sdk flow
|
|
17
|
+
- **Steam (OpenID)**: Use `/api/v1/auth/steam` flow
|
|
17
18
|
|
|
18
19
|
Both methods return:
|
|
19
20
|
- `access_token` - Short-lived (15 min), use for API requests
|
|
@@ -28,12 +29,33 @@ Authorization: Bearer <access_token>
|
|
|
28
29
|
### Refreshing Tokens
|
|
29
30
|
When your access token expires, use POST `/api/v1/refresh` with your refresh token to get a new access token.
|
|
30
31
|
|
|
31
|
-
##
|
|
32
|
-
|
|
32
|
+
## Users
|
|
33
|
+
Users endpoints cover the user lifecycle and profile features. Key highlights:
|
|
34
|
+
|
|
35
|
+
- **Registration and login** (email/password, device token for SDKs, and OAuth providers)
|
|
36
|
+
- **Profile metadata** (JSON blob per user) and editable profile fields
|
|
37
|
+
- **Account lifecycle**: password reset, email confirmation, and account deletion
|
|
38
|
+
- **Sessions & tokens**: both browser sessions and JWT-based API tokens are supported
|
|
39
|
+
|
|
40
|
+
## Friends
|
|
41
|
+
The Friends domain offers lightweight social features:
|
|
42
|
+
|
|
43
|
+
- **Friend requests** (send / accept / reject / block flows)
|
|
44
|
+
- **Friend listing & pagination**, with basic privacy controls
|
|
45
|
+
- **Domain helpers** to manage and query friend relationships from API or UI contexts
|
|
46
|
+
|
|
47
|
+
## Lobbies
|
|
48
|
+
Lobbies provide matchmaking / room management primitives. Highlights:
|
|
49
|
+
|
|
50
|
+
- **Create / list / update / delete** lobbies with rich metadata (mode, region, tags)
|
|
51
|
+
- **Host-managed or hostless** modes (hostless allowed internally, not creatable via public API)
|
|
52
|
+
- **Membership management**: join, leave, kick users, and automatic host transfer
|
|
53
|
+
- **Controls & protection**: max users, hidden/locked states, and optional password protection
|
|
54
|
+
- **Hidden lobbies** are excluded from public listings; public listing endpoints are paginated
|
|
33
55
|
|
|
34
56
|
This SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
|
|
35
57
|
|
|
36
|
-
- API version: 1.0.
|
|
58
|
+
- API version: 1.0.220
|
|
37
59
|
- Package version: 1.0.0
|
|
38
60
|
- Generator version: 7.17.0
|
|
39
61
|
- Build package: org.openapitools.codegen.languages.JavascriptClientCodegen
|
|
@@ -150,10 +172,10 @@ All URIs are relative to *http://localhost:4000*
|
|
|
150
172
|
|
|
151
173
|
Class | Method | HTTP request | Description
|
|
152
174
|
------------ | ------------- | ------------- | -------------
|
|
153
|
-
*UghuuuGameServer.AuthenticationApi* | [**deviceLogin**](docs/AuthenticationApi.md#deviceLogin) | **POST** /api/v1/login/device | Device login
|
|
175
|
+
*UghuuuGameServer.AuthenticationApi* | [**deviceLogin**](docs/AuthenticationApi.md#deviceLogin) | **POST** /api/v1/login/device | Device login
|
|
154
176
|
*UghuuuGameServer.AuthenticationApi* | [**login**](docs/AuthenticationApi.md#login) | **POST** /api/v1/login | Login
|
|
155
177
|
*UghuuuGameServer.AuthenticationApi* | [**logout**](docs/AuthenticationApi.md#logout) | **DELETE** /api/v1/logout | Logout
|
|
156
|
-
*UghuuuGameServer.AuthenticationApi* | [**
|
|
178
|
+
*UghuuuGameServer.AuthenticationApi* | [**oauthApiCallback**](docs/AuthenticationApi.md#oauthApiCallback) | **POST** /api/v1/auth/{provider}/callback | API callback / code exchange
|
|
157
179
|
*UghuuuGameServer.AuthenticationApi* | [**oauthRequest**](docs/AuthenticationApi.md#oauthRequest) | **GET** /api/v1/auth/{provider} | Initiate API OAuth
|
|
158
180
|
*UghuuuGameServer.AuthenticationApi* | [**oauthSessionStatus**](docs/AuthenticationApi.md#oauthSessionStatus) | **GET** /api/v1/auth/session/{session_id} | Get OAuth session status
|
|
159
181
|
*UghuuuGameServer.AuthenticationApi* | [**refreshToken**](docs/AuthenticationApi.md#refreshToken) | **POST** /api/v1/refresh | Refresh access token
|
|
@@ -170,13 +192,14 @@ Class | Method | HTTP request | Description
|
|
|
170
192
|
*UghuuuGameServer.HealthApi* | [**index**](docs/HealthApi.md#index) | **GET** /api/v1/health | Health check
|
|
171
193
|
*UghuuuGameServer.LobbiesApi* | [**createLobby**](docs/LobbiesApi.md#createLobby) | **POST** /api/v1/lobbies | Create a lobby
|
|
172
194
|
*UghuuuGameServer.LobbiesApi* | [**joinLobby**](docs/LobbiesApi.md#joinLobby) | **POST** /api/v1/lobbies/{id}/join | Join a lobby
|
|
173
|
-
*UghuuuGameServer.LobbiesApi* | [**kickUser**](docs/LobbiesApi.md#kickUser) | **POST** /api/v1/lobbies/
|
|
174
|
-
*UghuuuGameServer.LobbiesApi* | [**leaveLobby**](docs/LobbiesApi.md#leaveLobby) | **POST** /api/v1/lobbies/
|
|
195
|
+
*UghuuuGameServer.LobbiesApi* | [**kickUser**](docs/LobbiesApi.md#kickUser) | **POST** /api/v1/lobbies/kick | Kick a user from the lobby (host only)
|
|
196
|
+
*UghuuuGameServer.LobbiesApi* | [**leaveLobby**](docs/LobbiesApi.md#leaveLobby) | **POST** /api/v1/lobbies/leave | Leave the current lobby
|
|
175
197
|
*UghuuuGameServer.LobbiesApi* | [**listLobbies**](docs/LobbiesApi.md#listLobbies) | **GET** /api/v1/lobbies | List lobbies
|
|
176
|
-
*UghuuuGameServer.LobbiesApi* | [**updateLobby**](docs/LobbiesApi.md#updateLobby) | **PATCH** /api/v1/lobbies
|
|
198
|
+
*UghuuuGameServer.LobbiesApi* | [**updateLobby**](docs/LobbiesApi.md#updateLobby) | **PATCH** /api/v1/lobbies | Update lobby (host only)
|
|
199
|
+
*UghuuuGameServer.UsersApi* | [**deleteCurrentUser**](docs/UsersApi.md#deleteCurrentUser) | **DELETE** /api/v1/me | Delete current user
|
|
177
200
|
*UghuuuGameServer.UsersApi* | [**getCurrentUser**](docs/UsersApi.md#getCurrentUser) | **GET** /api/v1/me | Return current user info
|
|
178
|
-
*UghuuuGameServer.UsersApi* | [**getUser**](docs/UsersApi.md#getUser) | **GET** /api/v1/users/{id} | Get a user by id
|
|
179
|
-
*UghuuuGameServer.UsersApi* | [**searchUsers**](docs/UsersApi.md#searchUsers) | **GET** /api/v1/users | Search users by id/email/display_name
|
|
201
|
+
*UghuuuGameServer.UsersApi* | [**getUser**](docs/UsersApi.md#getUser) | **GET** /api/v1/users/{id} | Get a user by id
|
|
202
|
+
*UghuuuGameServer.UsersApi* | [**searchUsers**](docs/UsersApi.md#searchUsers) | **GET** /api/v1/users | Search users by id/email/display_name
|
|
180
203
|
*UghuuuGameServer.UsersApi* | [**updateCurrentUserDisplayName**](docs/UsersApi.md#updateCurrentUserDisplayName) | **PATCH** /api/v1/me/display_name | Update current user's display name
|
|
181
204
|
*UghuuuGameServer.UsersApi* | [**updateCurrentUserPassword**](docs/UsersApi.md#updateCurrentUserPassword) | **PATCH** /api/v1/me/password | Update current user password
|
|
182
205
|
|
|
@@ -210,9 +233,12 @@ Class | Method | HTTP request | Description
|
|
|
210
233
|
- [UghuuuGameServer.OAuthSessionData](docs/OAuthSessionData.md)
|
|
211
234
|
- [UghuuuGameServer.OAuthSessionDataDetails](docs/OAuthSessionDataDetails.md)
|
|
212
235
|
- [UghuuuGameServer.OAuthSessionStatus](docs/OAuthSessionStatus.md)
|
|
236
|
+
- [UghuuuGameServer.OauthApiCallbackRequest](docs/OauthApiCallbackRequest.md)
|
|
213
237
|
- [UghuuuGameServer.OauthRequest200Response](docs/OauthRequest200Response.md)
|
|
214
238
|
- [UghuuuGameServer.RefreshToken200Response](docs/RefreshToken200Response.md)
|
|
215
239
|
- [UghuuuGameServer.RefreshTokenRequest](docs/RefreshTokenRequest.md)
|
|
240
|
+
- [UghuuuGameServer.UpdateCurrentUserDisplayNameRequest](docs/UpdateCurrentUserDisplayNameRequest.md)
|
|
241
|
+
- [UghuuuGameServer.UpdateCurrentUserPasswordRequest](docs/UpdateCurrentUserPasswordRequest.md)
|
|
216
242
|
- [UghuuuGameServer.UpdateLobbyRequest](docs/UpdateLobbyRequest.md)
|
|
217
243
|
|
|
218
244
|
|
package/dist/ApiClient.js
CHANGED
|
@@ -13,9 +13,9 @@ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r),
|
|
|
13
13
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
14
14
|
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); } /**
|
|
15
15
|
* Game Server API
|
|
16
|
-
* 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 - **Device (SDK)**: POST to `/api/v1/login` with a `device_id` string (creates/returns a device user) - **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
|
|
16
|
+
* 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 - **Device (SDK)**: POST to `/api/v1/login` with a `device_id` string (creates/returns a device user) - **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 or apple sdk flow - **Steam (OpenID)**: Use `/api/v1/auth/steam` flow 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. ## Users Users endpoints cover the user lifecycle and profile features. Key highlights: - **Registration and login** (email/password, device token for SDKs, and OAuth providers) - **Profile metadata** (JSON blob per user) and editable profile fields - **Account lifecycle**: password reset, email confirmation, and account deletion - **Sessions & tokens**: both browser sessions and JWT-based API tokens are supported ## Friends The Friends domain offers lightweight social features: - **Friend requests** (send / accept / reject / block flows) - **Friend listing & pagination**, with basic privacy controls - **Domain helpers** to manage and query friend relationships from API or UI contexts ## Lobbies Lobbies provide matchmaking / room management primitives. Highlights: - **Create / list / update / delete** lobbies with rich metadata (mode, region, tags) - **Host-managed or hostless** modes (hostless allowed internally, not creatable via public API) - **Membership management**: join, leave, kick users, and automatic host transfer - **Controls & protection**: max users, hidden/locked states, and optional password protection - **Hidden lobbies** are excluded from public listings; public listing endpoints are paginated
|
|
17
17
|
*
|
|
18
|
-
* The version of the OpenAPI document: 1.0.
|
|
18
|
+
* The version of the OpenAPI document: 1.0.220
|
|
19
19
|
*
|
|
20
20
|
*
|
|
21
21
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -9,6 +9,7 @@ var _DeviceLoginRequest = _interopRequireDefault(require("../model/DeviceLoginRe
|
|
|
9
9
|
var _Login200Response = _interopRequireDefault(require("../model/Login200Response"));
|
|
10
10
|
var _LoginRequest = _interopRequireDefault(require("../model/LoginRequest"));
|
|
11
11
|
var _OAuthSessionStatus = _interopRequireDefault(require("../model/OAuthSessionStatus"));
|
|
12
|
+
var _OauthApiCallbackRequest = _interopRequireDefault(require("../model/OauthApiCallbackRequest"));
|
|
12
13
|
var _OauthRequest200Response = _interopRequireDefault(require("../model/OauthRequest200Response"));
|
|
13
14
|
var _RefreshToken200Response = _interopRequireDefault(require("../model/RefreshToken200Response"));
|
|
14
15
|
var _RefreshTokenRequest = _interopRequireDefault(require("../model/RefreshTokenRequest"));
|
|
@@ -20,9 +21,9 @@ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r),
|
|
|
20
21
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
21
22
|
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); } /**
|
|
22
23
|
* Game Server API
|
|
23
|
-
* 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 - **Device (SDK)**: POST to `/api/v1/login` with a `device_id` string (creates/returns a device user) - **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
|
|
24
|
+
* 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 - **Device (SDK)**: POST to `/api/v1/login` with a `device_id` string (creates/returns a device user) - **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 or apple sdk flow - **Steam (OpenID)**: Use `/api/v1/auth/steam` flow 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. ## Users Users endpoints cover the user lifecycle and profile features. Key highlights: - **Registration and login** (email/password, device token for SDKs, and OAuth providers) - **Profile metadata** (JSON blob per user) and editable profile fields - **Account lifecycle**: password reset, email confirmation, and account deletion - **Sessions & tokens**: both browser sessions and JWT-based API tokens are supported ## Friends The Friends domain offers lightweight social features: - **Friend requests** (send / accept / reject / block flows) - **Friend listing & pagination**, with basic privacy controls - **Domain helpers** to manage and query friend relationships from API or UI contexts ## Lobbies Lobbies provide matchmaking / room management primitives. Highlights: - **Create / list / update / delete** lobbies with rich metadata (mode, region, tags) - **Host-managed or hostless** modes (hostless allowed internally, not creatable via public API) - **Membership management**: join, leave, kick users, and automatic host transfer - **Controls & protection**: max users, hidden/locked states, and optional password protection - **Hidden lobbies** are excluded from public listings; public listing endpoints are paginated
|
|
24
25
|
*
|
|
25
|
-
* The version of the OpenAPI document: 1.0.
|
|
26
|
+
* The version of the OpenAPI document: 1.0.220
|
|
26
27
|
*
|
|
27
28
|
*
|
|
28
29
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -49,7 +50,7 @@ var AuthenticationApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
49
50
|
}
|
|
50
51
|
|
|
51
52
|
/**
|
|
52
|
-
* Device login
|
|
53
|
+
* Device login
|
|
53
54
|
* Authenticate or create a device-backed user using a device_id (no password).
|
|
54
55
|
* @param {Object} opts Optional parameters
|
|
55
56
|
* @param {module:model/DeviceLoginRequest} [deviceLoginRequest] Device login
|
|
@@ -72,7 +73,7 @@ var AuthenticationApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
72
73
|
}
|
|
73
74
|
|
|
74
75
|
/**
|
|
75
|
-
* Device login
|
|
76
|
+
* Device login
|
|
76
77
|
* Authenticate or create a device-backed user using a device_id (no password).
|
|
77
78
|
* @param {Object} opts Optional parameters
|
|
78
79
|
* @param {module:model/DeviceLoginRequest} opts.deviceLoginRequest Device login
|
|
@@ -158,50 +159,47 @@ var AuthenticationApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
158
159
|
}
|
|
159
160
|
|
|
160
161
|
/**
|
|
161
|
-
*
|
|
162
|
-
*
|
|
163
|
-
* @param {
|
|
164
|
-
* @param {
|
|
162
|
+
* API callback / code exchange
|
|
163
|
+
* Accepts an OAuth authorization code via the API and returns access/refresh tokens on success. For the Steam provider, the `code` field should contain a server-verifiable Steam credential (for example a Steam auth ticket or Steam identifier) and will be validated via the Steam Web API.
|
|
164
|
+
* @param {String} provider
|
|
165
|
+
* @param {Object} opts Optional parameters
|
|
166
|
+
* @param {module:model/OauthApiCallbackRequest} [oauthApiCallbackRequest] Code exchange or steam payload
|
|
165
167
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link Object} and HTTP response
|
|
166
168
|
*/
|
|
167
169
|
}, {
|
|
168
|
-
key: "
|
|
169
|
-
value: function
|
|
170
|
-
|
|
170
|
+
key: "oauthApiCallbackWithHttpInfo",
|
|
171
|
+
value: function oauthApiCallbackWithHttpInfo(provider, opts) {
|
|
172
|
+
opts = opts || {};
|
|
173
|
+
var postBody = opts['oauthApiCallbackRequest'];
|
|
171
174
|
// verify the required parameter 'provider' is set
|
|
172
175
|
if (provider === undefined || provider === null) {
|
|
173
|
-
throw new Error("Missing the required parameter 'provider' when calling
|
|
174
|
-
}
|
|
175
|
-
// verify the required parameter 'conflictUserId' is set
|
|
176
|
-
if (conflictUserId === undefined || conflictUserId === null) {
|
|
177
|
-
throw new Error("Missing the required parameter 'conflictUserId' when calling oauthConflictDelete");
|
|
176
|
+
throw new Error("Missing the required parameter 'provider' when calling oauthApiCallback");
|
|
178
177
|
}
|
|
179
178
|
var pathParams = {
|
|
180
179
|
'provider': provider
|
|
181
180
|
};
|
|
182
|
-
var queryParams = {
|
|
183
|
-
'conflict_user_id': conflictUserId
|
|
184
|
-
};
|
|
181
|
+
var queryParams = {};
|
|
185
182
|
var headerParams = {};
|
|
186
183
|
var formParams = {};
|
|
187
|
-
var authNames = [
|
|
188
|
-
var contentTypes = [];
|
|
184
|
+
var authNames = [];
|
|
185
|
+
var contentTypes = ['application/json'];
|
|
189
186
|
var accepts = ['application/json'];
|
|
190
187
|
var returnType = Object;
|
|
191
|
-
return this.apiClient.callApi('/api/v1/auth/{provider}/
|
|
188
|
+
return this.apiClient.callApi('/api/v1/auth/{provider}/callback', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
192
189
|
}
|
|
193
190
|
|
|
194
191
|
/**
|
|
195
|
-
*
|
|
196
|
-
*
|
|
197
|
-
* @param {
|
|
198
|
-
* @param {
|
|
192
|
+
* API callback / code exchange
|
|
193
|
+
* Accepts an OAuth authorization code via the API and returns access/refresh tokens on success. For the Steam provider, the `code` field should contain a server-verifiable Steam credential (for example a Steam auth ticket or Steam identifier) and will be validated via the Steam Web API.
|
|
194
|
+
* @param {String} provider
|
|
195
|
+
* @param {Object} opts Optional parameters
|
|
196
|
+
* @param {module:model/OauthApiCallbackRequest} opts.oauthApiCallbackRequest Code exchange or steam payload
|
|
199
197
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link Object}
|
|
200
198
|
*/
|
|
201
199
|
}, {
|
|
202
|
-
key: "
|
|
203
|
-
value: function
|
|
204
|
-
return this.
|
|
200
|
+
key: "oauthApiCallback",
|
|
201
|
+
value: function oauthApiCallback(provider, opts) {
|
|
202
|
+
return this.oauthApiCallbackWithHttpInfo(provider, opts).then(function (response_and_data) {
|
|
205
203
|
return response_and_data.data;
|
|
206
204
|
});
|
|
207
205
|
}
|
package/dist/api/FriendsApi.js
CHANGED
|
@@ -17,9 +17,9 @@ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r),
|
|
|
17
17
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
18
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
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 - **Device (SDK)**: POST to `/api/v1/login` with a `device_id` string (creates/returns a device user) - **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
|
|
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 - **Device (SDK)**: POST to `/api/v1/login` with a `device_id` string (creates/returns a device user) - **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 or apple sdk flow - **Steam (OpenID)**: Use `/api/v1/auth/steam` flow 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. ## Users Users endpoints cover the user lifecycle and profile features. Key highlights: - **Registration and login** (email/password, device token for SDKs, and OAuth providers) - **Profile metadata** (JSON blob per user) and editable profile fields - **Account lifecycle**: password reset, email confirmation, and account deletion - **Sessions & tokens**: both browser sessions and JWT-based API tokens are supported ## Friends The Friends domain offers lightweight social features: - **Friend requests** (send / accept / reject / block flows) - **Friend listing & pagination**, with basic privacy controls - **Domain helpers** to manage and query friend relationships from API or UI contexts ## Lobbies Lobbies provide matchmaking / room management primitives. Highlights: - **Create / list / update / delete** lobbies with rich metadata (mode, region, tags) - **Host-managed or hostless** modes (hostless allowed internally, not creatable via public API) - **Membership management**: join, leave, kick users, and automatic host transfer - **Controls & protection**: max users, hidden/locked states, and optional password protection - **Hidden lobbies** are excluded from public listings; public listing endpoints are paginated
|
|
21
21
|
*
|
|
22
|
-
* The version of the OpenAPI document: 1.0.
|
|
22
|
+
* The version of the OpenAPI document: 1.0.220
|
|
23
23
|
*
|
|
24
24
|
*
|
|
25
25
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/dist/api/HealthApi.js
CHANGED
|
@@ -14,9 +14,9 @@ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r),
|
|
|
14
14
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
15
15
|
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); } /**
|
|
16
16
|
* Game Server API
|
|
17
|
-
* 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 - **Device (SDK)**: POST to `/api/v1/login` with a `device_id` string (creates/returns a device user) - **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
|
|
17
|
+
* 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 - **Device (SDK)**: POST to `/api/v1/login` with a `device_id` string (creates/returns a device user) - **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 or apple sdk flow - **Steam (OpenID)**: Use `/api/v1/auth/steam` flow 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. ## Users Users endpoints cover the user lifecycle and profile features. Key highlights: - **Registration and login** (email/password, device token for SDKs, and OAuth providers) - **Profile metadata** (JSON blob per user) and editable profile fields - **Account lifecycle**: password reset, email confirmation, and account deletion - **Sessions & tokens**: both browser sessions and JWT-based API tokens are supported ## Friends The Friends domain offers lightweight social features: - **Friend requests** (send / accept / reject / block flows) - **Friend listing & pagination**, with basic privacy controls - **Domain helpers** to manage and query friend relationships from API or UI contexts ## Lobbies Lobbies provide matchmaking / room management primitives. Highlights: - **Create / list / update / delete** lobbies with rich metadata (mode, region, tags) - **Host-managed or hostless** modes (hostless allowed internally, not creatable via public API) - **Membership management**: join, leave, kick users, and automatic host transfer - **Controls & protection**: max users, hidden/locked states, and optional password protection - **Hidden lobbies** are excluded from public listings; public listing endpoints are paginated
|
|
18
18
|
*
|
|
19
|
-
* The version of the OpenAPI document: 1.0.
|
|
19
|
+
* The version of the OpenAPI document: 1.0.220
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/dist/api/LobbiesApi.js
CHANGED
|
@@ -20,9 +20,9 @@ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r),
|
|
|
20
20
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
21
21
|
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); } /**
|
|
22
22
|
* Game Server API
|
|
23
|
-
* 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 - **Device (SDK)**: POST to `/api/v1/login` with a `device_id` string (creates/returns a device user) - **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
|
|
23
|
+
* 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 - **Device (SDK)**: POST to `/api/v1/login` with a `device_id` string (creates/returns a device user) - **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 or apple sdk flow - **Steam (OpenID)**: Use `/api/v1/auth/steam` flow 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. ## Users Users endpoints cover the user lifecycle and profile features. Key highlights: - **Registration and login** (email/password, device token for SDKs, and OAuth providers) - **Profile metadata** (JSON blob per user) and editable profile fields - **Account lifecycle**: password reset, email confirmation, and account deletion - **Sessions & tokens**: both browser sessions and JWT-based API tokens are supported ## Friends The Friends domain offers lightweight social features: - **Friend requests** (send / accept / reject / block flows) - **Friend listing & pagination**, with basic privacy controls - **Domain helpers** to manage and query friend relationships from API or UI contexts ## Lobbies Lobbies provide matchmaking / room management primitives. Highlights: - **Create / list / update / delete** lobbies with rich metadata (mode, region, tags) - **Host-managed or hostless** modes (hostless allowed internally, not creatable via public API) - **Membership management**: join, leave, kick users, and automatic host transfer - **Controls & protection**: max users, hidden/locked states, and optional password protection - **Hidden lobbies** are excluded from public listings; public listing endpoints are paginated
|
|
24
24
|
*
|
|
25
|
-
* The version of the OpenAPI document: 1.0.
|
|
25
|
+
* The version of the OpenAPI document: 1.0.220
|
|
26
26
|
*
|
|
27
27
|
*
|
|
28
28
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -133,25 +133,18 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
133
133
|
}
|
|
134
134
|
|
|
135
135
|
/**
|
|
136
|
-
* Kick a user from the lobby
|
|
136
|
+
* Kick a user from the lobby (host only)
|
|
137
137
|
* Remove a user from the lobby. Only the host can kick users via the API (returns 403 if not host).
|
|
138
|
-
* @param {Number} id Lobby ID
|
|
139
138
|
* @param {Object} opts Optional parameters
|
|
140
139
|
* @param {module:model/KickUserRequest} [kickUserRequest] Kick parameters
|
|
141
140
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
142
141
|
*/
|
|
143
142
|
}, {
|
|
144
143
|
key: "kickUserWithHttpInfo",
|
|
145
|
-
value: function kickUserWithHttpInfo(
|
|
144
|
+
value: function kickUserWithHttpInfo(opts) {
|
|
146
145
|
opts = opts || {};
|
|
147
146
|
var postBody = opts['kickUserRequest'];
|
|
148
|
-
|
|
149
|
-
if (id === undefined || id === null) {
|
|
150
|
-
throw new Error("Missing the required parameter 'id' when calling kickUser");
|
|
151
|
-
}
|
|
152
|
-
var pathParams = {
|
|
153
|
-
'id': id
|
|
154
|
-
};
|
|
147
|
+
var pathParams = {};
|
|
155
148
|
var queryParams = {};
|
|
156
149
|
var headerParams = {};
|
|
157
150
|
var formParams = {};
|
|
@@ -159,21 +152,20 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
159
152
|
var contentTypes = ['application/json'];
|
|
160
153
|
var accepts = ['application/json'];
|
|
161
154
|
var returnType = null;
|
|
162
|
-
return this.apiClient.callApi('/api/v1/lobbies/
|
|
155
|
+
return this.apiClient.callApi('/api/v1/lobbies/kick', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
163
156
|
}
|
|
164
157
|
|
|
165
158
|
/**
|
|
166
|
-
* Kick a user from the lobby
|
|
159
|
+
* Kick a user from the lobby (host only)
|
|
167
160
|
* Remove a user from the lobby. Only the host can kick users via the API (returns 403 if not host).
|
|
168
|
-
* @param {Number} id Lobby ID
|
|
169
161
|
* @param {Object} opts Optional parameters
|
|
170
162
|
* @param {module:model/KickUserRequest} opts.kickUserRequest Kick parameters
|
|
171
163
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
172
164
|
*/
|
|
173
165
|
}, {
|
|
174
166
|
key: "kickUser",
|
|
175
|
-
value: function kickUser(
|
|
176
|
-
return this.kickUserWithHttpInfo(
|
|
167
|
+
value: function kickUser(opts) {
|
|
168
|
+
return this.kickUserWithHttpInfo(opts).then(function (response_and_data) {
|
|
177
169
|
return response_and_data.data;
|
|
178
170
|
});
|
|
179
171
|
}
|
|
@@ -181,20 +173,13 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
181
173
|
/**
|
|
182
174
|
* Leave the current lobby
|
|
183
175
|
* Leave the lobby you are currently in.
|
|
184
|
-
* @param {Number} id Lobby ID
|
|
185
176
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
186
177
|
*/
|
|
187
178
|
}, {
|
|
188
179
|
key: "leaveLobbyWithHttpInfo",
|
|
189
|
-
value: function leaveLobbyWithHttpInfo(
|
|
180
|
+
value: function leaveLobbyWithHttpInfo() {
|
|
190
181
|
var postBody = null;
|
|
191
|
-
|
|
192
|
-
if (id === undefined || id === null) {
|
|
193
|
-
throw new Error("Missing the required parameter 'id' when calling leaveLobby");
|
|
194
|
-
}
|
|
195
|
-
var pathParams = {
|
|
196
|
-
'id': id
|
|
197
|
-
};
|
|
182
|
+
var pathParams = {};
|
|
198
183
|
var queryParams = {};
|
|
199
184
|
var headerParams = {};
|
|
200
185
|
var formParams = {};
|
|
@@ -202,19 +187,18 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
202
187
|
var contentTypes = [];
|
|
203
188
|
var accepts = ['application/json'];
|
|
204
189
|
var returnType = null;
|
|
205
|
-
return this.apiClient.callApi('/api/v1/lobbies/
|
|
190
|
+
return this.apiClient.callApi('/api/v1/lobbies/leave', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
206
191
|
}
|
|
207
192
|
|
|
208
193
|
/**
|
|
209
194
|
* Leave the current lobby
|
|
210
195
|
* Leave the lobby you are currently in.
|
|
211
|
-
* @param {Number} id Lobby ID
|
|
212
196
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
213
197
|
*/
|
|
214
198
|
}, {
|
|
215
199
|
key: "leaveLobby",
|
|
216
|
-
value: function leaveLobby(
|
|
217
|
-
return this.leaveLobbyWithHttpInfo(
|
|
200
|
+
value: function leaveLobby() {
|
|
201
|
+
return this.leaveLobbyWithHttpInfo().then(function (response_and_data) {
|
|
218
202
|
return response_and_data.data;
|
|
219
203
|
});
|
|
220
204
|
}
|
|
@@ -274,23 +258,16 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
274
258
|
/**
|
|
275
259
|
* Update lobby (host only)
|
|
276
260
|
* 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.
|
|
277
|
-
* @param {Number} id Lobby ID
|
|
278
261
|
* @param {Object} opts Optional parameters
|
|
279
262
|
* @param {module:model/UpdateLobbyRequest} [updateLobbyRequest] Lobby update parameters
|
|
280
263
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/ListLobbies200ResponseDataInner} and HTTP response
|
|
281
264
|
*/
|
|
282
265
|
}, {
|
|
283
266
|
key: "updateLobbyWithHttpInfo",
|
|
284
|
-
value: function updateLobbyWithHttpInfo(
|
|
267
|
+
value: function updateLobbyWithHttpInfo(opts) {
|
|
285
268
|
opts = opts || {};
|
|
286
269
|
var postBody = opts['updateLobbyRequest'];
|
|
287
|
-
|
|
288
|
-
if (id === undefined || id === null) {
|
|
289
|
-
throw new Error("Missing the required parameter 'id' when calling updateLobby");
|
|
290
|
-
}
|
|
291
|
-
var pathParams = {
|
|
292
|
-
'id': id
|
|
293
|
-
};
|
|
270
|
+
var pathParams = {};
|
|
294
271
|
var queryParams = {};
|
|
295
272
|
var headerParams = {};
|
|
296
273
|
var formParams = {};
|
|
@@ -298,21 +275,20 @@ var LobbiesApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
298
275
|
var contentTypes = ['application/json'];
|
|
299
276
|
var accepts = ['application/json'];
|
|
300
277
|
var returnType = _ListLobbies200ResponseDataInner["default"];
|
|
301
|
-
return this.apiClient.callApi('/api/v1/lobbies
|
|
278
|
+
return this.apiClient.callApi('/api/v1/lobbies', 'PATCH', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
302
279
|
}
|
|
303
280
|
|
|
304
281
|
/**
|
|
305
282
|
* Update lobby (host only)
|
|
306
283
|
* 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.
|
|
307
|
-
* @param {Number} id Lobby ID
|
|
308
284
|
* @param {Object} opts Optional parameters
|
|
309
285
|
* @param {module:model/UpdateLobbyRequest} opts.updateLobbyRequest Lobby update parameters
|
|
310
286
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/ListLobbies200ResponseDataInner}
|
|
311
287
|
*/
|
|
312
288
|
}, {
|
|
313
289
|
key: "updateLobby",
|
|
314
|
-
value: function updateLobby(
|
|
315
|
-
return this.updateLobbyWithHttpInfo(
|
|
290
|
+
value: function updateLobby(opts) {
|
|
291
|
+
return this.updateLobbyWithHttpInfo(opts).then(function (response_and_data) {
|
|
316
292
|
return response_and_data.data;
|
|
317
293
|
});
|
|
318
294
|
}
|