connectbase-client 6.26.1 → 6.27.1
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/CHANGELOG.md +33 -0
- package/dist/cli.js +15 -3
- package/dist/connect-base.umd.js +5 -5
- package/dist/index.d.mts +675 -1
- package/dist/index.d.ts +675 -1
- package/dist/index.js +722 -2
- package/dist/index.mjs +718 -2
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -5011,6 +5011,352 @@ interface ScriptMetricsResponse {
|
|
|
5011
5011
|
phase_samples: number;
|
|
5012
5012
|
}
|
|
5013
5013
|
|
|
5014
|
+
/**
|
|
5015
|
+
* 앱 안의 게임 단위(game_key) 타입.
|
|
5016
|
+
*
|
|
5017
|
+
* 원본 계약: docs/game-server/MULTI_GAME.md "API 계약" 절. Go 쪽 같은 이름 타입은
|
|
5018
|
+
* backend/pkg/gameunit 에 있고 JSON 칸 이름이 같다.
|
|
5019
|
+
*/
|
|
5020
|
+
/** 게임 상태. `deleted` 는 청소가 끝나고 24시간(키 보류) 뒤 행이 사라진다. 삭제하면 웹 스토리지는 연결만 끊긴다. */
|
|
5021
|
+
type GameStatus = "active" | "disabled" | "deleted";
|
|
5022
|
+
/**
|
|
5023
|
+
* 게임 안에서 플레이어를 가리키는 방식.
|
|
5024
|
+
* - `anonymous`: 게임별 익명 id(`gp_...`). 새 게임의 기본.
|
|
5025
|
+
* - `member`: 앱 회원 id 그대로(이관한 옛 게임 호환).
|
|
5026
|
+
*/
|
|
5027
|
+
type GamePlayerIdMode = "anonymous" | "member";
|
|
5028
|
+
/** 게임을 만든 경로. */
|
|
5029
|
+
type GameCreatedVia = "console" | "mcp" | "secret_key" | "function";
|
|
5030
|
+
/** 게임별로 끌 수 있는 기능. 값은 `false`(끔)만 의미가 있다. 실효 값 = 앱 값 AND 게임 값. */
|
|
5031
|
+
interface GameFeatureOverrides {
|
|
5032
|
+
matchqueue?: boolean;
|
|
5033
|
+
leaderboard?: boolean;
|
|
5034
|
+
entity?: boolean;
|
|
5035
|
+
scripts?: boolean;
|
|
5036
|
+
voice?: boolean;
|
|
5037
|
+
replay?: boolean;
|
|
5038
|
+
spectator?: boolean;
|
|
5039
|
+
kv?: boolean;
|
|
5040
|
+
}
|
|
5041
|
+
/** 실효 기능 값(앱 AND 게임). */
|
|
5042
|
+
type GameEffectiveFeatures = Required<GameFeatureOverrides>;
|
|
5043
|
+
/**
|
|
5044
|
+
* 게임별 상한. 전역 값보다 낮게만 둘 수 있고 1 이상이어야 한다(아니면 400 `caps_invalid`).
|
|
5045
|
+
* 최대값: max_rooms 1000, max_members_per_board 100000, max_entity_schemas 1000,
|
|
5046
|
+
* max_entities_per_schema 100000, max_queue_tickets 10000, kv_max_keys_per_player 64,
|
|
5047
|
+
* kv_max_value_bytes 16384, kv_max_bytes_per_player 262144, writes_per_sec 50.
|
|
5048
|
+
*/
|
|
5049
|
+
interface GameCaps {
|
|
5050
|
+
max_rooms?: number;
|
|
5051
|
+
max_members_per_board?: number;
|
|
5052
|
+
max_entity_schemas?: number;
|
|
5053
|
+
max_entities_per_schema?: number;
|
|
5054
|
+
max_queue_tickets?: number;
|
|
5055
|
+
kv_max_keys_per_player?: number;
|
|
5056
|
+
kv_max_value_bytes?: number;
|
|
5057
|
+
kv_max_bytes_per_player?: number;
|
|
5058
|
+
writes_per_sec?: number;
|
|
5059
|
+
}
|
|
5060
|
+
/** 실효 상한. `0` 은 "게임 상한 없음, 전역만". */
|
|
5061
|
+
type GameEffectiveCaps = Required<GameCaps>;
|
|
5062
|
+
/** 게임 하나 (`gameunit.GameView`). */
|
|
5063
|
+
interface GameUnit {
|
|
5064
|
+
id: string;
|
|
5065
|
+
app_id: string;
|
|
5066
|
+
game_key: string;
|
|
5067
|
+
name: string;
|
|
5068
|
+
status: GameStatus;
|
|
5069
|
+
web_storage_id: string | null;
|
|
5070
|
+
player_id_mode: GamePlayerIdMode;
|
|
5071
|
+
origin_pin: boolean;
|
|
5072
|
+
features: GameFeatureOverrides;
|
|
5073
|
+
effective_features: GameEffectiveFeatures;
|
|
5074
|
+
caps: GameCaps;
|
|
5075
|
+
effective_caps: GameEffectiveCaps;
|
|
5076
|
+
kv_client_write: boolean;
|
|
5077
|
+
/** 연결 스토리지가 서빙되는 origin 목록(`scheme://host[:port]`). */
|
|
5078
|
+
origins: string[];
|
|
5079
|
+
disabled_reason: string;
|
|
5080
|
+
disabled_at: string | null;
|
|
5081
|
+
disabled_by: string;
|
|
5082
|
+
deleted_at: string | null;
|
|
5083
|
+
purged_at: string | null;
|
|
5084
|
+
created_by_user_id: string;
|
|
5085
|
+
created_via: GameCreatedVia;
|
|
5086
|
+
created_at: string;
|
|
5087
|
+
updated_at: string;
|
|
5088
|
+
}
|
|
5089
|
+
/** 게임 만들기 본문. */
|
|
5090
|
+
interface CreateGameUnitRequest {
|
|
5091
|
+
/** = Lua 스크립트 이름. 1~200자, 영문, 숫자, `_`, `-`, `=` 만. 만든 뒤 바꿀 수 없다. */
|
|
5092
|
+
game_key: string;
|
|
5093
|
+
/** 표시 이름 1~100자. */
|
|
5094
|
+
name: string;
|
|
5095
|
+
web_storage_id?: string | null;
|
|
5096
|
+
player_id_mode?: GamePlayerIdMode;
|
|
5097
|
+
origin_pin?: boolean;
|
|
5098
|
+
features?: GameFeatureOverrides;
|
|
5099
|
+
caps?: GameCaps;
|
|
5100
|
+
kv_client_write?: boolean;
|
|
5101
|
+
}
|
|
5102
|
+
/** 게임 수정 본문. 보낸 칸만 바뀐다. `web_storage_id: null` 은 연결 해제. */
|
|
5103
|
+
interface UpdateGameUnitRequest {
|
|
5104
|
+
name?: string;
|
|
5105
|
+
web_storage_id?: string | null;
|
|
5106
|
+
player_id_mode?: GamePlayerIdMode;
|
|
5107
|
+
origin_pin?: boolean;
|
|
5108
|
+
features?: GameFeatureOverrides;
|
|
5109
|
+
caps?: GameCaps;
|
|
5110
|
+
kv_client_write?: boolean;
|
|
5111
|
+
}
|
|
5112
|
+
/** 제작자 토큰 스코프. */
|
|
5113
|
+
type GameCreatorTokenScope = "webstorage:qa_deploy" | "game:script_draft";
|
|
5114
|
+
/** 제작자 토큰 (`gameunit.CreatorTokenView`). */
|
|
5115
|
+
interface GameCreatorToken {
|
|
5116
|
+
id: string;
|
|
5117
|
+
app_id: string;
|
|
5118
|
+
game_key: string;
|
|
5119
|
+
web_storage_id: string;
|
|
5120
|
+
name: string;
|
|
5121
|
+
/** 앞 12자 (`cb_gct_Ab3dE`). 평문이 아니다. */
|
|
5122
|
+
token_prefix: string;
|
|
5123
|
+
scopes: GameCreatorTokenScope[];
|
|
5124
|
+
expires_at: string;
|
|
5125
|
+
revoked_at: string | null;
|
|
5126
|
+
revoked_by: string;
|
|
5127
|
+
last_used_at: string | null;
|
|
5128
|
+
created_via: GameCreatedVia;
|
|
5129
|
+
created_at: string;
|
|
5130
|
+
/** 파생값: revoked > expired > active. */
|
|
5131
|
+
status: "active" | "expired" | "revoked";
|
|
5132
|
+
}
|
|
5133
|
+
/** 발급 응답. 평문 `token` 은 이 응답에서 한 번만 보인다. */
|
|
5134
|
+
interface IssuedGameCreatorToken extends GameCreatorToken {
|
|
5135
|
+
token: string;
|
|
5136
|
+
}
|
|
5137
|
+
/** 제작자 토큰 발급 본문. */
|
|
5138
|
+
interface IssueGameCreatorTokenRequest {
|
|
5139
|
+
name?: string;
|
|
5140
|
+
/** 1~90, 기본 30. */
|
|
5141
|
+
expires_in_days?: number;
|
|
5142
|
+
/** 기본은 둘 다. */
|
|
5143
|
+
scopes?: GameCreatorTokenScope[];
|
|
5144
|
+
}
|
|
5145
|
+
/** `players/resolve` 응답. 둘 중 보낸 쪽에 맞는 칸 하나만 온다. */
|
|
5146
|
+
interface ResolveGamePlayersResponse {
|
|
5147
|
+
game_key: string;
|
|
5148
|
+
/** member_ids 로 물었을 때: 회원 id → player id(앱 회원이 아니면 null). */
|
|
5149
|
+
players?: Record<string, string | null>;
|
|
5150
|
+
/** player_ids 로 물었을 때: player id → 회원 id(연결 기록이 없으면 null). */
|
|
5151
|
+
members?: Record<string, string | null>;
|
|
5152
|
+
}
|
|
5153
|
+
/** 게임별 일별 사용량. */
|
|
5154
|
+
interface GameUsageDay {
|
|
5155
|
+
date: string;
|
|
5156
|
+
rest_calls: number;
|
|
5157
|
+
ws_connects: number;
|
|
5158
|
+
ws_seconds: number;
|
|
5159
|
+
script_execs: number;
|
|
5160
|
+
lb_writes: number;
|
|
5161
|
+
entity_writes: number;
|
|
5162
|
+
kv_ops: number;
|
|
5163
|
+
kv_bytes_delta: number;
|
|
5164
|
+
web_egress_bytes: number;
|
|
5165
|
+
/** 그날 활동한(실시간 연결이나 신원 있는 API 요청) 서로 다른 플레이어 수. */
|
|
5166
|
+
active_players: number;
|
|
5167
|
+
/** 그날 최고 동시 접속. */
|
|
5168
|
+
peak_concurrent: number;
|
|
5169
|
+
}
|
|
5170
|
+
/** 게임별 사용량 (`gameunit.UsageResponse`). 콘솔 경로 전용. */
|
|
5171
|
+
interface GameUsageResponse {
|
|
5172
|
+
game_key: string;
|
|
5173
|
+
from: string;
|
|
5174
|
+
to: string;
|
|
5175
|
+
days: GameUsageDay[];
|
|
5176
|
+
totals: Omit<GameUsageDay, "date" | "active_players" | "peak_concurrent">;
|
|
5177
|
+
storage: {
|
|
5178
|
+
lb_members: number;
|
|
5179
|
+
entities: number;
|
|
5180
|
+
kv_bytes: number;
|
|
5181
|
+
computed_at: string;
|
|
5182
|
+
truncated: boolean;
|
|
5183
|
+
} | null;
|
|
5184
|
+
/** 기간 활동 플레이어와 지금 동시 접속. 게임 서버 집계를 읽지 못하면 null. */
|
|
5185
|
+
players: {
|
|
5186
|
+
/** 기간 전체의 서로 다른 활동 플레이어 수(날마다 더한 값이 아니다). */
|
|
5187
|
+
active_players: number;
|
|
5188
|
+
/** 지금 동시 접속(최대 15초 전 값). */
|
|
5189
|
+
concurrent_now: number;
|
|
5190
|
+
/** 고유 수 가운데 추정값(4,096명 넘는 구간, 오차 약 0.8%)이 있으면 true. */
|
|
5191
|
+
approximate: boolean;
|
|
5192
|
+
computed_at: string;
|
|
5193
|
+
} | null;
|
|
5194
|
+
partial: boolean;
|
|
5195
|
+
}
|
|
5196
|
+
/**
|
|
5197
|
+
* 게임 토큰 발급 응답 (`POST /v1/public/game/tokens`, v2).
|
|
5198
|
+
*
|
|
5199
|
+
* 게임(iframe)에 넘길 값은 `access_token`, `player_id`, `game_id`, `expires_in` 뿐이다.
|
|
5200
|
+
* `app_member_id` 는 허브 서버만 보고 게임에 넘기지 않는다.
|
|
5201
|
+
*/
|
|
5202
|
+
interface GameTokenResponse {
|
|
5203
|
+
access_token: string;
|
|
5204
|
+
game_id: string;
|
|
5205
|
+
/** 초. */
|
|
5206
|
+
expires_in: number;
|
|
5207
|
+
app_id: string;
|
|
5208
|
+
app_member_id: string;
|
|
5209
|
+
/**
|
|
5210
|
+
* game-server 가 이 게임에서 이 플레이어를 부르는 식별자(리더보드 member, 매치큐 member, 룸 플레이어).
|
|
5211
|
+
* 게임의 `player_id_mode` 를 따른다 — `anonymous` 면 게임별 익명 id(`gp_...`), `member`(와 등록하지 않은 게임)면 회원 id.
|
|
5212
|
+
*/
|
|
5213
|
+
player_id: string;
|
|
5214
|
+
/** `player_id` 가 어느 방식인지. 옛 core 는 이 칸이 없다. */
|
|
5215
|
+
player_id_mode?: GamePlayerIdMode;
|
|
5216
|
+
/** 옛 core 는 이 칸이 없다(v1). */
|
|
5217
|
+
token_version?: "v1" | "v2";
|
|
5218
|
+
}
|
|
5219
|
+
/** 게임 토큰 발급 입력. */
|
|
5220
|
+
interface IssueGameTokenOptions {
|
|
5221
|
+
/** 축소할 회원 액세스 토큰. 함수 안에서는 `await ctx.cb.auth.getAccessToken()`. */
|
|
5222
|
+
accessToken: string;
|
|
5223
|
+
/** game_key. */
|
|
5224
|
+
gameId: string;
|
|
5225
|
+
/** 60~86400. 생략하면 서버 기본. 원본 토큰의 남은 수명을 넘지 않는다. */
|
|
5226
|
+
ttlSeconds?: number;
|
|
5227
|
+
}
|
|
5228
|
+
/**
|
|
5229
|
+
* 게임(iframe)에 넘기는 토큰 묶음. 허브의 `getToken` 이 돌려주는 값.
|
|
5230
|
+
*
|
|
5231
|
+
* 발급 응답(`GameTokenResponse`) 을 그대로 돌려줘도 되고, 함수 호출 결과(`{ result: ... }`)
|
|
5232
|
+
* 를 그대로 돌려줘도 SDK 가 풀어 쓴다.
|
|
5233
|
+
*/
|
|
5234
|
+
interface GameTokenGrant {
|
|
5235
|
+
/** 게임 토큰. `access_token` 이름도 받는다. */
|
|
5236
|
+
token?: string;
|
|
5237
|
+
access_token?: string;
|
|
5238
|
+
/** 이 게임에서 내 식별자. `player_id` 이름도 받는다. */
|
|
5239
|
+
playerId?: string;
|
|
5240
|
+
player_id?: string;
|
|
5241
|
+
/** `player_id` 의 방식. `player_id_mode` 이름도 받는다. */
|
|
5242
|
+
playerIdMode?: GamePlayerIdMode;
|
|
5243
|
+
player_id_mode?: GamePlayerIdMode;
|
|
5244
|
+
/** 만료 시각(ms). 없으면 `expires_in` 으로 계산하고, 둘 다 없으면 JWT `exp` 를 읽는다. */
|
|
5245
|
+
expiresAt?: number;
|
|
5246
|
+
expires_in?: number;
|
|
5247
|
+
game_id?: string;
|
|
5248
|
+
}
|
|
5249
|
+
/** 게임 범위 클라이언트(`cb.game.forGame`) 옵션. */
|
|
5250
|
+
interface GameScopeOptions {
|
|
5251
|
+
/** 게임 토큰. */
|
|
5252
|
+
token: string;
|
|
5253
|
+
/**
|
|
5254
|
+
* 이 게임에서 내 식별자. 리더보드 member, 매치큐 ticket id, 자기 기록 지우기에 자동으로 쓴다.
|
|
5255
|
+
* 발급 응답의 `player_id` 를 그대로 넘긴다(게임 방식에 맞는 값이 이미 들어 있다).
|
|
5256
|
+
* 생략하면 토큰의 `gpid`(없으면 `sub`) 를 읽는다 — 이 값은 늘 익명 id 라서 `playerIdMode: "member"` 면 읽지 않는다.
|
|
5257
|
+
*/
|
|
5258
|
+
playerId?: string;
|
|
5259
|
+
/** 발급 응답의 `player_id_mode`. `member` 게임은 `playerId` 를 꼭 넘겨야 한다(토큰에서 회원 id 를 읽을 수 없다). */
|
|
5260
|
+
playerIdMode?: GamePlayerIdMode;
|
|
5261
|
+
/** 토큰 만료 시각(ms). 생략하면 JWT `exp` 로 계산한다. */
|
|
5262
|
+
expiresAt?: number;
|
|
5263
|
+
/** 앱 ID. 생략하면 `new ConnectBase({ appId })` 값. */
|
|
5264
|
+
appId?: string;
|
|
5265
|
+
/**
|
|
5266
|
+
* 만료 `refreshBeforeMs` 전에 한 번 부른다. 새 묶음을 돌려주면 SDK 가 토큰을 바꾼다.
|
|
5267
|
+
* 아무것도 돌려주지 않으면 호출자가 `setToken` 으로 직접 바꿔야 한다.
|
|
5268
|
+
*/
|
|
5269
|
+
onTokenExpiring?: (scope: {
|
|
5270
|
+
gameId: string;
|
|
5271
|
+
expiresAt: number;
|
|
5272
|
+
}) => GameTokenGrant | undefined | Promise<GameTokenGrant | undefined>;
|
|
5273
|
+
/** 기본 120000(2분). */
|
|
5274
|
+
refreshBeforeMs?: number;
|
|
5275
|
+
}
|
|
5276
|
+
/** per-player KV 목록 응답. */
|
|
5277
|
+
interface PlayerKVListResponse {
|
|
5278
|
+
keys: {
|
|
5279
|
+
key: string;
|
|
5280
|
+
size: number;
|
|
5281
|
+
revision: number;
|
|
5282
|
+
updated_at: string;
|
|
5283
|
+
}[];
|
|
5284
|
+
total_bytes: number;
|
|
5285
|
+
max_keys: number;
|
|
5286
|
+
max_bytes: number;
|
|
5287
|
+
}
|
|
5288
|
+
/** per-player KV 한 칸. */
|
|
5289
|
+
interface PlayerKVItem<T = unknown> {
|
|
5290
|
+
key: string;
|
|
5291
|
+
value: T;
|
|
5292
|
+
revision: number;
|
|
5293
|
+
updated_at: string;
|
|
5294
|
+
}
|
|
5295
|
+
/** per-player KV 쓰기 응답. */
|
|
5296
|
+
interface PlayerKVWriteResult {
|
|
5297
|
+
key: string;
|
|
5298
|
+
revision: number;
|
|
5299
|
+
size: number;
|
|
5300
|
+
updated_at: string;
|
|
5301
|
+
}
|
|
5302
|
+
/** 게임 엔티티 한 건(읽기 전용). */
|
|
5303
|
+
interface GameEntity<F = Record<string, unknown>> {
|
|
5304
|
+
id: string;
|
|
5305
|
+
entity_name: string;
|
|
5306
|
+
app_id: string;
|
|
5307
|
+
fields: F;
|
|
5308
|
+
created_at: string;
|
|
5309
|
+
updated_at: string;
|
|
5310
|
+
revision?: number;
|
|
5311
|
+
}
|
|
5312
|
+
/** 게임 엔티티 목록 응답. */
|
|
5313
|
+
interface GameEntityListResponse<F = Record<string, unknown>> {
|
|
5314
|
+
entities: GameEntity<F>[];
|
|
5315
|
+
total_count: number;
|
|
5316
|
+
truncated?: boolean;
|
|
5317
|
+
actual_count?: number;
|
|
5318
|
+
next_cursor?: string;
|
|
5319
|
+
}
|
|
5320
|
+
/** 허브 `cb.game.hub.mount` 옵션. */
|
|
5321
|
+
interface GameHubMountOptions {
|
|
5322
|
+
/** game_key. */
|
|
5323
|
+
gameId: string;
|
|
5324
|
+
/** 게임(iframe) 의 정확한 origin. `https://<storage>.web.connectbase.world` 처럼 scheme+host[:port]. */
|
|
5325
|
+
origin: string;
|
|
5326
|
+
/** 게임 토큰을 받아 오는 함수. 보통 허브 서버 함수 호출. */
|
|
5327
|
+
getToken: () => Promise<GameTokenGrant | {
|
|
5328
|
+
result?: GameTokenGrant;
|
|
5329
|
+
}>;
|
|
5330
|
+
/** 만료 몇 ms 전에 새 토큰을 보낼지. 기본 120000(2분). */
|
|
5331
|
+
refreshBeforeMs?: number;
|
|
5332
|
+
/** 토큰을 받아 오다 실패했을 때. */
|
|
5333
|
+
onError?: (error: unknown) => void;
|
|
5334
|
+
}
|
|
5335
|
+
/** `hub.mount` 가 돌려주는 손잡이. */
|
|
5336
|
+
interface GameHubHandle {
|
|
5337
|
+
/** 지금 토큰을 다시 받아 게임에 보낸다. */
|
|
5338
|
+
refresh(): Promise<void>;
|
|
5339
|
+
/** 메시지 수신과 갱신 타이머를 멈춘다. iframe 을 지우기 전에 부른다. */
|
|
5340
|
+
destroy(): void;
|
|
5341
|
+
}
|
|
5342
|
+
/** 게임(iframe) `cb.game.fromHost` 옵션. */
|
|
5343
|
+
interface GameFromHostOptions {
|
|
5344
|
+
/** 토큰을 받아도 되는 부모 origin 목록(정확히 일치). 비우면 거부한다. */
|
|
5345
|
+
allowedParentOrigins: string[];
|
|
5346
|
+
/** 기대하는 game_key. 주면 다른 게임 토큰을 받지 않는다. */
|
|
5347
|
+
gameId?: string;
|
|
5348
|
+
/** 첫 토큰을 기다리는 시간(ms). 기본 15000. */
|
|
5349
|
+
timeoutMs?: number;
|
|
5350
|
+
}
|
|
5351
|
+
/** 앱 격리 설정 (`gameunit.AppIsolation`). `cb.game.config` 응답에 함께 온다. */
|
|
5352
|
+
interface GameAppIsolation {
|
|
5353
|
+
subtenant_isolation: boolean;
|
|
5354
|
+
game_credential_mode: "required" | "declared";
|
|
5355
|
+
entity_game_namespace: boolean;
|
|
5356
|
+
unregistered_game_policy: "allow" | "deny";
|
|
5357
|
+
kv_enabled: boolean;
|
|
5358
|
+
}
|
|
5359
|
+
|
|
5014
5360
|
/**
|
|
5015
5361
|
* 게임 서버 기능 opt-in 토글 API.
|
|
5016
5362
|
*
|
|
@@ -5042,6 +5388,16 @@ interface GameConfig {
|
|
|
5042
5388
|
voice_enabled: boolean;
|
|
5043
5389
|
replay_enabled: boolean;
|
|
5044
5390
|
spectator_enabled: boolean;
|
|
5391
|
+
/** 앱 안의 게임 단위 격리. 콘솔 "게임 단위 격리" 카드와 같은 값(새 core 만 보냄). */
|
|
5392
|
+
subtenant_isolation?: boolean;
|
|
5393
|
+
/** `required`(게임 토큰만 범위 인정) / `declared`(`?game_id=` 선언도 인정, 이관 유예). */
|
|
5394
|
+
game_credential_mode?: "required" | "declared";
|
|
5395
|
+
/** 격리 앱에서 엔티티 이름에 게임 이름공간을 붙일지. */
|
|
5396
|
+
entity_game_namespace?: boolean;
|
|
5397
|
+
/** 등록하지 않은 스크립트 이름에 게임 토큰을 내줄지. 허브 앱은 `deny` 권장. */
|
|
5398
|
+
unregistered_game_policy?: "allow" | "deny";
|
|
5399
|
+
/** per-player KV 기능 토글. */
|
|
5400
|
+
kv_enabled?: boolean;
|
|
5045
5401
|
}
|
|
5046
5402
|
/** PATCH body — 변경할 필드만 명시 (partial update). */
|
|
5047
5403
|
type GameConfigPatch = Partial<GameConfig>;
|
|
@@ -5081,6 +5437,210 @@ declare class GameConfigAPI {
|
|
|
5081
5437
|
private resolveAppId;
|
|
5082
5438
|
}
|
|
5083
5439
|
|
|
5440
|
+
/**
|
|
5441
|
+
* 앱 안의 게임 단위(game_key) — 게임 쪽(iframe), 허브 쪽(부모 창), 서버 쪽(cbAdmin) SDK.
|
|
5442
|
+
*
|
|
5443
|
+
* 원본 계약: docs/game-server/MULTI_GAME.md "API 계약" 절.
|
|
5444
|
+
*
|
|
5445
|
+
* - `cb.game.forGame(gameId, { token })`: 게임 토큰을 고정한 게임 범위 클라이언트(`GameScope`).
|
|
5446
|
+
* SDK 로그인 토큰(`http.getAccessToken()`)으로 바꿔 끼우지 않는다. 게임 토큰은 game-server 에서만
|
|
5447
|
+
* 통하고 다른 서버는 403 `game_token_not_allowed` 로 막는다.
|
|
5448
|
+
* - `cb.game.hub.mount(iframe, ...)`: 허브(부모 창)가 iframe 게임에 토큰을 postMessage 로 넘긴다.
|
|
5449
|
+
* - `cb.game.fromHost(...)`: iframe 안 게임이 허브에서 토큰을 받는다.
|
|
5450
|
+
* - `cb.games.*`: 시크릿 키 또는 함수 `ctx.cbAdmin`(management_scopes `game:manage`) 전용 관리 API.
|
|
5451
|
+
*
|
|
5452
|
+
* 보안 원칙
|
|
5453
|
+
* - 토큰은 메모리에만 둔다. localStorage, sessionStorage, 쿠키에 쓰지 않는다.
|
|
5454
|
+
* - postMessage 는 보내는 쪽이 정확한 targetOrigin 을 쓰고(`*` 금지), 받는 쪽이 `event.origin` 과
|
|
5455
|
+
* `event.source` 를 둘 다 확인한다.
|
|
5456
|
+
*/
|
|
5457
|
+
|
|
5458
|
+
/** postMessage 프로토콜 메시지 type. 바꾸면 이미 배포된 허브, 게임과 어긋난다. */
|
|
5459
|
+
declare const GAME_MESSAGE: {
|
|
5460
|
+
readonly ready: "cb:game:ready";
|
|
5461
|
+
readonly token: "cb:game:token";
|
|
5462
|
+
readonly refresh: "cb:game:token:refresh";
|
|
5463
|
+
};
|
|
5464
|
+
/** `GameRoom` 중 게임 범위 클라이언트가 쓰는 부분. 순환 import 를 피하려고 구조로만 받는다. */
|
|
5465
|
+
interface ScopedRoom {
|
|
5466
|
+
setAccessToken(token: string): void;
|
|
5467
|
+
}
|
|
5468
|
+
/** GameScope 가 GameAPI 에서 받는 의존성. */
|
|
5469
|
+
interface GameScopeDeps {
|
|
5470
|
+
gameServerUrl: string;
|
|
5471
|
+
publicKey?: string;
|
|
5472
|
+
defaultAppId?: string;
|
|
5473
|
+
createRoom: (config: GameClientConfig) => ScopedRoom;
|
|
5474
|
+
}
|
|
5475
|
+
/**
|
|
5476
|
+
* 게임 범위 클라이언트. `cb.game.forGame(gameId, { token })` 으로 만든다.
|
|
5477
|
+
*
|
|
5478
|
+
* 모든 요청이 `Authorization: Bearer <게임 토큰>` 을 고정해서 보낸다. SDK 로그인 토큰으로 바꿔 끼우지
|
|
5479
|
+
* 않고, 토큰이 없으면 요청하지 않는다. 리더보드 member, 매치큐 ticket id 는 `playerId` 로 자동으로 채운다.
|
|
5480
|
+
*
|
|
5481
|
+
* @example
|
|
5482
|
+
* ```ts
|
|
5483
|
+
* const game = cb.game.forGame('space-shooter', { token, playerId })
|
|
5484
|
+
* await game.leaderboard.submit('ranking', 120, { mode: 'incr' })
|
|
5485
|
+
* const top = await game.leaderboard.top('ranking', 10)
|
|
5486
|
+
* await game.kv.set('save', { stage: 3 })
|
|
5487
|
+
* ```
|
|
5488
|
+
*/
|
|
5489
|
+
declare class GameScope {
|
|
5490
|
+
readonly gameId: string;
|
|
5491
|
+
readonly appId: string;
|
|
5492
|
+
private token;
|
|
5493
|
+
private _playerId;
|
|
5494
|
+
private _playerIdMode;
|
|
5495
|
+
private _expiresAt;
|
|
5496
|
+
private readonly deps;
|
|
5497
|
+
private readonly options;
|
|
5498
|
+
private refreshTimer;
|
|
5499
|
+
private readonly rooms;
|
|
5500
|
+
private readonly disposers;
|
|
5501
|
+
private disposed;
|
|
5502
|
+
/** 리더보드. member 는 늘 내 playerId. */
|
|
5503
|
+
readonly leaderboard: {
|
|
5504
|
+
submit(key: string, score: number, options?: {
|
|
5505
|
+
mode?: "set" | "incr";
|
|
5506
|
+
}): Promise<LeaderboardScoreEntry>;
|
|
5507
|
+
top(key: string, n?: number): Promise<LeaderboardListResponse>;
|
|
5508
|
+
rank(key: string): Promise<LeaderboardScoreEntry>;
|
|
5509
|
+
around(key: string, above?: number, below?: number): Promise<LeaderboardListResponse>;
|
|
5510
|
+
removeMe(key: string): Promise<void>;
|
|
5511
|
+
};
|
|
5512
|
+
/** 매치큐. ticket id 는 기본으로 내 playerId. */
|
|
5513
|
+
readonly matchqueue: {
|
|
5514
|
+
enqueue(queueKey: string, attributes?: Record<string, unknown>, ttlSec?: number, ticketId?: string): Promise<MatchqueueTicket>;
|
|
5515
|
+
list(queueKey: string): Promise<MatchqueueListResponse>;
|
|
5516
|
+
cancel(queueKey: string, ticketId?: string): Promise<void>;
|
|
5517
|
+
};
|
|
5518
|
+
/** 엔티티 읽기. 쓰기는 서버 Lua(`entity.*`) 로만 한다. */
|
|
5519
|
+
readonly entities: {
|
|
5520
|
+
list<F = Record<string, unknown>>(name: string, options?: {
|
|
5521
|
+
limit?: number;
|
|
5522
|
+
cursor?: string;
|
|
5523
|
+
}): Promise<GameEntityListResponse<F>>;
|
|
5524
|
+
get<F = Record<string, unknown>>(name: string, id: string): Promise<GameEntity<F>>;
|
|
5525
|
+
};
|
|
5526
|
+
/** 내 per-player KV. 경로로 남의 player 를 지정할 방법은 없다. */
|
|
5527
|
+
readonly kv: {
|
|
5528
|
+
list(): Promise<PlayerKVListResponse>;
|
|
5529
|
+
get<T = unknown>(key: string): Promise<PlayerKVItem<T>>;
|
|
5530
|
+
set<T = unknown>(key: string, value: T, options?: {
|
|
5531
|
+
expectedRevision?: number;
|
|
5532
|
+
}): Promise<PlayerKVWriteResult>;
|
|
5533
|
+
delete(key: string): Promise<void>;
|
|
5534
|
+
};
|
|
5535
|
+
constructor(deps: GameScopeDeps, gameId: string, options: GameScopeOptions);
|
|
5536
|
+
/** 이 게임에서 내 식별자(리더보드 member, 매치큐 ticket id). */
|
|
5537
|
+
get playerId(): string;
|
|
5538
|
+
/** `playerId` 의 방식(`anonymous` / `member`). 발급 응답이나 옵션으로 받지 못했으면 undefined. */
|
|
5539
|
+
get playerIdMode(): GamePlayerIdMode | undefined;
|
|
5540
|
+
/** 토큰 만료 시각(ms). 모르면 0. */
|
|
5541
|
+
get expiresAt(): number;
|
|
5542
|
+
/** 지금 쓰는 게임 토큰. 다른 곳에 저장하지 마세요(메모리에만 두는 것이 원칙). */
|
|
5543
|
+
getToken(): string;
|
|
5544
|
+
/**
|
|
5545
|
+
* 게임 룸(WebSocket) 클라이언트. 토큰은 이 게임 토큰으로 고정한다. 토큰이 바뀌면 다음 연결,
|
|
5546
|
+
* 재연결부터 새 토큰을 쓴다.
|
|
5547
|
+
*/
|
|
5548
|
+
createClient(config: Omit<GameClientConfig, "gameServerUrl" | "accessToken" | "appId" | "publicKey">): ScopedRoom;
|
|
5549
|
+
/** 토큰을 바꾼다(갱신). 문자열 또는 발급 응답 모양을 받는다. */
|
|
5550
|
+
setToken(grant: string | GameTokenGrant): void;
|
|
5551
|
+
/** 갱신 타이머를 멈추고 붙은 리스너(fromHost)를 뗀다. */
|
|
5552
|
+
dispose(): void;
|
|
5553
|
+
/** @internal fromHost 가 리스너 정리를 맡긴다. */
|
|
5554
|
+
_onDispose(fn: () => void): void;
|
|
5555
|
+
private applyGrant;
|
|
5556
|
+
private scheduleRefresh;
|
|
5557
|
+
private requirePlayerId;
|
|
5558
|
+
private request;
|
|
5559
|
+
}
|
|
5560
|
+
/**
|
|
5561
|
+
* 허브(부모 창) 쪽. `cb.game.hub` 로 접근한다.
|
|
5562
|
+
*/
|
|
5563
|
+
declare class GameHubAPI {
|
|
5564
|
+
/**
|
|
5565
|
+
* iframe 게임에 게임 토큰을 넘긴다.
|
|
5566
|
+
*
|
|
5567
|
+
* 게임이 `cb:game:ready` 나 `cb:game:token:refresh` 를 보내면 `getToken()` 으로 토큰을 받아
|
|
5568
|
+
* `{type:'cb:game:token', gameId, token, playerId, playerIdMode, expiresAt}` 를 **게임 origin 으로만**
|
|
5569
|
+
* 보낸다. 만료 2분 전에는 게임이 묻지 않아도 새 토큰을 보낸다. 다른 origin 이나 다른 창에서 온
|
|
5570
|
+
* 메시지는 무시한다.
|
|
5571
|
+
*
|
|
5572
|
+
* @example
|
|
5573
|
+
* ```ts
|
|
5574
|
+
* const handle = cb.game.hub.mount(iframeEl, {
|
|
5575
|
+
* gameId: 'space-shooter',
|
|
5576
|
+
* origin: 'https://abc.web.connectbase.world',
|
|
5577
|
+
* getToken: async () => (await cb.functions.invoke('issue-game-token', { gameId: 'space-shooter' })).result,
|
|
5578
|
+
* })
|
|
5579
|
+
* // 화면을 떠날 때
|
|
5580
|
+
* handle.destroy()
|
|
5581
|
+
* ```
|
|
5582
|
+
*/
|
|
5583
|
+
mount(iframe: {
|
|
5584
|
+
contentWindow: unknown;
|
|
5585
|
+
ownerDocument?: unknown;
|
|
5586
|
+
}, options: GameHubMountOptions): GameHubHandle;
|
|
5587
|
+
}
|
|
5588
|
+
/**
|
|
5589
|
+
* 게임 단위 관리 API (`cb.games`). 시크릿 키 또는 함수 `ctx.cbAdmin` 전용.
|
|
5590
|
+
*
|
|
5591
|
+
* 공개 API 로는 게임을 지우지 못한다(콘솔, MCP 전용).
|
|
5592
|
+
*
|
|
5593
|
+
* @example
|
|
5594
|
+
* ```ts
|
|
5595
|
+
* // 함수(service_role, management_scopes: ["game:manage"]) 안에서
|
|
5596
|
+
* const game = await ctx.cbAdmin.games.create({ game_key: 'space-shooter', name: '스페이스 슈터', web_storage_id })
|
|
5597
|
+
* const issued = await ctx.cbAdmin.games.creatorTokens.issue('space-shooter', { name: '외주 스튜디오 A' })
|
|
5598
|
+
* ```
|
|
5599
|
+
*/
|
|
5600
|
+
declare class GamesAPI {
|
|
5601
|
+
private readonly http;
|
|
5602
|
+
/** 제작자 토큰(`cb_gct_`). 스토리지 하나의 QA 배포와 스크립트 초안 업로드만 연다. */
|
|
5603
|
+
readonly creatorTokens: {
|
|
5604
|
+
list(gameKey: string): Promise<GameCreatorToken[]>;
|
|
5605
|
+
issue(gameKey: string, request?: IssueGameCreatorTokenRequest): Promise<IssuedGameCreatorToken>;
|
|
5606
|
+
revoke(gameKey: string, tokenId: string): Promise<void>;
|
|
5607
|
+
};
|
|
5608
|
+
constructor(http: HttpClient);
|
|
5609
|
+
/** 게임 목록(삭제 중 포함, 최근 순). */
|
|
5610
|
+
list(): Promise<GameUnit[]>;
|
|
5611
|
+
/** 게임 하나. 없으면 404 `game_not_found`. */
|
|
5612
|
+
get(gameKey: string): Promise<GameUnit>;
|
|
5613
|
+
/** 게임 등록. game_key = Lua 스크립트 이름. */
|
|
5614
|
+
create(request: CreateGameUnitRequest): Promise<GameUnit>;
|
|
5615
|
+
/** 게임 수정. 스토리지를 바꾸거나 떼면 그 게임의 제작자 토큰이 모두 회수된다. */
|
|
5616
|
+
update(gameKey: string, request: UpdateGameUnitRequest): Promise<GameUnit>;
|
|
5617
|
+
/** 강제 비활성화. 게임 토큰, 연결, 룸, 사이트, 제작자 토큰이 한 번에 막힌다. */
|
|
5618
|
+
disable(gameKey: string, reason?: string): Promise<GameUnit>;
|
|
5619
|
+
/** 다시 켜기. 데이터와 스크립트는 그대로 돌아온다. */
|
|
5620
|
+
enable(gameKey: string): Promise<GameUnit>;
|
|
5621
|
+
/**
|
|
5622
|
+
* 회원 id 와 player id 를 서로 찾는다(최대 100개). 허브 화면에 닉네임을 보여 줄 때 쓴다.
|
|
5623
|
+
*
|
|
5624
|
+
* @example
|
|
5625
|
+
* const { members } = await ctx.cbAdmin.games.resolvePlayers('space-shooter', { playerIds: top.entries.map(e => e.member) })
|
|
5626
|
+
*/
|
|
5627
|
+
resolvePlayers(gameKey: string, ids: {
|
|
5628
|
+
memberIds: string[];
|
|
5629
|
+
} | {
|
|
5630
|
+
playerIds: string[];
|
|
5631
|
+
}): Promise<ResolveGamePlayersResponse>;
|
|
5632
|
+
/**
|
|
5633
|
+
* 스크립트 버전 활성화(제작자 초안 승인). 스크립트 이름은 game_key 와 같아야 한다.
|
|
5634
|
+
* version 을 생략하면 최신 버전.
|
|
5635
|
+
*/
|
|
5636
|
+
activateScript(gameKey: string, options?: {
|
|
5637
|
+
name?: string;
|
|
5638
|
+
version?: number;
|
|
5639
|
+
}): Promise<unknown>;
|
|
5640
|
+
private path;
|
|
5641
|
+
private guard;
|
|
5642
|
+
}
|
|
5643
|
+
|
|
5084
5644
|
/**
|
|
5085
5645
|
* 게임 서버 `create_room` 메시지 페이로드는 snake_case 필드를 기대한다 (Go 핸들러 JSON 태그).
|
|
5086
5646
|
* SDK 의 GameRoomConfig 는 camelCase 이므로, scriptName / tickRate / maxPlayers / roomId /
|
|
@@ -5135,6 +5695,10 @@ declare class GameRoom {
|
|
|
5135
5695
|
*/
|
|
5136
5696
|
private connectionTicket;
|
|
5137
5697
|
private openSocket;
|
|
5698
|
+
/**
|
|
5699
|
+
* 다음 연결과 재연결부터 쓸 액세스 토큰을 바꾼다(게임 토큰 갱신용). 이미 열린 연결은 그대로 둔다.
|
|
5700
|
+
*/
|
|
5701
|
+
setAccessToken(token: string): void;
|
|
5138
5702
|
/**
|
|
5139
5703
|
* 연결 해제
|
|
5140
5704
|
*/
|
|
@@ -5230,7 +5794,56 @@ declare class GameAPI {
|
|
|
5230
5794
|
* 자세한 내용은 [GameConfigAPI] 참고.
|
|
5231
5795
|
*/
|
|
5232
5796
|
readonly config: GameConfigAPI;
|
|
5797
|
+
/**
|
|
5798
|
+
* 허브(부모 창) 쪽 도구. `cb.game.hub.mount(iframe, { gameId, origin, getToken })` 로
|
|
5799
|
+
* iframe 게임에 게임 토큰을 넘긴다. 자세한 내용은 {@link GameHubAPI}.
|
|
5800
|
+
*/
|
|
5801
|
+
readonly hub: GameHubAPI;
|
|
5233
5802
|
constructor(http: HttpClient, gameServerUrl?: string, appId?: string);
|
|
5803
|
+
/**
|
|
5804
|
+
* 게임 하나로 범위를 고정한 클라이언트를 만든다(앱 안의 게임 단위).
|
|
5805
|
+
*
|
|
5806
|
+
* 모든 요청에 `Authorization: Bearer <게임 토큰>` 을 고정해서 보내고, 리더보드 member 와
|
|
5807
|
+
* 매치큐 ticket id 는 `playerId` 로 자동으로 채운다. SDK 로그인 토큰으로 바꿔 끼우지 않는다.
|
|
5808
|
+
*
|
|
5809
|
+
* @example
|
|
5810
|
+
* ```ts
|
|
5811
|
+
* const game = cb.game.forGame('space-shooter', { token, playerId, expiresAt,
|
|
5812
|
+
* onTokenExpiring: () => fetchNewTokenFromHub() })
|
|
5813
|
+
* await game.leaderboard.submit('ranking', 120, { mode: 'incr' })
|
|
5814
|
+
* const room = game.createClient({ clientId: game.playerId })
|
|
5815
|
+
* ```
|
|
5816
|
+
*/
|
|
5817
|
+
forGame(gameId: string, options: GameScopeOptions): GameScope;
|
|
5818
|
+
/**
|
|
5819
|
+
* iframe 안 게임이 허브(부모 창)에서 게임 토큰을 받아 게임 범위 클라이언트를 만든다.
|
|
5820
|
+
*
|
|
5821
|
+
* `allowedParentOrigins` 에 없는 origin 이나 부모가 아닌 창에서 온 메시지는 받지 않는다. 토큰은
|
|
5822
|
+
* 메모리에만 두고, 만료 2분 전에 허브에 새 토큰을 요청한다.
|
|
5823
|
+
*
|
|
5824
|
+
* @example
|
|
5825
|
+
* ```ts
|
|
5826
|
+
* const game = await cb.game.fromHost({ allowedParentOrigins: ['https://hub.example.com'] })
|
|
5827
|
+
* await game.kv.set('save', { stage: 3 })
|
|
5828
|
+
* ```
|
|
5829
|
+
*/
|
|
5830
|
+
fromHost(options: GameFromHostOptions): Promise<GameScope>;
|
|
5831
|
+
/**
|
|
5832
|
+
* 회원 토큰을 게임 하나로 축소한 게임 토큰을 발급한다(서버 전용).
|
|
5833
|
+
*
|
|
5834
|
+
* 시크릿 키 SDK 또는 함수의 `ctx.cbAdmin`(management_scopes `game:manage`) 에서만 부른다.
|
|
5835
|
+
* 응답의 `app_member_id` 는 게임에 넘기지 않는다.
|
|
5836
|
+
*
|
|
5837
|
+
* @example
|
|
5838
|
+
* ```ts
|
|
5839
|
+
* export default async (payload, ctx) => {
|
|
5840
|
+
* const accessToken = await ctx.cb.auth.getAccessToken()
|
|
5841
|
+
* const t = await ctx.cbAdmin.game.issueToken({ accessToken, gameId: payload.gameId, ttlSeconds: 3600 })
|
|
5842
|
+
* return { access_token: t.access_token, player_id: t.player_id, player_id_mode: t.player_id_mode, expires_in: t.expires_in, game_id: t.game_id }
|
|
5843
|
+
* }
|
|
5844
|
+
* ```
|
|
5845
|
+
*/
|
|
5846
|
+
issueToken(options: IssueGameTokenOptions): Promise<GameTokenResponse>;
|
|
5234
5847
|
/**
|
|
5235
5848
|
* 게임 룸 클라이언트 생성.
|
|
5236
5849
|
*
|
|
@@ -7246,6 +7859,12 @@ interface PreparePaymentOptions {
|
|
|
7246
7859
|
* 앱이 정하는 부가 데이터. **클라이언트가 보낸 값이라 권한 지급의 근거로 쓰지 않는다** — 무엇을 샀는지는 결제
|
|
7247
7860
|
* 기록의 `product_id`/`quantity` 를 본다.
|
|
7248
7861
|
*/
|
|
7862
|
+
/**
|
|
7863
|
+
* 앱 안의 게임 하나에 이 결제를 묶는다(선택, game_key). 그 앱의 active 게임이어야 하고(아니면 400
|
|
7864
|
+
* `game_id_not_active`), 시크릿 키나 service_role 함수 호출에서만 받는다(공개 키만이면 403
|
|
7865
|
+
* `game_id_server_only`). 게임별 합계는 `cb.payment.summary(appId, { groupBy: 'game_key' })`.
|
|
7866
|
+
*/
|
|
7867
|
+
game_id?: string;
|
|
7249
7868
|
metadata?: Record<string, unknown>;
|
|
7250
7869
|
}
|
|
7251
7870
|
/** 가격표 결제 — 서버가 `단가 x 수량` 과 통화를 정한다. */
|
|
@@ -7314,6 +7933,12 @@ interface CreateCheckoutSessionOptions {
|
|
|
7314
7933
|
customer_email?: string;
|
|
7315
7934
|
customer_name?: string;
|
|
7316
7935
|
metadata?: Record<string, unknown>;
|
|
7936
|
+
/**
|
|
7937
|
+
* 앱 안의 게임 하나에 이 결제를 묶는다(선택, game_key). 그 앱의 active 게임이어야 하고(아니면 400
|
|
7938
|
+
* `game_id_not_active`), 시크릿 키나 service_role 함수 호출에서만 받는다(공개 키만이면 403
|
|
7939
|
+
* `game_id_server_only`). 게임별 합계는 `cb.payment.summary(appId, { groupBy: 'game_key' })`.
|
|
7940
|
+
*/
|
|
7941
|
+
game_id?: string;
|
|
7317
7942
|
}
|
|
7318
7943
|
/** 가격표 결제 — 금액, 통화, 상품명은 서버가 가격표에서 정한다. */
|
|
7319
7944
|
interface CreateCheckoutSessionWithProduct extends CreateCheckoutSessionOptions {
|
|
@@ -7441,6 +8066,36 @@ interface ListPaymentsOptions {
|
|
|
7441
8066
|
/** 기본 50. */
|
|
7442
8067
|
limit?: number;
|
|
7443
8068
|
offset?: number;
|
|
8069
|
+
/** 앱 안의 게임 하나(game_key)의 결제만 정확히 거른다. */
|
|
8070
|
+
gameKey?: string;
|
|
8071
|
+
}
|
|
8072
|
+
/** `cb.payment.summary` 옵션. */
|
|
8073
|
+
interface PaymentSummaryOptions {
|
|
8074
|
+
/** 지금은 `game_key` 만. */
|
|
8075
|
+
groupBy?: "game_key";
|
|
8076
|
+
/** `YYYY-MM-DD`(UTC, 포함). 생략하면 이번 달 1일. */
|
|
8077
|
+
from?: string;
|
|
8078
|
+
/** `YYYY-MM-DD`(UTC, 포함). 생략하면 오늘. */
|
|
8079
|
+
to?: string;
|
|
8080
|
+
}
|
|
8081
|
+
/** 통화 하나의 합계(최소 단위). */
|
|
8082
|
+
interface PaymentSummaryAmounts {
|
|
8083
|
+
amount: number;
|
|
8084
|
+
canceled_amount: number;
|
|
8085
|
+
net_amount: number;
|
|
8086
|
+
}
|
|
8087
|
+
/** `cb.payment.summary` 반환값. 테스트 모드 결제는 빠진다. */
|
|
8088
|
+
interface PaymentSummaryResult {
|
|
8089
|
+
group_by: "game_key";
|
|
8090
|
+
from: string;
|
|
8091
|
+
to: string;
|
|
8092
|
+
groups: {
|
|
8093
|
+
/** 게임에 묶이지 않은 결제는 null. */
|
|
8094
|
+
game_key: string | null;
|
|
8095
|
+
count: number;
|
|
8096
|
+
/** 통화별로 나눈다(합치지 않는다). */
|
|
8097
|
+
currencies: Record<string, PaymentSummaryAmounts>;
|
|
8098
|
+
}[];
|
|
7444
8099
|
}
|
|
7445
8100
|
/** 결제 목록 항목. 백엔드 `PaymentListItem` 매핑. */
|
|
7446
8101
|
interface PaymentListItem {
|
|
@@ -7462,6 +8117,8 @@ interface PaymentListItem {
|
|
|
7462
8117
|
customer_email?: string;
|
|
7463
8118
|
approved_at?: string;
|
|
7464
8119
|
created_at: string;
|
|
8120
|
+
/** 이 결제를 묶은 게임(game_key). 없으면 null. 옛 서버는 칸이 없다. */
|
|
8121
|
+
game_key?: string | null;
|
|
7465
8122
|
}
|
|
7466
8123
|
/** `cb.payment.list` 반환값. 백엔드 `ListPaymentsResponse` 매핑. */
|
|
7467
8124
|
interface PaymentListResult {
|
|
@@ -7677,6 +8334,18 @@ declare class PaymentAPI {
|
|
|
7677
8334
|
* ```
|
|
7678
8335
|
*/
|
|
7679
8336
|
list(appId: string, options?: ListPaymentsOptions): Promise<PaymentListResult>;
|
|
8337
|
+
/**
|
|
8338
|
+
* 결제 합계를 게임(game_key)별로 묶어 돌려준다(통화별, 테스트 결제 제외).
|
|
8339
|
+
*
|
|
8340
|
+
* 서버사이드 전용 — service_role(ctx.cbAdmin, management_scopes=["payment:read"]) 또는 콘솔 JWT.
|
|
8341
|
+
* 대상은 `approved_at` 이 기간 안이고 상태가 done, partial_canceled, canceled 인 결제다.
|
|
8342
|
+
*
|
|
8343
|
+
* @example
|
|
8344
|
+
* ```typescript
|
|
8345
|
+
* const { groups } = await ctx.cbAdmin.payment.summary(ctx.appId, { groupBy: 'game_key', from: '2026-11-01', to: '2026-11-30' })
|
|
8346
|
+
* ```
|
|
8347
|
+
*/
|
|
8348
|
+
summary(appId: string, options?: PaymentSummaryOptions): Promise<PaymentSummaryResult>;
|
|
7680
8349
|
}
|
|
7681
8350
|
|
|
7682
8351
|
/**
|
|
@@ -13130,6 +13799,11 @@ declare class ConnectBase {
|
|
|
13130
13799
|
* 게임 API (실시간 멀티플레이어)
|
|
13131
13800
|
*/
|
|
13132
13801
|
readonly game: GameAPI;
|
|
13802
|
+
/**
|
|
13803
|
+
* 앱 안의 게임 단위 관리 API (시크릿 키 또는 함수 `ctx.cbAdmin` 전용).
|
|
13804
|
+
* 게임 등록, 강제 비활성화, 제작자 토큰, player id 찾기.
|
|
13805
|
+
*/
|
|
13806
|
+
readonly games: GamesAPI;
|
|
13133
13807
|
/**
|
|
13134
13808
|
* 광고 API (Google AdSense)
|
|
13135
13809
|
*/
|
|
@@ -13203,4 +13877,4 @@ declare class ConnectBase {
|
|
|
13203
13877
|
updateConfig(config: Partial<ConnectBaseConfig>): void;
|
|
13204
13878
|
}
|
|
13205
13879
|
|
|
13206
|
-
export { AIAPI, type AIChatOptions, type AIChatRequest, type AIChatResponse, type AIChatStreamCallbacks, type AIChatStreamOptions, AIError, type AIErrorCode, type AIGeneratedImage, type AIMessage, type AISource, type AIStreamChunk, type AITool, type AIToolCall, type AIToolEvent, AUTH_MEMBER_ID_TOKEN, type AcceptInvitationResponse, type AckMessagesRequest, type AckMessagesResponse, type AdMobDailyReport, type AdMobReportResponse, type AdMobReportSummary, type AdReportResponse, type AdReportSummary, type AdmobConnectionInfo, AdsAPI, type AdsenseConnectionInfo, type AgenticSearchProgress, type AggregateResult, type AggregateStage, type AnalyticsConfig, type AnalyticsEvent, ApiError, type ApiErrorDetail, type AppMemberDetail, type AppMemberIdentityDetail, type AppMemberIdentitySummary, type AppMemberList, type AppMemberListItem, type AppMemberProviderType, AppMembersAPI, type AppStatsResponse, type ArchivePolicy, type AtomicOperator, type AtomicOperatorType, AuthError, type AuthSettingsResponse, type BackupInfo, type BatchOperation, type BatchOperationResult, type BatchSetPageMetaRequest, type BatchWriteResult, type BillingCycle, type BillingKeyResponse, type BiometricInfo, type BiometricResult, type BulkCreateResponse, type BulkError, type CPUInfo, type CancelPaymentRequest, type CancelPaymentResponse, type CancelSubscriptionRequest, type CategoryInfo, type ChangePlanOptions, type ChangePlanPreview, type ChangePlanRequest, type ChangePlanWithPriceRef, type ChangePlanWithProduct, type Channel, type ChannelMembership, type ChannelStats, type ChargeWithBillingKeyAmount, type ChargeWithBillingKeyOptions, type ChargeWithBillingKeyProduct, type ChargeWithBillingKeyRequest, type ChargeWithBillingKeyResponse, type ChatMessage, type ClientMessage, type ColumnSchema, type CommentListResponse, type CompleteUploadRequest, type CompleteUploadResponse, type ConfirmBillingKeyRequest, type ConfirmPaymentRequest, type ConfirmPaymentResponse, ConnectBase, type ConnectBaseConfig, type ConnectedData, type ConnectionState, type ConsentOptions, type ConsumeMessagesResponse, type ConsumeOptions, type CopyTableRequest, type CopyTableResponse, type CreateBackupRequest, type CreateChannelRequest, type CreateCheckoutSessionOptions, type CreateCheckoutSessionRequest, type CreateCheckoutSessionResponse, type CreateCheckoutSessionWithAmount, type CreateCheckoutSessionWithProduct, type CreateColumnRequest, type CreateDataRequest, type CreateDocumentRequest, type CreateFolderRequest, type CreateFolderResponse, type CreateGeoIndexRequest, type CreateIndexRequest, type CreateInvitationRequest, type CreateInvitationResponse, type CreateLobbyRequest, type CreateOrganizationRequest, type CreatePlaylistRequest, type CreatePublicKeyRequest, type CreatePublicKeyResponse, type CreateRelationRequest, type CreateRolePayload, type CreateRoleResult, type CreateRoomResult, type CreateSearchIndexRequest, type CreateSecurityRuleRequest, type CreateSubscriptionOptions, type CreateSubscriptionRequest, type CreateSubscriptionWithAmount, type CreateSubscriptionWithProduct, type CreateTableRequest, type CreateTopicOptions, type CreateTriggerRequest, type CreateVideoStorageRequest, type DailyReport, type DataItem, type DataType, type DatabaseChange, type DatabaseChangeMessage, type DatabaseChangeType, type DatabaseRealtimeConnectOptions, type DatabaseRealtimeFilter, type DatabaseRealtimeHandlers, type DatabaseRealtimeSubscription, type DatabaseSnapshot, type DatabaseSnapshotMessage, type DatabaseSubscribeOptions, type DeleteBillingKeyResponse, type DeleteWhereResponse, type DeviceInfo, type DocumentResponse, type EnabledProviderInfo, type EnabledProvidersResponse, EndpointAPI, type EndpointCallInit, type ErrorHandler, type ErrorMessage, type ErrorReport, type ErrorTrackerConfig, type ErrorType, type ExportDataRequest, type ExportDataResponse, type FetchDataResponse, type FetchFilesResponse, type FetchPublicKeysResponse, type FileItem, type FileStats, GameAPI, type GameAction, type GameClientConfig, type GameConfig, GameConfigAPI, type GameConfigPatch, type GameConnectionState, type GameConnectionStatus, type GameDelta, GameError, type GameErrorCode, type GameEventHandlers, type GamePlayer, GameRoom, type GameRoomConfig, type GameRoomInfo, GameRoomTransport, type GameServerMessage, type GameServerMessageType, type GameState, type GameTransportConfig, type GenerateUploadURLByPathRequest, type GenerateUploadURLRequest, type GenerateUploadURLResponse, type GeoBoundingBox, type GeoIndex, type GeoNear, type GeoPoint, type GeoPolygon, type GeoQuery, type GeoResponse, type GeoResult, type GetAuthorizationURLResponse, type GetFileByPathResponse, type GoogleConnectionStatus, type HistoryResponse, type ICEServer, type ICEServersResponse, type ImageResult, type ImportDataRequest, type ImportDataResponse, type IndexAnalysis, type IndexRecommendation, type InitUploadResponse, type InvokeFunctionRequest, type InvokeFunctionResponse, type IssueBillingKeyRequest, type IssueBillingKeyResponse, type JoinQueueRequest, type JoinRoomRequest, type JoinRoomResponse, type KnowledgeSearchRequest, type KnowledgeSearchResponse, type KnowledgeSearchResult, type LeaderboardEntry, type LeaderboardListResponse, type LeaderboardScoreEntry, type LifecyclePolicy, type ListAppMembersOptions, type ListBillingKeysResponse, type ListDocumentsResponse, type ListFilesOptions, type ListFilesResult, type ListPageMetasOptions, type ListPageMetasResponse, type ListPaymentsOptions, type ListSubscriptionPaymentsRequest, type ListSubscriptionPaymentsResponse, type ListSubscriptionsRequest, type ListSubscriptionsResponse, type LobbyInfo, type LobbyInvite, type LobbyMember, type LobbyVisibility, type MatchResult, type MatchmakingTicket, type MatchqueueListResponse, type MatchqueueTicket, type MemberChangePasswordRequest, type MemberCredentialMessageResponse, type MemberEmailVerificationConfirmRequest, type MemberEmailVerificationConfirmResponse, type MemberEmailVerificationRequest, type MemberInfoResponse, type MemberPasswordResetConfirmRequest, type MemberPasswordResetRequest, type MemberRedirectOption, type MemberSession, type MemberSessionList, type MemberSessionRevokeResponse, type MemberSignInRequest, type MemberSignInResponse, type MemberSignUpRequest, type MemberSignUpResponse, type MembershipTier, type MemoryInfo, type MessageHandler, type MigrateDataRequest, type MigrateDataResponse, type MoveFileRequest, type NackMessageRequest, type NackMessageResponse, NativeAPI, type OAuthCallbackResponse, type OAuthPrompt, type OAuthProvider, type OnPaymentFailure, type OpenDialogOptions, type OpenDialogResult, type Organization, type OrganizationContext, type OrganizationInvitation, type OrganizationMember, type OrganizationMemberList, type OrganizationRole, OrganizationsAPI, type PageMetaResponse, type PartyInfo, type PartyInvite, type PartyMember, type PauseSubscriptionRequest, type PaymentDetail, type PaymentListItem, type PaymentListResult, type PaymentMode, type PaymentProvider, type PaymentStatus, type PeerInfo, type Platform, type PlayerEvent, type PlayerStats, type Playlist, type PlaylistItem, type PollUntilOptions, type PongMessage, type PopulateOption, type Position, type PostponeBillingRequest, type PreparePaymentOptions, type PreparePaymentRequest, type PreparePaymentResponse, type PreparePaymentWithAmount, type PreparePaymentWithProduct, type PresenceChangeHandler, type PresenceInfo, type PresenceSetOptions, type PresenceStatus, type PresenceStatusResult, type ProrationMode, type PublicKeyItem, type PublicKeyPaymentMode, type PublishBatchError, type PublishBatchRequest, type PublishBatchResponse, type PublishMessageRequest, type PublishMessageResponse, type PushPlatform, type PushStatsResult, type PushTopicInfo, type QueryOptions, type QueueInfoResponse, type QueueMessage, type ReadReceiptHandler, type ReadReceiptInfo, type RealtimeConnectOptions, RealtimeConnectionError, type RealtimeConnectionErrorCode, type RealtimeMessage, RealtimeRequestError, type RealtimeSendPolicy, type RegisterDeviceRequest, type RelationType, type RenameFileRequest, type RenameFileResponse, type ReplayHighlight, type ReplayInfo, type ReplayPlayerInfo, type RestoreBackupRequest, type RestoreBackupResponse, type RetentionPolicy, type RoleDetail, type RoleList, type RoleListItem, type RolePermissionItem, type RoleUserItem, RolesAPI, type RoomInfo, type RoomStaleMessage, type RoomSummary, type RoomsResponse, type RotatePublicKeyRequest, type RotatePublicKeyResponse, type SFUTokenOptions, type SFUTokenResponse, type SaveDialogOptions, type SaveDialogResult, type ScriptDetailResponse, type ScriptListResponse, type ScriptLogEntry, type ScriptLogsResponse, type ScriptMeta, type ScriptMetricsResponse, type ScriptVersion, type ScriptVersionListResponse, type SearchIndex, type SearchOptions, type SearchResponse, type SearchResult, type SecurityRule, type SendOptions, type SendSuperChatOptions, type SendSuperChatResponse, type ServerMessage, SessionManager, type SetPageMetaRequest, type Shorts, type ShortsListResponse, type SignalingMessage, type SignalingMessageType, type SlowQueryInfo, type SpectatorInfo, type SpectatorPlayerState, type SpectatorState, type SpeechRecognizeOptions, type SpeechResult, type StateChange, type StateChangeHandler, type StorageUploadOptions, type StorageUploadProgress, type StorageVideoListOptions, type StreamContentPart, type StreamDoneCallback, type StreamDoneData, type StreamErrorCallback, type StreamHandlers, type StreamImageURLPart, type StreamMessage, type StreamOptions, type StreamSession, type StreamTextPart, type StreamTokenCallback, type StreamToolCallCallback, type StreamToolResultCallback, type StreamURLResponse, type SubscribeOptions, type SubscribeTopicRequest, type SubscribedData, type Subscription, type SubscriptionPaymentResponse, type SubscriptionPaymentStatus, type SubscriptionResponse, type SubscriptionStatus, type SuperChat, type SuperChatType, type SuspendAppMemberOptions, type SuspendAppMemberResult, type SyncLostMessage, type SystemInfo, type TTLConfig, type TableAccessLevel, type TableColumnDef, type TableIndex, type TableRelation, type TableSchema, type TableSchemaDefinition, type TokenPersistence, type TransactionRead, type TransactionResult, type TransactionWrite, type TransactionWriteResult, type TranscodeJob, type TranscodeStatus, type TransportType, type Trigger, type TriggerEvent, type TriggerHandlerType, type TypingChangeHandler, type TypingInfo, type UnsuspendAppMemberResult, type UpdateBillingKeyRequest, type UpdateChannelRequest, type UpdateColumnRequest, type UpdateCustomDataRequest, type UpdateCustomDataResponse, type UpdateDataRequest, type UpdateDocumentRequest, type UpdateLobbyRequest, type UpdateOrganizationRequest, type UpdatePublicKeyRequest, type UpdatePublicKeyResponse, type UpdateRolePayload, type UpdateSecurityRuleRequest, type UpdateSubscriptionRequest, type UpdateTriggerRequest, type UpdateVideoRequest, type UpdateVideoStorageRequest, type UploadByPathOptions, type UploadFileOptions, type UploadFileResponse, type UploadOptions, type UploadProgress, type VAPIDPublicKeyResponse, type ValidateResponse, type ValidationSchema, type ValidationSchemaField, type ValidationStateTransitions, type Video, type VideoComment, type VideoCompleteUploadResponse, type VideoListOptions, type VideoListResponse, VideoProcessingError, type VideoQuality, type VideoStatus, type VideoStorage, type VideoStorageAccessLevel, type VideoStorageListResponse, type VideoVisibility, type VoiceChannel, type VoiceMember, type WaitOptions, type WatchHistoryItem, type WebPushSubscription, type WebRTCConnectOptions, type WebRTCConnectionState, type WebRTCMode, type WebRTCWarning, type WhereCondition, type WhereOperator, WsTicketError, ConnectBase as default, detectInAppBrowser, escapeToExternalBrowser, isWebTransportSupported, toAIError, toCreateRoomWire };
|
|
13880
|
+
export { AIAPI, type AIChatOptions, type AIChatRequest, type AIChatResponse, type AIChatStreamCallbacks, type AIChatStreamOptions, AIError, type AIErrorCode, type AIGeneratedImage, type AIMessage, type AISource, type AIStreamChunk, type AITool, type AIToolCall, type AIToolEvent, AUTH_MEMBER_ID_TOKEN, type AcceptInvitationResponse, type AckMessagesRequest, type AckMessagesResponse, type AdMobDailyReport, type AdMobReportResponse, type AdMobReportSummary, type AdReportResponse, type AdReportSummary, type AdmobConnectionInfo, AdsAPI, type AdsenseConnectionInfo, type AgenticSearchProgress, type AggregateResult, type AggregateStage, type AnalyticsConfig, type AnalyticsEvent, ApiError, type ApiErrorDetail, type AppMemberDetail, type AppMemberIdentityDetail, type AppMemberIdentitySummary, type AppMemberList, type AppMemberListItem, type AppMemberProviderType, AppMembersAPI, type AppStatsResponse, type ArchivePolicy, type AtomicOperator, type AtomicOperatorType, AuthError, type AuthSettingsResponse, type BackupInfo, type BatchOperation, type BatchOperationResult, type BatchSetPageMetaRequest, type BatchWriteResult, type BillingCycle, type BillingKeyResponse, type BiometricInfo, type BiometricResult, type BulkCreateResponse, type BulkError, type CPUInfo, type CancelPaymentRequest, type CancelPaymentResponse, type CancelSubscriptionRequest, type CategoryInfo, type ChangePlanOptions, type ChangePlanPreview, type ChangePlanRequest, type ChangePlanWithPriceRef, type ChangePlanWithProduct, type Channel, type ChannelMembership, type ChannelStats, type ChargeWithBillingKeyAmount, type ChargeWithBillingKeyOptions, type ChargeWithBillingKeyProduct, type ChargeWithBillingKeyRequest, type ChargeWithBillingKeyResponse, type ChatMessage, type ClientMessage, type ColumnSchema, type CommentListResponse, type CompleteUploadRequest, type CompleteUploadResponse, type ConfirmBillingKeyRequest, type ConfirmPaymentRequest, type ConfirmPaymentResponse, ConnectBase, type ConnectBaseConfig, type ConnectedData, type ConnectionState, type ConsentOptions, type ConsumeMessagesResponse, type ConsumeOptions, type CopyTableRequest, type CopyTableResponse, type CreateBackupRequest, type CreateChannelRequest, type CreateCheckoutSessionOptions, type CreateCheckoutSessionRequest, type CreateCheckoutSessionResponse, type CreateCheckoutSessionWithAmount, type CreateCheckoutSessionWithProduct, type CreateColumnRequest, type CreateDataRequest, type CreateDocumentRequest, type CreateFolderRequest, type CreateFolderResponse, type CreateGameUnitRequest, type CreateGeoIndexRequest, type CreateIndexRequest, type CreateInvitationRequest, type CreateInvitationResponse, type CreateLobbyRequest, type CreateOrganizationRequest, type CreatePlaylistRequest, type CreatePublicKeyRequest, type CreatePublicKeyResponse, type CreateRelationRequest, type CreateRolePayload, type CreateRoleResult, type CreateRoomResult, type CreateSearchIndexRequest, type CreateSecurityRuleRequest, type CreateSubscriptionOptions, type CreateSubscriptionRequest, type CreateSubscriptionWithAmount, type CreateSubscriptionWithProduct, type CreateTableRequest, type CreateTopicOptions, type CreateTriggerRequest, type CreateVideoStorageRequest, type DailyReport, type DataItem, type DataType, type DatabaseChange, type DatabaseChangeMessage, type DatabaseChangeType, type DatabaseRealtimeConnectOptions, type DatabaseRealtimeFilter, type DatabaseRealtimeHandlers, type DatabaseRealtimeSubscription, type DatabaseSnapshot, type DatabaseSnapshotMessage, type DatabaseSubscribeOptions, type DeleteBillingKeyResponse, type DeleteWhereResponse, type DeviceInfo, type DocumentResponse, type EnabledProviderInfo, type EnabledProvidersResponse, EndpointAPI, type EndpointCallInit, type ErrorHandler, type ErrorMessage, type ErrorReport, type ErrorTrackerConfig, type ErrorType, type ExportDataRequest, type ExportDataResponse, type FetchDataResponse, type FetchFilesResponse, type FetchPublicKeysResponse, type FileItem, type FileStats, GAME_MESSAGE, GameAPI, type GameAction, type GameAppIsolation, type GameCaps, type GameClientConfig, type GameConfig, GameConfigAPI, type GameConfigPatch, type GameConnectionState, type GameConnectionStatus, type GameCreatedVia, type GameCreatorToken, type GameCreatorTokenScope, type GameDelta, type GameEffectiveCaps, type GameEffectiveFeatures, type GameEntity, type GameEntityListResponse, GameError, type GameErrorCode, type GameEventHandlers, type GameFeatureOverrides, type GameFromHostOptions, GameHubAPI, type GameHubHandle, type GameHubMountOptions, type GamePlayer, type GamePlayerIdMode, GameRoom, type GameRoomConfig, type GameRoomInfo, GameRoomTransport, GameScope, type GameScopeOptions, type GameServerMessage, type GameServerMessageType, type GameState, type GameStatus, type GameTokenGrant, type GameTokenResponse, type GameTransportConfig, type GameUnit, type GameUsageDay, type GameUsageResponse, GamesAPI, type GenerateUploadURLByPathRequest, type GenerateUploadURLRequest, type GenerateUploadURLResponse, type GeoBoundingBox, type GeoIndex, type GeoNear, type GeoPoint, type GeoPolygon, type GeoQuery, type GeoResponse, type GeoResult, type GetAuthorizationURLResponse, type GetFileByPathResponse, type GoogleConnectionStatus, type HistoryResponse, type ICEServer, type ICEServersResponse, type ImageResult, type ImportDataRequest, type ImportDataResponse, type IndexAnalysis, type IndexRecommendation, type InitUploadResponse, type InvokeFunctionRequest, type InvokeFunctionResponse, type IssueBillingKeyRequest, type IssueBillingKeyResponse, type IssueGameCreatorTokenRequest, type IssueGameTokenOptions, type IssuedGameCreatorToken, type JoinQueueRequest, type JoinRoomRequest, type JoinRoomResponse, type KnowledgeSearchRequest, type KnowledgeSearchResponse, type KnowledgeSearchResult, type LeaderboardEntry, type LeaderboardListResponse, type LeaderboardScoreEntry, type LifecyclePolicy, type ListAppMembersOptions, type ListBillingKeysResponse, type ListDocumentsResponse, type ListFilesOptions, type ListFilesResult, type ListPageMetasOptions, type ListPageMetasResponse, type ListPaymentsOptions, type ListSubscriptionPaymentsRequest, type ListSubscriptionPaymentsResponse, type ListSubscriptionsRequest, type ListSubscriptionsResponse, type LobbyInfo, type LobbyInvite, type LobbyMember, type LobbyVisibility, type MatchResult, type MatchmakingTicket, type MatchqueueListResponse, type MatchqueueTicket, type MemberChangePasswordRequest, type MemberCredentialMessageResponse, type MemberEmailVerificationConfirmRequest, type MemberEmailVerificationConfirmResponse, type MemberEmailVerificationRequest, type MemberInfoResponse, type MemberPasswordResetConfirmRequest, type MemberPasswordResetRequest, type MemberRedirectOption, type MemberSession, type MemberSessionList, type MemberSessionRevokeResponse, type MemberSignInRequest, type MemberSignInResponse, type MemberSignUpRequest, type MemberSignUpResponse, type MembershipTier, type MemoryInfo, type MessageHandler, type MigrateDataRequest, type MigrateDataResponse, type MoveFileRequest, type NackMessageRequest, type NackMessageResponse, NativeAPI, type OAuthCallbackResponse, type OAuthPrompt, type OAuthProvider, type OnPaymentFailure, type OpenDialogOptions, type OpenDialogResult, type Organization, type OrganizationContext, type OrganizationInvitation, type OrganizationMember, type OrganizationMemberList, type OrganizationRole, OrganizationsAPI, type PageMetaResponse, type PartyInfo, type PartyInvite, type PartyMember, type PauseSubscriptionRequest, type PaymentDetail, type PaymentListItem, type PaymentListResult, type PaymentMode, type PaymentProvider, type PaymentStatus, type PaymentSummaryAmounts, type PaymentSummaryOptions, type PaymentSummaryResult, type PeerInfo, type Platform, type PlayerEvent, type PlayerKVItem, type PlayerKVListResponse, type PlayerKVWriteResult, type PlayerStats, type Playlist, type PlaylistItem, type PollUntilOptions, type PongMessage, type PopulateOption, type Position, type PostponeBillingRequest, type PreparePaymentOptions, type PreparePaymentRequest, type PreparePaymentResponse, type PreparePaymentWithAmount, type PreparePaymentWithProduct, type PresenceChangeHandler, type PresenceInfo, type PresenceSetOptions, type PresenceStatus, type PresenceStatusResult, type ProrationMode, type PublicKeyItem, type PublicKeyPaymentMode, type PublishBatchError, type PublishBatchRequest, type PublishBatchResponse, type PublishMessageRequest, type PublishMessageResponse, type PushPlatform, type PushStatsResult, type PushTopicInfo, type QueryOptions, type QueueInfoResponse, type QueueMessage, type ReadReceiptHandler, type ReadReceiptInfo, type RealtimeConnectOptions, RealtimeConnectionError, type RealtimeConnectionErrorCode, type RealtimeMessage, RealtimeRequestError, type RealtimeSendPolicy, type RegisterDeviceRequest, type RelationType, type RenameFileRequest, type RenameFileResponse, type ReplayHighlight, type ReplayInfo, type ReplayPlayerInfo, type ResolveGamePlayersResponse, type RestoreBackupRequest, type RestoreBackupResponse, type RetentionPolicy, type RoleDetail, type RoleList, type RoleListItem, type RolePermissionItem, type RoleUserItem, RolesAPI, type RoomInfo, type RoomStaleMessage, type RoomSummary, type RoomsResponse, type RotatePublicKeyRequest, type RotatePublicKeyResponse, type SFUTokenOptions, type SFUTokenResponse, type SaveDialogOptions, type SaveDialogResult, type ScriptDetailResponse, type ScriptListResponse, type ScriptLogEntry, type ScriptLogsResponse, type ScriptMeta, type ScriptMetricsResponse, type ScriptVersion, type ScriptVersionListResponse, type SearchIndex, type SearchOptions, type SearchResponse, type SearchResult, type SecurityRule, type SendOptions, type SendSuperChatOptions, type SendSuperChatResponse, type ServerMessage, SessionManager, type SetPageMetaRequest, type Shorts, type ShortsListResponse, type SignalingMessage, type SignalingMessageType, type SlowQueryInfo, type SpectatorInfo, type SpectatorPlayerState, type SpectatorState, type SpeechRecognizeOptions, type SpeechResult, type StateChange, type StateChangeHandler, type StorageUploadOptions, type StorageUploadProgress, type StorageVideoListOptions, type StreamContentPart, type StreamDoneCallback, type StreamDoneData, type StreamErrorCallback, type StreamHandlers, type StreamImageURLPart, type StreamMessage, type StreamOptions, type StreamSession, type StreamTextPart, type StreamTokenCallback, type StreamToolCallCallback, type StreamToolResultCallback, type StreamURLResponse, type SubscribeOptions, type SubscribeTopicRequest, type SubscribedData, type Subscription, type SubscriptionPaymentResponse, type SubscriptionPaymentStatus, type SubscriptionResponse, type SubscriptionStatus, type SuperChat, type SuperChatType, type SuspendAppMemberOptions, type SuspendAppMemberResult, type SyncLostMessage, type SystemInfo, type TTLConfig, type TableAccessLevel, type TableColumnDef, type TableIndex, type TableRelation, type TableSchema, type TableSchemaDefinition, type TokenPersistence, type TransactionRead, type TransactionResult, type TransactionWrite, type TransactionWriteResult, type TranscodeJob, type TranscodeStatus, type TransportType, type Trigger, type TriggerEvent, type TriggerHandlerType, type TypingChangeHandler, type TypingInfo, type UnsuspendAppMemberResult, type UpdateBillingKeyRequest, type UpdateChannelRequest, type UpdateColumnRequest, type UpdateCustomDataRequest, type UpdateCustomDataResponse, type UpdateDataRequest, type UpdateDocumentRequest, type UpdateGameUnitRequest, type UpdateLobbyRequest, type UpdateOrganizationRequest, type UpdatePublicKeyRequest, type UpdatePublicKeyResponse, type UpdateRolePayload, type UpdateSecurityRuleRequest, type UpdateSubscriptionRequest, type UpdateTriggerRequest, type UpdateVideoRequest, type UpdateVideoStorageRequest, type UploadByPathOptions, type UploadFileOptions, type UploadFileResponse, type UploadOptions, type UploadProgress, type VAPIDPublicKeyResponse, type ValidateResponse, type ValidationSchema, type ValidationSchemaField, type ValidationStateTransitions, type Video, type VideoComment, type VideoCompleteUploadResponse, type VideoListOptions, type VideoListResponse, VideoProcessingError, type VideoQuality, type VideoStatus, type VideoStorage, type VideoStorageAccessLevel, type VideoStorageListResponse, type VideoVisibility, type VoiceChannel, type VoiceMember, type WaitOptions, type WatchHistoryItem, type WebPushSubscription, type WebRTCConnectOptions, type WebRTCConnectionState, type WebRTCMode, type WebRTCWarning, type WhereCondition, type WhereOperator, WsTicketError, ConnectBase as default, detectInAppBrowser, escapeToExternalBrowser, isWebTransportSupported, toAIError, toCreateRoomWire };
|