discogs-marketplace-api-nodejs 1.5.2 → 1.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (84) hide show
  1. package/README.MD +111 -97
  2. package/dist/data/countries.data.d.ts +306 -0
  3. package/dist/data/countries.data.js +327 -0
  4. package/dist/data/currencies.data.d.ts +33 -0
  5. package/dist/data/currencies.data.js +35 -0
  6. package/dist/data/index.d.ts +3 -0
  7. package/dist/data/index.js +10 -0
  8. package/dist/index.d.ts +2 -6
  9. package/dist/index.js +0 -12
  10. package/dist/marketplace.d.ts +1 -2
  11. package/dist/marketplace.js +16 -18
  12. package/dist/types/commons/index.d.ts +4 -0
  13. package/dist/{interfaces → types/commons}/index.js +0 -0
  14. package/dist/types/commons/input.type.d.ts +95 -0
  15. package/dist/{interfaces/input.interface.js → types/commons/input.type.js} +0 -0
  16. package/dist/{interfaces/output-error.interface.d.ts → types/commons/output-error.type.d.ts} +3 -2
  17. package/dist/{interfaces/item.interface.js → types/commons/output-error.type.js} +0 -0
  18. package/dist/types/commons/output-sucess.type.d.ts +116 -0
  19. package/dist/{interfaces/output-error.interface.js → types/commons/output-sucess.type.js} +0 -0
  20. package/dist/types/unions/condition.type.d.ts +5 -0
  21. package/dist/{interfaces/output-sucess.interface.js → types/unions/condition.type.js} +0 -0
  22. package/dist/types/unions/currency.type.d.ts +5 -0
  23. package/dist/{interfaces/year.interface.js → types/unions/currency.type.js} +0 -0
  24. package/dist/types/unions/format-description.type.d.ts +5 -0
  25. package/dist/types/{index.js → unions/format-description.type.js} +0 -0
  26. package/dist/types/unions/format.type.d.ts +5 -0
  27. package/dist/types/{limit.type.js → unions/format.type.js} +0 -0
  28. package/dist/types/unions/from.type.d.ts +5 -0
  29. package/dist/types/unions/from.type.js +2 -0
  30. package/dist/types/unions/genre.type.d.ts +5 -0
  31. package/dist/types/unions/genre.type.js +2 -0
  32. package/dist/types/unions/index.d.ts +12 -0
  33. package/dist/types/unions/index.js +2 -0
  34. package/dist/types/unions/lang.type.d.ts +5 -0
  35. package/dist/types/unions/lang.type.js +2 -0
  36. package/dist/types/{limit.type.d.ts → unions/limit.type.d.ts} +1 -1
  37. package/dist/types/unions/limit.type.js +2 -0
  38. package/dist/types/unions/search-type.type.d.ts +5 -0
  39. package/dist/types/unions/search-type.type.js +2 -0
  40. package/dist/types/unions/sort.type.d.ts +5 -0
  41. package/dist/types/unions/sort.type.js +2 -0
  42. package/dist/types/unions/style.type.d.ts +5 -0
  43. package/dist/types/unions/style.type.js +2 -0
  44. package/package.json +16 -16
  45. package/dist/enums/currency.enum.d.ts +0 -19
  46. package/dist/enums/currency.enum.js +0 -22
  47. package/dist/enums/format-description.enum.d.ts +0 -144
  48. package/dist/enums/format-description.enum.js +0 -147
  49. package/dist/enums/format.enum.d.ts +0 -59
  50. package/dist/enums/format.enum.js +0 -62
  51. package/dist/enums/from.enum.d.ts +0 -251
  52. package/dist/enums/from.enum.js +0 -254
  53. package/dist/enums/genre.enum.d.ts +0 -21
  54. package/dist/enums/genre.enum.js +0 -24
  55. package/dist/enums/index.d.ts +0 -11
  56. package/dist/enums/index.js +0 -26
  57. package/dist/enums/iso/country-code.enum.d.ts +0 -255
  58. package/dist/enums/iso/country-code.enum.js +0 -258
  59. package/dist/enums/iso/country-name.enum.d.ts +0 -255
  60. package/dist/enums/iso/country-name.enum.js +0 -258
  61. package/dist/enums/iso/index.d.ts +0 -3
  62. package/dist/enums/iso/index.js +0 -10
  63. package/dist/enums/iso/translate/discogs-country-name-to-iso-code.enum.d.ts +0 -69
  64. package/dist/enums/iso/translate/discogs-country-name-to-iso-code.enum.js +0 -72
  65. package/dist/enums/iso/translate/discogs-currency-to-iso-code.enum.d.ts +0 -36
  66. package/dist/enums/iso/translate/discogs-currency-to-iso-code.enum.js +0 -39
  67. package/dist/enums/iso/translate/index.d.ts +0 -3
  68. package/dist/enums/iso/translate/index.js +0 -10
  69. package/dist/enums/lang.enum.d.ts +0 -15
  70. package/dist/enums/lang.enum.js +0 -18
  71. package/dist/enums/media-condition.enum.d.ts +0 -14
  72. package/dist/enums/media-condition.enum.js +0 -17
  73. package/dist/enums/stort.enum.d.ts +0 -62
  74. package/dist/enums/stort.enum.js +0 -65
  75. package/dist/enums/style.enum.d.ts +0 -255
  76. package/dist/enums/style.enum.js +0 -258
  77. package/dist/enums/type.enum.d.ts +0 -30
  78. package/dist/enums/type.enum.js +0 -33
  79. package/dist/interfaces/index.d.ts +0 -6
  80. package/dist/interfaces/input.interface.d.ts +0 -80
  81. package/dist/interfaces/item.interface.d.ts +0 -89
  82. package/dist/interfaces/output-sucess.interface.d.ts +0 -32
  83. package/dist/interfaces/year.interface.d.ts +0 -9
  84. package/dist/types/index.d.ts +0 -2
@@ -1,80 +0,0 @@
1
- import { ECurrency, EFormat, EFormatDescription, EFrom, EGenre, ELang, EMediaCondition, ESort, EStyle, EType } from '../enums/index.js';
2
- import { LimitType } from '../types/index.js';
3
- import IYears from '../interfaces/year.interface.js';
4
- /**
5
- * Element that can be provided by user
6
- */
7
- export default interface IInput {
8
- /**
9
- * Type of elements to search
10
- */
11
- searchType: EType;
12
- /**
13
- * Value to search corresponding to searchType
14
- */
15
- searchValue: string | number | undefined;
16
- /**
17
- * Currency
18
- */
19
- currency?: ECurrency;
20
- /**
21
- * Genre
22
- */
23
- genre?: EGenre;
24
- /**
25
- * Styles
26
- */
27
- style?: EStyle[];
28
- /**
29
- * Formats
30
- */
31
- format?: EFormat[];
32
- /**
33
- * Format descriptions
34
- */
35
- formatDescription?: EFormatDescription[];
36
- /**
37
- * Media conditions
38
- */
39
- mediaCondition?: EMediaCondition[];
40
- /**
41
- * Year (Do not use it with years)
42
- */
43
- year?: number;
44
- /**
45
- * Interval of years (Do not use it with year)
46
- */
47
- years?: IYears;
48
- /**
49
- * Is audio sample ?
50
- */
51
- isAudioSample?: boolean;
52
- /**
53
- * Is make an offer only ?
54
- */
55
- isMakeAnOfferOnly?: boolean;
56
- /**
57
- * Expedition country
58
- */
59
- from?: EFrom;
60
- /**
61
- * Seller name
62
- */
63
- seller?: string;
64
- /**
65
- * Sort elements by
66
- */
67
- sort?: ESort;
68
- /**
69
- * Limit of elements to search (25 | 50 | 100 | 250)
70
- */
71
- limit?: LimitType;
72
- /**
73
- * Page (Must be < 401 or discogs will return an error 404)
74
- */
75
- page?: number;
76
- /**
77
- * Lang to use for Discogs
78
- */
79
- lang?: ELang;
80
- }
@@ -1,89 +0,0 @@
1
- import { ECountryCode } from '../enums/iso/index.js';
2
- /**
3
- * One item from discogs
4
- */
5
- export default interface IItem {
6
- /** Id */
7
- id: number;
8
- /** Title */
9
- title: {
10
- /** Original */
11
- original: string;
12
- /** Artist */
13
- artist: string;
14
- /** Item */
15
- item: string;
16
- /** Formats */
17
- formats: string[];
18
- };
19
- /** Url */
20
- url: string;
21
- /** Labels */
22
- labels: string[];
23
- /** Catnos */
24
- catnos: string[];
25
- /** ImageUrl */
26
- imageUrl: string;
27
- /** Description */
28
- description: string;
29
- /** IsAcceptingOffer */
30
- isAcceptingOffer: boolean;
31
- /** IsAvailable */
32
- isAvailable: boolean;
33
- /** Condition */
34
- condition: {
35
- /** Media */
36
- media: {
37
- /** Full */
38
- full: string;
39
- /** Short */
40
- short: string;
41
- };
42
- /** Sleeve */
43
- sleeve: {
44
- /** Full */
45
- full: string;
46
- /** Short */
47
- short: string;
48
- };
49
- };
50
- /** Seller */
51
- seller: {
52
- /** Name */
53
- name: string;
54
- /** Url */
55
- url: string;
56
- /** Score */
57
- score: string;
58
- /** Notes */
59
- notes: number;
60
- };
61
- /** Price */
62
- price: {
63
- /** Base */
64
- base: string;
65
- /** Shipping */
66
- shipping: string;
67
- };
68
- /** From */
69
- country: {
70
- /** Name */
71
- name: string;
72
- /** Iso code */
73
- code: ECountryCode;
74
- };
75
- /** Community */
76
- community: {
77
- /** Have */
78
- have: number;
79
- /** Want */
80
- want: number;
81
- };
82
- /** Release */
83
- release: {
84
- /** Id */
85
- id: number;
86
- /** Url */
87
- url: string;
88
- };
89
- }
@@ -1,32 +0,0 @@
1
- import { EType } from '../enums/index.js';
2
- import IItem from '../interfaces/item.interface.js';
3
- /**
4
- * Result provided to user
5
- */
6
- export default interface IOutputSuccess {
7
- /** Items */
8
- items: IItem[];
9
- /** Page */
10
- page: {
11
- /** Current */
12
- current: number;
13
- /** Total */
14
- total: number;
15
- };
16
- /** Result */
17
- result: {
18
- /** Total */
19
- total: number;
20
- /** PerPage */
21
- perPage: number;
22
- };
23
- /** Search */
24
- search: {
25
- /** Value */
26
- value: string | number;
27
- /** Type */
28
- type: EType;
29
- };
30
- /** UrlGenerated */
31
- urlGenerated: string;
32
- }
@@ -1,9 +0,0 @@
1
- /**
2
- * Provide interval of years
3
- */
4
- export default interface IYears {
5
- /** Min */
6
- min: number;
7
- /** Max */
8
- max: number;
9
- }
@@ -1,2 +0,0 @@
1
- import LimitType from '../types/limit.type.js';
2
- export { LimitType, };