tornapi-typescript 3.0.8 → 3.0.9

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
@@ -472,6 +472,11 @@ export interface UserPropertyDetailsExtendedRented extends UserPropertyBasicDeta
472
472
  rental_period: number;
473
473
  rental_period_remaining: number;
474
474
  rented_by: BasicUser;
475
+ lease_extension: {
476
+ cost: number;
477
+ period: number;
478
+ created_at: number;
479
+ } | null;
475
480
  }
476
481
  export interface UserPropertyDetailsExtendedForRent extends UserPropertyBasicDetails {
477
482
  used_by: BasicUser[];
@@ -6149,7 +6154,7 @@ export interface UserV2 extends BaseSchema {
6149
6154
  };
6150
6155
  properties: {
6151
6156
  response: UserPropertiesResponse;
6152
- params: "offset" | "limit" | "timestamp";
6157
+ params: "filters" | "offset" | "limit" | "timestamp";
6153
6158
  };
6154
6159
  property: {
6155
6160
  response: UserPropertyResponse;
@@ -6341,7 +6346,7 @@ export interface ForumV2 extends BaseSchema {
6341
6346
  };
6342
6347
  posts: {
6343
6348
  response: ForumPostsResponse;
6344
- params: "offset" | "striptags" | "threadId" | "timestamp";
6349
+ params: "striptags" | "offset" | "sort" | "from" | "to" | "threadId" | "timestamp";
6345
6350
  };
6346
6351
  thread: {
6347
6352
  response: ForumThreadResponse;
package/dist/index.ts CHANGED
@@ -5266,6 +5266,11 @@ export interface UserPropertyDetailsExtendedRented
5266
5266
  rental_period: number;
5267
5267
  rental_period_remaining: number;
5268
5268
  rented_by: BasicUser;
5269
+ lease_extension: {
5270
+ cost: number;
5271
+ period: number;
5272
+ created_at: number;
5273
+ } | null;
5269
5274
  }
5270
5275
 
5271
5276
  export interface UserPropertyDetailsExtendedForRent
@@ -11648,7 +11653,7 @@ export interface UserV2 extends BaseSchema {
11648
11653
  };
11649
11654
  properties: {
11650
11655
  response: UserPropertiesResponse;
11651
- params: "offset" | "limit" | "timestamp";
11656
+ params: "filters" | "offset" | "limit" | "timestamp";
11652
11657
  };
11653
11658
  property: {
11654
11659
  response: UserPropertyResponse;
@@ -11882,7 +11887,14 @@ export interface ForumV2 extends BaseSchema {
11882
11887
  };
11883
11888
  posts: {
11884
11889
  response: ForumPostsResponse;
11885
- params: "offset" | "striptags" | "threadId" | "timestamp";
11890
+ params:
11891
+ | "striptags"
11892
+ | "offset"
11893
+ | "sort"
11894
+ | "from"
11895
+ | "to"
11896
+ | "threadId"
11897
+ | "timestamp";
11886
11898
  };
11887
11899
  thread: {
11888
11900
  response: ForumThreadResponse;
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": "3.0.8"
6
+ "version": "3.0.9"
7
7
  },
8
8
  "servers": [
9
9
  {
@@ -1458,6 +1458,9 @@
1458
1458
  "description": "Requires public access key. <br>Extended responses are available when requesting the data with Limited or higher access keys.",
1459
1459
  "operationId": "574a416ca46717830f03a2f685955b87",
1460
1460
  "parameters": [
1461
+ {
1462
+ "$ref": "#/components/parameters/ApiFiltersUserProperties"
1463
+ },
1461
1464
  {
1462
1465
  "$ref": "#/components/parameters/ApiOffset"
1463
1466
  },
@@ -1512,6 +1515,9 @@
1512
1515
  "$ref": "#/components/schemas/UserId"
1513
1516
  }
1514
1517
  },
1518
+ {
1519
+ "$ref": "#/components/parameters/ApiFiltersUserProperties"
1520
+ },
1515
1521
  {
1516
1522
  "$ref": "#/components/parameters/ApiOffset"
1517
1523
  },
@@ -2158,7 +2164,7 @@
2158
2164
  }
2159
2165
  },
2160
2166
  {
2161
- "$ref": "#/components/parameters/ApiFiltersIncomingOutgoing"
2167
+ "$ref": "#/components/parameters/ApiFiltersUser"
2162
2168
  },
2163
2169
  {
2164
2170
  "$ref": "#/components/parameters/ApiStripTags"
@@ -4796,14 +4802,23 @@
4796
4802
  "Forum"
4797
4803
  ],
4798
4804
  "summary": "Get specific forum thread posts",
4799
- "description": "Requires public access key. <br>Returns 20 posts per page for a specific thread.",
4805
+ "description": "Requires public access key. <br>Returns 20 posts per page for a specific thread. <br> By default, it uses 'offset', but it's possible to filter posts with 'from' & 'to' parameters.",
4800
4806
  "operationId": "9c5eeb1aebb102b7c62fab11974c359a",
4801
4807
  "parameters": [
4808
+ {
4809
+ "$ref": "#/components/parameters/ApiStripTagsTrue"
4810
+ },
4802
4811
  {
4803
4812
  "$ref": "#/components/parameters/ApiOffsetNoDefault"
4804
4813
  },
4805
4814
  {
4806
- "$ref": "#/components/parameters/ApiStripTagsTrue"
4815
+ "$ref": "#/components/parameters/ApiSort"
4816
+ },
4817
+ {
4818
+ "$ref": "#/components/parameters/ApiFrom"
4819
+ },
4820
+ {
4821
+ "$ref": "#/components/parameters/ApiTo"
4807
4822
  },
4808
4823
  {
4809
4824
  "name": "threadId",
@@ -14493,7 +14508,8 @@
14493
14508
  "cost",
14494
14509
  "cost_per_day",
14495
14510
  "rental_period",
14496
- "rental_period_remaining"
14511
+ "rental_period_remaining",
14512
+ "lease_extension"
14497
14513
  ],
14498
14514
  "properties": {
14499
14515
  "used_by": {
@@ -14526,6 +14542,35 @@
14526
14542
  },
14527
14543
  "rented_by": {
14528
14544
  "$ref": "#/components/schemas/BasicUser"
14545
+ },
14546
+ "lease_extension": {
14547
+ "oneOf": [
14548
+ {
14549
+ "required": [
14550
+ "cost",
14551
+ "period",
14552
+ "created_at"
14553
+ ],
14554
+ "properties": {
14555
+ "cost": {
14556
+ "type": "integer",
14557
+ "format": "int64"
14558
+ },
14559
+ "period": {
14560
+ "type": "integer",
14561
+ "format": "int32"
14562
+ },
14563
+ "created_at": {
14564
+ "type": "integer",
14565
+ "format": "int32"
14566
+ }
14567
+ },
14568
+ "type": "object"
14569
+ },
14570
+ {
14571
+ "type": "null"
14572
+ }
14573
+ ]
14529
14574
  }
14530
14575
  },
14531
14576
  "type": "object"
@@ -26227,6 +26272,34 @@
26227
26272
  ]
26228
26273
  }
26229
26274
  },
26275
+ "ApiFiltersUser": {
26276
+ "name": "filters",
26277
+ "in": "query",
26278
+ "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.",
26279
+ "required": false,
26280
+ "schema": {
26281
+ "type": "string",
26282
+ "enum": [
26283
+ "incoming",
26284
+ "outgoing",
26285
+ "ownedByUser",
26286
+ "ownedBySpouse"
26287
+ ]
26288
+ }
26289
+ },
26290
+ "ApiFiltersUserProperties": {
26291
+ "name": "filters",
26292
+ "in": "query",
26293
+ "description": "It's possible to use this query parameter to filter properties by the key owner or their spouse.",
26294
+ "required": false,
26295
+ "schema": {
26296
+ "type": "string",
26297
+ "enum": [
26298
+ "ownedByUser",
26299
+ "ownedBySpouse"
26300
+ ]
26301
+ }
26302
+ },
26230
26303
  "ApiFactionSearchFilter": {
26231
26304
  "name": "filters",
26232
26305
  "in": "query",
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "tornapi-typescript",
3
3
  "type": "module",
4
- "version": "3.0.8",
4
+ "version": "3.0.9",
5
5
  "scripts": {
6
6
  "generate-types": "tsc && node build/index.js"
7
7
  },