@alba-cars/common-modules 2.15.3 → 2.16.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 (150) hide show
  1. package/README.md +42 -42
  2. package/dist/core/enums/Analytics.d.ts +31 -24
  3. package/dist/core/enums/HttpMethods.d.ts +12 -12
  4. package/dist/core/enums/HttpStatusCodes.d.ts +18 -18
  5. package/dist/core/enums/index.d.ts +3 -3
  6. package/dist/core/error-handling/AppError.d.ts +23 -23
  7. package/dist/core/error-handling/index.d.ts +1 -1
  8. package/dist/core/index.d.ts +5 -5
  9. package/dist/core/models/index.d.ts +3 -3
  10. package/dist/core/models/media/index.d.ts +1 -1
  11. package/dist/core/models/media/media_data.d.ts +5 -5
  12. package/dist/core/models/pagination/index.d.ts +1 -1
  13. package/dist/core/models/pagination/paginated_data.d.ts +23 -23
  14. package/dist/core/models/range.d.ts +4 -4
  15. package/dist/core/network/endpoint-config.d.ts +155 -155
  16. package/dist/core/network/fetch-api.d.ts +62 -62
  17. package/dist/core/network/index.d.ts +2 -2
  18. package/dist/core/utils/formatCurrency.d.ts +11 -11
  19. package/dist/core/utils/global-constants.d.ts +6 -6
  20. package/dist/core/utils/global-utils.d.ts +108 -108
  21. package/dist/core/utils/global_validators.d.ts +2 -2
  22. package/dist/core/utils/index.d.ts +4 -4
  23. package/dist/core/utils/query_flatten.d.ts +1 -1
  24. package/dist/features/auth/data/dto/AuthDTO.d.ts +32 -32
  25. package/dist/features/auth/data/dto/RoleDTO.d.ts +41 -41
  26. package/dist/features/auth/data/dto/UserDTO.d.ts +71 -71
  27. package/dist/features/auth/data/index.d.ts +3 -3
  28. package/dist/features/auth/index.d.ts +1 -1
  29. package/dist/features/bank-valuation-request/data/dto/BankValuationRequestDTO.d.ts +55 -55
  30. package/dist/features/bank-valuation-request/index.d.ts +1 -1
  31. package/dist/features/blog/data/dto/BlogDTO.d.ts +73 -73
  32. package/dist/features/blog/index.d.ts +1 -1
  33. package/dist/features/callback-request/data/dto/CallBackRequestDTO.d.ts +32 -32
  34. package/dist/features/callback-request/index.d.ts +1 -1
  35. package/dist/features/deposits/data/dto/DepositDTOs.d.ts +84 -84
  36. package/dist/features/deposits/data/index.d.ts +1 -1
  37. package/dist/features/deposits/index.d.ts +1 -1
  38. package/dist/features/faq/data/dtos/CreateFaqDTO.d.ts +15 -15
  39. package/dist/features/faq/data/dtos/FaqFetchDTO.d.ts +105 -105
  40. package/dist/features/faq/data/dtos/UpdateFaqDTO.d.ts +15 -15
  41. package/dist/features/faq/data/dtos/index.d.ts +3 -3
  42. package/dist/features/faq/data/enums/index.d.ts +6 -6
  43. package/dist/features/faq/data/index.d.ts +2 -2
  44. package/dist/features/faq/index.d.ts +1 -1
  45. package/dist/features/finance-eligibilty-request/data/dto/FinanceEligibilityRequestDTO.d.ts +144 -144
  46. package/dist/features/finance-eligibilty-request/data/index.d.ts +1 -1
  47. package/dist/features/finance-eligibilty-request/index.d.ts +1 -1
  48. package/dist/features/google-review/data/dto/google_review_dto.d.ts +103 -103
  49. package/dist/features/google-review/data/dto/index.d.ts +1 -1
  50. package/dist/features/google-review/data/enums/index.d.ts +4 -4
  51. package/dist/features/google-review/data/index.d.ts +2 -2
  52. package/dist/features/google-review/index.d.ts +1 -1
  53. package/dist/features/index.d.ts +18 -18
  54. package/dist/features/lead/data/dto/index.d.ts +4 -4
  55. package/dist/features/lead/data/dto/lead_documents_dto.d.ts +24 -24
  56. package/dist/features/lead/data/dto/lead_dto.d.ts +104 -104
  57. package/dist/features/lead/data/dto/lead_preference_history_dto.d.ts +84 -84
  58. package/dist/features/lead/data/dto/lead_prefernce_dto.d.ts +68 -68
  59. package/dist/features/lead/data/enum/index.d.ts +2 -2
  60. package/dist/features/lead/data/enum/lead_source_status_types.d.ts +15 -15
  61. package/dist/features/lead/data/enum/lead_status_type.d.ts +8 -8
  62. package/dist/features/lead/index.d.ts +2 -2
  63. package/dist/features/models/Bank.d.ts +9 -9
  64. package/dist/features/models/BankValuationRequest.d.ts +63 -63
  65. package/dist/features/models/BankValuationResult.d.ts +24 -24
  66. package/dist/features/models/Base.d.ts +12 -12
  67. package/dist/features/models/Color.d.ts +10 -10
  68. package/dist/features/models/Deposit.d.ts +18 -18
  69. package/dist/features/models/Lead.d.ts +25 -25
  70. package/dist/features/models/Payment.d.ts +46 -46
  71. package/dist/features/models/Roles.d.ts +7 -7
  72. package/dist/features/models/Ticket.d.ts +51 -51
  73. package/dist/features/models/User.d.ts +24 -24
  74. package/dist/features/models/UserFavoriteVehicle.d.ts +9 -9
  75. package/dist/features/models/Vehicle.d.ts +79 -79
  76. package/dist/features/models/VehicleBodyType.d.ts +8 -8
  77. package/dist/features/models/VehicleCategory.d.ts +6 -6
  78. package/dist/features/models/VehicleFeature.d.ts +10 -10
  79. package/dist/features/models/VehicleFeatureCategory.d.ts +7 -7
  80. package/dist/features/models/VehicleFinance.d.ts +29 -24
  81. package/dist/features/models/VehicleMake.d.ts +14 -14
  82. package/dist/features/models/VehicleMedia.d.ts +12 -12
  83. package/dist/features/models/VehicleMetaData.d.ts +11 -11
  84. package/dist/features/models/VehicleModel.d.ts +17 -17
  85. package/dist/features/models/VehicleOrder.d.ts +14 -14
  86. package/dist/features/models/_index.d.ts +14 -14
  87. package/dist/features/models/index.d.ts +21 -21
  88. package/dist/features/newsletter/data/dto/NewsletterDTO.d.ts +17 -17
  89. package/dist/features/newsletter/index.d.ts +1 -1
  90. package/dist/features/sales-team/data/dto/LanguageDTO.d.ts +20 -20
  91. package/dist/features/sales-team/data/dto/SalesAgentDTO.d.ts +204 -204
  92. package/dist/features/sales-team/data/index.d.ts +2 -2
  93. package/dist/features/sales-team/index.d.ts +1 -1
  94. package/dist/features/sell-car-request/data/dto/SellCarRequestDTO.d.ts +203 -203
  95. package/dist/features/sell-car-request/data/index.d.ts +1 -1
  96. package/dist/features/sell-car-request/index.d.ts +1 -1
  97. package/dist/features/showroom-visit/data/dto/ShowroomVisit.d.ts +69 -69
  98. package/dist/features/showroom-visit/data/enums/index.d.ts +11 -11
  99. package/dist/features/showroom-visit/data/index.d.ts +2 -2
  100. package/dist/features/showroom-visit/index.d.ts +1 -1
  101. package/dist/features/test-drive-request/api/GetTestDriveVehicles.d.ts +3 -3
  102. package/dist/features/test-drive-request/api/index.d.ts +1 -1
  103. package/dist/features/test-drive-request/data/dto/TestDriveRequestDTO.d.ts +51 -51
  104. package/dist/features/test-drive-request/data/enums/index.d.ts +24 -24
  105. package/dist/features/test-drive-request/data/index.d.ts +4 -4
  106. package/dist/features/test-drive-request/data/models/TestDriveRequest.d.ts +14 -14
  107. package/dist/features/test-drive-request/data/models/index.d.ts +2 -2
  108. package/dist/features/test-drive-request/data/utilities.d.ts +30 -30
  109. package/dist/features/test-drive-request/index.d.ts +2 -2
  110. package/dist/features/tickets/data/dto/TicketDto.d.ts +69 -69
  111. package/dist/features/tickets/data/enums/index.d.ts +18 -18
  112. package/dist/features/tickets/index.d.ts +2 -2
  113. package/dist/features/vehicle/data/dto/BaseDTO.d.ts +9 -9
  114. package/dist/features/vehicle/data/dto/ColorDTO.d.ts +10 -10
  115. package/dist/features/vehicle/data/dto/MediaDTO.d.ts +5 -5
  116. package/dist/features/vehicle/data/dto/PaymentDTO.d.ts +52 -52
  117. package/dist/features/vehicle/data/dto/SimilarVehicleDTO.d.ts +12 -12
  118. package/dist/features/vehicle/data/dto/VehicleCategoryDTO.d.ts +39 -39
  119. package/dist/features/vehicle/data/dto/VehicleDTO.d.ts +145 -145
  120. package/dist/features/vehicle/data/dto/VehicleFavoritesDTO.d.ts +14 -14
  121. package/dist/features/vehicle/data/dto/VehicleFeatureCategoriesDTO.d.ts +39 -39
  122. package/dist/features/vehicle/data/dto/VehicleFeatureDTO.d.ts +40 -40
  123. package/dist/features/vehicle/data/dto/VehicleFilterDTO.d.ts +258 -258
  124. package/dist/features/vehicle/data/dto/VehicleFinanceDTO.d.ts +63 -63
  125. package/dist/features/vehicle/data/dto/VehicleInspectionDTO.d.ts +147 -147
  126. package/dist/features/vehicle/data/dto/VehicleMakeDTO.d.ts +52 -52
  127. package/dist/features/vehicle/data/dto/VehicleMedia.d.ts +44 -44
  128. package/dist/features/vehicle/data/dto/VehicleModelDTO.d.ts +50 -50
  129. package/dist/features/vehicle/data/dto/VehicleOrderDTO.d.ts +34 -34
  130. package/dist/features/vehicle/data/dto/VehicleTypeDTO.d.ts +35 -35
  131. package/dist/features/vehicle/data/dto/VehicleWarrantyDTO.d.ts +9 -9
  132. package/dist/features/vehicle/data/dto/index.d.ts +20 -20
  133. package/dist/features/vehicle/data/enums/index.d.ts +40 -40
  134. package/dist/features/vehicle/data/index.d.ts +3 -3
  135. package/dist/features/vehicle/data/utilities.d.ts +185 -185
  136. package/dist/features/vehicle/index.d.ts +1 -1
  137. package/dist/features/vehicle-reservations/data/dto/VehicleReservationDTO.d.ts +106 -106
  138. package/dist/features/vehicle-reservations/data/dto/index.d.ts +1 -1
  139. package/dist/features/vehicle-reservations/data/enums/finance-type.d.ts +5 -5
  140. package/dist/features/vehicle-reservations/data/enums/index.d.ts +3 -3
  141. package/dist/features/vehicle-reservations/data/enums/reservation-type.d.ts +9 -9
  142. package/dist/features/vehicle-reservations/data/enums/vehicle-reservation-type.d.ts +4 -4
  143. package/dist/features/vehicle-reservations/index.d.ts +2 -2
  144. package/dist/global/dto/BaseGetDTO.d.ts +8 -8
  145. package/dist/global/dto/index.d.ts +1 -1
  146. package/dist/global/index.d.ts +2 -2
  147. package/dist/global/utilities.d.ts +53 -53
  148. package/dist/index.d.ts +5 -5
  149. package/dist/models.d.ts +1 -1
  150. package/package.json +62 -62
@@ -1,155 +1,155 @@
1
- type EndpointFunction = (_id: number | string) => string;
2
- interface BaseEndpoint {
3
- getAll: string | EndpointFunction;
4
- create: string | EndpointFunction;
5
- getOne: EndpointFunction;
6
- deleteOne: EndpointFunction;
7
- updateOne: EndpointFunction;
8
- }
9
- interface VehicleEndpoints extends BaseEndpoint {
10
- getSimilar: EndpointFunction;
11
- getOneBySlug: EndpointFunction;
12
- getOneByRef: EndpointFunction;
13
- publishVehicle: EndpointFunction;
14
- unpublishVehicle: EndpointFunction;
15
- reserveVehicle: EndpointFunction;
16
- selfReserveVehicle: EndpointFunction;
17
- markVehicleSold: EndpointFunction;
18
- markVehicleDraft: EndpointFunction;
19
- }
20
- interface BlogEndpoints extends BaseEndpoint {
21
- getOneBySlug: EndpointFunction;
22
- }
23
- type MetaEndpoints = BaseEndpoint & {
24
- aiGenerateTitle: EndpointFunction;
25
- aiGenerateDescription: EndpointFunction;
26
- aiGenerateKeyword: EndpointFunction;
27
- aiGenerateVehicleDescription: EndpointFunction;
28
- };
29
- type DepositEndpoints = BaseEndpoint & {
30
- initiateRefund: string | EndpointFunction;
31
- getOrCreateUserInformation: string;
32
- };
33
- type UserEndpoints = BaseEndpoint & {
34
- changeProfilePicture: EndpointFunction;
35
- deleteProfilePicture: EndpointFunction;
36
- };
37
- type TicketEndpoints = BaseEndpoint & {
38
- getMyTickets: string;
39
- getUserTickets: EndpointFunction;
40
- getAgentTickets: EndpointFunction;
41
- addMessage: EndpointFunction;
42
- addDocument: EndpointFunction;
43
- getDocuments: EndpointFunction;
44
- reopenTicket: EndpointFunction;
45
- sendToKissFlow: string;
46
- };
47
- type ReviewEndpoints = BaseEndpoint & {
48
- changeReviewShowPublic: EndpointFunction;
49
- };
50
- type VehicleFeatureEndpoints = BaseEndpoint & {
51
- changeIcon: EndpointFunction;
52
- };
53
- type DealDriveEndpoints = BaseEndpoint & {
54
- getAllMakes: EndpointFunction;
55
- getAllModels: EndpointFunction;
56
- };
57
- type FinanceEligibilityRequestEndpoints = BaseEndpoint & {
58
- updateStatus: EndpointFunction;
59
- };
60
- type BankValuationRequestEndpoints = BaseEndpoint & {
61
- approveValuation: EndpointFunction;
62
- rejectValuation: EndpointFunction;
63
- overridePayment: EndpointFunction;
64
- updateStatus: EndpointFunction;
65
- previewCertificatePdf: EndpointFunction;
66
- reissueCertificate: EndpointFunction;
67
- getCertificateEditableData: EndpointFunction;
68
- estimate: string;
69
- rangeEstimate: string;
70
- getStats: string;
71
- notifyAboutExistingLead: string;
72
- getRequestStatus: EndpointFunction;
73
- checkRequestIsIncomplete: EndpointFunction;
74
- sendContinuationReminder: EndpointFunction;
75
- };
76
- type ColorEndpoints = BaseEndpoint & {
77
- list: string;
78
- getBySlug: (slug: string) => string;
79
- };
80
- type ExchangeCarRequestEndpoints = {
81
- getAll: string;
82
- create: string;
83
- getOne: EndpointFunction;
84
- updateOne: EndpointFunction;
85
- deleteOne: EndpointFunction;
86
- };
87
- type DubiCarsEndpoints = {
88
- getAdByDubiCarsId: EndpointFunction;
89
- checkVehicleAdStatus: EndpointFunction;
90
- getAvailableModelsForMake: (make: string) => string;
91
- postAd: string;
92
- doAction: (action: "pause" | "activate" | "refresh" | "sold" | "premium" | "remove-premium") => string;
93
- deleteAd: EndpointFunction;
94
- deleteAdByVehicleId: EndpointFunction;
95
- };
96
- type APIEndpointType = {
97
- vehicle: VehicleEndpoints;
98
- blogs: BlogEndpoints;
99
- vehicleFinance: BaseEndpoint;
100
- TestDrive: BaseEndpoint;
101
- vehicleMake: BaseEndpoint & {
102
- getOneBySlug: (slug: string) => string;
103
- };
104
- vehicleModel: BaseEndpoint;
105
- vehicleMeta: MetaEndpoints;
106
- vehicleInspection: BaseEndpoint;
107
- vehicleOrder: BaseEndpoint;
108
- vehicleFeatures: VehicleFeatureEndpoints;
109
- vehicleFeatureCategories: BaseEndpoint;
110
- vehicleType: BaseEndpoint;
111
- payment: BaseEndpoint;
112
- deposit: DepositEndpoints;
113
- agents: BaseEndpoint;
114
- showroomVisit: BaseEndpoint;
115
- sellCarRequest: BaseEndpoint & {
116
- notifyAboutExistingLead: string;
117
- };
118
- financeEligibilityRequest: FinanceEligibilityRequestEndpoints;
119
- vehicleReservations: BaseEndpoint;
120
- languages: BaseEndpoint;
121
- leads: BaseEndpoint;
122
- leadPreferences: BaseEndpoint;
123
- googleReview: ReviewEndpoints;
124
- tickets: TicketEndpoints;
125
- user: UserEndpoints;
126
- faq: BaseEndpoint;
127
- dealDrive: DealDriveEndpoints;
128
- bankValuationRequest: BankValuationRequestEndpoints;
129
- exchangeCarRequest: ExchangeCarRequestEndpoints;
130
- dubiCars: DubiCarsEndpoints;
131
- colors: ColorEndpoints;
132
- bankValuationResult: BaseEndpoint;
133
- bank: BaseEndpoint;
134
- };
135
- export declare const API_ENDPOINTS: APIEndpointType;
136
- export declare const UTIL_ENDPOINTS: {
137
- media: {
138
- createS3Url: string;
139
- preprocessMediaUrl: string;
140
- removeS3Media: string;
141
- removeVehicleMedia: string;
142
- removeByIdentifier: string;
143
- compressImage: string;
144
- };
145
- };
146
- export declare const AUTH_ENDPOINTS: {
147
- login: string;
148
- register: string;
149
- refreshAccessToken: string;
150
- sendPhoneVerificationCode: string;
151
- verifyPhoneAndLogin: string;
152
- verifyAnyPhoneNumber: string;
153
- checkPhoneNumberExists: string;
154
- };
155
- export {};
1
+ type EndpointFunction = (_id: number | string) => string;
2
+ interface BaseEndpoint {
3
+ getAll: string | EndpointFunction;
4
+ create: string | EndpointFunction;
5
+ getOne: EndpointFunction;
6
+ deleteOne: EndpointFunction;
7
+ updateOne: EndpointFunction;
8
+ }
9
+ interface VehicleEndpoints extends BaseEndpoint {
10
+ getSimilar: EndpointFunction;
11
+ getOneBySlug: EndpointFunction;
12
+ getOneByRef: EndpointFunction;
13
+ publishVehicle: EndpointFunction;
14
+ unpublishVehicle: EndpointFunction;
15
+ reserveVehicle: EndpointFunction;
16
+ selfReserveVehicle: EndpointFunction;
17
+ markVehicleSold: EndpointFunction;
18
+ markVehicleDraft: EndpointFunction;
19
+ }
20
+ interface BlogEndpoints extends BaseEndpoint {
21
+ getOneBySlug: EndpointFunction;
22
+ }
23
+ type MetaEndpoints = BaseEndpoint & {
24
+ aiGenerateTitle: EndpointFunction;
25
+ aiGenerateDescription: EndpointFunction;
26
+ aiGenerateKeyword: EndpointFunction;
27
+ aiGenerateVehicleDescription: EndpointFunction;
28
+ };
29
+ type DepositEndpoints = BaseEndpoint & {
30
+ initiateRefund: string | EndpointFunction;
31
+ getOrCreateUserInformation: string;
32
+ };
33
+ type UserEndpoints = BaseEndpoint & {
34
+ changeProfilePicture: EndpointFunction;
35
+ deleteProfilePicture: EndpointFunction;
36
+ };
37
+ type TicketEndpoints = BaseEndpoint & {
38
+ getMyTickets: string;
39
+ getUserTickets: EndpointFunction;
40
+ getAgentTickets: EndpointFunction;
41
+ addMessage: EndpointFunction;
42
+ addDocument: EndpointFunction;
43
+ getDocuments: EndpointFunction;
44
+ reopenTicket: EndpointFunction;
45
+ sendToKissFlow: string;
46
+ };
47
+ type ReviewEndpoints = BaseEndpoint & {
48
+ changeReviewShowPublic: EndpointFunction;
49
+ };
50
+ type VehicleFeatureEndpoints = BaseEndpoint & {
51
+ changeIcon: EndpointFunction;
52
+ };
53
+ type DealDriveEndpoints = BaseEndpoint & {
54
+ getAllMakes: EndpointFunction;
55
+ getAllModels: EndpointFunction;
56
+ };
57
+ type FinanceEligibilityRequestEndpoints = BaseEndpoint & {
58
+ updateStatus: EndpointFunction;
59
+ };
60
+ type BankValuationRequestEndpoints = BaseEndpoint & {
61
+ approveValuation: EndpointFunction;
62
+ rejectValuation: EndpointFunction;
63
+ overridePayment: EndpointFunction;
64
+ updateStatus: EndpointFunction;
65
+ previewCertificatePdf: EndpointFunction;
66
+ reissueCertificate: EndpointFunction;
67
+ getCertificateEditableData: EndpointFunction;
68
+ estimate: string;
69
+ rangeEstimate: string;
70
+ getStats: string;
71
+ notifyAboutExistingLead: string;
72
+ getRequestStatus: EndpointFunction;
73
+ checkRequestIsIncomplete: EndpointFunction;
74
+ sendContinuationReminder: EndpointFunction;
75
+ };
76
+ type ColorEndpoints = BaseEndpoint & {
77
+ list: string;
78
+ getBySlug: (slug: string) => string;
79
+ };
80
+ type ExchangeCarRequestEndpoints = {
81
+ getAll: string;
82
+ create: string;
83
+ getOne: EndpointFunction;
84
+ updateOne: EndpointFunction;
85
+ deleteOne: EndpointFunction;
86
+ };
87
+ type DubiCarsEndpoints = {
88
+ getAdByDubiCarsId: EndpointFunction;
89
+ checkVehicleAdStatus: EndpointFunction;
90
+ getAvailableModelsForMake: (make: string) => string;
91
+ postAd: string;
92
+ doAction: (action: "pause" | "activate" | "refresh" | "sold" | "premium" | "remove-premium") => string;
93
+ deleteAd: EndpointFunction;
94
+ deleteAdByVehicleId: EndpointFunction;
95
+ };
96
+ type APIEndpointType = {
97
+ vehicle: VehicleEndpoints;
98
+ blogs: BlogEndpoints;
99
+ vehicleFinance: BaseEndpoint;
100
+ TestDrive: BaseEndpoint;
101
+ vehicleMake: BaseEndpoint & {
102
+ getOneBySlug: (slug: string) => string;
103
+ };
104
+ vehicleModel: BaseEndpoint;
105
+ vehicleMeta: MetaEndpoints;
106
+ vehicleInspection: BaseEndpoint;
107
+ vehicleOrder: BaseEndpoint;
108
+ vehicleFeatures: VehicleFeatureEndpoints;
109
+ vehicleFeatureCategories: BaseEndpoint;
110
+ vehicleType: BaseEndpoint;
111
+ payment: BaseEndpoint;
112
+ deposit: DepositEndpoints;
113
+ agents: BaseEndpoint;
114
+ showroomVisit: BaseEndpoint;
115
+ sellCarRequest: BaseEndpoint & {
116
+ notifyAboutExistingLead: string;
117
+ };
118
+ financeEligibilityRequest: FinanceEligibilityRequestEndpoints;
119
+ vehicleReservations: BaseEndpoint;
120
+ languages: BaseEndpoint;
121
+ leads: BaseEndpoint;
122
+ leadPreferences: BaseEndpoint;
123
+ googleReview: ReviewEndpoints;
124
+ tickets: TicketEndpoints;
125
+ user: UserEndpoints;
126
+ faq: BaseEndpoint;
127
+ dealDrive: DealDriveEndpoints;
128
+ bankValuationRequest: BankValuationRequestEndpoints;
129
+ exchangeCarRequest: ExchangeCarRequestEndpoints;
130
+ dubiCars: DubiCarsEndpoints;
131
+ colors: ColorEndpoints;
132
+ bankValuationResult: BaseEndpoint;
133
+ bank: BaseEndpoint;
134
+ };
135
+ export declare const API_ENDPOINTS: APIEndpointType;
136
+ export declare const UTIL_ENDPOINTS: {
137
+ media: {
138
+ createS3Url: string;
139
+ preprocessMediaUrl: string;
140
+ removeS3Media: string;
141
+ removeVehicleMedia: string;
142
+ removeByIdentifier: string;
143
+ compressImage: string;
144
+ };
145
+ };
146
+ export declare const AUTH_ENDPOINTS: {
147
+ login: string;
148
+ register: string;
149
+ refreshAccessToken: string;
150
+ sendPhoneVerificationCode: string;
151
+ verifyPhoneAndLogin: string;
152
+ verifyAnyPhoneNumber: string;
153
+ checkPhoneNumberExists: string;
154
+ };
155
+ export {};
@@ -1,62 +1,62 @@
1
- interface ApiRequestOptions extends RequestInit {
2
- headers?: Record<string, string>;
3
- query?: Record<string, any>;
4
- timeout?: number;
5
- signal?: AbortSignal;
6
- isRetry?: boolean;
7
- }
8
- type RequestInterceptor = (config: RequestInit & {
9
- url: string;
10
- options: ApiRequestOptions;
11
- }) => Promise<RequestInit & {
12
- url: string;
13
- options: ApiRequestOptions;
14
- }> | (RequestInit & {
15
- url: string;
16
- options: ApiRequestOptions;
17
- });
18
- type ResponseInterceptor = (response: Response, requestConfig: RequestInit & {
19
- url: string;
20
- options: ApiRequestOptions;
21
- }) => Promise<Response> | Response;
22
- type ResponseErrorInterceptor = (error: any, requestConfig: RequestInit & {
23
- url: string;
24
- options: ApiRequestOptions;
25
- }) => Promise<any> | any;
26
- declare class InterceptorManager {
27
- private requestInterceptors;
28
- private responseInterceptors;
29
- private responseErrorInterceptors;
30
- addRequestInterceptor(interceptor: RequestInterceptor): number;
31
- addResponseInterceptor(interceptor: ResponseInterceptor): number;
32
- addResponseErrorInterceptor(interceptor: ResponseErrorInterceptor): number;
33
- removeRequestInterceptor(index: number): void;
34
- removeResponseInterceptor(index: number): void;
35
- removeResponseErrorInterceptor(index: number): void;
36
- clearRequestInterceptors(): void;
37
- clearResponseInterceptors(): void;
38
- clearResponseErrorInterceptors(): void;
39
- clearAllInterceptors(): void;
40
- applyRequestInterceptors(config: RequestInit & {
41
- url: string;
42
- options: ApiRequestOptions;
43
- }): Promise<RequestInit & {
44
- url: string;
45
- options: ApiRequestOptions;
46
- }>;
47
- applyResponseInterceptors(response: Response, requestConfig: RequestInit & {
48
- url: string;
49
- options: ApiRequestOptions;
50
- }): Promise<Response>;
51
- applyResponseErrorInterceptors(error: any, requestConfig: RequestInit & {
52
- url: string;
53
- options: ApiRequestOptions;
54
- }): Promise<any>;
55
- retryRequest<T>(config: RequestInit & {
56
- url: string;
57
- options: ApiRequestOptions;
58
- }): Promise<T>;
59
- }
60
- export declare const interceptors: InterceptorManager;
61
- export declare function apiRequest<T>(endpoint: string, options?: ApiRequestOptions): Promise<T>;
62
- export {};
1
+ interface ApiRequestOptions extends RequestInit {
2
+ headers?: Record<string, string>;
3
+ query?: Record<string, any>;
4
+ timeout?: number;
5
+ signal?: AbortSignal;
6
+ isRetry?: boolean;
7
+ }
8
+ type RequestInterceptor = (config: RequestInit & {
9
+ url: string;
10
+ options: ApiRequestOptions;
11
+ }) => Promise<RequestInit & {
12
+ url: string;
13
+ options: ApiRequestOptions;
14
+ }> | (RequestInit & {
15
+ url: string;
16
+ options: ApiRequestOptions;
17
+ });
18
+ type ResponseInterceptor = (response: Response, requestConfig: RequestInit & {
19
+ url: string;
20
+ options: ApiRequestOptions;
21
+ }) => Promise<Response> | Response;
22
+ type ResponseErrorInterceptor = (error: any, requestConfig: RequestInit & {
23
+ url: string;
24
+ options: ApiRequestOptions;
25
+ }) => Promise<any> | any;
26
+ declare class InterceptorManager {
27
+ private requestInterceptors;
28
+ private responseInterceptors;
29
+ private responseErrorInterceptors;
30
+ addRequestInterceptor(interceptor: RequestInterceptor): number;
31
+ addResponseInterceptor(interceptor: ResponseInterceptor): number;
32
+ addResponseErrorInterceptor(interceptor: ResponseErrorInterceptor): number;
33
+ removeRequestInterceptor(index: number): void;
34
+ removeResponseInterceptor(index: number): void;
35
+ removeResponseErrorInterceptor(index: number): void;
36
+ clearRequestInterceptors(): void;
37
+ clearResponseInterceptors(): void;
38
+ clearResponseErrorInterceptors(): void;
39
+ clearAllInterceptors(): void;
40
+ applyRequestInterceptors(config: RequestInit & {
41
+ url: string;
42
+ options: ApiRequestOptions;
43
+ }): Promise<RequestInit & {
44
+ url: string;
45
+ options: ApiRequestOptions;
46
+ }>;
47
+ applyResponseInterceptors(response: Response, requestConfig: RequestInit & {
48
+ url: string;
49
+ options: ApiRequestOptions;
50
+ }): Promise<Response>;
51
+ applyResponseErrorInterceptors(error: any, requestConfig: RequestInit & {
52
+ url: string;
53
+ options: ApiRequestOptions;
54
+ }): Promise<any>;
55
+ retryRequest<T>(config: RequestInit & {
56
+ url: string;
57
+ options: ApiRequestOptions;
58
+ }): Promise<T>;
59
+ }
60
+ export declare const interceptors: InterceptorManager;
61
+ export declare function apiRequest<T>(endpoint: string, options?: ApiRequestOptions): Promise<T>;
62
+ export {};
@@ -1,2 +1,2 @@
1
- export * from "./endpoint-config";
2
- export * from "./fetch-api";
1
+ export * from "./endpoint-config";
2
+ export * from "./fetch-api";
@@ -1,11 +1,11 @@
1
- /**
2
- * Formats a number as UAE Dirham (AED) currency with proper comma separation
3
- * @param amount The numeric value to be formatted
4
- * @param options Optional configuration for formatting
5
- * @returns Formatted currency string
6
- */
7
- export declare const formatCurrency: (amount?: number | null, options?: {
8
- currency?: string;
9
- minimumFractionDigits?: number;
10
- maximumFractionDigits?: number;
11
- }) => string;
1
+ /**
2
+ * Formats a number as UAE Dirham (AED) currency with proper comma separation
3
+ * @param amount The numeric value to be formatted
4
+ * @param options Optional configuration for formatting
5
+ * @returns Formatted currency string
6
+ */
7
+ export declare const formatCurrency: (amount?: number | null, options?: {
8
+ currency?: string;
9
+ minimumFractionDigits?: number;
10
+ maximumFractionDigits?: number;
11
+ }) => string;
@@ -1,6 +1,6 @@
1
- export declare const ONE_MINUTE_MILLIS: number;
2
- export declare const ONE_HOUR_MILLIS: number;
3
- export declare const FIFTEEN_MINUTES_MILLIS: number;
4
- export declare const THIRTY_MINUTES_MILLIS: number;
5
- export declare const ONE_HOUR = 3600;
6
- export declare const ONE_MINUTE = 60;
1
+ export declare const ONE_MINUTE_MILLIS: number;
2
+ export declare const ONE_HOUR_MILLIS: number;
3
+ export declare const FIFTEEN_MINUTES_MILLIS: number;
4
+ export declare const THIRTY_MINUTES_MILLIS: number;
5
+ export declare const ONE_HOUR = 3600;
6
+ export declare const ONE_MINUTE = 60;