maplestory-openapi 2.3.2 → 2.4.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.
Files changed (37) hide show
  1. package/README.md +11 -9
  2. package/dist/index.js +1474 -1249
  3. package/dist/index.min.js +1 -1
  4. package/dist/index.mjs +1467 -1250
  5. package/package.json +1 -1
  6. package/types/index.d.ts +8 -0
  7. package/types/maplestory/api/dto/character/characterAbilityDto.d.ts +17 -0
  8. package/types/maplestory/api/dto/character/characterAbilityInfoDto.d.ts +9 -0
  9. package/types/maplestory/api/dto/character/characterAbilityPresetDto.d.ts +17 -0
  10. package/types/maplestory/api/dto/character/characterAndroidEquipmentDto.d.ts +33 -0
  11. package/types/maplestory/api/dto/character/characterAndroidEquipmentPresetDto.d.ts +58 -0
  12. package/types/maplestory/api/dto/character/characterCashItemEquipmentDto.d.ts +14 -6
  13. package/types/maplestory/api/dto/character/characterCashItemEquipmentPresetDto.d.ts +2 -2
  14. package/types/maplestory/api/dto/character/characterItemEquipmentDto.d.ts +19 -3
  15. package/types/maplestory/api/dto/character/characterLinkSkillDto.d.ts +25 -1
  16. package/types/maplestory/api/dto/character/characterPetEquipmentDto.d.ts +51 -21
  17. package/types/maplestory/api/dto/character/characterPetEquipmentItemDto.d.ts +9 -1
  18. package/types/maplestory/api/dto/history/cubeHistoryDto.d.ts +1 -1
  19. package/types/maplestory/api/dto/history/cubeResultOptionDto.d.ts +1 -1
  20. package/types/maplestory/api/dto/history/potentialHistoryDto.d.ts +82 -0
  21. package/types/maplestory/api/dto/history/potentialHistoryResponseDto.d.ts +21 -0
  22. package/types/maplestory/api/dto/history/potentialResultOptionDto.d.ts +18 -0
  23. package/types/maplestory/api/dto/union/unionArtifactCrystalDto.d.ts +36 -0
  24. package/types/maplestory/api/dto/union/unionArtifactDto.d.ts +26 -0
  25. package/types/maplestory/api/dto/union/unionArtifactEffectDto.d.ts +16 -0
  26. package/types/maplestory/api/dto/union/unionDto.d.ts +12 -0
  27. package/types/maplestory/api/mapleStoryApi.d.ts +55 -12
  28. package/types/maplestory/api/mapleStoryApiError.d.ts +3 -1
  29. package/types/maplestory/api/response/character/characterAbilityDtoBody.d.ts +9 -1
  30. package/types/maplestory/api/response/character/characterAndroidEquipmentDtoBody.d.ts +23 -1
  31. package/types/maplestory/api/response/character/characterCashItemEquipmentDtoBody.d.ts +3 -1
  32. package/types/maplestory/api/response/character/characterItemEquipmentDtoBody.d.ts +4 -0
  33. package/types/maplestory/api/response/character/characterLinkSkillDtoBody.d.ts +7 -1
  34. package/types/maplestory/api/response/character/characterPetEquipmentDtoBody.d.ts +30 -22
  35. package/types/maplestory/api/response/history/potentialHistoryResponseDtoBody.d.ts +29 -0
  36. package/types/maplestory/api/response/union/unionArtifactDtoBody.d.ts +20 -0
  37. package/types/maplestory/api/response/union/unionDtoBody.d.ts +3 -0
package/dist/index.mjs CHANGED
@@ -21,80 +21,45 @@ var utc$1 = {exports: {}};
21
21
  var utc = utc$1.exports;
22
22
 
23
23
  /**
24
- * 업적 랭킹 정보
24
+ * 캐릭터 어빌리티 상세 정보
25
25
  */
26
- class AchievementRankingDto {
27
- /**
28
- * 랭킹 업데이트 일자 (KST, 일 단위 데이터로 시, 분은 일괄 0으로 표기)
29
- */
30
- date;
31
- /**
32
- * 업적 랭킹 순위
33
- */
34
- ranking;
35
- /**
36
- * 캐릭터 명
37
- */
38
- characterName;
39
- /**
40
- * 월드 명
41
- */
42
- worldName;
43
- /**
44
- * 직업 명
45
- */
46
- className;
26
+ class CharacterAbilityInfoDto {
47
27
  /**
48
- * 전직 직업 명
28
+ * 어빌리티 번호
49
29
  */
50
- subClassName;
30
+ abilityNo;
51
31
  /**
52
- * 업적 등급
32
+ * 어빌리티 등급
53
33
  */
54
- trophyGrade;
34
+ abilityGrade;
55
35
  /**
56
- * 업적 점수
36
+ * 어빌리티 옵션 및 수치
57
37
  */
58
- trophyScore;
38
+ abilityValue;
59
39
  constructor(obj) {
60
- const { date, ranking, character_name, world_name, class_name, sub_class_name, trophy_grade, trophy_score, } = obj;
61
- this.date = new Date(date);
62
- this.ranking = ranking;
63
- this.characterName = character_name;
64
- this.worldName = world_name;
65
- this.className = class_name;
66
- this.subClassName = sub_class_name;
67
- this.trophyGrade = trophy_grade;
68
- this.trophyScore = trophy_score;
40
+ const { ability_no, ability_grade, ability_value } = obj;
41
+ this.abilityNo = ability_no;
42
+ this.abilityGrade = ability_grade;
43
+ this.abilityValue = ability_value;
69
44
  }
70
45
  }
71
46
 
72
47
  /**
73
- * 업적 랭킹 응답 정보
48
+ * 캐릭터 어빌리티 프리셋 정보
74
49
  */
75
- class AchievementRankingResponseDto {
50
+ class CharacterAbilityPresetDto {
76
51
  /**
77
- * 업적 랭킹 정보
52
+ * 프리셋의 어빌리티 등급
78
53
  */
79
- ranking;
80
- constructor(obj) {
81
- const { ranking } = obj;
82
- this.ranking = ranking.map((rank) => new AchievementRankingDto(rank));
83
- }
84
- }
85
-
86
- /**
87
- * 캐릭터 어빌리티 상세 정보
88
- */
89
- class CharacterAbilityInfoDto {
90
- abilityNo;
91
- abilityGrade;
92
- abilityValue;
54
+ abilityPresetGrade;
55
+ /**
56
+ * 프리셋의 어빌리티 정보
57
+ */
58
+ abilityInfo;
93
59
  constructor(obj) {
94
- const { ability_no, ability_grade, ability_value } = obj;
95
- this.abilityNo = ability_no;
96
- this.abilityGrade = ability_grade;
97
- this.abilityValue = ability_value;
60
+ const { ability_preset_grade, ability_info } = obj;
61
+ this.abilityPresetGrade = ability_preset_grade;
62
+ this.abilityInfo = ability_info.map((info) => new CharacterAbilityInfoDto(info));
98
63
  }
99
64
  }
100
65
 
@@ -118,13 +83,39 @@ class CharacterAbilityDto {
118
83
  * 보유 명성치
119
84
  */
120
85
  remainFame;
86
+ /**
87
+ * 적용 중인 어빌리티 프리셋 번호
88
+ */
89
+ presetNo;
90
+ /**
91
+ * 어빌리티 1번 프리셋 전체 정보
92
+ */
93
+ abilityPreset1;
94
+ /**
95
+ * 어빌리티 2번 프리셋 전체 정보
96
+ */
97
+ abilityPreset2;
98
+ /**
99
+ * 어빌리티 3번 프리셋 전체 정보
100
+ */
101
+ abilityPreset3;
121
102
  constructor(obj) {
122
- const { date, ability_grade, ability_info, remain_fame } = obj;
103
+ const { date, ability_grade, ability_info, remain_fame, preset_no, ability_preset_1, ability_preset_2, ability_preset_3, } = obj;
123
104
  // 날짜는 Date 객체로 변환
124
105
  this.date = new Date(date);
125
106
  this.abilityGrade = ability_grade;
126
107
  this.abilityInfo = ability_info.map((info) => new CharacterAbilityInfoDto(info));
127
108
  this.remainFame = remain_fame;
109
+ this.presetNo = preset_no;
110
+ this.abilityPreset1 = ability_preset_1
111
+ ? new CharacterAbilityPresetDto(ability_preset_1)
112
+ : null;
113
+ this.abilityPreset2 = ability_preset_2
114
+ ? new CharacterAbilityPresetDto(ability_preset_2)
115
+ : null;
116
+ this.abilityPreset3 = ability_preset_3
117
+ ? new CharacterAbilityPresetDto(ability_preset_3)
118
+ : null;
128
119
  }
129
120
  }
130
121
 
@@ -297,6 +288,75 @@ class CharacterAndroidEquipmentHairDto {
297
288
  }
298
289
  }
299
290
 
291
+ /**
292
+ * 캐릭터 안드로이드 프리셋 정보
293
+ */
294
+ class CharacterAndroidEquipmentPresetDto {
295
+ /**
296
+ * 안드로이드 명
297
+ */
298
+ androidName;
299
+ /**
300
+ * 안드로이드 닉네임
301
+ */
302
+ androidNickname;
303
+ /**
304
+ * 안드로이드 아이콘
305
+ */
306
+ androidIcon;
307
+ /**
308
+ * 안드로이드 아이템 설명
309
+ */
310
+ androidDescription;
311
+ /**
312
+ * 안드로이드 성별
313
+ */
314
+ androidGender;
315
+ /**
316
+ * 안드로이드 등급
317
+ */
318
+ androidGrade;
319
+ /**
320
+ * 안드로이드 피부 명
321
+ */
322
+ androidSkinName;
323
+ /**
324
+ * 안드로이드 헤어 정보
325
+ */
326
+ androidHair;
327
+ /**
328
+ * 안드로이드 성형 정보
329
+ */
330
+ androidFace;
331
+ /**
332
+ * 안드로이드 이어센서 클립 적용 여부
333
+ */
334
+ androidEarSensorClipFlag;
335
+ /**
336
+ * 비인간형 안드로이드 여부
337
+ */
338
+ androidNonHumanoidFlag;
339
+ /**
340
+ * 잡화상점 기능 이용 가능 여부
341
+ */
342
+ androidShopUsableFlag;
343
+ constructor(obj) {
344
+ const { android_name, android_nickname, android_icon, android_description, android_gender, android_grade, android_skin_name, android_hair, android_face, android_ear_sensor_clip_flag, android_non_humanoid_flag, android_shop_usable_flag, } = obj;
345
+ this.androidName = android_name;
346
+ this.androidNickname = android_nickname;
347
+ this.androidIcon = android_icon;
348
+ this.androidDescription = android_description;
349
+ this.androidGender = android_gender;
350
+ this.androidGrade = android_grade;
351
+ this.androidSkinName = android_skin_name;
352
+ this.androidHair = new CharacterAndroidEquipmentHairDto(android_hair);
353
+ this.androidFace = new CharacterAndroidEquipmentFaceDto(android_face);
354
+ this.androidEarSensorClipFlag = android_ear_sensor_clip_flag;
355
+ this.androidNonHumanoidFlag = android_non_humanoid_flag;
356
+ this.androidShopUsableFlag = android_shop_usable_flag;
357
+ }
358
+ }
359
+
300
360
  /**
301
361
  * 캐릭터 안드로이드 장비 정보
302
362
  */
@@ -341,8 +401,40 @@ class CharacterAndroidEquipmentDto {
341
401
  * 안드로이드 이어센서 클립 적용 여부
342
402
  */
343
403
  androidEarSensorClipFlag;
404
+ /**
405
+ * 안드로이드 성별
406
+ */
407
+ androidGender;
408
+ /**
409
+ * 안드로이드 등급
410
+ */
411
+ androidGrade;
412
+ /**
413
+ * 비인간형 안드로이드 여부
414
+ */
415
+ androidNonHumanoidFlag;
416
+ /**
417
+ * 잡화상점 기능 이용 가능 여부
418
+ */
419
+ androidShopUsableFlag;
420
+ /**
421
+ * 적용 중인 장비 프리셋 번호
422
+ */
423
+ presetNo;
424
+ /**
425
+ * 1번 프리셋 안드로이드 정보
426
+ */
427
+ androidPreset1;
428
+ /**
429
+ * 2번 프리셋 안드로이드 정보
430
+ */
431
+ androidPreset2;
432
+ /**
433
+ * 3번 프리셋 안드로이드 정보
434
+ */
435
+ androidPreset3;
344
436
  constructor(obj) {
345
- const { date, android_name, android_nickname, android_icon, android_description, android_hair, android_face, android_skin_name, android_cash_item_equipment, android_ear_sensor_clip_flag, } = obj;
437
+ const { date, android_name, android_nickname, android_icon, android_description, android_hair, android_face, android_skin_name, android_cash_item_equipment, android_ear_sensor_clip_flag, android_gender, android_grade, android_non_humanoid_flag, android_shop_usable_flag, preset_no, android_preset_1, android_preset_2, android_preset_3, } = obj;
346
438
  this.date = new Date(date);
347
439
  this.androidName = android_name;
348
440
  this.androidNickname = android_nickname;
@@ -353,6 +445,14 @@ class CharacterAndroidEquipmentDto {
353
445
  this.androidSkinName = android_skin_name;
354
446
  this.androidCashItemEquipment = android_cash_item_equipment.map((equipment) => new CharacterAndroidCashItemEquipmentDto(equipment));
355
447
  this.androidEarSensorClipFlag = android_ear_sensor_clip_flag ?? null;
448
+ this.androidGender = android_gender;
449
+ this.androidGrade = android_grade;
450
+ this.androidNonHumanoidFlag = android_non_humanoid_flag;
451
+ this.androidShopUsableFlag = android_shop_usable_flag;
452
+ this.presetNo = preset_no;
453
+ this.androidPreset1 = android_preset_1 ? new CharacterAndroidEquipmentPresetDto(android_preset_1) : null;
454
+ this.androidPreset2 = android_preset_2 ? new CharacterAndroidEquipmentPresetDto(android_preset_2) : null;
455
+ this.androidPreset3 = android_preset_3 ? new CharacterAndroidEquipmentPresetDto(android_preset_3) : null;
356
456
  }
357
457
  }
358
458
 
@@ -629,11 +729,11 @@ class CharacterCashItemEquipmentPresetDto {
629
729
  */
630
730
  cashItemColoringPrism;
631
731
  /**
632
- * 다른 프리셋에서 장비 추가 장착 없이 1번 프리셋의 장비 공유를 비활성화 했는지 여부
732
+ * 아이템 장착 가능 성별
633
733
  */
634
- basePresetItemDisableFlag;
734
+ itemGender;
635
735
  constructor(obj) {
636
- const { cash_item_equipment_part, cash_item_equipment_slot, cash_item_name, cash_item_icon, cash_item_description, cash_item_option, date_expire, date_option_expire, cash_item_label, cash_item_coloring_prism, base_preset_item_disable_flag, } = obj;
736
+ const { cash_item_equipment_part, cash_item_equipment_slot, cash_item_name, cash_item_icon, cash_item_description, cash_item_option, date_expire, date_option_expire, cash_item_label, cash_item_coloring_prism, item_gender, } = obj;
637
737
  this.cashItemEquipmentPart = cash_item_equipment_part;
638
738
  this.cashItemEquipmentSlot = cash_item_equipment_slot;
639
739
  this.cashItemName = cash_item_name;
@@ -646,7 +746,7 @@ class CharacterCashItemEquipmentPresetDto {
646
746
  this.cashItemColoringPrism = cash_item_coloring_prism
647
747
  ? new CharacterCashItemEquipmentColoringPrismDto(cash_item_coloring_prism)
648
748
  : null;
649
- this.basePresetItemDisableFlag = base_preset_item_disable_flag;
749
+ this.itemGender = item_gender;
650
750
  }
651
751
  }
652
752
 
@@ -671,37 +771,49 @@ class CharacterCashItemEquipmentDto {
671
771
  */
672
772
  presetNo;
673
773
  /**
674
- * 1번 프리셋 장착 캐시 장비 정보
774
+ * 장착 중인 캐시 장비
775
+ */
776
+ cashItemEquipmentBase;
777
+ /**
778
+ * 1번 코디 프리셋
675
779
  */
676
780
  cashItemEquipmentPreset1;
677
781
  /**
678
- * 2번 프리셋 장착 캐시 장비 정보
782
+ * 2번 코디 프리셋
679
783
  */
680
784
  cashItemEquipmentPreset2;
681
785
  /**
682
- * 3번 프리셋 장착 캐시 장비 정보
786
+ * 3번 코디 프리셋
683
787
  */
684
788
  cashItemEquipmentPreset3;
685
789
  /**
686
- * 제로인 경우 베타, 엔젤릭버스터인 경우 드레스 업 모드의 1번 프리셋 장착 캐시 장비 정보
790
+ * 제로인 경우 베타, 엔젤릭버스터인 경우 드레스 업 모드에서 장착 중인 캐시 장비
791
+ */
792
+ additionalCashItemEquipmentBase;
793
+ /**
794
+ * 제로인 경우 베타, 엔젤릭버스터인 경우 드레스 업 모드의 1번 코디 프리셋
687
795
  */
688
796
  additionalCashItemEquipmentPreset1;
689
797
  /**
690
- * 제로인 경우 베타, 엔젤릭버스터인 경우 드레스 업 모드의 2번 프리셋 장착 캐시 장비 정보
798
+ * 제로인 경우 베타, 엔젤릭버스터인 경우 드레스 업 모드의 2번 코디 프리셋
691
799
  */
692
800
  additionalCashItemEquipmentPreset2;
693
801
  /**
694
- * 제로인 경우 베타, 엔젤릭버스터인 경우 드레스 업 모드의 3번 프리셋 장착 캐시 장비 정보
802
+ * 제로인 경우 베타, 엔젤릭버스터인 경우 드레스 업 모드의 3번 코디 프리셋
695
803
  */
696
804
  additionalCashItemEquipmentPreset3;
697
805
  constructor(obj) {
698
- const { date, character_gender, character_class, preset_no, cash_item_equipment_preset_1, cash_item_equipment_preset_2, cash_item_equipment_preset_3, additional_cash_item_equipment_preset_1, additional_cash_item_equipment_preset_2, additional_cash_item_equipment_preset_3, } = obj;
699
- (this.date = new Date(date)), (this.characterGender = character_gender);
806
+ const { date, character_gender, character_class, preset_no, cash_item_equipment_base, cash_item_equipment_preset_1, cash_item_equipment_preset_2, cash_item_equipment_preset_3, additional_cash_item_equipment_base, additional_cash_item_equipment_preset_1, additional_cash_item_equipment_preset_2, additional_cash_item_equipment_preset_3, } = obj;
807
+ this.date = new Date(date);
808
+ this.characterGender = character_gender;
700
809
  this.characterClass = character_class;
701
810
  this.presetNo = preset_no;
811
+ this.cashItemEquipmentBase = cash_item_equipment_base.map((preset) => new CharacterCashItemEquipmentPresetDto(preset));
702
812
  this.cashItemEquipmentPreset1 = cash_item_equipment_preset_1.map((preset) => new CharacterCashItemEquipmentPresetDto(preset));
703
813
  this.cashItemEquipmentPreset2 = cash_item_equipment_preset_2.map((preset) => new CharacterCashItemEquipmentPresetDto(preset));
704
814
  this.cashItemEquipmentPreset3 = cash_item_equipment_preset_3.map((preset) => new CharacterCashItemEquipmentPresetDto(preset));
815
+ this.additionalCashItemEquipmentBase =
816
+ additional_cash_item_equipment_base.map((preset) => new CharacterCashItemEquipmentPresetDto(preset));
705
817
  this.additionalCashItemEquipmentPreset1 =
706
818
  additional_cash_item_equipment_preset_1.map((preset) => new CharacterCashItemEquipmentPresetDto(preset));
707
819
  this.additionalCashItemEquipmentPreset2 =
@@ -1449,9 +1561,9 @@ class CharacterItemEquipmentTotalOptionDto {
1449
1561
  }
1450
1562
 
1451
1563
  /**
1452
- * 캐릭터 장비 아이템 상세 정보
1564
+ * 에반 드래곤 장비 정보
1453
1565
  */
1454
- class CharacterItemEquipmentInfoDto {
1566
+ class CharacterItemEquipmentDragonInfoDto {
1455
1567
  /**
1456
1568
  * 장비 부위 명
1457
1569
  */
@@ -1492,38 +1604,6 @@ class CharacterItemEquipmentInfoDto {
1492
1604
  * 장비 기본 옵션
1493
1605
  */
1494
1606
  itemBaseOption;
1495
- /**
1496
- * 잠재능력 등급
1497
- */
1498
- potentialOptionGrade;
1499
- /**
1500
- * 에디셔널 잠재능력 등급
1501
- */
1502
- additionalPotentialOptionGrade;
1503
- /**
1504
- * 잠재능력 첫 번째 옵션
1505
- */
1506
- potentialOption1;
1507
- /**
1508
- * 잠재능력 두 번째 옵션
1509
- */
1510
- potentialOption2;
1511
- /**
1512
- * 잠재능력 세 번째 옵션
1513
- */
1514
- potentialOption3;
1515
- /**
1516
- * 에디셔널 잠재능력 첫 번째 옵션
1517
- */
1518
- additionalPotentialOption1;
1519
- /**
1520
- * 에디셔널 잠재능력 두 번째 옵션
1521
- */
1522
- additionalPotentialOption2;
1523
- /**
1524
- * 에디셔널 잠재능력 세 번째 옵션
1525
- */
1526
- additionalPotentialOption3;
1527
1607
  /**
1528
1608
  * 착용 레벨 증가
1529
1609
  */
@@ -1597,7 +1677,7 @@ class CharacterItemEquipmentInfoDto {
1597
1677
  */
1598
1678
  dateExpire;
1599
1679
  constructor(obj) {
1600
- const { item_equipment_part, item_equipment_slot, item_name, item_icon, item_description, item_shape_name, item_shape_icon, item_gender, item_total_option, item_base_option, potential_option_grade, additional_potential_option_grade, potential_option_1, potential_option_2, potential_option_3, additional_potential_option_1, additional_potential_option_2, additional_potential_option_3, equipment_level_increase, item_exceptional_option, item_add_option, growth_exp, growth_level, scroll_upgrade, cuttable_count, golden_hammer_flag, scroll_resilience_count, scroll_upgradeable_count, soul_name, soul_option, item_etc_option, starforce, starforce_scroll_flag, item_starforce_option, special_ring_level, date_expire, } = obj;
1680
+ const { item_equipment_part, item_equipment_slot, item_name, item_icon, item_description, item_shape_name, item_shape_icon, item_gender, item_total_option, item_base_option, equipment_level_increase, item_exceptional_option, item_add_option, growth_exp, growth_level, scroll_upgrade, cuttable_count, golden_hammer_flag, scroll_resilience_count, scroll_upgradeable_count, soul_name, soul_option, item_etc_option, starforce, starforce_scroll_flag, item_starforce_option, special_ring_level, date_expire, } = obj;
1601
1681
  this.itemEquipmentPart = item_equipment_part;
1602
1682
  this.itemEquipmentSlot = item_equipment_slot;
1603
1683
  this.itemName = item_name;
@@ -1608,14 +1688,6 @@ class CharacterItemEquipmentInfoDto {
1608
1688
  this.itemGender = item_gender;
1609
1689
  this.itemTotalOption = new CharacterItemEquipmentTotalOptionDto(item_total_option);
1610
1690
  this.itemBaseOption = new CharacterItemEquipmentBaseOptionDto(item_base_option);
1611
- this.potentialOptionGrade = potential_option_grade;
1612
- this.additionalPotentialOptionGrade = additional_potential_option_grade;
1613
- this.potentialOption1 = potential_option_1;
1614
- this.potentialOption2 = potential_option_2;
1615
- this.potentialOption3 = potential_option_3;
1616
- this.additionalPotentialOption1 = additional_potential_option_1;
1617
- this.additionalPotentialOption2 = additional_potential_option_2;
1618
- this.additionalPotentialOption3 = additional_potential_option_3;
1619
1691
  this.equipmentLevelIncrease = equipment_level_increase;
1620
1692
  this.itemExceptionalOption = new CharacterItemEquipmentExceptionalOptionDto(item_exceptional_option);
1621
1693
  this.itemAddOption = new CharacterItemEquipmentAddOptionDto(item_add_option);
@@ -1638,94 +1710,81 @@ class CharacterItemEquipmentInfoDto {
1638
1710
  }
1639
1711
 
1640
1712
  /**
1641
- * 캐릭터 칭호 아이템 정보
1713
+ * 캐릭터 장비 아이템 상세 정보
1642
1714
  */
1643
- class CharacterItemEquipmentTitleDto {
1715
+ class CharacterItemEquipmentInfoDto {
1644
1716
  /**
1645
- * 칭호 장비 명
1717
+ * 장비 부위
1646
1718
  */
1647
- titleName;
1719
+ itemEquipmentPart;
1648
1720
  /**
1649
- * 칭호 아이콘
1721
+ * 장비 슬롯 위치
1650
1722
  */
1651
- titleIcon;
1723
+ itemEquipmentSlot;
1652
1724
  /**
1653
- * 칭호 설명
1725
+ * 장비
1654
1726
  */
1655
- titleDescription;
1727
+ itemName;
1656
1728
  /**
1657
- * 칭호 유효 기간
1729
+ * 장비 아이콘
1658
1730
  */
1659
- dateExpire;
1731
+ itemIcon;
1660
1732
  /**
1661
- * 칭호 옵션 유효 기간
1733
+ * 장비 설명
1662
1734
  */
1663
- dateOptionExpire = null;
1735
+ itemDescription;
1664
1736
  /**
1665
- * 칭호 옵션 유효 기간 만료 여부
1737
+ * 장비 외형
1666
1738
  */
1667
- isOptionExpired = null;
1668
- constructor(obj) {
1669
- const { title_name, title_icon, title_description, date_expire, date_option_expire, } = obj;
1670
- this.titleName = title_name;
1671
- this.titleIcon = title_icon;
1672
- this.titleDescription = title_description;
1673
- this.dateExpire = date_expire ? new Date(date_expire) : null;
1674
- if (date_option_expire === 'expired') {
1675
- this.isOptionExpired = true;
1676
- }
1677
- else if (typeof date_option_expire === 'string') {
1678
- this.dateOptionExpire = date_option_expire
1679
- ? new Date(date_option_expire)
1680
- : null;
1681
- }
1682
- }
1683
- }
1684
-
1685
- /**
1686
- * 에반 드래곤 장비 정보
1687
- */
1688
- class CharacterItemEquipmentDragonInfoDto {
1739
+ itemShapeName;
1689
1740
  /**
1690
- * 장비 부위
1741
+ * 장비 외형 아이콘
1691
1742
  */
1692
- itemEquipmentPart;
1743
+ itemShapeIcon;
1693
1744
  /**
1694
- * 장비 슬롯 위치
1745
+ * 전용 성별
1695
1746
  */
1696
- itemEquipmentSlot;
1747
+ itemGender;
1697
1748
  /**
1698
- * 장비
1749
+ * 장비 최종 옵션
1699
1750
  */
1700
- itemName;
1751
+ itemTotalOption;
1701
1752
  /**
1702
- * 장비 아이콘
1753
+ * 장비 기본 옵션
1703
1754
  */
1704
- itemIcon;
1755
+ itemBaseOption;
1705
1756
  /**
1706
- * 장비 설명
1757
+ * 잠재능력 등급
1707
1758
  */
1708
- itemDescription;
1759
+ potentialOptionGrade;
1709
1760
  /**
1710
- * 장비 외형
1761
+ * 에디셔널 잠재능력 등급
1711
1762
  */
1712
- itemShapeName;
1763
+ additionalPotentialOptionGrade;
1713
1764
  /**
1714
- * 장비 외형 아이콘
1765
+ * 잠재능력 번째 옵션
1715
1766
  */
1716
- itemShapeIcon;
1767
+ potentialOption1;
1717
1768
  /**
1718
- * 전용 성별
1769
+ * 잠재능력 두 번째 옵션
1719
1770
  */
1720
- itemGender;
1771
+ potentialOption2;
1721
1772
  /**
1722
- * 장비 최종 옵션
1773
+ * 잠재능력 번째 옵션
1723
1774
  */
1724
- itemTotalOption;
1775
+ potentialOption3;
1725
1776
  /**
1726
- * 장비 기본 옵션
1777
+ * 에디셔널 잠재능력 첫 번째 옵션
1727
1778
  */
1728
- itemBaseOption;
1779
+ additionalPotentialOption1;
1780
+ /**
1781
+ * 에디셔널 잠재능력 두 번째 옵션
1782
+ */
1783
+ additionalPotentialOption2;
1784
+ /**
1785
+ * 에디셔널 잠재능력 세 번째 옵션
1786
+ */
1787
+ additionalPotentialOption3;
1729
1788
  /**
1730
1789
  * 착용 레벨 증가
1731
1790
  */
@@ -1799,7 +1858,7 @@ class CharacterItemEquipmentDragonInfoDto {
1799
1858
  */
1800
1859
  dateExpire;
1801
1860
  constructor(obj) {
1802
- const { item_equipment_part, item_equipment_slot, item_name, item_icon, item_description, item_shape_name, item_shape_icon, item_gender, item_total_option, item_base_option, equipment_level_increase, item_exceptional_option, item_add_option, growth_exp, growth_level, scroll_upgrade, cuttable_count, golden_hammer_flag, scroll_resilience_count, scroll_upgradeable_count, soul_name, soul_option, item_etc_option, starforce, starforce_scroll_flag, item_starforce_option, special_ring_level, date_expire, } = obj;
1861
+ const { item_equipment_part, item_equipment_slot, item_name, item_icon, item_description, item_shape_name, item_shape_icon, item_gender, item_total_option, item_base_option, potential_option_grade, additional_potential_option_grade, potential_option_1, potential_option_2, potential_option_3, additional_potential_option_1, additional_potential_option_2, additional_potential_option_3, equipment_level_increase, item_exceptional_option, item_add_option, growth_exp, growth_level, scroll_upgrade, cuttable_count, golden_hammer_flag, scroll_resilience_count, scroll_upgradeable_count, soul_name, soul_option, item_etc_option, starforce, starforce_scroll_flag, item_starforce_option, special_ring_level, date_expire, } = obj;
1803
1862
  this.itemEquipmentPart = item_equipment_part;
1804
1863
  this.itemEquipmentSlot = item_equipment_slot;
1805
1864
  this.itemName = item_name;
@@ -1810,6 +1869,14 @@ class CharacterItemEquipmentDragonInfoDto {
1810
1869
  this.itemGender = item_gender;
1811
1870
  this.itemTotalOption = new CharacterItemEquipmentTotalOptionDto(item_total_option);
1812
1871
  this.itemBaseOption = new CharacterItemEquipmentBaseOptionDto(item_base_option);
1872
+ this.potentialOptionGrade = potential_option_grade;
1873
+ this.additionalPotentialOptionGrade = additional_potential_option_grade;
1874
+ this.potentialOption1 = potential_option_1;
1875
+ this.potentialOption2 = potential_option_2;
1876
+ this.potentialOption3 = potential_option_3;
1877
+ this.additionalPotentialOption1 = additional_potential_option_1;
1878
+ this.additionalPotentialOption2 = additional_potential_option_2;
1879
+ this.additionalPotentialOption3 = additional_potential_option_3;
1813
1880
  this.equipmentLevelIncrease = equipment_level_increase;
1814
1881
  this.itemExceptionalOption = new CharacterItemEquipmentExceptionalOptionDto(item_exceptional_option);
1815
1882
  this.itemAddOption = new CharacterItemEquipmentAddOptionDto(item_add_option);
@@ -1980,6 +2047,51 @@ class CharacterItemEquipmentMechanicInfoDto {
1980
2047
  }
1981
2048
  }
1982
2049
 
2050
+ /**
2051
+ * 캐릭터 칭호 아이템 정보
2052
+ */
2053
+ class CharacterItemEquipmentTitleDto {
2054
+ /**
2055
+ * 칭호 장비 명
2056
+ */
2057
+ titleName;
2058
+ /**
2059
+ * 칭호 아이콘
2060
+ */
2061
+ titleIcon;
2062
+ /**
2063
+ * 칭호 설명
2064
+ */
2065
+ titleDescription;
2066
+ /**
2067
+ * 칭호 유효 기간
2068
+ */
2069
+ dateExpire;
2070
+ /**
2071
+ * 칭호 옵션 유효 기간
2072
+ */
2073
+ dateOptionExpire = null;
2074
+ /**
2075
+ * 칭호 옵션 유효 기간 만료 여부
2076
+ */
2077
+ isOptionExpired = null;
2078
+ constructor(obj) {
2079
+ const { title_name, title_icon, title_description, date_expire, date_option_expire, } = obj;
2080
+ this.titleName = title_name;
2081
+ this.titleIcon = title_icon;
2082
+ this.titleDescription = title_description;
2083
+ this.dateExpire = date_expire ? new Date(date_expire) : null;
2084
+ if (date_option_expire === 'expired') {
2085
+ this.isOptionExpired = true;
2086
+ }
2087
+ else if (typeof date_option_expire === 'string') {
2088
+ this.dateOptionExpire = date_option_expire
2089
+ ? new Date(date_option_expire)
2090
+ : null;
2091
+ }
2092
+ }
2093
+ }
2094
+
1983
2095
  /**
1984
2096
  * 캐릭터 장비 아이템 정보
1985
2097
  */
@@ -1997,9 +2109,25 @@ class CharacterItemEquipmentDto {
1997
2109
  */
1998
2110
  characterClass;
1999
2111
  /**
2000
- * 장비 정보 배열
2112
+ * 적용 중인 장비 프리셋 번호
2113
+ */
2114
+ presetNo;
2115
+ /**
2116
+ * 장비 정보
2001
2117
  */
2002
2118
  itemEquipment;
2119
+ /**
2120
+ * 1번 프리셋 장비 정보
2121
+ */
2122
+ itemEquipmentPreset1;
2123
+ /**
2124
+ * 2번 프리셋 장비 정보
2125
+ */
2126
+ itemEquipmentPreset2;
2127
+ /**
2128
+ * 3번 프리셋 장비 정보
2129
+ */
2130
+ itemEquipmentPreset3;
2003
2131
  /**
2004
2132
  * 칭호 정보
2005
2133
  */
@@ -2013,11 +2141,15 @@ class CharacterItemEquipmentDto {
2013
2141
  */
2014
2142
  mechanicEquipment;
2015
2143
  constructor(obj) {
2016
- const { date, character_gender, character_class, item_equipment, title, dragon_equipment, mechanic_equipment, } = obj;
2144
+ const { date, character_gender, character_class, preset_no, item_equipment, item_equipment_preset_1, item_equipment_preset_2, item_equipment_preset_3, title, dragon_equipment, mechanic_equipment, } = obj;
2017
2145
  this.date = new Date(date);
2018
2146
  this.characterGender = character_gender;
2019
2147
  this.characterClass = character_class;
2148
+ this.presetNo = preset_no;
2020
2149
  this.itemEquipment = item_equipment.map((equipment) => new CharacterItemEquipmentInfoDto(equipment));
2150
+ this.itemEquipmentPreset1 = item_equipment_preset_1 ? item_equipment_preset_1.map((equipment) => new CharacterItemEquipmentInfoDto(equipment)) : null;
2151
+ this.itemEquipmentPreset2 = item_equipment_preset_2 ? item_equipment_preset_2.map((equipment) => new CharacterItemEquipmentInfoDto(equipment)) : null;
2152
+ this.itemEquipmentPreset3 = item_equipment_preset_3 ? item_equipment_preset_3.map((equipment) => new CharacterItemEquipmentInfoDto(equipment)) : null;
2021
2153
  this.title = title ? new CharacterItemEquipmentTitleDto(title) : null;
2022
2154
  this.dragonEquipment = dragon_equipment.map((equipment) => new CharacterItemEquipmentDragonInfoDto(equipment));
2023
2155
  this.mechanicEquipment = mechanic_equipment.map((equipment) => new CharacterItemEquipmentMechanicInfoDto(equipment));
@@ -2074,16 +2206,46 @@ class CharacterLinkSkillDto {
2074
2206
  * 링크 스킬 정보
2075
2207
  */
2076
2208
  characterLinkSkill;
2209
+ /**
2210
+ * 링크 스킬 1번 프리셋 정보
2211
+ */
2212
+ characterLinkSkillPreset1;
2213
+ /**
2214
+ * 링크 스킬 2번 프리셋 정보
2215
+ */
2216
+ characterLinkSkillPreset2;
2217
+ /**
2218
+ * 링크 스킬 3번 프리셋 정보
2219
+ */
2220
+ characterLinkSkillPreset3;
2077
2221
  /**
2078
2222
  * 내 링크 스킬 정보
2079
2223
  */
2080
2224
  characterOwnedLinkSkill;
2225
+ /**
2226
+ * 내 링크 스킬 1번 프리셋 정보
2227
+ */
2228
+ characterOwnedLinkSkillPreset1;
2229
+ /**
2230
+ * 내 링크 스킬 2번 프리셋 정보
2231
+ */
2232
+ characterOwnedLinkSkillPreset2;
2233
+ /**
2234
+ * 내 링크 스킬 3번 프리셋 정보
2235
+ */
2236
+ characterOwnedLinkSkillPreset3;
2081
2237
  constructor(obj) {
2082
- const { date, character_class, character_link_skill, character_owned_link_skill, } = obj;
2238
+ const { date, character_class, character_link_skill, character_link_skill_preset_1, character_link_skill_preset_2, character_link_skill_preset_3, character_owned_link_skill, character_owned_link_skill_preset_1, character_owned_link_skill_preset_2, character_owned_link_skill_preset_3, } = obj;
2083
2239
  this.date = new Date(date);
2084
2240
  this.characterClass = character_class;
2085
- this.characterLinkSkill = new CharacterLinkSkillInfoDto(character_link_skill);
2241
+ this.characterLinkSkill = character_link_skill.map((skill) => new CharacterLinkSkillInfoDto(skill));
2242
+ this.characterLinkSkillPreset1 = character_link_skill_preset_1.map((skill) => new CharacterLinkSkillInfoDto(skill));
2243
+ this.characterLinkSkillPreset2 = character_link_skill_preset_2.map((skill) => new CharacterLinkSkillInfoDto(skill));
2244
+ this.characterLinkSkillPreset3 = character_link_skill_preset_3.map((skill) => new CharacterLinkSkillInfoDto(skill));
2086
2245
  this.characterOwnedLinkSkill = new CharacterLinkSkillInfoDto(character_owned_link_skill);
2246
+ this.characterOwnedLinkSkillPreset1 = character_owned_link_skill_preset_1 ? new CharacterLinkSkillInfoDto(character_owned_link_skill_preset_1) : null;
2247
+ this.characterOwnedLinkSkillPreset2 = character_owned_link_skill_preset_2 ? new CharacterLinkSkillInfoDto(character_owned_link_skill_preset_2) : null;
2248
+ this.characterOwnedLinkSkillPreset3 = character_owned_link_skill_preset_3 ? new CharacterLinkSkillInfoDto(character_owned_link_skill_preset_3) : null;
2087
2249
  }
2088
2250
  }
2089
2251
 
@@ -2162,15 +2324,25 @@ class CharacterPetEquipmentItemDto {
2162
2324
  /**
2163
2325
  * 업그레이드 가능 횟수
2164
2326
  */
2165
- scrollUpgradeable;
2327
+ scrollUpgradable;
2328
+ /**
2329
+ * 아이템 외형
2330
+ */
2331
+ itemShape;
2332
+ /**
2333
+ * 아이템 외형 아이콘
2334
+ */
2335
+ itemShapeIcon;
2166
2336
  constructor(obj) {
2167
- const { item_name, item_icon, item_description, item_option, scroll_upgrade, scroll_upgradeable, } = obj;
2337
+ const { item_name, item_icon, item_description, item_option, scroll_upgrade, scroll_upgradable, item_shape, item_shape_icon } = obj;
2168
2338
  this.itemName = item_name;
2169
2339
  this.itemIcon = item_icon;
2170
2340
  this.itemDescription = item_description;
2171
2341
  this.itemOption = item_option.map((option) => new CharacterPetEquipmentItemOptionDto(option));
2172
2342
  this.scrollUpgrade = scroll_upgrade;
2173
- this.scrollUpgradeable = scroll_upgradeable;
2343
+ this.scrollUpgradable = scroll_upgradable;
2344
+ this.itemShape = item_shape;
2345
+ this.itemShapeIcon = item_shape_icon;
2174
2346
  }
2175
2347
  }
2176
2348
 
@@ -2218,6 +2390,14 @@ class CharacterPetEquipmentDto {
2218
2390
  * 펫1 마법의 시간 (KST, 시간 단위 데이터로 분은 일괄 0으로 표기)
2219
2391
  */
2220
2392
  pet1DateExpire;
2393
+ /**
2394
+ * 펫1 외형
2395
+ */
2396
+ pet1Appearance;
2397
+ /**
2398
+ * 펫1 외형 아이콘
2399
+ */
2400
+ pet1AppearanceIcon;
2221
2401
  /**
2222
2402
  * 펫2 명
2223
2403
  */
@@ -2250,10 +2430,18 @@ class CharacterPetEquipmentDto {
2250
2430
  * 펫2 펫 보유 스킬
2251
2431
  */
2252
2432
  pet2Skill;
2253
- /*
2433
+ /**
2254
2434
  * 펫2 마법의 시간 (KST, 시간 단위 데이터로 분은 일괄 0으로 표기)
2255
2435
  */
2256
2436
  pet2DateExpire;
2437
+ /**
2438
+ * 펫2 외형
2439
+ */
2440
+ pet2Appearance;
2441
+ /**
2442
+ * 펫2 외형 아이콘
2443
+ */
2444
+ pet2AppearanceIcon;
2257
2445
  /**
2258
2446
  * 펫3 명
2259
2447
  */
@@ -2286,40 +2474,54 @@ class CharacterPetEquipmentDto {
2286
2474
  * 펫3 펫 보유 스킬
2287
2475
  */
2288
2476
  pet3Skill;
2289
- /*
2477
+ /**
2290
2478
  * 펫3 마법의 시간 (KST, 시간 단위 데이터로 분은 일괄 0으로 표기)
2291
2479
  */
2292
2480
  pet3DateExpire;
2481
+ /**
2482
+ * 펫3 외형
2483
+ */
2484
+ pet3Appearance;
2485
+ /**
2486
+ * 펫3 외형 아이콘
2487
+ */
2488
+ pet3AppearanceIcon;
2293
2489
  constructor(obj) {
2294
- const { date, pet_1_name, pet_1_nickname, pet_1_icon, pet_1_description, pet_1_equipment, pet_1_auto_skill, pet_1_pet_type, pet_1_skill, pet_1_date_expire, pet_2_name, pet_2_nickname, pet_2_icon, pet_2_description, pet_2_equipment, pet_2_auto_skill, pet_2_pet_type, pet_2_skill, pet_2_date_expire, pet_3_name, pet_3_nickname, pet_3_icon, pet_3_description, pet_3_equipment, pet_3_auto_skill, pet_3_pet_type, pet_3_skill, pet_3_date_expire, } = obj;
2490
+ const { date, pet_1_name, pet_1_nickname, pet_1_icon, pet_1_description, pet_1_equipment, pet_1_auto_skill, pet_1_pet_type, pet_1_skill, pet_1_date_expire, pet_1_appearance, pet_1_appearance_icon, pet_2_name, pet_2_nickname, pet_2_icon, pet_2_description, pet_2_equipment, pet_2_auto_skill, pet_2_pet_type, pet_2_skill, pet_2_date_expire, pet_2_appearance, pet_2_appearance_icon, pet_3_name, pet_3_nickname, pet_3_icon, pet_3_description, pet_3_equipment, pet_3_auto_skill, pet_3_pet_type, pet_3_skill, pet_3_date_expire, pet_3_appearance, pet_3_appearance_icon, } = obj;
2295
2491
  this.date = new Date(date);
2296
2492
  this.pet1Name = pet_1_name;
2297
2493
  this.pet1Nickname = pet_1_nickname;
2298
2494
  this.pet1Icon = pet_1_icon;
2299
2495
  this.pet1Description = pet_1_description;
2300
- this.pet1Equipment = new CharacterPetEquipmentItemDto(pet_1_equipment);
2301
- this.pet1AutoSkill = new CharacterPetEquipmentAutoSkillDto(pet_1_auto_skill);
2496
+ this.pet1Equipment = pet_1_equipment ? new CharacterPetEquipmentItemDto(pet_1_equipment) : null;
2497
+ this.pet1AutoSkill = pet_1_auto_skill ? new CharacterPetEquipmentAutoSkillDto(pet_1_auto_skill) : null;
2302
2498
  this.pet1PetType = pet_1_pet_type;
2303
2499
  this.pet1Skill = pet_1_skill;
2304
- this.pet1DateExpire = new Date(pet_1_date_expire);
2500
+ this.pet1DateExpire = pet_1_date_expire ? new Date(pet_1_date_expire) : null;
2501
+ this.pet1Appearance = pet_1_appearance;
2502
+ this.pet1AppearanceIcon = pet_1_appearance_icon;
2305
2503
  this.pet2Name = pet_2_name;
2306
2504
  this.pet2Nickname = pet_2_nickname;
2307
2505
  this.pet2Icon = pet_2_icon;
2308
2506
  this.pet2Description = pet_2_description;
2309
- this.pet2Equipment = new CharacterPetEquipmentItemDto(pet_2_equipment);
2310
- this.pet2AutoSkill = new CharacterPetEquipmentAutoSkillDto(pet_2_auto_skill);
2507
+ this.pet2Equipment = pet_2_equipment ? new CharacterPetEquipmentItemDto(pet_2_equipment) : null;
2508
+ this.pet2AutoSkill = pet_2_auto_skill ? new CharacterPetEquipmentAutoSkillDto(pet_2_auto_skill) : null;
2311
2509
  this.pet2PetType = pet_2_pet_type;
2312
2510
  this.pet2Skill = pet_2_skill;
2313
- this.pet2DateExpire = new Date(pet_2_date_expire);
2511
+ this.pet2DateExpire = pet_2_date_expire ? new Date(pet_2_date_expire) : null;
2512
+ this.pet2Appearance = pet_2_appearance;
2513
+ this.pet2AppearanceIcon = pet_2_appearance_icon;
2314
2514
  this.pet3Name = pet_3_name;
2315
2515
  this.pet3Nickname = pet_3_nickname;
2316
2516
  this.pet3Icon = pet_3_icon;
2317
2517
  this.pet3Description = pet_3_description;
2318
- this.pet3Equipment = new CharacterPetEquipmentItemDto(pet_3_equipment);
2319
- this.pet3AutoSkill = new CharacterPetEquipmentAutoSkillDto(pet_3_auto_skill);
2518
+ this.pet3Equipment = pet_3_equipment ? new CharacterPetEquipmentItemDto(pet_3_equipment) : null;
2519
+ this.pet3AutoSkill = pet_3_auto_skill ? new CharacterPetEquipmentAutoSkillDto(pet_3_auto_skill) : null;
2320
2520
  this.pet3PetType = pet_3_pet_type;
2321
2521
  this.pet3Skill = pet_3_skill;
2322
- this.pet3DateExpire = new Date(pet_3_date_expire);
2522
+ this.pet3DateExpire = pet_3_date_expire ? new Date(pet_3_date_expire) : null;
2523
+ this.pet3Appearance = pet_3_appearance;
2524
+ this.pet3AppearanceIcon = pet_3_appearance_icon;
2323
2525
  }
2324
2526
  }
2325
2527
 
@@ -2714,104 +2916,226 @@ class CharacterVMatrixDto {
2714
2916
  }
2715
2917
  }
2716
2918
 
2717
- var PotentialOptionGrade;
2718
- (function (PotentialOptionGrade) {
2719
- PotentialOptionGrade[PotentialOptionGrade["RARE"] = 0] = "RARE";
2720
- PotentialOptionGrade[PotentialOptionGrade["EPIC"] = 1] = "EPIC";
2721
- PotentialOptionGrade[PotentialOptionGrade["UNIQUE"] = 2] = "UNIQUE";
2722
- PotentialOptionGrade[PotentialOptionGrade["LEGENDARY"] = 3] = "LEGENDARY";
2723
- })(PotentialOptionGrade || (PotentialOptionGrade = {}));
2724
- /**
2725
- * 한글로 정의된 잠재옵션 등급을 PotentialOptionGrade으로 변환합니다.
2726
- *
2727
- * @param text support only "레어", "에픽", "유니크", "레전드리"
2728
- */
2729
- const potentialOptionGradeFromString = (text) => {
2730
- const potentialOptionGradeMap = {
2731
- 레어: PotentialOptionGrade.RARE,
2732
- 에픽: PotentialOptionGrade.EPIC,
2733
- 유니크: PotentialOptionGrade.UNIQUE,
2734
- 레전드리: PotentialOptionGrade.LEGENDARY,
2735
- };
2736
- const grade = potentialOptionGradeMap[text];
2737
- if (!grade) {
2738
- throw new TypeError('No enum constant for string: ' + text);
2739
- }
2740
- return grade;
2741
- };
2742
-
2743
2919
  /**
2744
- * 큐브 결과 옵션 정보
2920
+ * 길드 스킬 정보
2745
2921
  */
2746
- class CubeResultOptionDto {
2922
+ class GuildSkillDto {
2747
2923
  /**
2748
- * 옵션
2924
+ * 스킬
2749
2925
  */
2750
- value;
2926
+ skillName;
2751
2927
  /**
2752
- * 옵션 등급
2928
+ * 스킬 설명
2753
2929
  */
2754
- grade;
2930
+ skillDescription;
2931
+ /**
2932
+ * 스킬 레벨
2933
+ */
2934
+ skillLevel;
2935
+ /**
2936
+ * 스킬 레벨 별 효과
2937
+ */
2938
+ skillEffect;
2939
+ /**
2940
+ * 스킬 아이콘
2941
+ */
2942
+ skillIcon;
2755
2943
  constructor(obj) {
2756
- const { value, grade } = obj;
2757
- this.value = value;
2758
- this.grade = grade;
2759
- }
2760
- get gradeEnum() {
2761
- return potentialOptionGradeFromString(this.grade);
2944
+ const { skill_name, skill_description, skill_level, skill_effect, skill_icon, } = obj;
2945
+ this.skillName = skill_name;
2946
+ this.skillDescription = skill_description;
2947
+ this.skillLevel = skill_level;
2948
+ this.skillEffect = skill_effect;
2949
+ this.skillIcon = skill_icon;
2762
2950
  }
2763
2951
  }
2764
2952
 
2765
2953
  /**
2766
- * 큐브 히스토리
2954
+ * 길드 기본 정보
2767
2955
  */
2768
- class CubeHistoryDto {
2769
- /**
2770
- * 큐브 히스토리 식별자
2771
- */
2772
- id;
2956
+ class GuildBasicDto {
2773
2957
  /**
2774
- * 캐릭터
2958
+ * 조회 기준일
2775
2959
  */
2776
- characterName;
2960
+ date;
2777
2961
  /**
2778
2962
  * 월드 명
2779
2963
  */
2780
2964
  worldName;
2781
2965
  /**
2782
- * 사용 일시
2966
+ * 길드
2783
2967
  */
2784
- dateCreate;
2968
+ guildName;
2785
2969
  /**
2786
- * 사용 큐브
2970
+ * 길드 레벨
2787
2971
  */
2788
- cubeType;
2972
+ guildLevel;
2789
2973
  /**
2790
- * 사용 결과
2974
+ * 길드 명성치
2791
2975
  */
2792
- itemUpgradeResult;
2976
+ guildFame;
2793
2977
  /**
2794
- * 미라클 타임 적용 여부
2978
+ * 길드 포인트(GP)
2795
2979
  */
2796
- miracleTimeFlag;
2980
+ guildPoint;
2797
2981
  /**
2798
- * 장비 분류
2982
+ * 길드 마스터 캐릭터 명
2799
2983
  */
2800
- itemEquipmentPart;
2984
+ guildMasterName;
2801
2985
  /**
2802
- * 장비 레벨
2986
+ * 길드원
2803
2987
  */
2804
- itemLevel;
2988
+ guildMemberCount;
2805
2989
  /**
2806
- * 큐브 사용한 장비
2990
+ * 길드원 목록
2807
2991
  */
2808
- targetItem;
2992
+ guildMember;
2809
2993
  /**
2810
- * 잠재능력 등급
2994
+ * 길드 스킬 목록
2811
2995
  */
2812
- potentialOptionGrade;
2996
+ guildSkill;
2813
2997
  /**
2814
- * 에디셔널 잠재능력 등급
2998
+ * 노블레스 스킬 목록
2999
+ */
3000
+ guildNoblesseSkill;
3001
+ /**
3002
+ * 조합형 길드 마크
3003
+ */
3004
+ guildMark;
3005
+ /**
3006
+ * 커스텀 길드 마크 (base64 인코딩 형식)
3007
+ */
3008
+ guildMarkCustom;
3009
+ constructor(obj) {
3010
+ const { date, world_name, guild_name, guild_level, guild_fame, guild_point, guild_master_name, guild_member_count, guild_member, guild_skill, guild_noblesse_skill, guild_mark, guild_mark_custom, } = obj;
3011
+ this.date = new Date(date);
3012
+ this.worldName = world_name;
3013
+ this.guildName = guild_name;
3014
+ this.guildLevel = guild_level;
3015
+ this.guildFame = guild_fame;
3016
+ this.guildPoint = guild_point;
3017
+ this.guildMasterName = guild_master_name;
3018
+ this.guildMemberCount = guild_member_count;
3019
+ this.guildMember = guild_member;
3020
+ this.guildSkill = guild_skill.map((skill) => new GuildSkillDto(skill));
3021
+ this.guildNoblesseSkill = guild_noblesse_skill.map((skill) => new GuildSkillDto(skill));
3022
+ this.guildMark = guild_mark;
3023
+ this.guildMarkCustom = guild_mark_custom;
3024
+ }
3025
+ }
3026
+
3027
+ /**
3028
+ * 길드 식별자 정보
3029
+ */
3030
+ class GuildDto {
3031
+ /**
3032
+ * 길드 식별자
3033
+ */
3034
+ oguildId;
3035
+ constructor(obj) {
3036
+ const { oguild_id } = obj;
3037
+ this.oguildId = oguild_id;
3038
+ }
3039
+ }
3040
+
3041
+ var PotentialOptionGrade;
3042
+ (function (PotentialOptionGrade) {
3043
+ PotentialOptionGrade[PotentialOptionGrade["RARE"] = 0] = "RARE";
3044
+ PotentialOptionGrade[PotentialOptionGrade["EPIC"] = 1] = "EPIC";
3045
+ PotentialOptionGrade[PotentialOptionGrade["UNIQUE"] = 2] = "UNIQUE";
3046
+ PotentialOptionGrade[PotentialOptionGrade["LEGENDARY"] = 3] = "LEGENDARY";
3047
+ })(PotentialOptionGrade || (PotentialOptionGrade = {}));
3048
+ /**
3049
+ * 한글로 정의된 잠재옵션 등급을 PotentialOptionGrade으로 변환합니다.
3050
+ *
3051
+ * @param text support only "레어", "에픽", "유니크", "레전드리"
3052
+ */
3053
+ const potentialOptionGradeFromString = (text) => {
3054
+ const potentialOptionGradeMap = {
3055
+ 레어: PotentialOptionGrade.RARE,
3056
+ 에픽: PotentialOptionGrade.EPIC,
3057
+ 유니크: PotentialOptionGrade.UNIQUE,
3058
+ 레전드리: PotentialOptionGrade.LEGENDARY,
3059
+ };
3060
+ const grade = potentialOptionGradeMap[text];
3061
+ if (!grade) {
3062
+ throw new TypeError('No enum constant for string: ' + text);
3063
+ }
3064
+ return grade;
3065
+ };
3066
+
3067
+ /**
3068
+ * 큐브 결과 옵션 정보
3069
+ */
3070
+ class CubeResultOptionDto {
3071
+ /**
3072
+ * 옵션 명
3073
+ */
3074
+ value;
3075
+ /**
3076
+ * 옵션 등급
3077
+ */
3078
+ grade;
3079
+ constructor(obj) {
3080
+ const { value, grade } = obj;
3081
+ this.value = value;
3082
+ this.grade = grade;
3083
+ }
3084
+ get gradeEnum() {
3085
+ return potentialOptionGradeFromString(this.grade);
3086
+ }
3087
+ }
3088
+
3089
+ /**
3090
+ * 큐브 히스토리
3091
+ */
3092
+ class CubeHistoryDto {
3093
+ /**
3094
+ * 큐브 히스토리 식별자
3095
+ */
3096
+ id;
3097
+ /**
3098
+ * 캐릭터 명
3099
+ */
3100
+ characterName;
3101
+ /**
3102
+ * 월드 명
3103
+ */
3104
+ worldName;
3105
+ /**
3106
+ * 사용 일시
3107
+ */
3108
+ dateCreate;
3109
+ /**
3110
+ * 사용 큐브
3111
+ */
3112
+ cubeType;
3113
+ /**
3114
+ * 사용 결과
3115
+ */
3116
+ itemUpgradeResult;
3117
+ /**
3118
+ * 미라클 타임 적용 여부
3119
+ */
3120
+ miracleTimeFlag;
3121
+ /**
3122
+ * 장비 분류
3123
+ */
3124
+ itemEquipmentPart;
3125
+ /**
3126
+ * 장비 레벨
3127
+ */
3128
+ itemLevel;
3129
+ /**
3130
+ * 큐브 사용한 장비
3131
+ */
3132
+ targetItem;
3133
+ /**
3134
+ * 잠재능력 등급
3135
+ */
3136
+ potentialOptionGrade;
3137
+ /**
3138
+ * 에디셔널 잠재능력 등급
2815
3139
  */
2816
3140
  additionalPotentialOptionGrade;
2817
3141
  /**
@@ -2899,192 +3223,462 @@ class CubeHistoryResponseDto {
2899
3223
  }
2900
3224
 
2901
3225
  /**
2902
- * 무릉도장 랭킹 정보
3226
+ * 잠재능력 재설정 결과 옵션 정보
2903
3227
  */
2904
- class DojangRankingDto {
3228
+ class PotentialResultOptionDto {
2905
3229
  /**
2906
- * 랭킹 업데이트 일자 (KST, 일 단위 데이터로 시, 분은 일괄 0으로 표기)
3230
+ * 옵션
2907
3231
  */
2908
- date;
3232
+ value;
2909
3233
  /**
2910
- * 무릉도장 랭킹 순위
3234
+ * 옵션 등급
2911
3235
  */
2912
- ranking;
3236
+ grade;
3237
+ constructor(obj) {
3238
+ const { value, grade } = obj;
3239
+ this.value = value;
3240
+ this.grade = grade;
3241
+ }
3242
+ get gradeEnum() {
3243
+ return potentialOptionGradeFromString(this.grade);
3244
+ }
3245
+ }
3246
+
3247
+ /**
3248
+ * 잠재능력 재설정 히스토리
3249
+ */
3250
+ class PotentialHistoryDto {
3251
+ /**
3252
+ * 잠재능력 재설정 히스토리 식별자
3253
+ */
3254
+ id;
2913
3255
  /**
2914
3256
  * 캐릭터 명
2915
3257
  */
2916
3258
  characterName;
2917
3259
  /**
2918
- * 월드
3260
+ * 사용 일시
2919
3261
  */
2920
- worldName;
3262
+ dateCreate;
2921
3263
  /**
2922
- * 직업
3264
+ * 대상 잠재능력 타입 (잠재능력, 에디셔널 잠재능력)
2923
3265
  */
2924
- className;
3266
+ potentialType;
2925
3267
  /**
2926
- * 전직 직업 명
3268
+ * 사용 결과
2927
3269
  */
2928
- subClassName;
3270
+ itemUpgradeResult;
2929
3271
  /**
2930
- * 캐릭터 레벨
3272
+ * 미라클 타임 적용 여부
2931
3273
  */
2932
- characterLevel;
3274
+ miracleTimeFlag;
2933
3275
  /**
2934
- * 무릉도장 구간
3276
+ * 장비 분류
2935
3277
  */
2936
- dojangFloor;
3278
+ itemEquipmentPart;
2937
3279
  /**
2938
- * 무릉도장 클리어 시간 기록 (초 단위)
3280
+ * 장비 레벨
2939
3281
  */
2940
- dojangTimeRecord;
3282
+ itemLevel;
3283
+ /**
3284
+ * 잠재능력 재설정 장비 명
3285
+ */
3286
+ targetItem;
3287
+ /**
3288
+ * 잠재능력 등급
3289
+ */
3290
+ potentialOptionGrade;
3291
+ /**
3292
+ * 에디셔널 잠재능력 등급
3293
+ */
3294
+ additionalPotentialOptionGrade;
3295
+ /**
3296
+ * 천장에 도달하여 확정 등급 상승한 여부
3297
+ */
3298
+ upgradeGuarantee;
3299
+ /**
3300
+ * 현재까지 쌓은 스택
3301
+ */
3302
+ upgradeGuaranteeCount;
3303
+ /**
3304
+ * 사용 전 잠재능력 옵션
3305
+ */
3306
+ beforePotentialOption;
3307
+ /**
3308
+ * 사용 전 에디셔널 잠재능력 옵션
3309
+ */
3310
+ beforeAdditionalPotentialOption;
3311
+ /**
3312
+ * 사용 후 잠재능력 옵션
3313
+ */
3314
+ afterPotentialOption;
3315
+ /**
3316
+ * 사용 후 에디셔널 잠재능력 옵션
3317
+ */
3318
+ afterAdditionalPotentialOption;
2941
3319
  constructor(obj) {
2942
- const { date, ranking, character_name, world_name, class_name, sub_class_name, character_level, dojang_floor, dojang_time_record, } = obj;
2943
- this.date = new Date(date);
2944
- this.ranking = ranking;
3320
+ const { id, character_name, date_create, potential_type, item_upgrade_result, miracle_time_flag, item_equipment_part, item_level, target_item, potential_option_grade, additional_potential_option_grade, upgrade_guarantee, upgrade_guarantee_count, before_potential_option, before_additional_potential_option, after_potential_option, after_additional_potential_option, } = obj;
3321
+ this.id = id;
3322
+ this.characterName = character_name;
3323
+ this.dateCreate = new Date(date_create);
3324
+ this.potentialType = potential_type;
3325
+ this.itemUpgradeResult = item_upgrade_result;
3326
+ this.miracleTimeFlag = miracle_time_flag;
3327
+ this.itemEquipmentPart = item_equipment_part;
3328
+ this.itemLevel = item_level;
3329
+ this.targetItem = target_item;
3330
+ this.potentialOptionGrade = potential_option_grade;
3331
+ this.additionalPotentialOptionGrade = additional_potential_option_grade;
3332
+ this.upgradeGuarantee = upgrade_guarantee;
3333
+ this.upgradeGuaranteeCount = upgrade_guarantee_count;
3334
+ this.beforePotentialOption = before_potential_option.map((origin) => new PotentialResultOptionDto(origin));
3335
+ this.beforeAdditionalPotentialOption =
3336
+ before_additional_potential_option.map((origin) => new PotentialResultOptionDto(origin));
3337
+ this.afterPotentialOption = after_potential_option.map((origin) => new PotentialResultOptionDto(origin));
3338
+ this.afterAdditionalPotentialOption = after_additional_potential_option.map((origin) => new PotentialResultOptionDto(origin));
3339
+ }
3340
+ get isItemUpgrade() {
3341
+ return this.itemUpgradeResult === '성공';
3342
+ }
3343
+ get isMiracleTimeFlag() {
3344
+ return this.miracleTimeFlag !== '이벤트 적용되지 않음';
3345
+ }
3346
+ get potentialOptionGradeEnum() {
3347
+ return potentialOptionGradeFromString(this.potentialOptionGrade);
3348
+ }
3349
+ get additionalPotentialOptionGradeEnum() {
3350
+ return potentialOptionGradeFromString(this.additionalPotentialOptionGrade);
3351
+ }
3352
+ }
3353
+
3354
+ /**
3355
+ * 잠재능력 재설정 히스토리 응답 정보
3356
+ */
3357
+ class PotentialHistoryResponseDto {
3358
+ /**
3359
+ * 결과 건 수
3360
+ */
3361
+ count;
3362
+ /**
3363
+ * 잠재능력 재설정 히스토리
3364
+ */
3365
+ potentialHistory;
3366
+ /**
3367
+ * 페이징 처리를 위한 cursor
3368
+ */
3369
+ nextCursor;
3370
+ constructor(obj) {
3371
+ const { count, potential_history, next_cursor } = obj;
3372
+ this.count = count;
3373
+ this.potentialHistory = potential_history.map((origin) => new PotentialHistoryDto(origin));
3374
+ this.nextCursor = next_cursor;
3375
+ }
3376
+ }
3377
+
3378
+ /**
3379
+ * 스타포스 강화 이벤트 정보
3380
+ */
3381
+ class StarforceEventDto {
3382
+ /**
3383
+ * 이벤트 성공 확률
3384
+ */
3385
+ successRate;
3386
+ /**
3387
+ * 이벤트 비용 할인율
3388
+ */
3389
+ costDiscountRate;
3390
+ /**
3391
+ * 이벤트 강화 수치 가중값
3392
+ */
3393
+ plusValue;
3394
+ /**
3395
+ * 이벤트 적용 강화 시도 가능한 n성 범위
3396
+ */
3397
+ starforceEventRange;
3398
+ constructor(obj) {
3399
+ const { success_rate, cost_discount_rate, plus_value, starforce_event_range, } = obj;
3400
+ this.successRate = success_rate;
3401
+ this.costDiscountRate = cost_discount_rate;
3402
+ this.plusValue = plus_value;
3403
+ this.starforceEventRange = starforce_event_range;
3404
+ }
3405
+ }
3406
+
3407
+ /**
3408
+ * 스타포스 히스토리
3409
+ */
3410
+ class StarforceHistoryDto {
3411
+ /**
3412
+ *스타포스 히스토리 식별자
3413
+ */
3414
+ id;
3415
+ /**
3416
+ *강화 시도 결과
3417
+ */
3418
+ itemUpgradeResult;
3419
+ /**
3420
+ *강화 시도 전 스타포스 수치
3421
+ */
3422
+ beforeStarforceCount;
3423
+ /**
3424
+ *강화 시도 후 스타포스 수치
3425
+ */
3426
+ afterStarforceCount;
3427
+ /**
3428
+ *스타 캐치
3429
+ */
3430
+ starCatchResult;
3431
+ /**
3432
+ *슈페리얼 장비
3433
+ */
3434
+ superiorItemFlag;
3435
+ /**
3436
+ *파괴 방지
3437
+ */
3438
+ destroyDefence;
3439
+ /**
3440
+ *찬스 타임
3441
+ */
3442
+ chanceTime;
3443
+ /**
3444
+ *파괴 방지 필드 이벤트
3445
+ */
3446
+ eventFieldFlag;
3447
+ /**
3448
+ *사용 주문서 명
3449
+ */
3450
+ upgradeItem;
3451
+ /**
3452
+ *프로텍트 실드
3453
+ */
3454
+ protectShield;
3455
+ /**
3456
+ *보너스 스탯 부여 아이템 여부
3457
+ */
3458
+ bonusStatUpgrade;
3459
+ /**
3460
+ *캐릭터 명
3461
+ */
3462
+ characterName;
3463
+ /**
3464
+ *월드 명
3465
+ */
3466
+ worldName;
3467
+ /**
3468
+ *대상 장비 아이템 명
3469
+ */
3470
+ targetItem;
3471
+ /**
3472
+ *강화 일시 (KST)
3473
+ */
3474
+ dateCreate;
3475
+ /**
3476
+ * 진행 중인 스타포스 강화 이벤트 정보
3477
+ */
3478
+ starforceEventList;
3479
+ constructor(obj) {
3480
+ const { id, item_upgrade_result, before_starforce_count, after_starforce_count, starcatch_result, superior_item_flag, destroy_defence, chance_time, event_field_flag, upgrade_item, protect_shield, bonus_stat_upgrade, character_name, world_name, target_item, date_create, starforce_event_list, } = obj;
3481
+ this.id = id;
3482
+ this.itemUpgradeResult = item_upgrade_result;
3483
+ this.beforeStarforceCount = before_starforce_count;
3484
+ this.afterStarforceCount = after_starforce_count;
3485
+ this.starCatchResult = starcatch_result;
3486
+ this.superiorItemFlag = superior_item_flag;
3487
+ this.destroyDefence = destroy_defence;
3488
+ this.chanceTime = chance_time;
3489
+ this.eventFieldFlag = event_field_flag;
3490
+ this.upgradeItem = upgrade_item;
3491
+ this.protectShield = protect_shield;
3492
+ this.bonusStatUpgrade = bonus_stat_upgrade;
2945
3493
  this.characterName = character_name;
2946
3494
  this.worldName = world_name;
2947
- this.className = class_name;
2948
- this.subClassName = sub_class_name;
2949
- this.characterLevel = character_level;
2950
- this.dojangFloor = dojang_floor;
2951
- this.dojangTimeRecord = dojang_time_record;
3495
+ this.targetItem = target_item;
3496
+ this.dateCreate = new Date(date_create);
3497
+ this.starforceEventList = starforce_event_list.map((event) => new StarforceEventDto(event));
2952
3498
  }
2953
3499
  }
2954
3500
 
2955
3501
  /**
2956
- * 무릉도장 랭킹 응답 정보
3502
+ * 스타포스 히스토리 응답 정보
2957
3503
  */
2958
- class DojangRankingResponseDto {
3504
+ class StarforceHistoryResponseDto {
2959
3505
  /**
2960
- * 길드 랭킹 정보
3506
+ * 결과
2961
3507
  */
2962
- ranking;
3508
+ count;
3509
+ /**
3510
+ * 스타포스 히스토리
3511
+ */
3512
+ starforceHistory;
3513
+ /**
3514
+ * 페이징 처리를 위한 cursor
3515
+ */
3516
+ nextCursor;
2963
3517
  constructor(obj) {
2964
- const { ranking } = obj;
2965
- this.ranking = ranking.map((rank) => new DojangRankingDto(rank));
3518
+ const { count, starforce_history, next_cursor } = obj;
3519
+ this.count = count;
3520
+ this.starforceHistory = starforce_history.map((origin) => new StarforceHistoryDto(origin));
3521
+ this.nextCursor = next_cursor;
2966
3522
  }
2967
3523
  }
2968
3524
 
2969
3525
  /**
2970
- * 길드 스킬 정보
3526
+ * 서버 점검 정보
2971
3527
  */
2972
- class GuildSkillDto {
3528
+ class InspectionInfoDto {
2973
3529
  /**
2974
- * 스킬
3530
+ * 서비스 코드
2975
3531
  */
2976
- skillName;
3532
+ serviceCode;
2977
3533
  /**
2978
- * 스킬 설명
3534
+ * 점검 시작 시각
2979
3535
  */
2980
- skillDescription;
3536
+ startDateTime;
2981
3537
  /**
2982
- * 스킬 레벨
3538
+ * 점검 종료 시각
2983
3539
  */
2984
- skillLevel;
3540
+ endDateTime;
2985
3541
  /**
2986
- * 스킬 레벨 별 효과
3542
+ * 점검 안내 제목
2987
3543
  */
2988
- skillEffect;
3544
+ strObstacleContents;
3545
+ constructor(obj) {
3546
+ const inspectionInfoTag = obj['soap:Envelope']['soap:Body'][0]['GetInspectionInfoResponse'][0]['GetInspectionInfoResult'][0]['diffgr:diffgram'][0]['NewDataSet'][0]['InspectionInfo'][0];
3547
+ this.serviceCode = Number(inspectionInfoTag.serviceCode[0]);
3548
+ this.startDateTime = new Date(inspectionInfoTag.startDateTime[0]);
3549
+ this.endDateTime = new Date(inspectionInfoTag.endDateTime[0]);
3550
+ this.strObstacleContents = inspectionInfoTag.strObstacleContents[0];
3551
+ }
3552
+ }
3553
+
3554
+ /**
3555
+ * 업적 랭킹 정보
3556
+ */
3557
+ class AchievementRankingDto {
2989
3558
  /**
2990
- * 스킬 아이콘
3559
+ * 랭킹 업데이트 일자 (KST, 일 단위 데이터로 시, 분은 일괄 0으로 표기)
3560
+ */
3561
+ date;
3562
+ /**
3563
+ * 업적 랭킹 순위
3564
+ */
3565
+ ranking;
3566
+ /**
3567
+ * 캐릭터 명
3568
+ */
3569
+ characterName;
3570
+ /**
3571
+ * 월드 명
3572
+ */
3573
+ worldName;
3574
+ /**
3575
+ * 직업 명
3576
+ */
3577
+ className;
3578
+ /**
3579
+ * 전직 직업 명
3580
+ */
3581
+ subClassName;
3582
+ /**
3583
+ * 업적 등급
3584
+ */
3585
+ trophyGrade;
3586
+ /**
3587
+ * 업적 점수
3588
+ */
3589
+ trophyScore;
3590
+ constructor(obj) {
3591
+ const { date, ranking, character_name, world_name, class_name, sub_class_name, trophy_grade, trophy_score, } = obj;
3592
+ this.date = new Date(date);
3593
+ this.ranking = ranking;
3594
+ this.characterName = character_name;
3595
+ this.worldName = world_name;
3596
+ this.className = class_name;
3597
+ this.subClassName = sub_class_name;
3598
+ this.trophyGrade = trophy_grade;
3599
+ this.trophyScore = trophy_score;
3600
+ }
3601
+ }
3602
+
3603
+ /**
3604
+ * 업적 랭킹 응답 정보
3605
+ */
3606
+ class AchievementRankingResponseDto {
3607
+ /**
3608
+ * 업적 랭킹 정보
2991
3609
  */
2992
- skillIcon;
3610
+ ranking;
2993
3611
  constructor(obj) {
2994
- const { skill_name, skill_description, skill_level, skill_effect, skill_icon, } = obj;
2995
- this.skillName = skill_name;
2996
- this.skillDescription = skill_description;
2997
- this.skillLevel = skill_level;
2998
- this.skillEffect = skill_effect;
2999
- this.skillIcon = skill_icon;
3612
+ const { ranking } = obj;
3613
+ this.ranking = ranking.map((rank) => new AchievementRankingDto(rank));
3000
3614
  }
3001
3615
  }
3002
3616
 
3003
3617
  /**
3004
- * 길드 기본 정보
3618
+ * 무릉도장 랭킹 정보
3005
3619
  */
3006
- class GuildBasicDto {
3620
+ class DojangRankingDto {
3007
3621
  /**
3008
- * 조회 기준일
3622
+ * 랭킹 업데이트 일자 (KST, 일 단위 데이터로 시, 분은 일괄 0으로 표기)
3009
3623
  */
3010
3624
  date;
3011
3625
  /**
3012
- * 월드
3013
- */
3014
- worldName;
3015
- /**
3016
- * 길드 명
3017
- */
3018
- guildName;
3019
- /**
3020
- * 길드 레벨
3021
- */
3022
- guildLevel;
3023
- /**
3024
- * 길드 명성치
3025
- */
3026
- guildFame;
3027
- /**
3028
- * 길드 포인트(GP)
3626
+ * 무릉도장 랭킹 순위
3029
3627
  */
3030
- guildPoint;
3628
+ ranking;
3031
3629
  /**
3032
- * 길드 마스터 캐릭터 명
3630
+ * 캐릭터 명
3033
3631
  */
3034
- guildMasterName;
3632
+ characterName;
3035
3633
  /**
3036
- * 길드원
3634
+ * 월드
3037
3635
  */
3038
- guildMemberCount;
3636
+ worldName;
3039
3637
  /**
3040
- * 길드원 목록
3638
+ * 직업
3041
3639
  */
3042
- guildMember;
3640
+ className;
3043
3641
  /**
3044
- * 길드 스킬 목록
3642
+ * 전직 직업
3045
3643
  */
3046
- guildSkill;
3644
+ subClassName;
3047
3645
  /**
3048
- * 노블레스 스킬 목록
3646
+ * 캐릭터 레벨
3049
3647
  */
3050
- guildNoblesseSkill;
3648
+ characterLevel;
3051
3649
  /**
3052
- * 조합형 길드 마크
3650
+ * 무릉도장 구간
3053
3651
  */
3054
- guildMark;
3652
+ dojangFloor;
3055
3653
  /**
3056
- * 커스텀 길드 마크 (base64 인코딩 형식)
3654
+ * 무릉도장 클리어 시간 기록 ( 단위)
3057
3655
  */
3058
- guildMarkCustom;
3656
+ dojangTimeRecord;
3059
3657
  constructor(obj) {
3060
- const { date, world_name, guild_name, guild_level, guild_fame, guild_point, guild_master_name, guild_member_count, guild_member, guild_skill, guild_noblesse_skill, guild_mark, guild_mark_custom, } = obj;
3658
+ const { date, ranking, character_name, world_name, class_name, sub_class_name, character_level, dojang_floor, dojang_time_record, } = obj;
3061
3659
  this.date = new Date(date);
3660
+ this.ranking = ranking;
3661
+ this.characterName = character_name;
3062
3662
  this.worldName = world_name;
3063
- this.guildName = guild_name;
3064
- this.guildLevel = guild_level;
3065
- this.guildFame = guild_fame;
3066
- this.guildPoint = guild_point;
3067
- this.guildMasterName = guild_master_name;
3068
- this.guildMemberCount = guild_member_count;
3069
- this.guildMember = guild_member;
3070
- this.guildSkill = guild_skill.map((skill) => new GuildSkillDto(skill));
3071
- this.guildNoblesseSkill = guild_noblesse_skill.map((skill) => new GuildSkillDto(skill));
3072
- this.guildMark = guild_mark;
3073
- this.guildMarkCustom = guild_mark_custom;
3663
+ this.className = class_name;
3664
+ this.subClassName = sub_class_name;
3665
+ this.characterLevel = character_level;
3666
+ this.dojangFloor = dojang_floor;
3667
+ this.dojangTimeRecord = dojang_time_record;
3074
3668
  }
3075
3669
  }
3076
3670
 
3077
3671
  /**
3078
- * 길드 식별자 정보
3672
+ * 무릉도장 랭킹 응답 정보
3079
3673
  */
3080
- class GuildDto {
3674
+ class DojangRankingResponseDto {
3081
3675
  /**
3082
- * 길드 식별자
3676
+ * 길드 랭킹 정보
3083
3677
  */
3084
- oguildId;
3678
+ ranking;
3085
3679
  constructor(obj) {
3086
- const { oguild_id } = obj;
3087
- this.oguildId = oguild_id;
3680
+ const { ranking } = obj;
3681
+ this.ranking = ranking.map((rank) => new DojangRankingDto(rank));
3088
3682
  }
3089
3683
  }
3090
3684
 
@@ -3151,35 +3745,6 @@ class GuildRankingResponseDto {
3151
3745
  }
3152
3746
  }
3153
3747
 
3154
- /**
3155
- * 서버 점검 정보
3156
- */
3157
- class InspectionInfoDto {
3158
- /**
3159
- * 서비스 코드
3160
- */
3161
- serviceCode;
3162
- /**
3163
- * 점검 시작 시각
3164
- */
3165
- startDateTime;
3166
- /**
3167
- * 점검 종료 시각
3168
- */
3169
- endDateTime;
3170
- /**
3171
- * 점검 안내 제목
3172
- */
3173
- strObstacleContents;
3174
- constructor(obj) {
3175
- const inspectionInfoTag = obj['soap:Envelope']['soap:Body'][0]['GetInspectionInfoResponse'][0]['GetInspectionInfoResult'][0]['diffgr:diffgram'][0]['NewDataSet'][0]['InspectionInfo'][0];
3176
- this.serviceCode = Number(inspectionInfoTag.serviceCode[0]);
3177
- this.startDateTime = new Date(inspectionInfoTag.startDateTime[0]);
3178
- this.endDateTime = new Date(inspectionInfoTag.endDateTime[0]);
3179
- this.strObstacleContents = inspectionInfoTag.strObstacleContents[0];
3180
- }
3181
- }
3182
-
3183
3748
  /**
3184
3749
  * 종합 랭킹 정보
3185
3750
  */
@@ -3308,164 +3873,16 @@ class TheSeedRankingDto {
3308
3873
  }
3309
3874
 
3310
3875
  /**
3311
- * 더 시드 랭킹 응답 정보
3312
- */
3313
- class TheSeedRankingResponseDto {
3314
- /**
3315
- * 더 시드 랭킹 정보
3316
- */
3317
- ranking;
3318
- constructor(obj) {
3319
- const { ranking } = obj;
3320
- this.ranking = ranking.map((rank) => new TheSeedRankingDto(rank));
3321
- }
3322
- }
3323
-
3324
- /**
3325
- * 유니온 정보
3326
- */
3327
- class UnionDto {
3328
- /**
3329
- * 조회 기준일
3330
- */
3331
- date;
3332
- /**
3333
- * 유니온 레벨
3334
- */
3335
- unionLevel;
3336
- /**
3337
- * 유니온 등급
3338
- */
3339
- unionGrade;
3340
- constructor(obj) {
3341
- const { date, union_level, union_grade } = obj;
3342
- this.date = new Date(date);
3343
- this.unionLevel = union_level;
3344
- this.unionGrade = union_grade;
3345
- }
3346
- }
3347
-
3348
- /**
3349
- * 유니온 블록이 차지하고 있는 영역 좌표들
3350
- */
3351
- class UnionRaiderBlockPositionDto {
3352
- /**
3353
- * 블록 X좌표
3354
- */
3355
- x;
3356
- /**
3357
- * 블록 Y좌표
3358
- */
3359
- y;
3360
- constructor(obj) {
3361
- const { x, y } = obj;
3362
- this.x = x;
3363
- this.y = y;
3364
- }
3365
- }
3366
-
3367
- /**
3368
- * 유니온 블록 기준점 좌표 정보
3369
- */
3370
- class UnionRaiderBlockControlPointDto {
3371
- /**
3372
- * 블록 기준점 X좌표
3373
- */
3374
- x;
3375
- /**
3376
- * 블록 기준점 Y좌표
3377
- */
3378
- y;
3379
- constructor(obj) {
3380
- const { x, y } = obj;
3381
- this.x = x;
3382
- this.y = y;
3383
- }
3384
- }
3385
-
3386
- /**
3387
- * 유니온 블록 정보
3388
- */
3389
- class UnionRaiderBlockDto {
3390
- /**
3391
- * 블록 모양 (전사, 마법사, 궁수, 도적, 해적, 메이플m, 하이브리드)
3392
- */
3393
- blockType;
3394
- /**
3395
- * 블록 해당 캐릭터 직업
3396
- */
3397
- blockClass;
3398
- /**
3399
- * 블록 해당 캐릭터 레벨
3400
- */
3401
- blockLevel;
3402
- /**
3403
- * 블록 기준점 좌표
3404
- */
3405
- blockControlPoint;
3406
- /**
3407
- * 블록이 차지하고 있는 영역 좌표들 (null:미 배치 시)
3408
- */
3409
- blockPosition;
3410
- constructor(obj) {
3411
- const { block_type, block_class, block_level, block_control_point, block_position, } = obj;
3412
- this.blockType = block_type;
3413
- this.blockClass = block_class;
3414
- this.blockLevel = block_level;
3415
- this.blockControlPoint = new UnionRaiderBlockControlPointDto(block_control_point);
3416
- this.blockPosition = block_position
3417
- ? block_position.map((position) => new UnionRaiderBlockPositionDto(position))
3418
- : null;
3419
- }
3420
- }
3421
-
3422
- /**
3423
- * 유니온 공격대 배치 정보
3424
- */
3425
- class UnionRaiderInnerStatDto {
3426
- /**
3427
- * 공격대 배치 위치 (11시 방향부터 시계 방향 순서대로 0~7)
3428
- */
3429
- statFieldId;
3430
- /**
3431
- * 해당 지역 점령 효과
3432
- */
3433
- statFieldEffect;
3434
- constructor(obj) {
3435
- const { stat_field_id, stat_field_effect } = obj;
3436
- this.statFieldId = stat_field_id;
3437
- this.statFieldEffect = stat_field_effect;
3438
- }
3439
- }
3440
-
3441
- /**
3442
- * 유니온 공격대 정보
3876
+ * 더 시드 랭킹 응답 정보
3443
3877
  */
3444
- class UnionRaiderDto {
3445
- date;
3446
- /**
3447
- * 유니온 공격대원 효과
3448
- */
3449
- unionRaiderStat;
3450
- /**
3451
- * 유니온 공격대 점령 효과
3452
- */
3453
- unionOccupiedStat;
3454
- /**
3455
- * 유니온 공격대 배치
3456
- */
3457
- unionInnerStat;
3878
+ class TheSeedRankingResponseDto {
3458
3879
  /**
3459
- * 유니온 블록 정보
3880
+ * 시드 랭킹 정보
3460
3881
  */
3461
- unionBlock;
3882
+ ranking;
3462
3883
  constructor(obj) {
3463
- const { date, union_raider_stat, union_occupied_stat, union_inner_stat, union_block, } = obj;
3464
- this.date = new Date(date);
3465
- this.unionRaiderStat = union_raider_stat;
3466
- this.unionOccupiedStat = union_occupied_stat;
3467
- this.unionInnerStat = union_inner_stat.map((stat) => new UnionRaiderInnerStatDto(stat));
3468
- this.unionBlock = union_block.map((block) => new UnionRaiderBlockDto(block));
3884
+ const { ranking } = obj;
3885
+ this.ranking = ranking.map((rank) => new TheSeedRankingDto(rank));
3469
3886
  }
3470
3887
  }
3471
3888
 
@@ -3533,190 +3950,302 @@ class UnionRankingResponseDto {
3533
3950
  }
3534
3951
 
3535
3952
  /**
3536
- * MapleStory OpenAPI error.<br>
3537
- * Please refer to <a href="https://openapi.nexon.com/guide/request-api/">MapleStory API guide</a> for the error details.
3953
+ * 유니온 아티팩트 크리스탈 정보
3538
3954
  */
3539
- class MapleStoryApiError extends Error {
3540
- name = 'MapleStoryApiError';
3541
- errorCode;
3542
- message;
3543
- constructor(errorBody) {
3544
- const { name, message } = errorBody.error;
3545
- super(message);
3546
- this.errorCode = errorMap[name];
3547
- this.message = message;
3955
+ class UnionArtifactCrystalDto {
3956
+ /**
3957
+ * 아티팩트 크리스탈 명
3958
+ */
3959
+ name;
3960
+ /**
3961
+ * 능력치 유효 여부 (0:유효, 1:유효하지 않음)
3962
+ */
3963
+ validityFlag;
3964
+ /**
3965
+ * 능력치 유효 기간(KST)
3966
+ */
3967
+ dateExpire;
3968
+ /**
3969
+ * 아티팩트 크리스탈 등급
3970
+ */
3971
+ level;
3972
+ /**
3973
+ * 아티팩트 크리스탈 첫 번째 옵션 명
3974
+ */
3975
+ crystalOptionName1;
3976
+ /**
3977
+ * 아티팩트 크리스탈 두 번째 옵션 명
3978
+ */
3979
+ crystalOptionName2;
3980
+ /**
3981
+ * 아티팩트 크리스탈 세 번째 옵션 명
3982
+ */
3983
+ crystalOptionName3;
3984
+ constructor(obj) {
3985
+ const { name, validity_flag, date_expire, level, crystal_option_name_1, crystal_option_name_2, crystal_option_name_3, } = obj;
3986
+ this.name = name;
3987
+ this.validityFlag = validity_flag;
3988
+ this.dateExpire = new Date(date_expire);
3989
+ this.level = level;
3990
+ this.crystalOptionName1 = crystal_option_name_1;
3991
+ this.crystalOptionName2 = crystal_option_name_2;
3992
+ this.crystalOptionName3 = crystal_option_name_3;
3548
3993
  }
3549
3994
  }
3995
+
3550
3996
  /**
3551
- * MapleStory OpenAPI error codes.<br>
3552
- * Please refer to <a href="https://openapi.nexon.com/guide/request-api/">MapleStory API guide</a> for the error code details.
3997
+ * 유니온 아티팩트 효과 정보
3553
3998
  */
3554
- var MapleStoryApiErrorCode;
3555
- (function (MapleStoryApiErrorCode) {
3556
- MapleStoryApiErrorCode[MapleStoryApiErrorCode["OPENAPI00001"] = 0] = "OPENAPI00001";
3557
- MapleStoryApiErrorCode[MapleStoryApiErrorCode["OPENAPI00002"] = 1] = "OPENAPI00002";
3558
- MapleStoryApiErrorCode[MapleStoryApiErrorCode["OPENAPI00003"] = 2] = "OPENAPI00003";
3559
- MapleStoryApiErrorCode[MapleStoryApiErrorCode["OPENAPI00004"] = 3] = "OPENAPI00004";
3560
- MapleStoryApiErrorCode[MapleStoryApiErrorCode["OPENAPI00005"] = 4] = "OPENAPI00005";
3561
- MapleStoryApiErrorCode[MapleStoryApiErrorCode["OPENAPI00006"] = 5] = "OPENAPI00006";
3562
- MapleStoryApiErrorCode[MapleStoryApiErrorCode["OPENAPI00007"] = 6] = "OPENAPI00007";
3563
- })(MapleStoryApiErrorCode || (MapleStoryApiErrorCode = {}));
3564
- const errorMap = {
3565
- ['OPENAPI00001']: MapleStoryApiErrorCode.OPENAPI00001,
3566
- ['OPENAPI00002']: MapleStoryApiErrorCode.OPENAPI00002,
3567
- ['OPENAPI00003']: MapleStoryApiErrorCode.OPENAPI00003,
3568
- ['OPENAPI00004']: MapleStoryApiErrorCode.OPENAPI00004,
3569
- ['OPENAPI00005']: MapleStoryApiErrorCode.OPENAPI00005,
3570
- ['OPENAPI00006']: MapleStoryApiErrorCode.OPENAPI00006,
3571
- ['OPENAPI00007']: MapleStoryApiErrorCode.OPENAPI00007,
3572
- };
3999
+ class UnionArtifactEffectDto {
4000
+ /**
4001
+ * 아티팩트 효과
4002
+ */
4003
+ name;
4004
+ /**
4005
+ * 아티팩트 효과 레벨
4006
+ */
4007
+ level;
4008
+ constructor(obj) {
4009
+ const { name, level } = obj;
4010
+ this.name = name;
4011
+ this.level = level;
4012
+ }
4013
+ }
3573
4014
 
3574
4015
  /**
3575
- * 스타포스 강화 이벤트 정보
4016
+ * 유니온 아티팩트 정보
3576
4017
  */
3577
- class StarforceEventDto {
4018
+ class UnionArtifactDto {
3578
4019
  /**
3579
- * 이벤트 성공 확률
4020
+ * 조회 기준일
3580
4021
  */
3581
- successRate;
4022
+ date;
3582
4023
  /**
3583
- * 이벤트 비용 할인율
4024
+ * 아티팩트 효과 정보
3584
4025
  */
3585
- costDiscountRate;
4026
+ unionArtifactEffect;
3586
4027
  /**
3587
- * 이벤트 강화 수치 가중값
4028
+ * 아티팩트 크리스탈 정보
3588
4029
  */
3589
- plusValue;
4030
+ unionArtifactCrystal;
3590
4031
  /**
3591
- * 이벤트 적용 강화 시도 가능한 n성 범위
4032
+ * 잔여 아티팩트 AP
3592
4033
  */
3593
- starforceEventRange;
4034
+ unionArtifactRemainAp;
3594
4035
  constructor(obj) {
3595
- const { success_rate, cost_discount_rate, plus_value, starforce_event_range, } = obj;
3596
- this.successRate = success_rate;
3597
- this.costDiscountRate = cost_discount_rate;
3598
- this.plusValue = plus_value;
3599
- this.starforceEventRange = starforce_event_range;
4036
+ const { date, union_artifact_effect, union_artifact_crystal, union_artifact_remain_ap, } = obj;
4037
+ this.date = new Date(date);
4038
+ this.unionArtifactEffect = union_artifact_effect.map((effect) => new UnionArtifactEffectDto(effect));
4039
+ this.unionArtifactCrystal = union_artifact_crystal.map((crystal) => new UnionArtifactCrystalDto(crystal));
4040
+ this.unionArtifactRemainAp = union_artifact_remain_ap;
3600
4041
  }
3601
4042
  }
3602
4043
 
3603
4044
  /**
3604
- * 스타포스 히스토리
4045
+ * 유니온 정보
3605
4046
  */
3606
- class StarforceHistoryDto {
4047
+ class UnionDto {
3607
4048
  /**
3608
- *스타포스 히스토리 식별자
4049
+ * 조회 기준일
3609
4050
  */
3610
- id;
4051
+ date;
3611
4052
  /**
3612
- *강화 시도 결과
4053
+ * 유니온 레벨
3613
4054
  */
3614
- itemUpgradeResult;
4055
+ unionLevel;
3615
4056
  /**
3616
- *강화 시도 전 스타포스 수치
4057
+ * 유니온 등급
3617
4058
  */
3618
- beforeStarforceCount;
4059
+ unionGrade;
3619
4060
  /**
3620
- *강화 시도 후 스타포스 수치
4061
+ * 아티팩트 레벨
3621
4062
  */
3622
- afterStarforceCount;
4063
+ unionArtifactLevel;
3623
4064
  /**
3624
- *스타 캐치
4065
+ * 보유 아티팩트 경험치
3625
4066
  */
3626
- starCatchResult;
4067
+ unionArtifactExp;
3627
4068
  /**
3628
- *슈페리얼 장비
4069
+ * 보유 아티팩트 포인트
3629
4070
  */
3630
- superiorItemFlag;
4071
+ unionArtifactPoint;
4072
+ constructor(obj) {
4073
+ const { date, union_level, union_grade, union_artifact_level, union_artifact_exp, union_artifact_point } = obj;
4074
+ this.date = new Date(date);
4075
+ this.unionLevel = union_level;
4076
+ this.unionGrade = union_grade;
4077
+ this.unionArtifactLevel = union_artifact_level;
4078
+ this.unionArtifactExp = union_artifact_exp;
4079
+ this.unionArtifactPoint = union_artifact_point;
4080
+ }
4081
+ }
4082
+
4083
+ /**
4084
+ * 유니온 블록이 차지하고 있는 영역 좌표들
4085
+ */
4086
+ class UnionRaiderBlockPositionDto {
3631
4087
  /**
3632
- *파괴 방지
4088
+ * 블록 X좌표
3633
4089
  */
3634
- destroyDefence;
4090
+ x;
3635
4091
  /**
3636
- *찬스 타임
4092
+ * 블록 Y좌표
3637
4093
  */
3638
- chanceTime;
4094
+ y;
4095
+ constructor(obj) {
4096
+ const { x, y } = obj;
4097
+ this.x = x;
4098
+ this.y = y;
4099
+ }
4100
+ }
4101
+
4102
+ /**
4103
+ * 유니온 블록 기준점 좌표 정보
4104
+ */
4105
+ class UnionRaiderBlockControlPointDto {
3639
4106
  /**
3640
- *파괴 방지 필드 이벤트
4107
+ * 블록 기준점 X좌표
3641
4108
  */
3642
- eventFieldFlag;
4109
+ x;
3643
4110
  /**
3644
- *사용 주문서
4111
+ * 블록 기준점 Y좌표
3645
4112
  */
3646
- upgradeItem;
4113
+ y;
4114
+ constructor(obj) {
4115
+ const { x, y } = obj;
4116
+ this.x = x;
4117
+ this.y = y;
4118
+ }
4119
+ }
4120
+
4121
+ /**
4122
+ * 유니온 블록 정보
4123
+ */
4124
+ class UnionRaiderBlockDto {
3647
4125
  /**
3648
- *프로텍트 실드
4126
+ * 블록 모양 (전사, 마법사, 궁수, 도적, 해적, 메이플m, 하이브리드)
3649
4127
  */
3650
- protectShield;
4128
+ blockType;
3651
4129
  /**
3652
- *보너스 스탯 부여 아이템 여부
4130
+ * 블록 해당 캐릭터 직업
3653
4131
  */
3654
- bonusStatUpgrade;
4132
+ blockClass;
3655
4133
  /**
3656
- *캐릭터
4134
+ * 블록 해당 캐릭터 레벨
3657
4135
  */
3658
- characterName;
4136
+ blockLevel;
3659
4137
  /**
3660
- *월드
4138
+ * 블록 기준점 좌표
3661
4139
  */
3662
- worldName;
4140
+ blockControlPoint;
3663
4141
  /**
3664
- *대상 장비 아이템
4142
+ * 블록이 차지하고 있는 영역 좌표들 (null:미 배치 시)
3665
4143
  */
3666
- targetItem;
4144
+ blockPosition;
4145
+ constructor(obj) {
4146
+ const { block_type, block_class, block_level, block_control_point, block_position, } = obj;
4147
+ this.blockType = block_type;
4148
+ this.blockClass = block_class;
4149
+ this.blockLevel = block_level;
4150
+ this.blockControlPoint = new UnionRaiderBlockControlPointDto(block_control_point);
4151
+ this.blockPosition = block_position
4152
+ ? block_position.map((position) => new UnionRaiderBlockPositionDto(position))
4153
+ : null;
4154
+ }
4155
+ }
4156
+
4157
+ /**
4158
+ * 유니온 공격대 배치 정보
4159
+ */
4160
+ class UnionRaiderInnerStatDto {
3667
4161
  /**
3668
- *강화 일시 (KST)
4162
+ * 공격대 배치 위치 (11시 방향부터 시계 방향 순서대로 0~7)
3669
4163
  */
3670
- dateCreate;
4164
+ statFieldId;
3671
4165
  /**
3672
- * 진행 중인 스타포스 강화 이벤트 정보
4166
+ * 해당 지역 점령 효과
3673
4167
  */
3674
- starforceEventList;
4168
+ statFieldEffect;
3675
4169
  constructor(obj) {
3676
- const { id, item_upgrade_result, before_starforce_count, after_starforce_count, starcatch_result, superior_item_flag, destroy_defence, chance_time, event_field_flag, upgrade_item, protect_shield, bonus_stat_upgrade, character_name, world_name, target_item, date_create, starforce_event_list, } = obj;
3677
- this.id = id;
3678
- this.itemUpgradeResult = item_upgrade_result;
3679
- this.beforeStarforceCount = before_starforce_count;
3680
- this.afterStarforceCount = after_starforce_count;
3681
- this.starCatchResult = starcatch_result;
3682
- this.superiorItemFlag = superior_item_flag;
3683
- this.destroyDefence = destroy_defence;
3684
- this.chanceTime = chance_time;
3685
- this.eventFieldFlag = event_field_flag;
3686
- this.upgradeItem = upgrade_item;
3687
- this.protectShield = protect_shield;
3688
- this.bonusStatUpgrade = bonus_stat_upgrade;
3689
- this.characterName = character_name;
3690
- this.worldName = world_name;
3691
- this.targetItem = target_item;
3692
- this.dateCreate = new Date(date_create);
3693
- this.starforceEventList = starforce_event_list.map((event) => new StarforceEventDto(event));
4170
+ const { stat_field_id, stat_field_effect } = obj;
4171
+ this.statFieldId = stat_field_id;
4172
+ this.statFieldEffect = stat_field_effect;
3694
4173
  }
3695
4174
  }
3696
4175
 
3697
4176
  /**
3698
- * 스타포스 히스토리 응답 정보
4177
+ * 유니온 공격대 정보
3699
4178
  */
3700
- class StarforceHistoryResponseDto {
4179
+ class UnionRaiderDto {
4180
+ date;
3701
4181
  /**
3702
- * 결과
4182
+ * 유니온 공격대원 효과
3703
4183
  */
3704
- count;
4184
+ unionRaiderStat;
3705
4185
  /**
3706
- * 스타포스 히스토리
4186
+ * 유니온 공격대 점령 효과
3707
4187
  */
3708
- starforceHistory;
4188
+ unionOccupiedStat;
3709
4189
  /**
3710
- * 페이징 처리를 위한 cursor
4190
+ * 유니온 공격대 배치
4191
+ */
4192
+ unionInnerStat;
4193
+ /**
4194
+ * 유니온 블록 정보
3711
4195
  */
3712
- nextCursor;
4196
+ unionBlock;
3713
4197
  constructor(obj) {
3714
- const { count, starforce_history, next_cursor } = obj;
3715
- this.count = count;
3716
- this.starforceHistory = starforce_history.map((origin) => new StarforceHistoryDto(origin));
3717
- this.nextCursor = next_cursor;
4198
+ const { date, union_raider_stat, union_occupied_stat, union_inner_stat, union_block, } = obj;
4199
+ this.date = new Date(date);
4200
+ this.unionRaiderStat = union_raider_stat;
4201
+ this.unionOccupiedStat = union_occupied_stat;
4202
+ this.unionInnerStat = union_inner_stat.map((stat) => new UnionRaiderInnerStatDto(stat));
4203
+ this.unionBlock = union_block.map((block) => new UnionRaiderBlockDto(block));
4204
+ }
4205
+ }
4206
+
4207
+ /**
4208
+ * MapleStory OpenAPI error.<br>
4209
+ * Please refer to <a href="https://openapi.nexon.com/guide/request-api/">MapleStory API guide</a> for the error details.
4210
+ */
4211
+ class MapleStoryApiError extends Error {
4212
+ name = 'MapleStoryApiError';
4213
+ errorCode;
4214
+ message;
4215
+ constructor(errorBody) {
4216
+ const { name, message } = errorBody.error;
4217
+ super(message);
4218
+ this.errorCode = errorMap[name];
4219
+ this.message = message;
3718
4220
  }
3719
4221
  }
4222
+ /**
4223
+ * MapleStory OpenAPI error codes.<br>
4224
+ * Please refer to <a href="https://openapi.nexon.com/guide/request-api/">MapleStory API guide</a> for the error code details.
4225
+ */
4226
+ var MapleStoryApiErrorCode;
4227
+ (function (MapleStoryApiErrorCode) {
4228
+ MapleStoryApiErrorCode[MapleStoryApiErrorCode["OPENAPI00001"] = 0] = "OPENAPI00001";
4229
+ MapleStoryApiErrorCode[MapleStoryApiErrorCode["OPENAPI00002"] = 1] = "OPENAPI00002";
4230
+ MapleStoryApiErrorCode[MapleStoryApiErrorCode["OPENAPI00003"] = 2] = "OPENAPI00003";
4231
+ MapleStoryApiErrorCode[MapleStoryApiErrorCode["OPENAPI00004"] = 3] = "OPENAPI00004";
4232
+ MapleStoryApiErrorCode[MapleStoryApiErrorCode["OPENAPI00005"] = 4] = "OPENAPI00005";
4233
+ MapleStoryApiErrorCode[MapleStoryApiErrorCode["OPENAPI00006"] = 5] = "OPENAPI00006";
4234
+ MapleStoryApiErrorCode[MapleStoryApiErrorCode["OPENAPI00007"] = 6] = "OPENAPI00007";
4235
+ MapleStoryApiErrorCode[MapleStoryApiErrorCode["OPENAPI00009"] = 7] = "OPENAPI00009";
4236
+ MapleStoryApiErrorCode[MapleStoryApiErrorCode["OPENAPI00010"] = 8] = "OPENAPI00010";
4237
+ })(MapleStoryApiErrorCode || (MapleStoryApiErrorCode = {}));
4238
+ const errorMap = {
4239
+ ['OPENAPI00001']: MapleStoryApiErrorCode.OPENAPI00001,
4240
+ ['OPENAPI00002']: MapleStoryApiErrorCode.OPENAPI00002,
4241
+ ['OPENAPI00003']: MapleStoryApiErrorCode.OPENAPI00003,
4242
+ ['OPENAPI00004']: MapleStoryApiErrorCode.OPENAPI00004,
4243
+ ['OPENAPI00005']: MapleStoryApiErrorCode.OPENAPI00005,
4244
+ ['OPENAPI00006']: MapleStoryApiErrorCode.OPENAPI00006,
4245
+ ['OPENAPI00007']: MapleStoryApiErrorCode.OPENAPI00007,
4246
+ ['OPENAPI00009']: MapleStoryApiErrorCode.OPENAPI00009,
4247
+ ['OPENAPI00010']: MapleStoryApiErrorCode.OPENAPI00010,
4248
+ };
3720
4249
 
3721
4250
  dayjs.extend(timezone);
3722
4251
  dayjs.extend(utc);
@@ -3726,12 +4255,32 @@ dayjs.extend(utc);
3726
4255
  */
3727
4256
  class MapleStoryApi {
3728
4257
  apiKey;
4258
+ client;
3729
4259
  static BASE_URL = 'https://open.api.nexon.com/';
4260
+ static DEFAULT_TIMEOUT = 5000;
3730
4261
  static kstOffset = 540;
3731
- timeout;
4262
+ get timeout() {
4263
+ return this.client.defaults.timeout;
4264
+ }
4265
+ set timeout(value) {
4266
+ this.client.defaults.timeout = value;
4267
+ }
3732
4268
  constructor(apiKey) {
3733
4269
  this.apiKey = apiKey;
3734
- this.timeout = 5000;
4270
+ this.client = axios.create({
4271
+ baseURL: MapleStoryApi.BASE_URL,
4272
+ timeout: MapleStoryApi.DEFAULT_TIMEOUT,
4273
+ headers: {
4274
+ 'x-nxopen-api-key': this.apiKey,
4275
+ },
4276
+ });
4277
+ this.client.interceptors.response.use((response) => response, (error) => {
4278
+ if (error instanceof AxiosError) {
4279
+ const errorBody = error.response.data;
4280
+ throw new MapleStoryApiError(errorBody);
4281
+ }
4282
+ throw error;
4283
+ });
3735
4284
  }
3736
4285
  //#region 캐릭터 정보 조회
3737
4286
  /**
@@ -3743,25 +4292,13 @@ class MapleStoryApi {
3743
4292
  * @param characterName 캐릭터 명
3744
4293
  */
3745
4294
  async getCharacter(characterName) {
3746
- try {
3747
- const path = 'maplestory/v1/id';
3748
- const response = await axios.get(path, {
3749
- baseURL: MapleStoryApi.BASE_URL,
3750
- timeout: this.timeout,
3751
- headers: this.buildHeaders(),
3752
- params: {
3753
- character_name: characterName,
3754
- },
3755
- });
3756
- return new CharacterDto(response.data);
3757
- }
3758
- catch (e) {
3759
- if (e instanceof AxiosError) {
3760
- const errorBody = e.response.data;
3761
- throw new MapleStoryApiError(errorBody);
3762
- }
3763
- throw e;
3764
- }
4295
+ const path = 'maplestory/v1/id';
4296
+ const { data } = await this.client.get(path, {
4297
+ params: {
4298
+ character_name: characterName,
4299
+ },
4300
+ });
4301
+ return new CharacterDto(data);
3765
4302
  }
3766
4303
  /**
3767
4304
  * 기본 정보를 조회합니다.
@@ -3775,8 +4312,9 @@ class MapleStoryApi {
3775
4312
  async getCharacterBasic(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
3776
4313
  hour: 1,
3777
4314
  minute: 0,
3778
- dateOffset: 1
4315
+ dateOffset: 1,
3779
4316
  })) {
4317
+ const path = 'maplestory/v1/character/basic';
3780
4318
  const query = {
3781
4319
  ocid: ocid,
3782
4320
  date: MapleStoryApi.toDateString({
@@ -3785,23 +4323,10 @@ class MapleStoryApi {
3785
4323
  day: 21,
3786
4324
  }, dateOptions),
3787
4325
  };
3788
- try {
3789
- const path = 'maplestory/v1/character/basic';
3790
- const response = await axios.get(path, {
3791
- baseURL: MapleStoryApi.BASE_URL,
3792
- timeout: this.timeout,
3793
- headers: this.buildHeaders(),
3794
- params: query,
3795
- });
3796
- return new CharacterBasicDto(response.data);
3797
- }
3798
- catch (e) {
3799
- if (e instanceof AxiosError) {
3800
- const errorBody = e.response.data;
3801
- throw new MapleStoryApiError(errorBody);
3802
- }
3803
- throw e;
3804
- }
4326
+ const { data } = await this.client.get(path, {
4327
+ params: query,
4328
+ });
4329
+ return new CharacterBasicDto(data);
3805
4330
  }
3806
4331
  /**
3807
4332
  * 인기도 정보를 조회합니다.
@@ -3815,8 +4340,9 @@ class MapleStoryApi {
3815
4340
  async getCharacterPopularity(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
3816
4341
  hour: 1,
3817
4342
  minute: 0,
3818
- dateOffset: 1
4343
+ dateOffset: 1,
3819
4344
  })) {
4345
+ const path = 'maplestory/v1/character/popularity';
3820
4346
  const query = {
3821
4347
  ocid: ocid,
3822
4348
  date: MapleStoryApi.toDateString({
@@ -3825,23 +4351,10 @@ class MapleStoryApi {
3825
4351
  day: 21,
3826
4352
  }, dateOptions),
3827
4353
  };
3828
- try {
3829
- const path = 'maplestory/v1/character/popularity';
3830
- const response = await axios.get(path, {
3831
- baseURL: MapleStoryApi.BASE_URL,
3832
- timeout: this.timeout,
3833
- headers: this.buildHeaders(),
3834
- params: query,
3835
- });
3836
- return new CharacterPopularityDto(response.data);
3837
- }
3838
- catch (e) {
3839
- if (e instanceof AxiosError) {
3840
- const errorBody = e.response.data;
3841
- throw new MapleStoryApiError(errorBody);
3842
- }
3843
- throw e;
3844
- }
4354
+ const { data } = await this.client.get(path, {
4355
+ params: query,
4356
+ });
4357
+ return new CharacterPopularityDto(data);
3845
4358
  }
3846
4359
  /**
3847
4360
  * 종합 능력치 정보를 조회합니다.
@@ -3855,8 +4368,9 @@ class MapleStoryApi {
3855
4368
  async getCharacterStat(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
3856
4369
  hour: 1,
3857
4370
  minute: 0,
3858
- dateOffset: 1
4371
+ dateOffset: 1,
3859
4372
  })) {
4373
+ const path = 'maplestory/v1/character/stat';
3860
4374
  const query = {
3861
4375
  ocid: ocid,
3862
4376
  date: MapleStoryApi.toDateString({
@@ -3865,23 +4379,10 @@ class MapleStoryApi {
3865
4379
  day: 21,
3866
4380
  }, dateOptions),
3867
4381
  };
3868
- try {
3869
- const path = 'maplestory/v1/character/stat';
3870
- const response = await axios.get(path, {
3871
- baseURL: MapleStoryApi.BASE_URL,
3872
- timeout: this.timeout,
3873
- headers: this.buildHeaders(),
3874
- params: query,
3875
- });
3876
- return new CharacterStatDto(response.data);
3877
- }
3878
- catch (e) {
3879
- if (e instanceof AxiosError) {
3880
- const errorBody = e.response.data;
3881
- throw new MapleStoryApiError(errorBody);
3882
- }
3883
- throw e;
3884
- }
4382
+ const { data } = await this.client.get(path, {
4383
+ params: query,
4384
+ });
4385
+ return new CharacterStatDto(data);
3885
4386
  }
3886
4387
  /**
3887
4388
  * 하이퍼스탯 정보를 조회합니다.
@@ -3895,8 +4396,9 @@ class MapleStoryApi {
3895
4396
  async getCharacterHyperStat(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
3896
4397
  hour: 1,
3897
4398
  minute: 0,
3898
- dateOffset: 1
4399
+ dateOffset: 1,
3899
4400
  })) {
4401
+ const path = 'maplestory/v1/character/hyper-stat';
3900
4402
  const query = {
3901
4403
  ocid: ocid,
3902
4404
  date: MapleStoryApi.toDateString({
@@ -3905,23 +4407,10 @@ class MapleStoryApi {
3905
4407
  day: 21,
3906
4408
  }, dateOptions),
3907
4409
  };
3908
- try {
3909
- const path = 'maplestory/v1/character/hyper-stat';
3910
- const response = await axios.get(path, {
3911
- baseURL: MapleStoryApi.BASE_URL,
3912
- timeout: this.timeout,
3913
- headers: this.buildHeaders(),
3914
- params: query,
3915
- });
3916
- return new CharacterHyperStatDto(response.data);
3917
- }
3918
- catch (e) {
3919
- if (e instanceof AxiosError) {
3920
- const errorBody = e.response.data;
3921
- throw new MapleStoryApiError(errorBody);
3922
- }
3923
- throw e;
3924
- }
4410
+ const { data } = await this.client.get(path, {
4411
+ params: query,
4412
+ });
4413
+ return new CharacterHyperStatDto(data);
3925
4414
  }
3926
4415
  /**
3927
4416
  * 성향 정보를 조회합니다.
@@ -3935,8 +4424,9 @@ class MapleStoryApi {
3935
4424
  async getCharacterPropensity(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
3936
4425
  hour: 1,
3937
4426
  minute: 0,
3938
- dateOffset: 1
4427
+ dateOffset: 1,
3939
4428
  })) {
4429
+ const path = 'maplestory/v1/character/propensity';
3940
4430
  const query = {
3941
4431
  ocid: ocid,
3942
4432
  date: MapleStoryApi.toDateString({
@@ -3945,23 +4435,10 @@ class MapleStoryApi {
3945
4435
  day: 21,
3946
4436
  }, dateOptions),
3947
4437
  };
3948
- try {
3949
- const path = 'maplestory/v1/character/propensity';
3950
- const response = await axios.get(path, {
3951
- baseURL: MapleStoryApi.BASE_URL,
3952
- timeout: this.timeout,
3953
- headers: this.buildHeaders(),
3954
- params: query,
3955
- });
3956
- return new CharacterPropensityDto(response.data);
3957
- }
3958
- catch (e) {
3959
- if (e instanceof AxiosError) {
3960
- const errorBody = e.response.data;
3961
- throw new MapleStoryApiError(errorBody);
3962
- }
3963
- throw e;
3964
- }
4438
+ const { data } = await this.client.get(path, {
4439
+ params: query,
4440
+ });
4441
+ return new CharacterPropensityDto(data);
3965
4442
  }
3966
4443
  /**
3967
4444
  * 어빌리티 정보를 조회합니다.
@@ -3975,8 +4452,9 @@ class MapleStoryApi {
3975
4452
  async getCharacterAbility(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
3976
4453
  hour: 1,
3977
4454
  minute: 0,
3978
- dateOffset: 1
4455
+ dateOffset: 1,
3979
4456
  })) {
4457
+ const path = 'maplestory/v1/character/ability';
3980
4458
  const query = {
3981
4459
  ocid: ocid,
3982
4460
  date: MapleStoryApi.toDateString({
@@ -3985,23 +4463,10 @@ class MapleStoryApi {
3985
4463
  day: 21,
3986
4464
  }, dateOptions),
3987
4465
  };
3988
- try {
3989
- const path = 'maplestory/v1/character/ability';
3990
- const response = await axios.get(path, {
3991
- baseURL: MapleStoryApi.BASE_URL,
3992
- timeout: this.timeout,
3993
- headers: this.buildHeaders(),
3994
- params: query,
3995
- });
3996
- return new CharacterAbilityDto(response.data);
3997
- }
3998
- catch (e) {
3999
- if (e instanceof AxiosError) {
4000
- const errorBody = e.response.data;
4001
- throw new MapleStoryApiError(errorBody);
4002
- }
4003
- throw e;
4004
- }
4466
+ const { data } = await this.client.get(path, {
4467
+ params: query,
4468
+ });
4469
+ return new CharacterAbilityDto(data);
4005
4470
  }
4006
4471
  /**
4007
4472
  * 장착한 장비 중 캐시 장비를 제외한 나머지 장비 정보를 조회합니다.
@@ -4015,8 +4480,9 @@ class MapleStoryApi {
4015
4480
  async getCharacterItemEquipment(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4016
4481
  hour: 1,
4017
4482
  minute: 0,
4018
- dateOffset: 1
4483
+ dateOffset: 1,
4019
4484
  })) {
4485
+ const path = 'maplestory/v1/character/item-equipment';
4020
4486
  const query = {
4021
4487
  ocid: ocid,
4022
4488
  date: MapleStoryApi.toDateString({
@@ -4025,23 +4491,10 @@ class MapleStoryApi {
4025
4491
  day: 21,
4026
4492
  }, dateOptions),
4027
4493
  };
4028
- try {
4029
- const path = 'maplestory/v1/character/item-equipment';
4030
- const response = await axios.get(path, {
4031
- baseURL: MapleStoryApi.BASE_URL,
4032
- timeout: this.timeout,
4033
- headers: this.buildHeaders(),
4034
- params: query,
4035
- });
4036
- return new CharacterItemEquipmentDto(response.data);
4037
- }
4038
- catch (e) {
4039
- if (e instanceof AxiosError) {
4040
- const errorBody = e.response.data;
4041
- throw new MapleStoryApiError(errorBody);
4042
- }
4043
- throw e;
4044
- }
4494
+ const { data } = await this.client.get(path, {
4495
+ params: query,
4496
+ });
4497
+ return new CharacterItemEquipmentDto(data);
4045
4498
  }
4046
4499
  /**
4047
4500
  * 장착한 캐시 장비 정보를 조회합니다.
@@ -4055,8 +4508,9 @@ class MapleStoryApi {
4055
4508
  async getCharacterCashItemEquipment(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4056
4509
  hour: 1,
4057
4510
  minute: 0,
4058
- dateOffset: 1
4511
+ dateOffset: 1,
4059
4512
  })) {
4513
+ const path = 'maplestory/v1/character/cashitem-equipment';
4060
4514
  const query = {
4061
4515
  ocid: ocid,
4062
4516
  date: MapleStoryApi.toDateString({
@@ -4065,23 +4519,10 @@ class MapleStoryApi {
4065
4519
  day: 21,
4066
4520
  }, dateOptions),
4067
4521
  };
4068
- try {
4069
- const path = 'maplestory/v1/character/cashitem-equipment';
4070
- const response = await axios.get(path, {
4071
- baseURL: MapleStoryApi.BASE_URL,
4072
- timeout: this.timeout,
4073
- headers: this.buildHeaders(),
4074
- params: query,
4075
- });
4076
- return new CharacterCashItemEquipmentDto(response.data);
4077
- }
4078
- catch (e) {
4079
- if (e instanceof AxiosError) {
4080
- const errorBody = e.response.data;
4081
- throw new MapleStoryApiError(errorBody);
4082
- }
4083
- throw e;
4084
- }
4522
+ const { data } = await this.client.get(path, {
4523
+ params: query,
4524
+ });
4525
+ return new CharacterCashItemEquipmentDto(data);
4085
4526
  }
4086
4527
  /**
4087
4528
  * 장착한 심볼 정보를 조회합니다.
@@ -4095,8 +4536,9 @@ class MapleStoryApi {
4095
4536
  async getCharacterSymbolEquipment(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4096
4537
  hour: 1,
4097
4538
  minute: 0,
4098
- dateOffset: 1
4539
+ dateOffset: 1,
4099
4540
  })) {
4541
+ const path = 'maplestory/v1/character/symbol-equipment';
4100
4542
  const query = {
4101
4543
  ocid: ocid,
4102
4544
  date: MapleStoryApi.toDateString({
@@ -4105,23 +4547,10 @@ class MapleStoryApi {
4105
4547
  day: 21,
4106
4548
  }, dateOptions),
4107
4549
  };
4108
- try {
4109
- const path = 'maplestory/v1/character/symbol-equipment';
4110
- const response = await axios.get(path, {
4111
- baseURL: MapleStoryApi.BASE_URL,
4112
- timeout: this.timeout,
4113
- headers: this.buildHeaders(),
4114
- params: query,
4115
- });
4116
- return new CharacterSymbolEquipmentDto(response.data);
4117
- }
4118
- catch (e) {
4119
- if (e instanceof AxiosError) {
4120
- const errorBody = e.response.data;
4121
- throw new MapleStoryApiError(errorBody);
4122
- }
4123
- throw e;
4124
- }
4550
+ const { data } = await this.client.get(path, {
4551
+ params: query,
4552
+ });
4553
+ return new CharacterSymbolEquipmentDto(data);
4125
4554
  }
4126
4555
  /**
4127
4556
  * 적용받고 있는 세트 효과 정보를 조회합니다.
@@ -4135,8 +4564,9 @@ class MapleStoryApi {
4135
4564
  async getCharacterSetEffect(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4136
4565
  hour: 1,
4137
4566
  minute: 0,
4138
- dateOffset: 1
4567
+ dateOffset: 1,
4139
4568
  })) {
4569
+ const path = 'maplestory/v1/character/set-effect';
4140
4570
  const query = {
4141
4571
  ocid: ocid,
4142
4572
  date: MapleStoryApi.toDateString({
@@ -4145,23 +4575,10 @@ class MapleStoryApi {
4145
4575
  day: 21,
4146
4576
  }, dateOptions),
4147
4577
  };
4148
- try {
4149
- const path = 'maplestory/v1/character/set-effect';
4150
- const response = await axios.get(path, {
4151
- baseURL: MapleStoryApi.BASE_URL,
4152
- timeout: this.timeout,
4153
- headers: this.buildHeaders(),
4154
- params: query,
4155
- });
4156
- return new CharacterSetEffectDto(response.data);
4157
- }
4158
- catch (e) {
4159
- if (e instanceof AxiosError) {
4160
- const errorBody = e.response.data;
4161
- throw new MapleStoryApiError(errorBody);
4162
- }
4163
- throw e;
4164
- }
4578
+ const { data } = await this.client.get(path, {
4579
+ params: query,
4580
+ });
4581
+ return new CharacterSetEffectDto(data);
4165
4582
  }
4166
4583
  /**
4167
4584
  * 장착 중인 헤어, 성형, 피부 정보를 조회합니다.
@@ -4175,8 +4592,9 @@ class MapleStoryApi {
4175
4592
  async getCharacterBeautyEquipment(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4176
4593
  hour: 1,
4177
4594
  minute: 0,
4178
- dateOffset: 1
4595
+ dateOffset: 1,
4179
4596
  })) {
4597
+ const path = 'maplestory/v1/character/beauty-equipment';
4180
4598
  const query = {
4181
4599
  ocid: ocid,
4182
4600
  date: MapleStoryApi.toDateString({
@@ -4185,23 +4603,10 @@ class MapleStoryApi {
4185
4603
  day: 21,
4186
4604
  }, dateOptions),
4187
4605
  };
4188
- try {
4189
- const path = 'maplestory/v1/character/beauty-equipment';
4190
- const response = await axios.get(path, {
4191
- baseURL: MapleStoryApi.BASE_URL,
4192
- timeout: this.timeout,
4193
- headers: this.buildHeaders(),
4194
- params: query,
4195
- });
4196
- return new CharacterBeautyEquipmentDto(response.data);
4197
- }
4198
- catch (e) {
4199
- if (e instanceof AxiosError) {
4200
- const errorBody = e.response.data;
4201
- throw new MapleStoryApiError(errorBody);
4202
- }
4203
- throw e;
4204
- }
4606
+ const { data } = await this.client.get(path, {
4607
+ params: query,
4608
+ });
4609
+ return new CharacterBeautyEquipmentDto(data);
4205
4610
  }
4206
4611
  /**
4207
4612
  * 장착한 안드로이드 정보를 조회합니다.
@@ -4215,8 +4620,9 @@ class MapleStoryApi {
4215
4620
  async getCharacterAndroidEquipment(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4216
4621
  hour: 1,
4217
4622
  minute: 0,
4218
- dateOffset: 1
4623
+ dateOffset: 1,
4219
4624
  })) {
4625
+ const path = 'maplestory/v1/character/android-equipment';
4220
4626
  const query = {
4221
4627
  ocid: ocid,
4222
4628
  date: MapleStoryApi.toDateString({
@@ -4225,23 +4631,10 @@ class MapleStoryApi {
4225
4631
  day: 21,
4226
4632
  }, dateOptions),
4227
4633
  };
4228
- try {
4229
- const path = 'maplestory/v1/character/android-equipment';
4230
- const response = await axios.get(path, {
4231
- baseURL: MapleStoryApi.BASE_URL,
4232
- timeout: this.timeout,
4233
- headers: this.buildHeaders(),
4234
- params: query,
4235
- });
4236
- return new CharacterAndroidEquipmentDto(response.data);
4237
- }
4238
- catch (e) {
4239
- if (e instanceof AxiosError) {
4240
- const errorBody = e.response.data;
4241
- throw new MapleStoryApiError(errorBody);
4242
- }
4243
- throw e;
4244
- }
4634
+ const { data } = await this.client.get(path, {
4635
+ params: query,
4636
+ });
4637
+ return new CharacterAndroidEquipmentDto(data);
4245
4638
  }
4246
4639
  /**
4247
4640
  * 장착한 펫 및 펫 스킬, 장비 정보를 조회합니다.
@@ -4255,8 +4648,9 @@ class MapleStoryApi {
4255
4648
  async getCharacterPetEquipment(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4256
4649
  hour: 1,
4257
4650
  minute: 0,
4258
- dateOffset: 1
4651
+ dateOffset: 1,
4259
4652
  })) {
4653
+ const path = 'maplestory/v1/character/pet-equipment';
4260
4654
  const query = {
4261
4655
  ocid: ocid,
4262
4656
  date: MapleStoryApi.toDateString({
@@ -4265,23 +4659,10 @@ class MapleStoryApi {
4265
4659
  day: 21,
4266
4660
  }, dateOptions),
4267
4661
  };
4268
- try {
4269
- const path = 'maplestory/v1/character/pet-equipment';
4270
- const response = await axios.get(path, {
4271
- baseURL: MapleStoryApi.BASE_URL,
4272
- timeout: this.timeout,
4273
- headers: this.buildHeaders(),
4274
- params: query,
4275
- });
4276
- return new CharacterPetEquipmentDto(response.data);
4277
- }
4278
- catch (e) {
4279
- if (e instanceof AxiosError) {
4280
- const errorBody = e.response.data;
4281
- throw new MapleStoryApiError(errorBody);
4282
- }
4283
- throw e;
4284
- }
4662
+ const { data } = await this.client.get(path, {
4663
+ params: query,
4664
+ });
4665
+ return new CharacterPetEquipmentDto(data);
4285
4666
  }
4286
4667
  /**
4287
4668
  * 캐릭터 스킬과 하이퍼 스킬 정보를 조회합니다.
@@ -4307,8 +4688,9 @@ class MapleStoryApi {
4307
4688
  async getCharacterSkill(ocid, characterSkillGrade, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4308
4689
  hour: 1,
4309
4690
  minute: 0,
4310
- dateOffset: 1
4691
+ dateOffset: 1,
4311
4692
  })) {
4693
+ const path = 'maplestory/v1/character/skill';
4312
4694
  const query = {
4313
4695
  ocid: ocid,
4314
4696
  character_skill_grade: characterSkillGrade,
@@ -4318,23 +4700,10 @@ class MapleStoryApi {
4318
4700
  day: 21,
4319
4701
  }, dateOptions),
4320
4702
  };
4321
- try {
4322
- const path = 'maplestory/v1/character/skill';
4323
- const response = await axios.get(path, {
4324
- baseURL: MapleStoryApi.BASE_URL,
4325
- timeout: this.timeout,
4326
- headers: this.buildHeaders(),
4327
- params: query,
4328
- });
4329
- return new CharacterSkillDto(response.data);
4330
- }
4331
- catch (e) {
4332
- if (e instanceof AxiosError) {
4333
- const errorBody = e.response.data;
4334
- throw new MapleStoryApiError(errorBody);
4335
- }
4336
- throw e;
4337
- }
4703
+ const { data } = await this.client.get(path, {
4704
+ params: query,
4705
+ });
4706
+ return new CharacterSkillDto(data);
4338
4707
  }
4339
4708
  /**
4340
4709
  * 장착 링크 스킬 정보를 조회합니다.
@@ -4348,8 +4717,9 @@ class MapleStoryApi {
4348
4717
  async getCharacterLinkSkill(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4349
4718
  hour: 1,
4350
4719
  minute: 0,
4351
- dateOffset: 1
4720
+ dateOffset: 1,
4352
4721
  })) {
4722
+ const path = 'maplestory/v1/character/link-skill';
4353
4723
  const query = {
4354
4724
  ocid: ocid,
4355
4725
  date: MapleStoryApi.toDateString({
@@ -4358,23 +4728,10 @@ class MapleStoryApi {
4358
4728
  day: 21,
4359
4729
  }, dateOptions),
4360
4730
  };
4361
- try {
4362
- const path = 'maplestory/v1/character/link-skill';
4363
- const response = await axios.get(path, {
4364
- baseURL: MapleStoryApi.BASE_URL,
4365
- timeout: this.timeout,
4366
- headers: this.buildHeaders(),
4367
- params: query,
4368
- });
4369
- return new CharacterLinkSkillDto(response.data);
4370
- }
4371
- catch (e) {
4372
- if (e instanceof AxiosError) {
4373
- const errorBody = e.response.data;
4374
- throw new MapleStoryApiError(errorBody);
4375
- }
4376
- throw e;
4377
- }
4731
+ const { data } = await this.client.get(path, {
4732
+ params: query,
4733
+ });
4734
+ return new CharacterLinkSkillDto(data);
4378
4735
  }
4379
4736
  /**
4380
4737
  * V매트릭스 슬롯 정보와 장착한 V코어 정보를 조회합니다.
@@ -4388,8 +4745,9 @@ class MapleStoryApi {
4388
4745
  async getCharacterVMatrix(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4389
4746
  hour: 1,
4390
4747
  minute: 0,
4391
- dateOffset: 1
4748
+ dateOffset: 1,
4392
4749
  })) {
4750
+ const path = 'maplestory/v1/character/vmatrix';
4393
4751
  const query = {
4394
4752
  ocid: ocid,
4395
4753
  date: MapleStoryApi.toDateString({
@@ -4398,23 +4756,10 @@ class MapleStoryApi {
4398
4756
  day: 21,
4399
4757
  }, dateOptions),
4400
4758
  };
4401
- try {
4402
- const path = 'maplestory/v1/character/vmatrix';
4403
- const response = await axios.get(path, {
4404
- baseURL: MapleStoryApi.BASE_URL,
4405
- timeout: this.timeout,
4406
- headers: this.buildHeaders(),
4407
- params: query,
4408
- });
4409
- return new CharacterVMatrixDto(response.data);
4410
- }
4411
- catch (e) {
4412
- if (e instanceof AxiosError) {
4413
- const errorBody = e.response.data;
4414
- throw new MapleStoryApiError(errorBody);
4415
- }
4416
- throw e;
4417
- }
4759
+ const { data } = await this.client.get(path, {
4760
+ params: query,
4761
+ });
4762
+ return new CharacterVMatrixDto(data);
4418
4763
  }
4419
4764
  /**
4420
4765
  * HEXA 매트릭스에 장착한 HEXA 코어 정보를 조회합니다.
@@ -4428,8 +4773,9 @@ class MapleStoryApi {
4428
4773
  async getCharacterHexaMatrix(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4429
4774
  hour: 1,
4430
4775
  minute: 0,
4431
- dateOffset: 1
4776
+ dateOffset: 1,
4432
4777
  })) {
4778
+ const path = 'maplestory/v1/character/hexamatrix';
4433
4779
  const query = {
4434
4780
  ocid: ocid,
4435
4781
  date: MapleStoryApi.toDateString({
@@ -4438,23 +4784,10 @@ class MapleStoryApi {
4438
4784
  day: 21,
4439
4785
  }, dateOptions),
4440
4786
  };
4441
- try {
4442
- const path = 'maplestory/v1/character/hexamatrix';
4443
- const response = await axios.get(path, {
4444
- baseURL: MapleStoryApi.BASE_URL,
4445
- timeout: this.timeout,
4446
- headers: this.buildHeaders(),
4447
- params: query,
4448
- });
4449
- return new CharacterHexaMatrixDto(response.data);
4450
- }
4451
- catch (e) {
4452
- if (e instanceof AxiosError) {
4453
- const errorBody = e.response.data;
4454
- throw new MapleStoryApiError(errorBody);
4455
- }
4456
- throw e;
4457
- }
4787
+ const { data } = await this.client.get(path, {
4788
+ params: query,
4789
+ });
4790
+ return new CharacterHexaMatrixDto(data);
4458
4791
  }
4459
4792
  /**
4460
4793
  * HEXA 매트릭스에 설정한 HEXA 스탯 정보를 조회합니다.
@@ -4468,8 +4801,9 @@ class MapleStoryApi {
4468
4801
  async getCharacterHexaMatrixStat(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4469
4802
  hour: 1,
4470
4803
  minute: 0,
4471
- dateOffset: 1
4804
+ dateOffset: 1,
4472
4805
  })) {
4806
+ const path = 'maplestory/v1/character/hexamatrix-stat';
4473
4807
  const query = {
4474
4808
  ocid: ocid,
4475
4809
  date: MapleStoryApi.toDateString({
@@ -4478,23 +4812,10 @@ class MapleStoryApi {
4478
4812
  day: 21,
4479
4813
  }, dateOptions),
4480
4814
  };
4481
- try {
4482
- const path = 'maplestory/v1/character/hexamatrix-stat';
4483
- const response = await axios.get(path, {
4484
- baseURL: MapleStoryApi.BASE_URL,
4485
- timeout: this.timeout,
4486
- headers: this.buildHeaders(),
4487
- params: query,
4488
- });
4489
- return new CharacterHexaMatrixStatDto(response.data);
4490
- }
4491
- catch (e) {
4492
- if (e instanceof AxiosError) {
4493
- const errorBody = e.response.data;
4494
- throw new MapleStoryApiError(errorBody);
4495
- }
4496
- throw e;
4497
- }
4815
+ const { data } = await this.client.get(path, {
4816
+ params: query,
4817
+ });
4818
+ return new CharacterHexaMatrixStatDto(data);
4498
4819
  }
4499
4820
  /**
4500
4821
  * 캐릭터 무릉도장 최고 기록 정보를 조회합니다.
@@ -4508,8 +4829,9 @@ class MapleStoryApi {
4508
4829
  async getCharacterDojang(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4509
4830
  hour: 1,
4510
4831
  minute: 0,
4511
- dateOffset: 1
4832
+ dateOffset: 1,
4512
4833
  })) {
4834
+ const path = 'maplestory/v1/character/dojang';
4513
4835
  const query = {
4514
4836
  ocid: ocid,
4515
4837
  date: MapleStoryApi.toDateString({
@@ -4518,23 +4840,10 @@ class MapleStoryApi {
4518
4840
  day: 21,
4519
4841
  }, dateOptions),
4520
4842
  };
4521
- try {
4522
- const path = 'maplestory/v1/character/dojang';
4523
- const response = await axios.get(path, {
4524
- baseURL: MapleStoryApi.BASE_URL,
4525
- timeout: this.timeout,
4526
- headers: this.buildHeaders(),
4527
- params: query,
4528
- });
4529
- return new CharacterDojangDto(response.data);
4530
- }
4531
- catch (e) {
4532
- if (e instanceof AxiosError) {
4533
- const errorBody = e.response.data;
4534
- throw new MapleStoryApiError(errorBody);
4535
- }
4536
- throw e;
4537
- }
4843
+ const { data } = await this.client.get(path, {
4844
+ params: query,
4845
+ });
4846
+ return new CharacterDojangDto(data);
4538
4847
  }
4539
4848
  //#endregion
4540
4849
  //#region 유니온 정보 조회
@@ -4547,11 +4856,12 @@ class MapleStoryApi {
4547
4856
  * @param ocid 캐릭터 식별자
4548
4857
  * @param dateOptions 조회 기준일 (KST)
4549
4858
  */
4550
- async getUnionInfo(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4859
+ async getUnion(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4551
4860
  hour: 1,
4552
4861
  minute: 0,
4553
- dateOffset: 1
4862
+ dateOffset: 1,
4554
4863
  })) {
4864
+ const path = 'maplestory/v1/user/union';
4555
4865
  const query = {
4556
4866
  ocid: ocid,
4557
4867
  date: MapleStoryApi.toDateString({
@@ -4560,23 +4870,10 @@ class MapleStoryApi {
4560
4870
  day: 21,
4561
4871
  }, dateOptions),
4562
4872
  };
4563
- try {
4564
- const path = 'maplestory/v1/user/union';
4565
- const response = await axios.get(path, {
4566
- baseURL: MapleStoryApi.BASE_URL,
4567
- timeout: this.timeout,
4568
- headers: this.buildHeaders(),
4569
- params: query,
4570
- });
4571
- return new UnionDto(response.data);
4572
- }
4573
- catch (e) {
4574
- if (e instanceof AxiosError) {
4575
- const errorBody = e.response.data;
4576
- throw new MapleStoryApiError(errorBody);
4577
- }
4578
- throw e;
4579
- }
4873
+ const { data } = await this.client.get(path, {
4874
+ params: query,
4875
+ });
4876
+ return new UnionDto(data);
4580
4877
  }
4581
4878
  /**
4582
4879
  * 유니온 공격대 정보를 조회합니다.
@@ -4587,11 +4884,12 @@ class MapleStoryApi {
4587
4884
  * @param ocid 캐릭터 식별자
4588
4885
  * @param dateOptions 조회 기준일 (KST)
4589
4886
  */
4590
- async getUnionRaiderInfo(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4887
+ async getUnionRaider(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4591
4888
  hour: 1,
4592
4889
  minute: 0,
4593
- dateOffset: 1
4890
+ dateOffset: 1,
4594
4891
  })) {
4892
+ const path = 'maplestory/v1/user/union-raider';
4595
4893
  const query = {
4596
4894
  ocid: ocid,
4597
4895
  date: MapleStoryApi.toDateString({
@@ -4600,23 +4898,38 @@ class MapleStoryApi {
4600
4898
  day: 21,
4601
4899
  }, dateOptions),
4602
4900
  };
4603
- try {
4604
- const path = 'maplestory/v1/user/union-raider';
4605
- const response = await axios.get(path, {
4606
- baseURL: MapleStoryApi.BASE_URL,
4607
- timeout: this.timeout,
4608
- headers: this.buildHeaders(),
4609
- params: query
4610
- });
4611
- return new UnionRaiderDto(response.data);
4612
- }
4613
- catch (e) {
4614
- if (e instanceof AxiosError) {
4615
- const errorBody = e.response.data;
4616
- throw new MapleStoryApiError(errorBody);
4617
- }
4618
- throw e;
4619
- }
4901
+ const { data } = await this.client.get(path, {
4902
+ params: query,
4903
+ });
4904
+ return new UnionRaiderDto(data);
4905
+ }
4906
+ /**
4907
+ * 유니온 아티팩트 정보를 조회합니다.
4908
+ * - 2023년 12월 21일 데이터부터 조회할 수 있습니다.
4909
+ * - 유니온 정보 조회 API는 일자별 데이터로 매일 오전 1시부터 전일 데이터 조회가 가능합니다. (예를 들어, 12월 22일 데이터를 조회하면 22일 00시부터 23일의 00시 사이의 데이터가 조회됩니다.)
4910
+ * - 게임 콘텐츠 변경으로 ocid가 변경될 수 있습니다. ocid 기반 서비스 갱신 시 유의해 주시길 바랍니다.
4911
+ *
4912
+ * @param ocid 캐릭터 식별자
4913
+ * @param dateOptions 조회 기준일 (KST)
4914
+ */
4915
+ async getUnionArtifact(ocid, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4916
+ hour: 1,
4917
+ minute: 0,
4918
+ dateOffset: 1,
4919
+ })) {
4920
+ const path = 'maplestory/v1/user/union-artifact';
4921
+ const query = {
4922
+ ocid: ocid,
4923
+ date: MapleStoryApi.toDateString({
4924
+ year: 2023,
4925
+ month: 12,
4926
+ day: 21,
4927
+ }, dateOptions),
4928
+ };
4929
+ const { data } = await this.client.get(path, {
4930
+ params: query,
4931
+ });
4932
+ return new UnionArtifactDto(data);
4620
4933
  }
4621
4934
  //#endregion
4622
4935
  //#region 길드 정보 조회
@@ -4630,26 +4943,14 @@ class MapleStoryApi {
4630
4943
  * @param worldName 월드 명
4631
4944
  */
4632
4945
  async getGuild(guildName, worldName) {
4633
- try {
4634
- const path = 'maplestory/v1/guild/id';
4635
- const response = await axios.get(path, {
4636
- baseURL: MapleStoryApi.BASE_URL,
4637
- timeout: this.timeout,
4638
- headers: this.buildHeaders(),
4639
- params: {
4640
- guild_name: guildName,
4641
- world_name: worldName,
4642
- },
4643
- });
4644
- return new GuildDto(response.data);
4645
- }
4646
- catch (e) {
4647
- if (e instanceof AxiosError) {
4648
- const errorBody = e.response.data;
4649
- throw new MapleStoryApiError(errorBody);
4650
- }
4651
- throw e;
4652
- }
4946
+ const path = 'maplestory/v1/guild/id';
4947
+ const { data } = await this.client.get(path, {
4948
+ params: {
4949
+ guild_name: guildName,
4950
+ world_name: worldName,
4951
+ },
4952
+ });
4953
+ return new GuildDto(data);
4653
4954
  }
4654
4955
  /**
4655
4956
  * 길드 기본 정보를 조회합니다.
@@ -4663,8 +4964,9 @@ class MapleStoryApi {
4663
4964
  async getGuildBasic(guildId, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4664
4965
  hour: 1,
4665
4966
  minute: 0,
4666
- dateOffset: 1
4967
+ dateOffset: 1,
4667
4968
  })) {
4969
+ const path = 'maplestory/v1/guild/basic';
4668
4970
  const query = {
4669
4971
  oguild_id: guildId,
4670
4972
  date: MapleStoryApi.toDateString({
@@ -4673,25 +4975,13 @@ class MapleStoryApi {
4673
4975
  day: 21,
4674
4976
  }, dateOptions),
4675
4977
  };
4676
- try {
4677
- const path = 'maplestory/v1/guild/basic';
4678
- const response = await axios.get(path, {
4679
- baseURL: MapleStoryApi.BASE_URL,
4680
- timeout: this.timeout,
4681
- headers: this.buildHeaders(),
4682
- params: query,
4683
- });
4684
- return new GuildBasicDto(response.data);
4685
- }
4686
- catch (e) {
4687
- if (e instanceof AxiosError) {
4688
- const errorBody = e.response.data;
4689
- throw new MapleStoryApiError(errorBody);
4690
- }
4691
- throw e;
4692
- }
4978
+ const { data } = await this.client.get(path, {
4979
+ params: query,
4980
+ });
4981
+ return new GuildBasicDto(data);
4693
4982
  }
4694
4983
  async getStarforceHistory(count, parameter) {
4984
+ const path = 'maplestory/v1/history/starforce';
4695
4985
  const query = {
4696
4986
  count,
4697
4987
  };
@@ -4703,65 +4993,67 @@ class MapleStoryApi {
4703
4993
  year: 2023,
4704
4994
  month: 12,
4705
4995
  day: 27,
4706
- }, parameter ?? MapleStoryApi.getProperDefaultDateOptions({
4707
- hour: 0,
4708
- minute: 0,
4709
- dateOffset: 0
4710
- }));
4711
- }
4712
- try {
4713
- const path = 'maplestory/v1/history/starforce';
4714
- const response = await axios.get(path, {
4715
- baseURL: MapleStoryApi.BASE_URL,
4716
- timeout: this.timeout,
4717
- headers: this.buildHeaders(),
4718
- params: query,
4719
- });
4720
- return new StarforceHistoryResponseDto(response.data);
4721
- }
4722
- catch (e) {
4723
- if (e instanceof AxiosError) {
4724
- const errorBody = e.response.data;
4725
- throw new MapleStoryApiError(errorBody);
4726
- }
4727
- throw e;
4996
+ }, parameter ??
4997
+ MapleStoryApi.getProperDefaultDateOptions({
4998
+ hour: 0,
4999
+ minute: 0,
5000
+ dateOffset: 0,
5001
+ }));
4728
5002
  }
5003
+ const { data } = await this.client.get(path, {
5004
+ params: query,
5005
+ });
5006
+ return new StarforceHistoryResponseDto(data);
4729
5007
  }
4730
5008
  async getCubeHistory(count, parameter) {
5009
+ const path = 'maplestory/v1/history/cube';
4731
5010
  const query = {
4732
5011
  count,
4733
5012
  };
4734
5013
  if (typeof parameter === 'string') {
4735
5014
  query.cursor = parameter;
4736
5015
  }
4737
- else if (typeof parameter === 'object') {
5016
+ else if (typeof parameter === 'object' || parameter === undefined) {
4738
5017
  query.date = MapleStoryApi.toDateString({
4739
5018
  year: 2022,
4740
5019
  month: 11,
4741
5020
  day: 25,
4742
- }, parameter ?? MapleStoryApi.getProperDefaultDateOptions({
4743
- hour: 4,
4744
- minute: 0,
4745
- dateOffset: 1
4746
- }));
5021
+ }, parameter ??
5022
+ MapleStoryApi.getProperDefaultDateOptions({
5023
+ hour: 4,
5024
+ minute: 0,
5025
+ dateOffset: 1,
5026
+ }));
4747
5027
  }
4748
- try {
4749
- const path = 'maplestory/v1/history/cube';
4750
- const response = await axios.get(path, {
4751
- baseURL: MapleStoryApi.BASE_URL,
4752
- timeout: this.timeout,
4753
- headers: this.buildHeaders(),
4754
- params: query,
4755
- });
4756
- return new CubeHistoryResponseDto(response.data);
5028
+ const { data } = await this.client.get(path, {
5029
+ params: query,
5030
+ });
5031
+ return new CubeHistoryResponseDto(data);
5032
+ }
5033
+ async getPotentialHistory(count, parameter) {
5034
+ const path = 'maplestory/v1/history/potential';
5035
+ const query = {
5036
+ count,
5037
+ };
5038
+ if (typeof parameter === 'string') {
5039
+ query.cursor = parameter;
4757
5040
  }
4758
- catch (e) {
4759
- if (e instanceof AxiosError) {
4760
- const errorBody = e.response.data;
4761
- throw new MapleStoryApiError(errorBody);
4762
- }
4763
- throw e;
5041
+ else if (typeof parameter === 'object' || parameter === undefined) {
5042
+ query.date = MapleStoryApi.toDateString({
5043
+ year: 2024,
5044
+ month: 1,
5045
+ day: 25,
5046
+ }, parameter ??
5047
+ MapleStoryApi.getProperDefaultDateOptions({
5048
+ hour: 4,
5049
+ minute: 0,
5050
+ dateOffset: 1,
5051
+ }));
4764
5052
  }
5053
+ const { data } = await this.client.get(path, {
5054
+ params: query,
5055
+ });
5056
+ return new PotentialHistoryResponseDto(data);
4765
5057
  }
4766
5058
  //#endregion
4767
5059
  //#region 랭킹 정보 조회
@@ -4778,8 +5070,9 @@ class MapleStoryApi {
4778
5070
  async getOverallRanking(filterOptions, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4779
5071
  hour: 8,
4780
5072
  minute: 30,
4781
- dateOffset: 0
5073
+ dateOffset: 0,
4782
5074
  })) {
5075
+ const path = 'maplestory/v1/ranking/overall';
4783
5076
  const query = {
4784
5077
  date: MapleStoryApi.toDateString({
4785
5078
  year: 2023,
@@ -4795,23 +5088,10 @@ class MapleStoryApi {
4795
5088
  query.ocid = ocid;
4796
5089
  query.page = page;
4797
5090
  }
4798
- try {
4799
- const path = 'maplestory/v1/ranking/overall';
4800
- const response = await axios.get(path, {
4801
- baseURL: MapleStoryApi.BASE_URL,
4802
- timeout: this.timeout,
4803
- headers: this.buildHeaders(),
4804
- params: query,
4805
- });
4806
- return new OverallRankingResponseDto(response.data);
4807
- }
4808
- catch (e) {
4809
- if (e instanceof AxiosError) {
4810
- const errorBody = e.response.data;
4811
- throw new MapleStoryApiError(errorBody);
4812
- }
4813
- throw e;
4814
- }
5091
+ const { data } = await this.client.get(path, {
5092
+ params: query,
5093
+ });
5094
+ return new OverallRankingResponseDto(data);
4815
5095
  }
4816
5096
  /**
4817
5097
  * 유니온 랭킹 정보를 조회합니다.
@@ -4825,8 +5105,9 @@ class MapleStoryApi {
4825
5105
  async getUnionRanking(filterOptions, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4826
5106
  hour: 8,
4827
5107
  minute: 30,
4828
- dateOffset: 0
5108
+ dateOffset: 0,
4829
5109
  })) {
5110
+ const path = 'maplestory/v1/ranking/union';
4830
5111
  const query = {
4831
5112
  date: MapleStoryApi.toDateString({
4832
5113
  year: 2023,
@@ -4840,23 +5121,10 @@ class MapleStoryApi {
4840
5121
  query.ocid = ocid;
4841
5122
  query.page = page;
4842
5123
  }
4843
- try {
4844
- const path = 'maplestory/v1/ranking/union';
4845
- const response = await axios.get(path, {
4846
- baseURL: MapleStoryApi.BASE_URL,
4847
- timeout: this.timeout,
4848
- headers: this.buildHeaders(),
4849
- params: query,
4850
- });
4851
- return new UnionRankingResponseDto(response.data);
4852
- }
4853
- catch (e) {
4854
- if (e instanceof AxiosError) {
4855
- const errorBody = e.response.data;
4856
- throw new MapleStoryApiError(errorBody);
4857
- }
4858
- throw e;
4859
- }
5124
+ const { data } = await this.client.get(path, {
5125
+ params: query,
5126
+ });
5127
+ return new UnionRankingResponseDto(data);
4860
5128
  }
4861
5129
  /**
4862
5130
  * 길드 랭킹 정보를 조회합니다.
@@ -4870,8 +5138,9 @@ class MapleStoryApi {
4870
5138
  async getGuildRanking(filterOptions, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4871
5139
  hour: 8,
4872
5140
  minute: 30,
4873
- dateOffset: 0
5141
+ dateOffset: 0,
4874
5142
  })) {
5143
+ const path = 'maplestory/v1/ranking/guild';
4875
5144
  const query = {
4876
5145
  date: MapleStoryApi.toDateString({
4877
5146
  year: 2023,
@@ -4887,23 +5156,10 @@ class MapleStoryApi {
4887
5156
  query.ocid = ocid;
4888
5157
  query.page = page;
4889
5158
  }
4890
- try {
4891
- const path = 'maplestory/v1/ranking/guild';
4892
- const response = await axios.get(path, {
4893
- baseURL: MapleStoryApi.BASE_URL,
4894
- timeout: this.timeout,
4895
- headers: this.buildHeaders(),
4896
- params: query,
4897
- });
4898
- return new GuildRankingResponseDto(response.data);
4899
- }
4900
- catch (e) {
4901
- if (e instanceof AxiosError) {
4902
- const errorBody = e.response.data;
4903
- throw new MapleStoryApiError(errorBody);
4904
- }
4905
- throw e;
4906
- }
5159
+ const { data } = await this.client.get(path, {
5160
+ params: query,
5161
+ });
5162
+ return new GuildRankingResponseDto(data);
4907
5163
  }
4908
5164
  /**
4909
5165
  * 무릉도장 랭킹 정보를 조회합니다.
@@ -4917,8 +5173,9 @@ class MapleStoryApi {
4917
5173
  async getDojangRanking(filterOptions, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4918
5174
  hour: 8,
4919
5175
  minute: 30,
4920
- dateOffset: 0
5176
+ dateOffset: 0,
4921
5177
  })) {
5178
+ const path = 'maplestory/v1/ranking/dojang';
4922
5179
  const query = {
4923
5180
  date: MapleStoryApi.toDateString({
4924
5181
  year: 2023,
@@ -4935,23 +5192,10 @@ class MapleStoryApi {
4935
5192
  query.ocid = ocid;
4936
5193
  query.page = page;
4937
5194
  }
4938
- try {
4939
- const path = 'maplestory/v1/ranking/dojang';
4940
- const response = await axios.get(path, {
4941
- baseURL: MapleStoryApi.BASE_URL,
4942
- timeout: this.timeout,
4943
- headers: this.buildHeaders(),
4944
- params: query,
4945
- });
4946
- return new DojangRankingResponseDto(response.data);
4947
- }
4948
- catch (e) {
4949
- if (e instanceof AxiosError) {
4950
- const errorBody = e.response.data;
4951
- throw new MapleStoryApiError(errorBody);
4952
- }
4953
- throw e;
4954
- }
5195
+ const { data } = await this.client.get(path, {
5196
+ params: query,
5197
+ });
5198
+ return new DojangRankingResponseDto(data);
4955
5199
  }
4956
5200
  /**
4957
5201
  * 더 시드 랭킹 정보를 조회합니다.
@@ -4965,8 +5209,9 @@ class MapleStoryApi {
4965
5209
  async getSeedRanking(filterOptions, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
4966
5210
  hour: 8,
4967
5211
  minute: 30,
4968
- dateOffset: 0
5212
+ dateOffset: 0,
4969
5213
  })) {
5214
+ const path = 'maplestory/v1/ranking/theseed';
4970
5215
  const query = {
4971
5216
  date: MapleStoryApi.toDateString({
4972
5217
  year: 2023,
@@ -4980,23 +5225,10 @@ class MapleStoryApi {
4980
5225
  query.ocid = ocid;
4981
5226
  query.page = page;
4982
5227
  }
4983
- try {
4984
- const path = 'maplestory/v1/ranking/theseed';
4985
- const response = await axios.get(path, {
4986
- baseURL: MapleStoryApi.BASE_URL,
4987
- timeout: this.timeout,
4988
- headers: this.buildHeaders(),
4989
- params: query,
4990
- });
4991
- return new TheSeedRankingResponseDto(response.data);
4992
- }
4993
- catch (e) {
4994
- if (e instanceof AxiosError) {
4995
- const errorBody = e.response.data;
4996
- throw new MapleStoryApiError(errorBody);
4997
- }
4998
- throw e;
4999
- }
5228
+ const { data } = await this.client.get(path, {
5229
+ params: query,
5230
+ });
5231
+ return new TheSeedRankingResponseDto(data);
5000
5232
  }
5001
5233
  /**
5002
5234
  * 업적 랭킹 정보를 조회합니다.
@@ -5010,8 +5242,9 @@ class MapleStoryApi {
5010
5242
  async getAchievementRanking(filterOptions, dateOptions = MapleStoryApi.getProperDefaultDateOptions({
5011
5243
  hour: 8,
5012
5244
  minute: 30,
5013
- dateOffset: 0
5245
+ dateOffset: 0,
5014
5246
  })) {
5247
+ const path = 'maplestory/v1/ranking/achievement';
5015
5248
  const query = {
5016
5249
  date: MapleStoryApi.toDateString({
5017
5250
  year: 2023,
@@ -5024,23 +5257,10 @@ class MapleStoryApi {
5024
5257
  query.ocid = ocid;
5025
5258
  query.page = page;
5026
5259
  }
5027
- try {
5028
- const path = 'maplestory/v1/ranking/achievement';
5029
- const response = await axios.get(path, {
5030
- baseURL: MapleStoryApi.BASE_URL,
5031
- timeout: this.timeout,
5032
- headers: this.buildHeaders(),
5033
- params: query,
5034
- });
5035
- return new AchievementRankingResponseDto(response.data);
5036
- }
5037
- catch (e) {
5038
- if (e instanceof AxiosError) {
5039
- const errorBody = e.response.data;
5040
- throw new MapleStoryApiError(errorBody);
5041
- }
5042
- throw e;
5043
- }
5260
+ const { data } = await this.client.get(path, {
5261
+ params: query,
5262
+ });
5263
+ return new AchievementRankingResponseDto(data);
5044
5264
  }
5045
5265
  //#endregion
5046
5266
  /**
@@ -5079,11 +5299,6 @@ class MapleStoryApi {
5079
5299
  const xml = (await xml2js.parseStringPromise(response.data));
5080
5300
  return new InspectionInfoDto(xml);
5081
5301
  }
5082
- buildHeaders() {
5083
- return {
5084
- 'x-nxopen-api-key': this.apiKey,
5085
- };
5086
- }
5087
5302
  /**
5088
5303
  * API 서버의 데이터 갱신 시간에 따라 데이터가 조회 가능한 최신 날짜를 반환합니다.
5089
5304
  *
@@ -5108,7 +5323,7 @@ class MapleStoryApi {
5108
5323
  return {
5109
5324
  year: adjustedDate.year(),
5110
5325
  month: adjustedDate.month() + 1,
5111
- day: adjustedDate.date()
5326
+ day: adjustedDate.date(),
5112
5327
  };
5113
5328
  }
5114
5329
  /**
@@ -5126,8 +5341,10 @@ class MapleStoryApi {
5126
5341
  (year === minYear && month === minMonth && day < minDay)) {
5127
5342
  throw new Error(`You can only retrieve data after ${dayjs(`${minYear}-${minMonth}-${minDay}`).format('YYYY-MM-DD')}.`);
5128
5343
  }
5129
- return dayjs(`${year}-${month}-${day}`).utcOffset(MapleStoryApi.kstOffset).format('YYYY-MM-DD');
5344
+ return dayjs(`${year}-${month}-${day}`)
5345
+ .utcOffset(MapleStoryApi.kstOffset)
5346
+ .format('YYYY-MM-DD');
5130
5347
  }
5131
5348
  }
5132
5349
 
5133
- export { AchievementRankingDto, AchievementRankingResponseDto, CharacterAbilityDto, CharacterAbilityInfoDto, CharacterAndroidCashItemEquipmentColoringPrismDto, CharacterAndroidCashItemEquipmentDto, CharacterAndroidCashItemEquipmentOptionDto, CharacterAndroidEquipmentDto, CharacterAndroidEquipmentFaceDto, CharacterAndroidEquipmentHairDto, CharacterBasicDto, CharacterBeautyEquipmentDto, CharacterBeautyEquipmentFaceDto, CharacterBeautyEquipmentHairDto, CharacterCashItemEquipmentColoringPrismDto, CharacterCashItemEquipmentDto, CharacterCashItemEquipmentOptionDto, CharacterCashItemEquipmentPresetDto, CharacterDojangDto, CharacterDto, CharacterHexaMatrixDto, CharacterHexaMatrixEquipmentDto, CharacterHexaMatrixEquipmentLinkedSkillDto, CharacterHexaMatrixStatCoreDto, CharacterHexaMatrixStatDto, CharacterHyperStatDto, CharacterHyperStatPresetDto, CharacterItemEquipmentAddOptionDto, CharacterItemEquipmentBaseOptionDto, CharacterItemEquipmentDragonInfoDto, CharacterItemEquipmentDto, CharacterItemEquipmentEtcOptionDto, CharacterItemEquipmentExceptionalOptionDto, CharacterItemEquipmentInfoDto, CharacterItemEquipmentMechanicInfoDto, CharacterItemEquipmentStarforceOptionDto, CharacterItemEquipmentTitleDto, CharacterItemEquipmentTotalOptionDto, CharacterLinkSkillDto, CharacterLinkSkillInfoDto, CharacterPetEquipmentAutoSkillDto, CharacterPetEquipmentDto, CharacterPetEquipmentItemDto, CharacterPetEquipmentItemOptionDto, CharacterPopularityDto, CharacterPropensityDto, CharacterSetEffectDto, CharacterSetEffectInfoDto, CharacterSetEffectOptionInfoDto, CharacterSkillDto, CharacterSkillInfoDto, CharacterStatDto, CharacterSymbolEquipmentDto, CharacterSymbolEquipmentInfoDto, CharacterVMatrixCodeEquipmentDto, CharacterVMatrixDto, CubeHistoryDto, CubeHistoryResponseDto, CubeResultOptionDto, DojangRankingDto, DojangRankingResponseDto, GuildBasicDto, GuildDto, GuildRankingDto, GuildRankingResponseDto, GuildSkillDto, InspectionInfoDto, MapleStoryApi, MapleStoryApiError, MapleStoryApiErrorCode, OverallRankingDto, OverallRankingResponseDto, PotentialOptionGrade, StarforceEventDto, StarforceHistoryDto, StarforceHistoryResponseDto, TheSeedRankingDto, TheSeedRankingResponseDto, UnionDto, UnionRaiderBlockControlPointDto, UnionRaiderBlockDto, UnionRaiderBlockPositionDto, UnionRaiderDto, UnionRaiderInnerStatDto, UnionRankingDto, UnionRankingResponseDto, potentialOptionGradeFromString };
5350
+ export { AchievementRankingDto, AchievementRankingResponseDto, CharacterAbilityDto, CharacterAbilityInfoDto, CharacterAbilityPresetDto, CharacterAndroidCashItemEquipmentColoringPrismDto, CharacterAndroidCashItemEquipmentDto, CharacterAndroidCashItemEquipmentOptionDto, CharacterAndroidEquipmentDto, CharacterAndroidEquipmentFaceDto, CharacterAndroidEquipmentHairDto, CharacterAndroidEquipmentPresetDto, CharacterBasicDto, CharacterBeautyEquipmentDto, CharacterBeautyEquipmentFaceDto, CharacterBeautyEquipmentHairDto, CharacterCashItemEquipmentColoringPrismDto, CharacterCashItemEquipmentDto, CharacterCashItemEquipmentOptionDto, CharacterCashItemEquipmentPresetDto, CharacterDojangDto, CharacterDto, CharacterHexaMatrixDto, CharacterHexaMatrixEquipmentDto, CharacterHexaMatrixEquipmentLinkedSkillDto, CharacterHexaMatrixStatCoreDto, CharacterHexaMatrixStatDto, CharacterHyperStatDto, CharacterHyperStatPresetDto, CharacterItemEquipmentAddOptionDto, CharacterItemEquipmentBaseOptionDto, CharacterItemEquipmentDragonInfoDto, CharacterItemEquipmentDto, CharacterItemEquipmentEtcOptionDto, CharacterItemEquipmentExceptionalOptionDto, CharacterItemEquipmentInfoDto, CharacterItemEquipmentMechanicInfoDto, CharacterItemEquipmentStarforceOptionDto, CharacterItemEquipmentTitleDto, CharacterItemEquipmentTotalOptionDto, CharacterLinkSkillDto, CharacterLinkSkillInfoDto, CharacterPetEquipmentAutoSkillDto, CharacterPetEquipmentDto, CharacterPetEquipmentItemDto, CharacterPetEquipmentItemOptionDto, CharacterPopularityDto, CharacterPropensityDto, CharacterSetEffectDto, CharacterSetEffectInfoDto, CharacterSetEffectOptionInfoDto, CharacterSkillDto, CharacterSkillInfoDto, CharacterStatDto, CharacterSymbolEquipmentDto, CharacterSymbolEquipmentInfoDto, CharacterVMatrixCodeEquipmentDto, CharacterVMatrixDto, CubeHistoryDto, CubeHistoryResponseDto, CubeResultOptionDto, DojangRankingDto, DojangRankingResponseDto, GuildBasicDto, GuildDto, GuildRankingDto, GuildRankingResponseDto, GuildSkillDto, InspectionInfoDto, MapleStoryApi, MapleStoryApiError, MapleStoryApiErrorCode, OverallRankingDto, OverallRankingResponseDto, PotentialHistoryDto, PotentialHistoryResponseDto, PotentialOptionGrade, PotentialResultOptionDto, StarforceEventDto, StarforceHistoryDto, StarforceHistoryResponseDto, TheSeedRankingDto, TheSeedRankingResponseDto, UnionArtifactCrystalDto, UnionArtifactDto, UnionArtifactEffectDto, UnionDto, UnionRaiderBlockControlPointDto, UnionRaiderBlockDto, UnionRaiderBlockPositionDto, UnionRaiderDto, UnionRaiderInnerStatDto, UnionRankingDto, UnionRankingResponseDto, potentialOptionGradeFromString };