@lichess-org/types 2.0.44 → 2.0.45

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.
Files changed (2) hide show
  1. package/lichess-api.d.ts +46 -98
  2. package/package.json +1 -1
package/lichess-api.d.ts CHANGED
@@ -3925,22 +3925,17 @@ export interface components {
3925
3925
  * } */
3926
3926
  Leaderboard: unknown;
3927
3927
  Perf: {
3928
- /** @example 2945 */
3929
- games?: number;
3930
- /** @example 1609 */
3931
- rating?: number;
3932
- /** @example 60 */
3933
- rd?: number;
3934
- /** @example -22 */
3935
- prog?: number;
3928
+ games: number;
3929
+ rating: number;
3930
+ /** @description rating deviation */
3931
+ rd: number;
3932
+ prog: number;
3936
3933
  /** @description only appears if a user's perf rating are [provisional](https://lichess.org/faq#provisional) */
3937
3934
  prov?: boolean;
3938
3935
  };
3939
3936
  PuzzleModePerf: {
3940
- /** @example 44 */
3941
- runs?: number;
3942
- /** @example 61 */
3943
- score?: number;
3937
+ runs: number;
3938
+ score: number;
3944
3939
  };
3945
3940
  Perfs: {
3946
3941
  chess960?: components["schemas"]["Perf"];
@@ -4465,18 +4460,9 @@ export interface components {
4465
4460
  puzzles?: {
4466
4461
  score?: components["schemas"]["UserActivityScore"];
4467
4462
  };
4468
- storm?: {
4469
- runs?: number;
4470
- score?: number;
4471
- };
4472
- racer?: {
4473
- runs?: number;
4474
- score?: number;
4475
- };
4476
- streak?: {
4477
- runs?: number;
4478
- score?: number;
4479
- };
4463
+ storm?: components["schemas"]["PuzzleModePerf"];
4464
+ racer?: components["schemas"]["PuzzleModePerf"];
4465
+ streak?: components["schemas"]["PuzzleModePerf"];
4480
4466
  tournaments?: {
4481
4467
  nb?: number;
4482
4468
  best?: {
@@ -4512,6 +4498,7 @@ export interface components {
4512
4498
  teams?: {
4513
4499
  url: string;
4514
4500
  name: string;
4501
+ flair?: components["schemas"]["Flair"];
4515
4502
  }[];
4516
4503
  posts?: {
4517
4504
  topicUrl: string;
@@ -5095,11 +5082,8 @@ export interface components {
5095
5082
  | "rapid"
5096
5083
  | "classical"
5097
5084
  | "correspondence";
5098
- /**
5099
- * @description Game status code. https://github.com/lichess-org/scalachess/blob/0a7d6f2c63b1ca06cd3c958ed3264e738af5c5f6/src/main/scala/Status.scala#L16-L28
5100
- * @enum {string}
5101
- */
5102
- GameStatus:
5085
+ /** @enum {string} */
5086
+ GameStatusName:
5103
5087
  | "created"
5104
5088
  | "started"
5105
5089
  | "aborted"
@@ -5169,7 +5153,7 @@ export interface components {
5169
5153
  createdAt: number;
5170
5154
  /** Format: int64 */
5171
5155
  lastMoveAt: number;
5172
- status: components["schemas"]["GameStatus"];
5156
+ status: components["schemas"]["GameStatusName"];
5173
5157
  source?: string;
5174
5158
  players: {
5175
5159
  white: components["schemas"]["GameUser"];
@@ -6316,70 +6300,51 @@ export interface components {
6316
6300
  */
6317
6301
  date?: number;
6318
6302
  };
6303
+ /** @enum {integer} */
6304
+ GameStatusId:
6305
+ | 10
6306
+ | 20
6307
+ | 25
6308
+ | 30
6309
+ | 31
6310
+ | 32
6311
+ | 33
6312
+ | 34
6313
+ | 35
6314
+ | 36
6315
+ | 37
6316
+ | 38
6317
+ | 60;
6318
+ GameStatus: {
6319
+ id?: components["schemas"]["GameStatusId"];
6320
+ name?: components["schemas"]["GameStatusName"];
6321
+ };
6322
+ GameEventOpponent: {
6323
+ id?: string;
6324
+ username?: string;
6325
+ rating?: number;
6326
+ };
6319
6327
  GameCompat: {
6320
6328
  /** @description Compatible with Bot API */
6321
6329
  bot?: boolean;
6322
6330
  /** @description Compatible with Board API */
6323
6331
  board?: boolean;
6324
6332
  };
6325
- /** @example {
6326
- * "fullId": "9NaCTu2vz1c4",
6327
- * "gameId": "9NaCTu2v",
6328
- * "fen": "rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq - 0 1",
6329
- * "color": "white",
6330
- * "lastMove": "",
6331
- * "source": "friend",
6332
- * "status": {
6333
- * "id": 20,
6334
- * "name": "started"
6335
- * },
6336
- * "variant": {
6337
- * "key": "standard",
6338
- * "name": "Standard"
6339
- * },
6340
- * "speed": "blitz",
6341
- * "perf": "blitz",
6342
- * "rated": false,
6343
- * "hasMoved": false,
6344
- * "opponent": {
6345
- * "id": "mary",
6346
- * "username": "Mary",
6347
- * "rating": 1007
6348
- * },
6349
- * "isMyTurn": true,
6350
- * "secondsLeft": 300,
6351
- * "compat": {
6352
- * "bot": false,
6353
- * "board": true
6354
- * },
6355
- * "id": "9NaCTu2v"
6356
- * } */
6357
6333
  GameEventInfo: {
6358
- fullId?: string;
6359
- gameId?: string;
6334
+ fullId: string;
6335
+ gameId: string;
6360
6336
  fen?: string;
6361
6337
  /** @enum {string} */
6362
6338
  color?: "white" | "black";
6363
6339
  lastMove?: string;
6364
6340
  source?: components["schemas"]["GameSource"];
6365
- status?: {
6366
- /** @enum {integer} */
6367
- id?: 10 | 20 | 25 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 60;
6368
- name?: components["schemas"]["GameStatus"];
6369
- };
6370
- variant?: {
6371
- key?: string;
6372
- name?: string;
6373
- };
6341
+ status?: components["schemas"]["GameStatus"];
6342
+ variant?: components["schemas"]["Variant"];
6374
6343
  speed?: components["schemas"]["Speed"];
6375
6344
  perf?: string;
6376
6345
  rated?: boolean;
6377
6346
  hasMoved?: boolean;
6378
- opponent?: {
6379
- id?: string;
6380
- username?: string;
6381
- rating?: number;
6382
- };
6347
+ opponent?: components["schemas"]["GameEventOpponent"];
6383
6348
  isMyTurn?: boolean;
6384
6349
  secondsLeft?: number;
6385
6350
  compat?: components["schemas"]["GameCompat"];
@@ -6612,7 +6577,7 @@ export interface components {
6612
6577
  winc: number;
6613
6578
  /** @description Integer of Black Fisher increment. */
6614
6579
  binc: number;
6615
- status: components["schemas"]["GameStatus"];
6580
+ status: components["schemas"]["GameStatusName"];
6616
6581
  /** @description Color of the winner, if any */
6617
6582
  winner?: string;
6618
6583
  /** @description true if white is offering draw, else omitted */
@@ -8306,7 +8271,7 @@ export interface operations {
8306
8271
  color: "white" | "black";
8307
8272
  lastMove: string;
8308
8273
  source: components["schemas"]["GameSource"];
8309
- status?: components["schemas"]["GameStatus"];
8274
+ status?: components["schemas"]["GameStatusName"];
8310
8275
  variant: components["schemas"]["Variant"];
8311
8276
  speed: components["schemas"]["Speed"];
8312
8277
  perf: components["schemas"]["PerfType"];
@@ -12840,24 +12805,7 @@ export interface operations {
12840
12805
  fen?: string;
12841
12806
  turns?: number;
12842
12807
  source?: components["schemas"]["GameSource"];
12843
- status?: {
12844
- /** @enum {integer} */
12845
- id?:
12846
- | 10
12847
- | 20
12848
- | 25
12849
- | 30
12850
- | 31
12851
- | 32
12852
- | 33
12853
- | 34
12854
- | 35
12855
- | 36
12856
- | 37
12857
- | 38
12858
- | 60;
12859
- name?: components["schemas"]["GameStatus"];
12860
- };
12808
+ status?: components["schemas"]["GameStatus"];
12861
12809
  /** Format: int64 */
12862
12810
  createdAt?: number;
12863
12811
  /** @enum {string} */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lichess-org/types",
3
- "version": "2.0.44",
3
+ "version": "2.0.45",
4
4
  "description": "Lichess.org API types",
5
5
  "homepage": "https://github.com/lichess-org/api",
6
6
  "license": "AGPL-3.0-or-later",