tornapi-typescript 0.2.8 → 1.10.0

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/dist/index.d.ts CHANGED
@@ -4201,6 +4201,32 @@ export type FactionBranchStateEnum = "war" | "peace";
4201
4201
 
4202
4202
  export type RacingRaceTypeEnum = "official" | "custom";
4203
4203
 
4204
+ export type MarketSpecializedBazaarCategoryEnum =
4205
+ | "Alcohol"
4206
+ | "Artifact"
4207
+ | "Booster"
4208
+ | "Candy"
4209
+ | "Car"
4210
+ | "Clothing"
4211
+ | "Collectible"
4212
+ | "Defensive"
4213
+ | "Drug"
4214
+ | "Energy Drink"
4215
+ | "Enhancer"
4216
+ | "Flower"
4217
+ | "Jewelry"
4218
+ | "Material"
4219
+ | "Medical"
4220
+ | "Melee"
4221
+ | "Other"
4222
+ | "Plushie"
4223
+ | "Primary"
4224
+ | "Secondary"
4225
+ | "Special"
4226
+ | "Supply Pack"
4227
+ | "Temporary"
4228
+ | "Tool";
4229
+
4204
4230
  export type FactionPositionAbilityEnum =
4205
4231
  | "Medical Item Usage"
4206
4232
  | "Booster Item Usage"
@@ -4505,7 +4531,8 @@ export type RaceCarUpgradeSubCategory =
4505
4531
  export type FactionApplicationStatusEnum =
4506
4532
  | "accepted"
4507
4533
  | "declined"
4508
- | "withdrawn";
4534
+ | "withdrawn"
4535
+ | "active";
4509
4536
 
4510
4537
  export type FactionRankedWarsCategoryEnum = "all" | "ongoing";
4511
4538
 
@@ -4520,6 +4547,8 @@ export type FactionCrimeUserOutcome =
4520
4547
 
4521
4548
  export type RaceId = number;
4522
4549
 
4550
+ export type DirtyBombId = number;
4551
+
4523
4552
  export type RaceTrackId = number;
4524
4553
 
4525
4554
  export type RaceCarId = number;
@@ -4536,6 +4565,8 @@ export type RankedWarId = number;
4536
4565
 
4537
4566
  export type TerritoryWarId = number;
4538
4567
 
4568
+ export type RaidWarId = number;
4569
+
4539
4570
  export type ItemUid = number;
4540
4571
 
4541
4572
  export type UserId = number;
@@ -4608,6 +4639,13 @@ export type ReviveSetting =
4608
4639
  | "No one"
4609
4640
  | "Unknown";
4610
4641
 
4642
+ export type FactionWarfareTypeEnum =
4643
+ | "ranked"
4644
+ | "territory"
4645
+ | "raid"
4646
+ | "chain"
4647
+ | "db";
4648
+
4611
4649
  export type FactionCrimeStatusEnum =
4612
4650
  | "Recruiting"
4613
4651
  | "Planning"
@@ -5030,8 +5068,6 @@ export interface UserCrimeDetailsBootlegging {
5030
5068
  horror: number;
5031
5069
  romance: number;
5032
5070
  thriller: number;
5033
- /** This is replaced with 'sci_fi' field and will be removed on 1st June 2025. */
5034
- "sci-fi"?: number;
5035
5071
  sci_fi: number;
5036
5072
  total: number;
5037
5073
  earnings: number;
@@ -6274,6 +6310,92 @@ export type PersonalStatsStatName =
6274
6310
  | "forgeryskill"
6275
6311
  | "scammingskill";
6276
6312
 
6313
+ export interface FactionRaidReport {
6314
+ id: RaidWarId;
6315
+ start: number;
6316
+ end: number;
6317
+ aggressor: FactionRaidReportFaction;
6318
+ defender: FactionRaidReportFaction;
6319
+ }
6320
+
6321
+ export interface FactionRaidReportFaction {
6322
+ id: FactionId;
6323
+ name: string;
6324
+ score: number;
6325
+ attackers: FactionRaidReportAttacker[];
6326
+ non_attackers: FactionRaidReportUser[];
6327
+ }
6328
+
6329
+ export interface FactionRaidReportAttacker {
6330
+ user: FactionRaidReportUser;
6331
+ attacks: number;
6332
+ damage: number;
6333
+ }
6334
+
6335
+ export interface FactionRaidReportUser {
6336
+ id: UserId;
6337
+ name: string;
6338
+ }
6339
+
6340
+ export interface FactionRaidWarReportResponse {
6341
+ raidreport: FactionRaidReport[];
6342
+ }
6343
+
6344
+ export interface FactionWarfareDirtyBomb {
6345
+ id: DirtyBombId;
6346
+ planted_at: number;
6347
+ detonated_at: number;
6348
+ faction: FactionWarfareDirtyBombTargetFaction;
6349
+ user: FactionWarfareDirtyBombPlanter | null;
6350
+ }
6351
+
6352
+ export interface FactionWarfareDirtyBombTargetFaction {
6353
+ id: FactionId;
6354
+ name: string;
6355
+ respect_lost: number;
6356
+ }
6357
+
6358
+ export interface FactionWarfareDirtyBombPlanter {
6359
+ id: UserId;
6360
+ name: string;
6361
+ }
6362
+
6363
+ export interface FactionRaidWarfare {
6364
+ id: RaidWarId;
6365
+ start: number;
6366
+ end: number | null;
6367
+ aggressor: FactionRaidWarfareFaction;
6368
+ defender: FactionRaidWarfareFaction;
6369
+ }
6370
+
6371
+ /** The field 'chain' exists only if the field 'end' is NOT populated in FactionRaidWarfare schema. */
6372
+ export interface FactionRaidWarfareFaction {
6373
+ id: FactionId;
6374
+ name: string;
6375
+ score: number;
6376
+ chain?: number;
6377
+ }
6378
+
6379
+ export interface FactionTerritoryWarfare {
6380
+ id: TerritoryWarId;
6381
+ territory: FactionTerritoryEnum;
6382
+ start: number;
6383
+ end: number;
6384
+ target: number;
6385
+ aggressor: FactionTerritoryWarFaction;
6386
+ defender: FactionTerritoryWarFaction;
6387
+ result: string;
6388
+ }
6389
+
6390
+ /** The fields 'chain' and 'players_on_wall' exist only for wars with the result 'in_progress'. */
6391
+ export interface FactionTerritoryWarFaction {
6392
+ id: FactionId;
6393
+ name: string;
6394
+ score: number;
6395
+ chain?: number;
6396
+ players_on_wall?: any[];
6397
+ }
6398
+
6277
6399
  export interface FactionTerritoryWarFinishedFaction {
6278
6400
  id: FactionId;
6279
6401
  name: string;
@@ -6542,7 +6664,6 @@ export interface FactionBasic {
6542
6664
  tag: string;
6543
6665
  tag_image: string;
6544
6666
  leader_id: UserId;
6545
- "co-leader_id"?: UserId;
6546
6667
  co_leader_id: UserId;
6547
6668
  respect: number;
6548
6669
  days_old: number;
@@ -6644,6 +6765,11 @@ export interface FactionNewsResponse {
6644
6765
  _metadata: RequestMetadataWithLinks;
6645
6766
  }
6646
6767
 
6768
+ export interface FactionRaidsResponse {
6769
+ raids: FactionRaidWarfare[];
6770
+ _metadata: RequestMetadataWithLinks;
6771
+ }
6772
+
6647
6773
  export interface FactionAttacksResponse {
6648
6774
  attacks: Attack[];
6649
6775
  _metadata: RequestMetadataWithLinks;
@@ -6702,6 +6828,13 @@ export interface FactionChain {
6702
6828
  end: number;
6703
6829
  }
6704
6830
 
6831
+ export interface FactionChainWarfare extends FactionChain {
6832
+ faction: {
6833
+ id: FactionId;
6834
+ name: string;
6835
+ };
6836
+ }
6837
+
6705
6838
  export interface FactionChainsResponse {
6706
6839
  chains: FactionChain[];
6707
6840
  _metadata: RequestMetadataWithLinks;
@@ -6719,8 +6852,6 @@ export interface FactionChainReport {
6719
6852
  details: FactionChainReportDetails;
6720
6853
  bonuses: FactionChainReportBonus[];
6721
6854
  attackers: FactionChainReportAttacker[];
6722
- /** This is replaced with 'non_attackers' field and will be removed on 1st June 2025. */
6723
- "non-attackers"?: UserId[];
6724
6855
  non_attackers: UserId[];
6725
6856
  }
6726
6857
 
@@ -6895,6 +7026,16 @@ export interface FactionRankedWarResponse {
6895
7026
  _metadata: RequestMetadataWithLinks;
6896
7027
  }
6897
7028
 
7029
+ export interface FactionWarfareResponse {
7030
+ warfare:
7031
+ | FactionRankedWarDetails[]
7032
+ | FactionTerritoryWarfare[]
7033
+ | FactionChainWarfare[]
7034
+ | FactionRaidWarfare[]
7035
+ | FactionWarfareDirtyBomb[];
7036
+ _metadata: RequestMetadataWithLinks;
7037
+ }
7038
+
6898
7039
  export interface FactionRankedWarReportResponse {
6899
7040
  rankedwarreport: {
6900
7041
  id: RankedWarId;
@@ -7086,6 +7227,67 @@ export interface KeyInfoResponse {
7086
7227
 
7087
7228
  export type KeySelectionName = string;
7088
7229
 
7230
+ export interface BazaarWeekly {
7231
+ busiest: BazaarWeeklyCustomers[];
7232
+ most_popular: BazaarTotalFavorites[];
7233
+ trending: BazaarRecentFavorites[];
7234
+ top_grossing: BazaarWeeklyIncome[];
7235
+ bulk: BazaarBulkSales[];
7236
+ advanced_item: BazaarAdvancedItemSales[];
7237
+ bargain: BazaarBargainSales[];
7238
+ dollar_sale: BazaarDollarSales[];
7239
+ }
7240
+
7241
+ export interface BazaarSpecialized {
7242
+ specialized: BazaarWeeklyCustomers[];
7243
+ }
7244
+
7245
+ export interface BazaarResponse {
7246
+ bazaar: BazaarWeekly | BazaarSpecialized;
7247
+ }
7248
+
7249
+ export interface BazaarResponseSpecialized {
7250
+ bazaar: BazaarSpecialized;
7251
+ }
7252
+
7253
+ export interface Bazaar {
7254
+ id: UserId;
7255
+ name: string;
7256
+ is_open: boolean;
7257
+ }
7258
+
7259
+ export interface BazaarWeeklyCustomers extends Bazaar {
7260
+ weekly_customers: number;
7261
+ }
7262
+
7263
+ export interface BazaarTotalFavorites extends Bazaar {
7264
+ total_favorites: number;
7265
+ }
7266
+
7267
+ export interface BazaarRecentFavorites extends Bazaar {
7268
+ recent_favorites: number;
7269
+ }
7270
+
7271
+ export interface BazaarWeeklyIncome extends Bazaar {
7272
+ weekly_income: number;
7273
+ }
7274
+
7275
+ export interface BazaarBulkSales extends Bazaar {
7276
+ bulk_sales: number;
7277
+ }
7278
+
7279
+ export interface BazaarAdvancedItemSales extends Bazaar {
7280
+ advanced_item_sales: number;
7281
+ }
7282
+
7283
+ export interface BazaarBargainSales extends Bazaar {
7284
+ bargain_sales: number;
7285
+ }
7286
+
7287
+ export interface BazaarDollarSales extends Bazaar {
7288
+ dollar_sales: number;
7289
+ }
7290
+
7089
7291
  export interface ItemMarketListingItemBonus {
7090
7292
  id: number;
7091
7293
  title: string;
@@ -7601,8 +7803,8 @@ export interface TornFactionTreeResponse {
7601
7803
  }
7602
7804
 
7603
7805
  /**
7604
- * The following selections will fallback to API v1 and may change at any time: 'bank','cards','cityshops','companies','competition','dirtybombs','gyms','honors','itemdetails','itemstats','medals','organisedcrimes','pawnshop','pokertables','properties','raidreport','raids','rockpaperscissors','searchforcash','shoplifting','stats','stocks'.
7605
- * * The following selections are not available in API v2: 'chainreport', 'rackets', 'rankedwarreport', 'rankedwars', 'territorynames', 'territorywarreport', 'territorywars'.
7806
+ * The following selections will fallback to API v1 and may change at any time: 'bank','cards','cityshops','companies','competition','gyms','honors','itemdetails','itemstats','medals','organisedcrimes','pawnshop','pokertables','properties','rockpaperscissors','searchforcash','shoplifting','stats','stocks'.
7807
+ * * The following selections are not available in API v2: 'dirtybombs','raidreport','raids', 'chainreport', 'rackets', 'rankedwarreport', 'rankedwars', 'territorynames', 'territorywarreport', 'territorywars'.
7606
7808
  */
7607
7809
  export type TornSelectionName = string;
7608
7810