artifacts-api-client 1.3.0 → 1.5.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.
@@ -1,5 +1,5 @@
1
1
  import { ArtifactsHttpClient } from '../http-client/artifacts.http-client';
2
- import { CreateCharacterApiBody, CreateCharacterApiResult, GetAllCharactersApiQuery, GetAllCharactersApiResult, GetCharacterApiResult } from './types/api-schema-bindings.types';
2
+ import { CreateCharacterApiBody, CreateCharacterApiResult, DeleteCharacterApiBody, DeleteCharacterApiResult, GetAllCharactersApiQuery, GetAllCharactersApiResult, GetCharacterApiResult } from './types/api-schema-bindings.types';
3
3
  export declare class ArtifactsCharactersApi {
4
4
  private readonly httpClient;
5
5
  constructor(httpClient: ArtifactsHttpClient);
@@ -9,4 +9,6 @@ export declare class ArtifactsCharactersApi {
9
9
  getAll(params?: GetAllCharactersApiQuery): Promise<GetAllCharactersApiResult>;
10
10
  /** Fetch characters details. */
11
11
  get(name: string): Promise<GetCharacterApiResult>;
12
+ /** Delete character on your account. */
13
+ delete(body: DeleteCharacterApiBody): Promise<DeleteCharacterApiResult>;
12
14
  }
@@ -23,5 +23,12 @@ class ArtifactsCharactersApi {
23
23
  get(name) {
24
24
  return this.httpClient.get(`/characters/${name}`);
25
25
  }
26
+ /** Delete character on your account. */
27
+ delete(body) {
28
+ return this.httpClient.post('/characters/delete', {
29
+ body,
30
+ isSecure: true,
31
+ });
32
+ }
26
33
  }
27
34
  exports.ArtifactsCharactersApi = ArtifactsCharactersApi;
@@ -62,3 +62,5 @@ export type GetAllResourcesApiQuery = paths['/resources/']['get']['parameters'][
62
62
  export type GetAllResourcesApiResult = paths['/resources/']['get']['responses'][200]['content']['application/json'];
63
63
  export type GetResourceApiResult = paths['/resources/{code}']['get']['responses'][200]['content']['application/json'];
64
64
  export type GenerateTokenResult = paths['/token/']['post']['responses'][200]['content']['application/json'];
65
+ export type DeleteCharacterApiBody = paths['/characters/delete']['post']['requestBody']['content']['application/json'];
66
+ export type DeleteCharacterApiResult = paths['/characters/delete']['post']['responses'][200]['content']['application/json'];
@@ -463,6 +463,26 @@ export interface paths {
463
463
  patch?: never;
464
464
  trace?: never;
465
465
  };
466
+ '/characters/delete': {
467
+ parameters: {
468
+ query?: never;
469
+ header?: never;
470
+ path?: never;
471
+ cookie?: never;
472
+ };
473
+ get?: never;
474
+ put?: never;
475
+ /**
476
+ * Delete Character
477
+ * @description Delete character on your account.
478
+ */
479
+ post: operations['delete_character_characters_delete_post'];
480
+ delete?: never;
481
+ options?: never;
482
+ head?: never;
483
+ patch?: never;
484
+ trace?: never;
485
+ };
466
486
  '/characters/': {
467
487
  parameters: {
468
488
  query?: never;
@@ -938,7 +958,7 @@ export interface components {
938
958
  /** @description Cooldown details */
939
959
  cooldown: components['schemas']['CooldownSchema'];
940
960
  /** @description Destination details. */
941
- destination: components['schemas']['DestinationResponseSchema'];
961
+ destination: components['schemas']['MapSchema'];
942
962
  /** @description Character details. */
943
963
  character: components['schemas']['CharacterSchema'];
944
964
  };
@@ -1195,9 +1215,10 @@ export interface components {
1195
1215
  cooldown: number;
1196
1216
  /**
1197
1217
  * Cooldown Expiration
1218
+ * Format: date-time
1198
1219
  * @description Datetime Cooldown expiration.
1199
1220
  */
1200
- cooldown_expiration?: string | null;
1221
+ cooldown_expiration?: string;
1201
1222
  /**
1202
1223
  * Weapon Slot
1203
1224
  * @description Weapon slot.
@@ -1345,13 +1366,14 @@ export interface components {
1345
1366
  /**
1346
1367
  * Skill code
1347
1368
  * @description Skill required to craft the item.
1369
+ * @enum {string}
1348
1370
  */
1349
- skill?: ('weaponcrafting' | 'gearcrafting' | 'jewelrycrafting' | 'cooking' | 'woodcutting' | 'mining') | null;
1371
+ skill?: 'weaponcrafting' | 'gearcrafting' | 'jewelrycrafting' | 'cooking' | 'woodcutting' | 'mining';
1350
1372
  /**
1351
1373
  * Level
1352
1374
  * @description The skill level required to craft the item.
1353
1375
  */
1354
- level?: number | null;
1376
+ level?: number;
1355
1377
  /**
1356
1378
  * Items
1357
1379
  * @description List of items required to craft the item.
@@ -1361,7 +1383,7 @@ export interface components {
1361
1383
  * Quantity
1362
1384
  * @description Quantity of items crafted.
1363
1385
  */
1364
- quantity?: number | null;
1386
+ quantity?: number;
1365
1387
  };
1366
1388
  /** CraftingSchema */
1367
1389
  CraftingSchema: {
@@ -1494,6 +1516,14 @@ export interface components {
1494
1516
  /** Pages */
1495
1517
  pages?: number | null;
1496
1518
  };
1519
+ /** DeleteCharacterSchema */
1520
+ DeleteCharacterSchema: {
1521
+ /**
1522
+ * Name
1523
+ * @description Character name.
1524
+ */
1525
+ name: string;
1526
+ };
1497
1527
  /** DeleteItemResponseSchema */
1498
1528
  DeleteItemResponseSchema: {
1499
1529
  data: components['schemas']['DeleteItemSchema'];
@@ -1515,29 +1545,6 @@ export interface components {
1515
1545
  */
1516
1546
  quantity: number;
1517
1547
  };
1518
- /** DestinationResponseSchema */
1519
- DestinationResponseSchema: {
1520
- /**
1521
- * Name
1522
- * @description The name of the destination.
1523
- */
1524
- name: string;
1525
- /**
1526
- * X
1527
- * @description The x coordinate of the destination.
1528
- */
1529
- x: number;
1530
- /**
1531
- * Y
1532
- * @description The y coordinate of the destination.
1533
- */
1534
- y: number;
1535
- /**
1536
- * Content
1537
- * @description Content of the destination.
1538
- */
1539
- content: unknown;
1540
- };
1541
1548
  /** DestinationSchema */
1542
1549
  DestinationSchema: {
1543
1550
  /**
@@ -2151,13 +2158,15 @@ export interface components {
2151
2158
  * @description Server status
2152
2159
  */
2153
2160
  status: string;
2154
- /**
2155
- * Version
2156
- * @description Game version.
2157
- */
2158
- version: string;
2161
+ /** Version */
2162
+ version?: string;
2159
2163
  /** Characters Online */
2160
2164
  characters_online?: number;
2165
+ /**
2166
+ * Server Time
2167
+ * Format: date-time
2168
+ */
2169
+ server_time?: string;
2161
2170
  /** Announcements */
2162
2171
  announcements?: components['schemas']['AnnouncementSchema'][];
2163
2172
  /**
@@ -2293,7 +2302,7 @@ export interface operations {
2293
2302
  };
2294
2303
  content?: never;
2295
2304
  };
2296
- /** @description Character is locked. Action is already in progress. */
2305
+ /** @description An action is already in progress by your character. */
2297
2306
  486: {
2298
2307
  headers: {
2299
2308
  [name: string]: unknown;
@@ -2369,7 +2378,7 @@ export interface operations {
2369
2378
  };
2370
2379
  content?: never;
2371
2380
  };
2372
- /** @description Character is locked. Action is already in progress. */
2381
+ /** @description An action is already in progress by your character. */
2373
2382
  486: {
2374
2383
  headers: {
2375
2384
  [name: string]: unknown;
@@ -2438,7 +2447,7 @@ export interface operations {
2438
2447
  };
2439
2448
  content?: never;
2440
2449
  };
2441
- /** @description Character is locked. Action is already in progress. */
2450
+ /** @description An action is already in progress by your character. */
2442
2451
  486: {
2443
2452
  headers: {
2444
2453
  [name: string]: unknown;
@@ -2496,7 +2505,7 @@ export interface operations {
2496
2505
  'application/json': components['schemas']['CharacterFightResponseSchema'];
2497
2506
  };
2498
2507
  };
2499
- /** @description Character is locked. Action is already in progress. */
2508
+ /** @description An action is already in progress by your character. */
2500
2509
  486: {
2501
2510
  headers: {
2502
2511
  [name: string]: unknown;
@@ -2554,7 +2563,7 @@ export interface operations {
2554
2563
  'application/json': components['schemas']['SkillResponseSchema'];
2555
2564
  };
2556
2565
  };
2557
- /** @description Character is locked. Action is already in progress. */
2566
+ /** @description An action is already in progress by your character. */
2558
2567
  486: {
2559
2568
  headers: {
2560
2569
  [name: string]: unknown;
@@ -2637,7 +2646,7 @@ export interface operations {
2637
2646
  };
2638
2647
  content?: never;
2639
2648
  };
2640
- /** @description Character is locked. Action is already in progress. */
2649
+ /** @description An action is already in progress by your character. */
2641
2650
  486: {
2642
2651
  headers: {
2643
2652
  [name: string]: unknown;
@@ -2713,6 +2722,13 @@ export interface operations {
2713
2722
  };
2714
2723
  content?: never;
2715
2724
  };
2725
+ /** @description A transaction is already in progress with this item/your golds in your bank. */
2726
+ 461: {
2727
+ headers: {
2728
+ [name: string]: unknown;
2729
+ };
2730
+ content?: never;
2731
+ };
2716
2732
  /** @description Missing item or insufficient quantity in your inventory. */
2717
2733
  478: {
2718
2734
  headers: {
@@ -2720,7 +2736,7 @@ export interface operations {
2720
2736
  };
2721
2737
  content?: never;
2722
2738
  };
2723
- /** @description Character is locked. Action is already in progress. */
2739
+ /** @description An action is already in progress by your character. */
2724
2740
  486: {
2725
2741
  headers: {
2726
2742
  [name: string]: unknown;
@@ -2775,6 +2791,13 @@ export interface operations {
2775
2791
  'application/json': components['schemas']['GoldResponseSchema'];
2776
2792
  };
2777
2793
  };
2794
+ /** @description A transaction is already in progress with this item/your golds in your bank. */
2795
+ 461: {
2796
+ headers: {
2797
+ [name: string]: unknown;
2798
+ };
2799
+ content?: never;
2800
+ };
2778
2801
  /** @description Missing item or insufficient quantity in your inventory. */
2779
2802
  478: {
2780
2803
  headers: {
@@ -2782,7 +2805,7 @@ export interface operations {
2782
2805
  };
2783
2806
  content?: never;
2784
2807
  };
2785
- /** @description Character is locked. Action is already in progress. */
2808
+ /** @description An action is already in progress by your character. */
2786
2809
  486: {
2787
2810
  headers: {
2788
2811
  [name: string]: unknown;
@@ -2865,7 +2888,7 @@ export interface operations {
2865
2888
  };
2866
2889
  content?: never;
2867
2890
  };
2868
- /** @description Character is locked. Action is already in progress. */
2891
+ /** @description An action is already in progress by your character. */
2869
2892
  486: {
2870
2893
  headers: {
2871
2894
  [name: string]: unknown;
@@ -2941,6 +2964,13 @@ export interface operations {
2941
2964
  };
2942
2965
  content?: never;
2943
2966
  };
2967
+ /** @description A transaction is already in progress with this item/your golds in your bank. */
2968
+ 461: {
2969
+ headers: {
2970
+ [name: string]: unknown;
2971
+ };
2972
+ content?: never;
2973
+ };
2944
2974
  /** @description Missing item or insufficient quantity in your inventory. */
2945
2975
  478: {
2946
2976
  headers: {
@@ -2948,7 +2978,7 @@ export interface operations {
2948
2978
  };
2949
2979
  content?: never;
2950
2980
  };
2951
- /** @description Character is locked. Action is already in progress. */
2981
+ /** @description An action is already in progress by your character. */
2952
2982
  486: {
2953
2983
  headers: {
2954
2984
  [name: string]: unknown;
@@ -3017,7 +3047,14 @@ export interface operations {
3017
3047
  };
3018
3048
  content?: never;
3019
3049
  };
3020
- /** @description Character is locked. Action is already in progress. */
3050
+ /** @description A transaction is already in progress with this item/your golds in your bank. */
3051
+ 461: {
3052
+ headers: {
3053
+ [name: string]: unknown;
3054
+ };
3055
+ content?: never;
3056
+ };
3057
+ /** @description An action is already in progress by your character. */
3021
3058
  486: {
3022
3059
  headers: {
3023
3060
  [name: string]: unknown;
@@ -3086,7 +3123,14 @@ export interface operations {
3086
3123
  };
3087
3124
  content?: never;
3088
3125
  };
3089
- /** @description Character is locked. Action is already in progress. */
3126
+ /** @description A transaction is already in progress on this item by a another character. */
3127
+ 483: {
3128
+ headers: {
3129
+ [name: string]: unknown;
3130
+ };
3131
+ content?: never;
3132
+ };
3133
+ /** @description An action is already in progress by your character. */
3090
3134
  486: {
3091
3135
  headers: {
3092
3136
  [name: string]: unknown;
@@ -3176,7 +3220,14 @@ export interface operations {
3176
3220
  };
3177
3221
  content?: never;
3178
3222
  };
3179
- /** @description Character is locked. Action is already in progress. */
3223
+ /** @description A transaction is already in progress on this item by a another character. */
3224
+ 483: {
3225
+ headers: {
3226
+ [name: string]: unknown;
3227
+ };
3228
+ content?: never;
3229
+ };
3230
+ /** @description An action is already in progress by your character. */
3180
3231
  486: {
3181
3232
  headers: {
3182
3233
  [name: string]: unknown;
@@ -3227,7 +3278,7 @@ export interface operations {
3227
3278
  'application/json': components['schemas']['TaskResponseSchema'];
3228
3279
  };
3229
3280
  };
3230
- /** @description Character is locked. Action is already in progress. */
3281
+ /** @description An action is already in progress by your character. */
3231
3282
  486: {
3232
3283
  headers: {
3233
3284
  [name: string]: unknown;
@@ -3285,7 +3336,7 @@ export interface operations {
3285
3336
  'application/json': components['schemas']['TaskRewardResponseSchema'];
3286
3337
  };
3287
3338
  };
3288
- /** @description Character is locked. Action is already in progress. */
3339
+ /** @description An action is already in progress by your character. */
3289
3340
  486: {
3290
3341
  headers: {
3291
3342
  [name: string]: unknown;
@@ -3364,7 +3415,7 @@ export interface operations {
3364
3415
  };
3365
3416
  content?: never;
3366
3417
  };
3367
- /** @description Character is locked. Action is already in progress. */
3418
+ /** @description An action is already in progress by your character. */
3368
3419
  486: {
3369
3420
  headers: {
3370
3421
  [name: string]: unknown;
@@ -3433,7 +3484,7 @@ export interface operations {
3433
3484
  };
3434
3485
  content?: never;
3435
3486
  };
3436
- /** @description Character is locked. Action is already in progress. */
3487
+ /** @description An action is already in progress by your character. */
3437
3488
  486: {
3438
3489
  headers: {
3439
3490
  [name: string]: unknown;
@@ -3645,6 +3696,37 @@ export interface operations {
3645
3696
  };
3646
3697
  };
3647
3698
  };
3699
+ delete_character_characters_delete_post: {
3700
+ parameters: {
3701
+ query?: never;
3702
+ header?: never;
3703
+ path?: never;
3704
+ cookie?: never;
3705
+ };
3706
+ requestBody: {
3707
+ content: {
3708
+ 'application/json': components['schemas']['DeleteCharacterSchema'];
3709
+ };
3710
+ };
3711
+ responses: {
3712
+ /** @description Successfully deleted character. */
3713
+ 200: {
3714
+ headers: {
3715
+ [name: string]: unknown;
3716
+ };
3717
+ content: {
3718
+ 'application/json': components['schemas']['CharacterResponseSchema'];
3719
+ };
3720
+ };
3721
+ /** @description Character not found. */
3722
+ 498: {
3723
+ headers: {
3724
+ [name: string]: unknown;
3725
+ };
3726
+ content?: never;
3727
+ };
3728
+ };
3729
+ };
3648
3730
  get_all_characters_characters__get: {
3649
3731
  parameters: {
3650
3732
  query?: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "artifacts-api-client",
3
- "version": "1.3.0",
3
+ "version": "1.5.0",
4
4
  "description": "Api client for https://artifactsmmo.com",
5
5
  "main": "dist/index.js",
6
6
  "repository": "https://github.com/siranweb/artifacts-api-client.git",