tornapi-typescript 5.5.0 → 5.5.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/dist/index.d.ts +8 -4
- package/dist/index.ts +9 -10
- package/dist/openapi.json +35 -27
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -58,6 +58,11 @@ export type RaceCarUpgradeSubCategory = "Engine Cooling" | "Front Diffuser" | "R
|
|
|
58
58
|
export type FactionApplicationStatusEnum = "accepted" | "declined" | "withdrawn" | "active";
|
|
59
59
|
export type FactionRankedWarsCategoryEnum = "all" | "ongoing";
|
|
60
60
|
export type FactionTerritoryWarsCategoryEnum = "finsihed" | "ongoing";
|
|
61
|
+
/**
|
|
62
|
+
* @default
|
|
63
|
+
* ongoing
|
|
64
|
+
*/
|
|
65
|
+
export type TradeCategoryEnum = "finished" | "ongoing";
|
|
61
66
|
export type FactionCrimeUserOutcome = "Successful" | "Failed" | "Jailed" | "Injured" | "Hospitalized";
|
|
62
67
|
export type FactionCrimeUserItemOutcomeEnum = "user" | "faction";
|
|
63
68
|
export type FactionCrimeItemOutcomeEnum = "lost" | "used";
|
|
@@ -503,7 +508,6 @@ export interface UserTrade {
|
|
|
503
508
|
export interface UserTradeParticipant {
|
|
504
509
|
id: UserId;
|
|
505
510
|
name: string;
|
|
506
|
-
summary: string[];
|
|
507
511
|
}
|
|
508
512
|
export interface UserTradeDetailed extends UserTrade {
|
|
509
513
|
items: TradeItem[];
|
|
@@ -546,7 +550,7 @@ export interface TradeItemCompany {
|
|
|
546
550
|
details: {
|
|
547
551
|
id: CompanyId;
|
|
548
552
|
name: string;
|
|
549
|
-
value:
|
|
553
|
+
value: number;
|
|
550
554
|
};
|
|
551
555
|
}
|
|
552
556
|
export interface TradeItemItem {
|
|
@@ -7020,11 +7024,11 @@ export interface UserV2 extends BaseSchema {
|
|
|
7020
7024
|
};
|
|
7021
7025
|
trades: {
|
|
7022
7026
|
response: UserTradesResponse;
|
|
7023
|
-
params: "
|
|
7027
|
+
params: "cat" | "limit" | "sort" | "to" | "from" | "timestamp";
|
|
7024
7028
|
};
|
|
7025
7029
|
trade: {
|
|
7026
7030
|
response: UserTradeResponse;
|
|
7027
|
-
params: "id" | "
|
|
7031
|
+
params: "id" | "timestamp";
|
|
7028
7032
|
};
|
|
7029
7033
|
travel: {
|
|
7030
7034
|
response: UserTravelResponse;
|
package/dist/index.ts
CHANGED
|
@@ -4728,6 +4728,12 @@ export type FactionRankedWarsCategoryEnum = "all" | "ongoing";
|
|
|
4728
4728
|
|
|
4729
4729
|
export type FactionTerritoryWarsCategoryEnum = "finsihed" | "ongoing";
|
|
4730
4730
|
|
|
4731
|
+
/**
|
|
4732
|
+
* @default
|
|
4733
|
+
* ongoing
|
|
4734
|
+
*/
|
|
4735
|
+
export type TradeCategoryEnum = "finished" | "ongoing";
|
|
4736
|
+
|
|
4731
4737
|
export type FactionCrimeUserOutcome =
|
|
4732
4738
|
| "Successful"
|
|
4733
4739
|
| "Failed"
|
|
@@ -5538,7 +5544,6 @@ export interface UserTrade {
|
|
|
5538
5544
|
export interface UserTradeParticipant {
|
|
5539
5545
|
id: UserId;
|
|
5540
5546
|
name: string;
|
|
5541
|
-
summary: string[];
|
|
5542
5547
|
}
|
|
5543
5548
|
|
|
5544
5549
|
export interface UserTradeDetailed extends UserTrade {
|
|
@@ -5587,7 +5592,7 @@ export interface TradeItemCompany {
|
|
|
5587
5592
|
details: {
|
|
5588
5593
|
id: CompanyId;
|
|
5589
5594
|
name: string;
|
|
5590
|
-
value:
|
|
5595
|
+
value: number;
|
|
5591
5596
|
};
|
|
5592
5597
|
}
|
|
5593
5598
|
|
|
@@ -12912,17 +12917,11 @@ export interface UserV2 extends BaseSchema {
|
|
|
12912
12917
|
};
|
|
12913
12918
|
trades: {
|
|
12914
12919
|
response: UserTradesResponse;
|
|
12915
|
-
params:
|
|
12916
|
-
| "striptags"
|
|
12917
|
-
| "limit"
|
|
12918
|
-
| "sort"
|
|
12919
|
-
| "to"
|
|
12920
|
-
| "from"
|
|
12921
|
-
| "timestamp";
|
|
12920
|
+
params: "cat" | "limit" | "sort" | "to" | "from" | "timestamp";
|
|
12922
12921
|
};
|
|
12923
12922
|
trade: {
|
|
12924
12923
|
response: UserTradeResponse;
|
|
12925
|
-
params: "id" | "
|
|
12924
|
+
params: "id" | "timestamp";
|
|
12926
12925
|
};
|
|
12927
12926
|
travel: {
|
|
12928
12927
|
response: UserTravelResponse;
|
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": "5.5.
|
|
6
|
+
"version": "5.5.1"
|
|
7
7
|
},
|
|
8
8
|
"servers": [
|
|
9
9
|
{
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
"api_key": []
|
|
49
49
|
}
|
|
50
50
|
],
|
|
51
|
-
"x-stability": "
|
|
51
|
+
"x-stability": "Stable"
|
|
52
52
|
}
|
|
53
53
|
},
|
|
54
54
|
"/user/attacks": {
|
|
@@ -666,7 +666,7 @@
|
|
|
666
666
|
"api_key": []
|
|
667
667
|
}
|
|
668
668
|
],
|
|
669
|
-
"x-stability": "
|
|
669
|
+
"x-stability": "Stable"
|
|
670
670
|
}
|
|
671
671
|
},
|
|
672
672
|
"/user/{id}/discord": {
|
|
@@ -714,7 +714,7 @@
|
|
|
714
714
|
"api_key": []
|
|
715
715
|
}
|
|
716
716
|
],
|
|
717
|
-
"x-stability": "
|
|
717
|
+
"x-stability": "Stable"
|
|
718
718
|
}
|
|
719
719
|
},
|
|
720
720
|
"/user/education": {
|
|
@@ -831,7 +831,7 @@
|
|
|
831
831
|
"api_key": []
|
|
832
832
|
}
|
|
833
833
|
],
|
|
834
|
-
"x-stability": "
|
|
834
|
+
"x-stability": "Stable"
|
|
835
835
|
}
|
|
836
836
|
},
|
|
837
837
|
"/user/events": {
|
|
@@ -2042,7 +2042,7 @@
|
|
|
2042
2042
|
"api_key": []
|
|
2043
2043
|
}
|
|
2044
2044
|
],
|
|
2045
|
-
"x-stability": "
|
|
2045
|
+
"x-stability": "Stable"
|
|
2046
2046
|
}
|
|
2047
2047
|
},
|
|
2048
2048
|
"/user/money": {
|
|
@@ -3107,7 +3107,7 @@
|
|
|
3107
3107
|
"api_key": []
|
|
3108
3108
|
}
|
|
3109
3109
|
],
|
|
3110
|
-
"x-stability": "
|
|
3110
|
+
"x-stability": "Stable"
|
|
3111
3111
|
}
|
|
3112
3112
|
},
|
|
3113
3113
|
"/user/trades": {
|
|
@@ -3116,11 +3116,17 @@
|
|
|
3116
3116
|
"User"
|
|
3117
3117
|
],
|
|
3118
3118
|
"summary": "Get your trades",
|
|
3119
|
-
"description": "Requires limited access key. <br>",
|
|
3119
|
+
"description": "Requires limited access key. <br> When requesting 'ongoing' trades (default), limit/offset/sort are not being used.",
|
|
3120
3120
|
"operationId": "getMyTrades",
|
|
3121
3121
|
"parameters": [
|
|
3122
3122
|
{
|
|
3123
|
-
"
|
|
3123
|
+
"name": "cat",
|
|
3124
|
+
"in": "query",
|
|
3125
|
+
"description": "Category of trades returned",
|
|
3126
|
+
"required": false,
|
|
3127
|
+
"schema": {
|
|
3128
|
+
"$ref": "#/components/schemas/TradeCategoryEnum"
|
|
3129
|
+
}
|
|
3124
3130
|
},
|
|
3125
3131
|
{
|
|
3126
3132
|
"$ref": "#/components/parameters/ApiLimit100"
|
|
@@ -3182,9 +3188,6 @@
|
|
|
3182
3188
|
"$ref": "#/components/schemas/TradeId"
|
|
3183
3189
|
}
|
|
3184
3190
|
},
|
|
3185
|
-
{
|
|
3186
|
-
"$ref": "#/components/parameters/ApiStripTagsTrue"
|
|
3187
|
-
},
|
|
3188
3191
|
{
|
|
3189
3192
|
"$ref": "#/components/parameters/ApiTimestamp"
|
|
3190
3193
|
},
|
|
@@ -3538,6 +3541,9 @@
|
|
|
3538
3541
|
},
|
|
3539
3542
|
{
|
|
3540
3543
|
"$ref": "#/components/schemas/RacingRaceTypeEnum"
|
|
3544
|
+
},
|
|
3545
|
+
{
|
|
3546
|
+
"$ref": "#/components/schemas/TradeCategoryEnum"
|
|
3541
3547
|
}
|
|
3542
3548
|
]
|
|
3543
3549
|
}
|
|
@@ -6930,7 +6936,7 @@
|
|
|
6930
6936
|
"api_key": []
|
|
6931
6937
|
}
|
|
6932
6938
|
],
|
|
6933
|
-
"x-stability": "
|
|
6939
|
+
"x-stability": "Stable"
|
|
6934
6940
|
}
|
|
6935
6941
|
},
|
|
6936
6942
|
"/market/{id}/auctionhouse": {
|
|
@@ -6990,7 +6996,7 @@
|
|
|
6990
6996
|
"api_key": []
|
|
6991
6997
|
}
|
|
6992
6998
|
],
|
|
6993
|
-
"x-stability": "
|
|
6999
|
+
"x-stability": "Stable"
|
|
6994
7000
|
}
|
|
6995
7001
|
},
|
|
6996
7002
|
"/market/auctionhouse": {
|
|
@@ -7041,7 +7047,7 @@
|
|
|
7041
7047
|
"api_key": []
|
|
7042
7048
|
}
|
|
7043
7049
|
],
|
|
7044
|
-
"x-stability": "
|
|
7050
|
+
"x-stability": "Stable"
|
|
7045
7051
|
}
|
|
7046
7052
|
},
|
|
7047
7053
|
"/market/bazaar": {
|
|
@@ -8873,7 +8879,7 @@
|
|
|
8873
8879
|
"api_key": []
|
|
8874
8880
|
}
|
|
8875
8881
|
],
|
|
8876
|
-
"x-stability": "
|
|
8882
|
+
"x-stability": "Stable"
|
|
8877
8883
|
}
|
|
8878
8884
|
},
|
|
8879
8885
|
"/torn/itemmods": {
|
|
@@ -9393,7 +9399,7 @@
|
|
|
9393
9399
|
"api_key": []
|
|
9394
9400
|
}
|
|
9395
9401
|
],
|
|
9396
|
-
"x-stability": "
|
|
9402
|
+
"x-stability": "Stable"
|
|
9397
9403
|
}
|
|
9398
9404
|
},
|
|
9399
9405
|
"/torn/{stockId}/stocks": {
|
|
@@ -9441,7 +9447,7 @@
|
|
|
9441
9447
|
"api_key": []
|
|
9442
9448
|
}
|
|
9443
9449
|
],
|
|
9444
|
-
"x-stability": "
|
|
9450
|
+
"x-stability": "Stable"
|
|
9445
9451
|
}
|
|
9446
9452
|
},
|
|
9447
9453
|
"/torn/{crimeId}/subcrimes": {
|
|
@@ -14795,6 +14801,14 @@
|
|
|
14795
14801
|
"ongoing"
|
|
14796
14802
|
]
|
|
14797
14803
|
},
|
|
14804
|
+
"TradeCategoryEnum": {
|
|
14805
|
+
"type": "string",
|
|
14806
|
+
"default": "ongoing",
|
|
14807
|
+
"enum": [
|
|
14808
|
+
"finished",
|
|
14809
|
+
"ongoing"
|
|
14810
|
+
]
|
|
14811
|
+
},
|
|
14798
14812
|
"FactionCrimeUserOutcome": {
|
|
14799
14813
|
"type": "string",
|
|
14800
14814
|
"enum": [
|
|
@@ -17191,8 +17205,7 @@
|
|
|
17191
17205
|
"UserTradeParticipant": {
|
|
17192
17206
|
"required": [
|
|
17193
17207
|
"id",
|
|
17194
|
-
"name"
|
|
17195
|
-
"summary"
|
|
17208
|
+
"name"
|
|
17196
17209
|
],
|
|
17197
17210
|
"properties": {
|
|
17198
17211
|
"id": {
|
|
@@ -17200,12 +17213,6 @@
|
|
|
17200
17213
|
},
|
|
17201
17214
|
"name": {
|
|
17202
17215
|
"type": "string"
|
|
17203
|
-
},
|
|
17204
|
-
"summary": {
|
|
17205
|
-
"type": "array",
|
|
17206
|
-
"items": {
|
|
17207
|
-
"type": "string"
|
|
17208
|
-
}
|
|
17209
17216
|
}
|
|
17210
17217
|
},
|
|
17211
17218
|
"type": "object"
|
|
@@ -17404,7 +17411,8 @@
|
|
|
17404
17411
|
"type": "string"
|
|
17405
17412
|
},
|
|
17406
17413
|
"value": {
|
|
17407
|
-
"type": "
|
|
17414
|
+
"type": "integer",
|
|
17415
|
+
"format": "int64"
|
|
17408
17416
|
}
|
|
17409
17417
|
},
|
|
17410
17418
|
"type": "object"
|