tornapi-typescript 4.3.5 → 4.3.8
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 +10 -1
- package/dist/index.ts +19 -1
- package/dist/openapi.json +62 -8
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -48,6 +48,7 @@ export type WeaponBonusEnum = "Any" | "Double" | "Yellow" | "Orange" | "Red" | "
|
|
|
48
48
|
export type UserListEnum = "Friends" | "Enemies" | "Targets";
|
|
49
49
|
export type JobPositionCasinoEnum = "Gaming Consultant" | "Marketing Manager" | "Revenue Manager" | "Casino Manager" | "Casino President";
|
|
50
50
|
export type AttackFinishingHitEffect = "proficience" | "stricken" | "revitalize" | "warlord" | "plunder" | "irradiate";
|
|
51
|
+
export type ApiFiltersAttacksRevivesEnum = "incoming" | "outgoing" | "idFilter";
|
|
51
52
|
export type JobPositionMedicalEnum = "Medical Student" | "Houseman" | "Senior Houseman" | "GP" | "Consultant" | "Surgeon" | "Brain Surgeon";
|
|
52
53
|
export type JobPositionLawEnum = "Law Student" | "Paralegal" | "Probate Lawyer" | "Trial Lawyer" | "Circuit Court Judge" | "Federal Judge";
|
|
53
54
|
export type JobPositionEducationEnum = "Recess Supervisor" | "Substitute Teacher" | "Elementary Teacher" | "Secondary Teacher" | "Professor" | "Vice-Principal" | "Principal";
|
|
@@ -124,6 +125,7 @@ export interface RequestMetadataWithLinksAndTotal {
|
|
|
124
125
|
export type ForumFeedTypeEnum = 1 | 2 | 3 | 4 | 5 | 6 | 7;
|
|
125
126
|
export type UserGenderEnum = "Male" | "Female" | "Enby";
|
|
126
127
|
export type HonorRarityEnum = "Extremely Rare" | "Very Rare" | "Rare" | "Limited" | "Uncommon" | "Common" | "Very Common" | "Unknown" | "Unknown Rarity";
|
|
128
|
+
export type AwardCrimesVersionEnum = "v1" | "v2";
|
|
127
129
|
export type Parameters = string;
|
|
128
130
|
export type ReviveSetting = "Everyone" | "Friends & faction" | "No one" | "Unknown";
|
|
129
131
|
export type FactionWarfareTypeEnum = "ranked" | "territory" | "raid" | "chain" | "chainOngoing" | "db";
|
|
@@ -603,7 +605,12 @@ export interface UserMoneyResponse {
|
|
|
603
605
|
cayman_bank: number;
|
|
604
606
|
city_bank: {
|
|
605
607
|
amount: number;
|
|
608
|
+
profit: number;
|
|
609
|
+
/** Initial duration in days. */
|
|
610
|
+
duration: number;
|
|
611
|
+
interest_rate: number;
|
|
606
612
|
until: number;
|
|
613
|
+
invested_at: number;
|
|
607
614
|
};
|
|
608
615
|
faction: {
|
|
609
616
|
money: number;
|
|
@@ -2777,6 +2784,7 @@ export interface TornHonor {
|
|
|
2777
2784
|
circulation?: number;
|
|
2778
2785
|
equipped?: number;
|
|
2779
2786
|
rarity?: HonorRarityEnum;
|
|
2787
|
+
crimes_version?: AwardCrimesVersionEnum;
|
|
2780
2788
|
}
|
|
2781
2789
|
export interface TornHonorsResponse {
|
|
2782
2790
|
honors: TornHonor[];
|
|
@@ -2791,6 +2799,7 @@ export interface TornMedal {
|
|
|
2791
2799
|
};
|
|
2792
2800
|
circulation: number;
|
|
2793
2801
|
rarity: HonorRarityEnum;
|
|
2802
|
+
crimes_version?: AwardCrimesVersionEnum;
|
|
2794
2803
|
}
|
|
2795
2804
|
export interface TornMedalsResponse {
|
|
2796
2805
|
medals: TornMedal[];
|
|
@@ -6516,7 +6525,7 @@ export interface UserV2 extends BaseSchema {
|
|
|
6516
6525
|
};
|
|
6517
6526
|
log: {
|
|
6518
6527
|
response: UserLogsResponse;
|
|
6519
|
-
params: "log" | "cat" | "limit" | "to" | "from" | "timestamp";
|
|
6528
|
+
params: "log" | "cat" | "target" | "limit" | "to" | "from" | "timestamp";
|
|
6520
6529
|
};
|
|
6521
6530
|
medals: {
|
|
6522
6531
|
response: UserMedalsResponse;
|
package/dist/index.ts
CHANGED
|
@@ -4629,6 +4629,8 @@ export type AttackFinishingHitEffect =
|
|
|
4629
4629
|
| "plunder"
|
|
4630
4630
|
| "irradiate";
|
|
4631
4631
|
|
|
4632
|
+
export type ApiFiltersAttacksRevivesEnum = "incoming" | "outgoing" | "idFilter";
|
|
4633
|
+
|
|
4632
4634
|
export type JobPositionMedicalEnum =
|
|
4633
4635
|
| "Medical Student"
|
|
4634
4636
|
| "Houseman"
|
|
@@ -4852,6 +4854,8 @@ export type HonorRarityEnum =
|
|
|
4852
4854
|
| "Unknown"
|
|
4853
4855
|
| "Unknown Rarity";
|
|
4854
4856
|
|
|
4857
|
+
export type AwardCrimesVersionEnum = "v1" | "v2";
|
|
4858
|
+
|
|
4855
4859
|
export type Parameters = string;
|
|
4856
4860
|
|
|
4857
4861
|
export type ReviveSetting =
|
|
@@ -5607,7 +5611,12 @@ export interface UserMoneyResponse {
|
|
|
5607
5611
|
cayman_bank: number;
|
|
5608
5612
|
city_bank: {
|
|
5609
5613
|
amount: number;
|
|
5614
|
+
profit: number;
|
|
5615
|
+
/** Initial duration in days. */
|
|
5616
|
+
duration: number;
|
|
5617
|
+
interest_rate: number;
|
|
5610
5618
|
until: number;
|
|
5619
|
+
invested_at: number;
|
|
5611
5620
|
};
|
|
5612
5621
|
faction: {
|
|
5613
5622
|
money: number;
|
|
@@ -8389,6 +8398,7 @@ export interface TornHonor {
|
|
|
8389
8398
|
circulation?: number;
|
|
8390
8399
|
equipped?: number;
|
|
8391
8400
|
rarity?: HonorRarityEnum;
|
|
8401
|
+
crimes_version?: AwardCrimesVersionEnum;
|
|
8392
8402
|
}
|
|
8393
8403
|
|
|
8394
8404
|
export interface TornHonorsResponse {
|
|
@@ -8405,6 +8415,7 @@ export interface TornMedal {
|
|
|
8405
8415
|
};
|
|
8406
8416
|
circulation: number;
|
|
8407
8417
|
rarity: HonorRarityEnum;
|
|
8418
|
+
crimes_version?: AwardCrimesVersionEnum;
|
|
8408
8419
|
}
|
|
8409
8420
|
|
|
8410
8421
|
export interface TornMedalsResponse {
|
|
@@ -12261,7 +12272,14 @@ export interface UserV2 extends BaseSchema {
|
|
|
12261
12272
|
};
|
|
12262
12273
|
log: {
|
|
12263
12274
|
response: UserLogsResponse;
|
|
12264
|
-
params:
|
|
12275
|
+
params:
|
|
12276
|
+
| "log"
|
|
12277
|
+
| "cat"
|
|
12278
|
+
| "target"
|
|
12279
|
+
| "limit"
|
|
12280
|
+
| "to"
|
|
12281
|
+
| "from"
|
|
12282
|
+
| "timestamp";
|
|
12265
12283
|
};
|
|
12266
12284
|
medals: {
|
|
12267
12285
|
response: UserMedalsResponse;
|
package/dist/openapi.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"info": {
|
|
4
4
|
"title": "Torn API",
|
|
5
5
|
"description": "\n * The development of Torn's API v2 is still ongoing.\n * If selections remain unaltered, they will default to the API v1 version.\n * Unlike API v1, API v2 accepts both selections and IDs as path and query parameters.\n * If any discrepancies or errors are found, please submit a [bug report](https://www.torn.com/forums.php#/p=forums&f=19&b=0&a=0) on the Torn Forums.\n * In case you're using bots to check for changes on openapi.json file, make sure to specificy a custom user-agent header - CloudFlare sometimes prevents requests from default user-agents.",
|
|
6
|
-
"version": "4.3.
|
|
6
|
+
"version": "4.3.8"
|
|
7
7
|
},
|
|
8
8
|
"servers": [
|
|
9
9
|
{
|
|
@@ -1704,6 +1704,15 @@
|
|
|
1704
1704
|
"$ref": "#/components/schemas/LogCategoryId"
|
|
1705
1705
|
}
|
|
1706
1706
|
},
|
|
1707
|
+
{
|
|
1708
|
+
"name": "target",
|
|
1709
|
+
"in": "query",
|
|
1710
|
+
"description": "Get logs where you interacted with a specific player by passing their player ID.",
|
|
1711
|
+
"required": false,
|
|
1712
|
+
"schema": {
|
|
1713
|
+
"$ref": "#/components/schemas/UserId"
|
|
1714
|
+
}
|
|
1715
|
+
},
|
|
1707
1716
|
{
|
|
1708
1717
|
"$ref": "#/components/parameters/ApiLimit100Default20"
|
|
1709
1718
|
},
|
|
@@ -13847,6 +13856,14 @@
|
|
|
13847
13856
|
"irradiate"
|
|
13848
13857
|
]
|
|
13849
13858
|
},
|
|
13859
|
+
"ApiFiltersAttacksRevivesEnum": {
|
|
13860
|
+
"type": "string",
|
|
13861
|
+
"enum": [
|
|
13862
|
+
"incoming",
|
|
13863
|
+
"outgoing",
|
|
13864
|
+
"idFilter"
|
|
13865
|
+
]
|
|
13866
|
+
},
|
|
13850
13867
|
"JobPositionMedicalEnum": {
|
|
13851
13868
|
"type": "string",
|
|
13852
13869
|
"enum": [
|
|
@@ -14243,6 +14260,13 @@
|
|
|
14243
14260
|
"Unknown Rarity"
|
|
14244
14261
|
]
|
|
14245
14262
|
},
|
|
14263
|
+
"AwardCrimesVersionEnum": {
|
|
14264
|
+
"type": "string",
|
|
14265
|
+
"enum": [
|
|
14266
|
+
"v1",
|
|
14267
|
+
"v2"
|
|
14268
|
+
]
|
|
14269
|
+
},
|
|
14246
14270
|
"Parameters": {
|
|
14247
14271
|
"oneOf": [
|
|
14248
14272
|
{
|
|
@@ -16842,16 +16866,37 @@
|
|
|
16842
16866
|
"city_bank": {
|
|
16843
16867
|
"required": [
|
|
16844
16868
|
"amount",
|
|
16845
|
-
"
|
|
16869
|
+
"profit",
|
|
16870
|
+
"duration",
|
|
16871
|
+
"interest_rate",
|
|
16872
|
+
"until",
|
|
16873
|
+
"invested_at"
|
|
16846
16874
|
],
|
|
16847
16875
|
"properties": {
|
|
16848
16876
|
"amount": {
|
|
16849
16877
|
"type": "integer",
|
|
16850
16878
|
"format": "int64"
|
|
16851
16879
|
},
|
|
16880
|
+
"profit": {
|
|
16881
|
+
"type": "integer",
|
|
16882
|
+
"format": "int64"
|
|
16883
|
+
},
|
|
16884
|
+
"duration": {
|
|
16885
|
+
"description": "Initial duration in days.",
|
|
16886
|
+
"type": "integer",
|
|
16887
|
+
"format": "int32"
|
|
16888
|
+
},
|
|
16889
|
+
"interest_rate": {
|
|
16890
|
+
"type": "number",
|
|
16891
|
+
"format": "float"
|
|
16892
|
+
},
|
|
16852
16893
|
"until": {
|
|
16853
16894
|
"type": "integer",
|
|
16854
16895
|
"format": "int64"
|
|
16896
|
+
},
|
|
16897
|
+
"invested_at": {
|
|
16898
|
+
"type": "integer",
|
|
16899
|
+
"format": "int32"
|
|
16855
16900
|
}
|
|
16856
16901
|
},
|
|
16857
16902
|
"type": "object"
|
|
@@ -27606,6 +27651,10 @@
|
|
|
27606
27651
|
},
|
|
27607
27652
|
"rarity": {
|
|
27608
27653
|
"$ref": "#/components/schemas/HonorRarityEnum"
|
|
27654
|
+
},
|
|
27655
|
+
"crimes_version": {
|
|
27656
|
+
"$ref": "#/components/schemas/AwardCrimesVersionEnum",
|
|
27657
|
+
"description": "Populated only when the type.id is 5."
|
|
27609
27658
|
}
|
|
27610
27659
|
},
|
|
27611
27660
|
"type": "object"
|
|
@@ -27665,6 +27714,10 @@
|
|
|
27665
27714
|
},
|
|
27666
27715
|
"rarity": {
|
|
27667
27716
|
"$ref": "#/components/schemas/HonorRarityEnum"
|
|
27717
|
+
},
|
|
27718
|
+
"crimes_version": {
|
|
27719
|
+
"$ref": "#/components/schemas/AwardCrimesVersionEnum",
|
|
27720
|
+
"description": "Populated only when the type.id is 'CRM'."
|
|
27668
27721
|
}
|
|
27669
27722
|
},
|
|
27670
27723
|
"type": "object"
|
|
@@ -29452,14 +29505,15 @@
|
|
|
29452
29505
|
"ApiFiltersIncomingOutgoing": {
|
|
29453
29506
|
"name": "filters",
|
|
29454
29507
|
"in": "query",
|
|
29455
|
-
"description": "It's possible to use this query parameter to only get incoming or outgoing attacks / revives. If not specified, this selection will return both incoming and outgoing attacks / revives.",
|
|
29508
|
+
"description": "It's possible to use this query parameter to only get incoming or outgoing attacks / revives. If not specified, this selection will return both incoming and outgoing attacks / revives.\nIt's also possible to combine this with 'idFilter'. This filter allows using from/to to filter by ids instead of timestamps.",
|
|
29456
29509
|
"required": false,
|
|
29510
|
+
"style": "form",
|
|
29511
|
+
"explode": false,
|
|
29457
29512
|
"schema": {
|
|
29458
|
-
"type": "
|
|
29459
|
-
"
|
|
29460
|
-
"
|
|
29461
|
-
|
|
29462
|
-
]
|
|
29513
|
+
"type": "array",
|
|
29514
|
+
"items": {
|
|
29515
|
+
"$ref": "#/components/schemas/ApiFiltersAttacksRevivesEnum"
|
|
29516
|
+
}
|
|
29463
29517
|
}
|
|
29464
29518
|
},
|
|
29465
29519
|
"ApiFiltersUser": {
|