@multimegas/sdk-js 0.0.60 → 0.0.62
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/client.d.ts +11 -11
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +2 -2
- package/dist/client.js.map +1 -1
- package/dist/services/ChildService.d.ts +8 -6
- package/dist/services/ChildService.d.ts.map +1 -1
- package/dist/services/ChildService.js +21 -15
- package/dist/services/ChildService.js.map +1 -1
- package/dist/services/ProductService.d.ts +9 -4
- package/dist/services/ProductService.d.ts.map +1 -1
- package/dist/services/ProductService.js +8 -4
- package/dist/services/ProductService.js.map +1 -1
- package/dist/services/StoreService.d.ts +33 -2
- package/dist/services/StoreService.d.ts.map +1 -1
- package/dist/services/StoreService.js +41 -0
- package/dist/services/StoreService.js.map +1 -1
- package/dist/types/entities.d.ts +106 -53
- package/dist/types/entities.d.ts.map +1 -1
- package/dist/types/requests.d.ts +63 -25
- package/dist/types/requests.d.ts.map +1 -1
- package/dist/types/responses.d.ts +119 -39
- package/dist/types/responses.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/types/requests.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Address, MexicanState } from
|
|
1
|
+
import { Address, MexicanState } from "./entities";
|
|
2
2
|
export interface LoginRequest {
|
|
3
3
|
phoneNumber: string;
|
|
4
4
|
countryCode?: string;
|
|
@@ -30,7 +30,7 @@ export interface VerifyParentRegistrationRequest extends RegisterParentRequest {
|
|
|
30
30
|
otpCode: string;
|
|
31
31
|
}
|
|
32
32
|
/** Carrier names commonly sent by the apps. See GET /public/carriers for the full list. */
|
|
33
|
-
export type KnownMobileCarrier =
|
|
33
|
+
export type KnownMobileCarrier = "FreedomPop" | "Telcel" | "AT&T" | "Movistar" | "Virgin Mobile" | "Mega Movil";
|
|
34
34
|
/**
|
|
35
35
|
* Carrier or MVNO of the line (1-60 chars). Any name is accepted; known ones
|
|
36
36
|
* are normalized server-side to their canonical spelling.
|
|
@@ -73,7 +73,7 @@ export interface PrepaidRegisterRequest {
|
|
|
73
73
|
firstName: string;
|
|
74
74
|
lastName: string;
|
|
75
75
|
birthDate?: string;
|
|
76
|
-
gender:
|
|
76
|
+
gender: "MALE" | "FEMALE" | "OTHER" | "PREFER_NOT_TO_SAY";
|
|
77
77
|
phoneNumber: string;
|
|
78
78
|
countryCode?: string;
|
|
79
79
|
address: {
|
|
@@ -90,7 +90,7 @@ export interface PrepaidRegisterRequest {
|
|
|
90
90
|
amount: number;
|
|
91
91
|
simPackageId: string;
|
|
92
92
|
paymentMethodToken?: string;
|
|
93
|
-
paymentReferenceMethod?:
|
|
93
|
+
paymentReferenceMethod?: "store" | "bank_account";
|
|
94
94
|
}
|
|
95
95
|
export interface PreRegisterChildUserRequest {
|
|
96
96
|
virtualSimId?: string;
|
|
@@ -107,7 +107,7 @@ export interface ChangeChildDistributorRequest {
|
|
|
107
107
|
/** Distributor alias, case-insensitive, optional leading @. */
|
|
108
108
|
alias: string;
|
|
109
109
|
}
|
|
110
|
-
export type PaymentFrequency =
|
|
110
|
+
export type PaymentFrequency = "WEEKLY" | "FORTNIGHTLY";
|
|
111
111
|
export interface TopupRequest {
|
|
112
112
|
productId: string;
|
|
113
113
|
phoneNumber: string;
|
|
@@ -125,7 +125,7 @@ export interface PurchaseSimPackagesRequest {
|
|
|
125
125
|
export interface PurchaseSimPackagesWithOpenPayRequest {
|
|
126
126
|
simPackageId: string;
|
|
127
127
|
paymentMethodId?: string;
|
|
128
|
-
paymentReferenceMethod?:
|
|
128
|
+
paymentReferenceMethod?: "store" | "bank_account";
|
|
129
129
|
quantity?: number;
|
|
130
130
|
}
|
|
131
131
|
export interface PurchaseESimsRequest {
|
|
@@ -142,6 +142,10 @@ export interface CreateTopupRequestRequest {
|
|
|
142
142
|
distributorCommissionAmount?: number;
|
|
143
143
|
phoneNumber?: string;
|
|
144
144
|
countryCode?: string;
|
|
145
|
+
/** Pagaqui service reference / opAccount (1-100 chars). Required for services and pins; topups default to phoneNumber. */
|
|
146
|
+
opAccount?: string;
|
|
147
|
+
/** Pagaqui amount before service fee, for variable-amount products (max 2 decimals). */
|
|
148
|
+
monto?: number;
|
|
145
149
|
}
|
|
146
150
|
export interface UpdateTopupRequestRequest {
|
|
147
151
|
productId?: string;
|
|
@@ -152,6 +156,33 @@ export interface UpdateTopupRequestRequest {
|
|
|
152
156
|
distributorCommissionAmount?: number;
|
|
153
157
|
phoneNumber?: string;
|
|
154
158
|
countryCode?: string;
|
|
159
|
+
/** Pagaqui service reference / opAccount (1-100 chars). Required for services and pins; topups default to phoneNumber. */
|
|
160
|
+
opAccount?: string;
|
|
161
|
+
/** Pagaqui amount before service fee, for variable-amount products (max 2 decimals). */
|
|
162
|
+
monto?: number;
|
|
163
|
+
}
|
|
164
|
+
export interface PagaquiQuoteRequest {
|
|
165
|
+
productId: string;
|
|
166
|
+
/** Phone number or service reference (1-100 chars). Checked against the product regex. */
|
|
167
|
+
opAccount: string;
|
|
168
|
+
/** Amount before the service fee. Required for variable-amount and quote-required products. */
|
|
169
|
+
monto?: number;
|
|
170
|
+
}
|
|
171
|
+
/** Body for POST /store/pagaqui/topup-or-service and POST /store/pagaqui/electronic-pin. */
|
|
172
|
+
export interface PagaquiPurchaseRequest {
|
|
173
|
+
productId: string;
|
|
174
|
+
/** Phone number or service reference (1-100 chars). Checked against the product regex. */
|
|
175
|
+
opAccount: string;
|
|
176
|
+
/** Amount before the service fee. Required for variable-amount and quote-required products (send the quoted monto). */
|
|
177
|
+
monto?: number;
|
|
178
|
+
customerPhone?: string;
|
|
179
|
+
/** Client-generated key (8-100 chars, [A-Za-z0-9._:-]). Retrying with the same key never charges twice. */
|
|
180
|
+
idempotencyKey: string;
|
|
181
|
+
createDebt?: boolean;
|
|
182
|
+
installmentsCount?: number;
|
|
183
|
+
paymentFrequency?: PaymentFrequency;
|
|
184
|
+
firstDueAt?: string;
|
|
185
|
+
distributorCommissionAmount?: number;
|
|
155
186
|
}
|
|
156
187
|
export interface CancelTopupRequestRequest {
|
|
157
188
|
responseNote?: string;
|
|
@@ -159,8 +190,8 @@ export interface CancelTopupRequestRequest {
|
|
|
159
190
|
export interface AcceptTopupRequestRequest {
|
|
160
191
|
responseNote?: string;
|
|
161
192
|
distributorCommissionAmount?: number;
|
|
162
|
-
processedPaymentSource?:
|
|
163
|
-
processedFundsSource?:
|
|
193
|
+
processedPaymentSource?: "CASH" | "INSTALLMENTS";
|
|
194
|
+
processedFundsSource?: "USER_FUNDS" | "VOLANA_FUNDS";
|
|
164
195
|
installmentsCount?: number;
|
|
165
196
|
firstDueAt?: string;
|
|
166
197
|
paymentFrequency?: PaymentFrequency;
|
|
@@ -178,7 +209,7 @@ export interface UpdatePhoneNumberRequest {
|
|
|
178
209
|
/** Carrier of the new line. When omitted the current brand is kept. */
|
|
179
210
|
brand?: MobileCarrier;
|
|
180
211
|
}
|
|
181
|
-
export interface CreateAddressRequest extends Omit<Address,
|
|
212
|
+
export interface CreateAddressRequest extends Omit<Address, "id" | "nickname" | "isDefault" | "userId" | "createdAt" | "updatedAt" | "deletedAt"> {
|
|
182
213
|
nickname?: string | null;
|
|
183
214
|
setAsDefault?: boolean;
|
|
184
215
|
}
|
|
@@ -195,7 +226,7 @@ export interface RegisterChildPaymentRequest {
|
|
|
195
226
|
export interface AddWalletFundsRequest {
|
|
196
227
|
amount: number;
|
|
197
228
|
paymentMethodId?: string;
|
|
198
|
-
paymentReferenceMethod?:
|
|
229
|
+
paymentReferenceMethod?: "store" | "bank_account";
|
|
199
230
|
}
|
|
200
231
|
export interface UpdateNetworkChildDetailsRequest {
|
|
201
232
|
phoneNumber?: string;
|
|
@@ -212,7 +243,7 @@ export interface UpdateNetworkChildFavoriteRequest {
|
|
|
212
243
|
isFavorite: boolean;
|
|
213
244
|
}
|
|
214
245
|
export interface UpdateNetworkChildDebtStatusRequest {
|
|
215
|
-
status:
|
|
246
|
+
status: "NO_ANSWER" | "PROMISED_PAYMENT" | "WRONG_NUMBER";
|
|
216
247
|
note?: string | null;
|
|
217
248
|
promisedPaymentDate?: string | null;
|
|
218
249
|
}
|
|
@@ -224,12 +255,12 @@ export interface UpdateNetworkChildAutoApprovalRequest {
|
|
|
224
255
|
enabled: true;
|
|
225
256
|
maxAmount: number | null;
|
|
226
257
|
commissionAmount?: number;
|
|
227
|
-
chargeMode:
|
|
228
|
-
chargeType:
|
|
229
|
-
paymentSource:
|
|
258
|
+
chargeMode: "with_charge" | "without_charge";
|
|
259
|
+
chargeType: "cash" | "installments";
|
|
260
|
+
paymentSource: "wallet" | "volana";
|
|
230
261
|
installmentPlan: {
|
|
231
262
|
installments: number;
|
|
232
|
-
unit:
|
|
263
|
+
unit: "week" | "fortnight" | "month";
|
|
233
264
|
} | null;
|
|
234
265
|
volanaAgreementAcceptedAt: string | null;
|
|
235
266
|
} | null;
|
|
@@ -239,25 +270,25 @@ export interface GetNetworkChildProfileMonthlyResultsParams {
|
|
|
239
270
|
month: number;
|
|
240
271
|
}
|
|
241
272
|
export interface GetNetworkChildProfileRequestsParams {
|
|
242
|
-
filter?:
|
|
273
|
+
filter?: "all" | "open";
|
|
243
274
|
page?: number;
|
|
244
275
|
pageSize?: number;
|
|
245
276
|
}
|
|
246
277
|
export interface GetWalletTransactionsParams {
|
|
247
278
|
cursor?: string;
|
|
248
279
|
limit?: number;
|
|
249
|
-
filter?:
|
|
250
|
-
order?:
|
|
280
|
+
filter?: "all" | "rewards" | "topups" | "ledger";
|
|
281
|
+
order?: "asc" | "desc";
|
|
251
282
|
}
|
|
252
283
|
export interface GetOverviewMonthlyResultsParams {
|
|
253
284
|
year: number;
|
|
254
285
|
month: number;
|
|
255
286
|
}
|
|
256
287
|
export interface GetNetworkRecordsParams {
|
|
257
|
-
filter?:
|
|
258
|
-
order?:
|
|
259
|
-
debtSource?:
|
|
260
|
-
debtStatus?:
|
|
288
|
+
filter?: "all" | "is_favorite" | "is_ally" | "is_inactive" | "has_request" | "has_debt";
|
|
289
|
+
order?: "latest" | "oldest";
|
|
290
|
+
debtSource?: "all" | "user_funds" | "volana";
|
|
291
|
+
debtStatus?: "urgency" | "overdue" | "expiring_soon" | "current";
|
|
261
292
|
search?: string;
|
|
262
293
|
}
|
|
263
294
|
export interface UpdateWalletAutoReloadRequest {
|
|
@@ -265,19 +296,26 @@ export interface UpdateWalletAutoReloadRequest {
|
|
|
265
296
|
triggerAmount?: number | null;
|
|
266
297
|
reloadAmount?: number | null;
|
|
267
298
|
}
|
|
299
|
+
export interface GetProductCatalogParams {
|
|
300
|
+
/**
|
|
301
|
+
* true: hide FreedomPop-source products (Pagaqui only, including its FreedomPop topups).
|
|
302
|
+
* false/omitted: both sources, without the Pagaqui FreedomPop topups that duplicate ours.
|
|
303
|
+
*/
|
|
304
|
+
hideAlly?: boolean | "0" | "1" | "true" | "false";
|
|
305
|
+
}
|
|
268
306
|
export interface GetChildPromosParams {
|
|
269
307
|
/** Include promos whose validity window has already lapsed. Defaults to false. */
|
|
270
|
-
includeExpired?: boolean |
|
|
308
|
+
includeExpired?: boolean | "0" | "1" | "true" | "false";
|
|
271
309
|
}
|
|
272
310
|
export interface GetChildInstallmentPlansParams {
|
|
273
311
|
page?: number;
|
|
274
312
|
pageSize?: number;
|
|
275
|
-
status?:
|
|
313
|
+
status?: "current" | "expiring_soon" | "overdue";
|
|
276
314
|
}
|
|
277
315
|
export interface GetVirtualSimsStockParams {
|
|
278
316
|
page?: number;
|
|
279
317
|
pageSize?: number;
|
|
280
|
-
status?:
|
|
318
|
+
status?: "AVAILABLE" | "ASSIGNED" | "ACTIVATED";
|
|
281
319
|
orderId?: string;
|
|
282
320
|
search?: string;
|
|
283
321
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"requests.d.ts","sourceRoot":"","sources":["../../src/types/requests.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAEnD,MAAM,WAAW,YAAY;
|
|
1
|
+
{"version":3,"file":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;IACpC,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,2BAA2B,CAAC,EAAE,MAAM,CAAC;CACtC;AAED,MAAM,WAAW,yBAAyB;IACxC,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IACpB,eAAe,EAAE,MAAM,CAAC;IACxB,gBAAgB,EAAE,MAAM,CAAC;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;CACxB"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { User, PaymentMethodData, Product, TopupRequestSummary, OverviewTopupRequestGroup, Notification, VolanaCreditMovement, VolanaCreditUsageItem, ChildLedgerSummary, ChildLedgerEntry, LedgerPaymentAllocation, PaymentMethodCard, PrepaidRegisterStatus, FreedomPopProfile, NetworkChildProfileData, NetworkChildProfileDetailsData, NetworkChildDebtAuditLogItem, NetworkChildProfileRequest, NetworkRecordItem, VirtualSim, VirtualSimActiveOrder, ChildNetworkDistributor, ChildNetworkReferrals, ChildCreditDistributor, ChildCreditSummary, ChildInstallmentPlan, ChildCreditPayment, ChildCreditPaymentDetail, ChildAwaitingDistributorRequest, ChildAwaitingApprovalRequest, ChildCompletedPurchase, ChildCreditTotals, ChildCountedList, ChildPromo } from
|
|
1
|
+
import { User, PaymentMethodData, Product, TopupRequestSummary, TopupRequestKind, OverviewTopupRequestGroup, Notification, VolanaCreditMovement, VolanaCreditUsageItem, ChildLedgerSummary, ChildLedgerEntry, LedgerPaymentAllocation, PaymentMethodCard, PrepaidRegisterStatus, FreedomPopProfile, NetworkChildProfileData, NetworkChildProfileDetailsData, NetworkChildDebtAuditLogItem, NetworkChildProfileRequest, NetworkRecordItem, VirtualSim, VirtualSimActiveOrder, ChildNetworkDistributor, ChildNetworkReferrals, ChildCreditDistributor, ChildCreditSummary, ChildInstallmentPlan, ChildCreditPayment, ChildCreditPaymentDetail, ChildAwaitingDistributorRequest, ChildAwaitingApprovalRequest, ChildCompletedPurchase, ChildCreditTotals, ChildCountedList, ChildPromo } from "./entities";
|
|
2
2
|
/**
|
|
3
3
|
* Access and refresh tokens.
|
|
4
4
|
* Access tokens are bearer JWTs. Child self-join tokens use claim type
|
|
@@ -17,10 +17,10 @@ export interface TokenResponse {
|
|
|
17
17
|
}
|
|
18
18
|
export interface RegistrationOtpResponse {
|
|
19
19
|
message: string;
|
|
20
|
-
provider:
|
|
20
|
+
provider: "whatsapp" | "sms";
|
|
21
21
|
}
|
|
22
22
|
export interface ParentPhoneAvailabilityResponse {
|
|
23
|
-
message:
|
|
23
|
+
message: "Phone number already registered" | "Phone number is available";
|
|
24
24
|
}
|
|
25
25
|
export interface ParentAliasAvailabilityResponse {
|
|
26
26
|
available: boolean;
|
|
@@ -104,7 +104,7 @@ export interface ChildDistributorDetailsResponse {
|
|
|
104
104
|
data: ChildDistributorDetails;
|
|
105
105
|
}
|
|
106
106
|
export interface LoginResponse extends TokenResponse {
|
|
107
|
-
user: Omit<User,
|
|
107
|
+
user: Omit<User, "parentUser">;
|
|
108
108
|
fpAT?: {
|
|
109
109
|
access_token: string;
|
|
110
110
|
refresh_token: string;
|
|
@@ -138,7 +138,7 @@ export interface WalletAddFundsResponse {
|
|
|
138
138
|
transactionId: string;
|
|
139
139
|
}
|
|
140
140
|
export interface PendingPaymentReference {
|
|
141
|
-
method:
|
|
141
|
+
method: "store" | "bank_account";
|
|
142
142
|
status: string;
|
|
143
143
|
amount: number;
|
|
144
144
|
currency: string;
|
|
@@ -154,7 +154,7 @@ export interface PendingPaymentReference {
|
|
|
154
154
|
}
|
|
155
155
|
export interface PendingPaymentTransaction {
|
|
156
156
|
id: string;
|
|
157
|
-
method:
|
|
157
|
+
method: "store" | "bank_account";
|
|
158
158
|
status: string;
|
|
159
159
|
amount: number;
|
|
160
160
|
currency: string;
|
|
@@ -186,7 +186,7 @@ export interface StoreSimPackagePurchaseWithUserFundsResponse extends StoreSimPa
|
|
|
186
186
|
simPackageLabel: string;
|
|
187
187
|
quantity: number;
|
|
188
188
|
chipsRequested: number;
|
|
189
|
-
fundsSource:
|
|
189
|
+
fundsSource: "USER_FUNDS";
|
|
190
190
|
providerResponse?: unknown;
|
|
191
191
|
}
|
|
192
192
|
export interface StoreSimPackagePurchaseReferenceResponse extends StoreSimPackagePurchaseBaseResponse {
|
|
@@ -199,7 +199,7 @@ export interface StoreESimPurchaseResponse {
|
|
|
199
199
|
paymentTransactionId: string;
|
|
200
200
|
quantity: number;
|
|
201
201
|
totalAmount: number;
|
|
202
|
-
fundsSource:
|
|
202
|
+
fundsSource: "USER_FUNDS";
|
|
203
203
|
providerResponses: unknown[];
|
|
204
204
|
}
|
|
205
205
|
export interface StoreSimPackagePurchaseStatusLogItem {
|
|
@@ -218,7 +218,7 @@ export interface StoreSimPackagePurchaseTimelineItem {
|
|
|
218
218
|
label: string;
|
|
219
219
|
description: string;
|
|
220
220
|
orderStatus: string;
|
|
221
|
-
state:
|
|
221
|
+
state: "pending" | "current" | "completed";
|
|
222
222
|
occurredAt: string | null;
|
|
223
223
|
}
|
|
224
224
|
export interface StoreSimPackagePurchaseCurrentStatus {
|
|
@@ -260,13 +260,13 @@ export interface StoreSimPackagePurchaseAddress {
|
|
|
260
260
|
state: string;
|
|
261
261
|
zipCode: string;
|
|
262
262
|
}
|
|
263
|
-
export type StoreSimPackagePurchaseUiStatusKey =
|
|
263
|
+
export type StoreSimPackagePurchaseUiStatusKey = "ORDER_CONFIRMED" | "SHIPPING_IN_PROGRESS" | "READY_FOR_DELIVERY" | "ORDER_DELIVERED" | "DATA_DISCREPANCY" | "RETURN_OR_COURIER_INCIDENT";
|
|
264
264
|
export interface StoreSimPackagePurchaseUiTimelineItem {
|
|
265
265
|
code: number;
|
|
266
266
|
key: StoreSimPackagePurchaseUiStatusKey;
|
|
267
267
|
label: string;
|
|
268
268
|
description: string;
|
|
269
|
-
state:
|
|
269
|
+
state: "pending" | "current" | "completed" | "failed";
|
|
270
270
|
occurredAt: string | null;
|
|
271
271
|
}
|
|
272
272
|
export interface StoreSimPackagePurchaseStatusBase {
|
|
@@ -280,7 +280,7 @@ export interface StoreSimPackagePurchaseStatusBase {
|
|
|
280
280
|
quantity: number;
|
|
281
281
|
simPackageId: string | null;
|
|
282
282
|
simPackageLabel: string | null;
|
|
283
|
-
fundsSource:
|
|
283
|
+
fundsSource: "USER_FUNDS" | null;
|
|
284
284
|
trackingNumber: string | null;
|
|
285
285
|
trackingUrl: string | null;
|
|
286
286
|
address: StoreSimPackagePurchaseAddress | null;
|
|
@@ -345,7 +345,7 @@ export interface ChildPreRegisterResponse {
|
|
|
345
345
|
}
|
|
346
346
|
export interface WalletTransactionMovement {
|
|
347
347
|
id: string;
|
|
348
|
-
source:
|
|
348
|
+
source: "wallet" | "reward" | "ledger";
|
|
349
349
|
createdAt: string;
|
|
350
350
|
title: string | null;
|
|
351
351
|
subtitle: string | null;
|
|
@@ -358,24 +358,24 @@ export interface WalletTransactionMovement {
|
|
|
358
358
|
isCredit: boolean;
|
|
359
359
|
details: {
|
|
360
360
|
wallet: {
|
|
361
|
-
type:
|
|
362
|
-
referenceType:
|
|
361
|
+
type: "DEPOSIT" | "TOPUP_USE" | "REFUND" | "ADJUSTMENT";
|
|
362
|
+
referenceType: "PAYMENT" | "TOPUP_REQUEST" | "ORDER" | "MANUAL" | null;
|
|
363
363
|
referenceId: string | null;
|
|
364
364
|
balanceAfter: number | null;
|
|
365
365
|
} | null;
|
|
366
366
|
reward: {
|
|
367
|
-
type:
|
|
368
|
-
status:
|
|
367
|
+
type: "ACCRUAL" | "REDEMPTION" | "EXPIRE" | "ADJUSTMENT";
|
|
368
|
+
status: "PENDING" | "CONFIRMED" | "REJECTED";
|
|
369
369
|
sourceTxId: string | null;
|
|
370
|
-
paymentSource:
|
|
370
|
+
paymentSource: "USER_FUNDS" | "VOLANA" | null;
|
|
371
371
|
rewardEarned: number;
|
|
372
372
|
description: string | null;
|
|
373
373
|
} | null;
|
|
374
374
|
ledger: {
|
|
375
|
-
type:
|
|
376
|
-
source:
|
|
375
|
+
type: "DEBT" | "PAYMENT";
|
|
376
|
+
source: "TOPUP_REQUEST" | "MANUAL";
|
|
377
377
|
topUpRequestId: string | null;
|
|
378
|
-
paymentMethod:
|
|
378
|
+
paymentMethod: "CASH" | "TRANSFER" | "CARD" | "IN_APP" | "OTHER" | null;
|
|
379
379
|
paymentReference: string | null;
|
|
380
380
|
parentUserId: string;
|
|
381
381
|
childUserId: string;
|
|
@@ -389,7 +389,7 @@ export interface WalletTransactionMovement {
|
|
|
389
389
|
} | null;
|
|
390
390
|
topUpRequest: {
|
|
391
391
|
id: string;
|
|
392
|
-
requestKind:
|
|
392
|
+
requestKind: TopupRequestKind;
|
|
393
393
|
} | null;
|
|
394
394
|
};
|
|
395
395
|
}
|
|
@@ -398,8 +398,8 @@ export interface WalletTransactionsResponse {
|
|
|
398
398
|
nextCursor: string | null;
|
|
399
399
|
hasNextPage: boolean;
|
|
400
400
|
limit: number;
|
|
401
|
-
filter:
|
|
402
|
-
order:
|
|
401
|
+
filter: "all" | "rewards" | "topups" | "ledger";
|
|
402
|
+
order: "asc" | "desc";
|
|
403
403
|
totals: {
|
|
404
404
|
total: number;
|
|
405
405
|
wallet: number;
|
|
@@ -579,13 +579,13 @@ export interface WalletPreferencesResponse {
|
|
|
579
579
|
}
|
|
580
580
|
export interface VolanaCreditOverviewResponse {
|
|
581
581
|
data: {
|
|
582
|
-
status:
|
|
582
|
+
status: "current" | "payment_pending" | "overdue";
|
|
583
583
|
summary: {
|
|
584
584
|
availableCredit: number;
|
|
585
585
|
creditLine: number;
|
|
586
586
|
usedAmount: number;
|
|
587
587
|
currency: string;
|
|
588
|
-
benefitsStatus:
|
|
588
|
+
benefitsStatus: "all_active" | "at_risk" | "suspended";
|
|
589
589
|
};
|
|
590
590
|
billing: {
|
|
591
591
|
nextCutDate: string;
|
|
@@ -596,15 +596,15 @@ export interface VolanaCreditOverviewResponse {
|
|
|
596
596
|
};
|
|
597
597
|
transactions: Array<{
|
|
598
598
|
id: string;
|
|
599
|
-
type:
|
|
599
|
+
type: "topup_sent" | "topup_received" | "payment_made" | "payment_received";
|
|
600
600
|
description: string;
|
|
601
601
|
date: string;
|
|
602
602
|
amount: number;
|
|
603
|
-
direction:
|
|
603
|
+
direction: "in" | "out";
|
|
604
604
|
}>;
|
|
605
605
|
warning: {
|
|
606
606
|
show: boolean;
|
|
607
|
-
type:
|
|
607
|
+
type: "info" | "warning" | "danger";
|
|
608
608
|
};
|
|
609
609
|
};
|
|
610
610
|
}
|
|
@@ -707,10 +707,10 @@ export interface ChildPromosResponse {
|
|
|
707
707
|
total: number;
|
|
708
708
|
};
|
|
709
709
|
}
|
|
710
|
-
export type NetworkRecordsFilter =
|
|
711
|
-
export type NetworkRecordsDebtSource =
|
|
712
|
-
export type NetworkRecordsDebtStatus =
|
|
713
|
-
export type NetworkRecordsOrder =
|
|
710
|
+
export type NetworkRecordsFilter = "all" | "is_favorite" | "is_ally" | "is_inactive" | "has_request" | "has_debt";
|
|
711
|
+
export type NetworkRecordsDebtSource = "all" | "user_funds" | "volana";
|
|
712
|
+
export type NetworkRecordsDebtStatus = "urgency" | "current" | "overdue" | "expiring_soon";
|
|
713
|
+
export type NetworkRecordsOrder = "latest" | "oldest";
|
|
714
714
|
export interface NetworkRecordsResponse {
|
|
715
715
|
data: {
|
|
716
716
|
filter: NetworkRecordsFilter;
|
|
@@ -775,8 +775,8 @@ export interface NetworkChildProfileMonthlyResultsResponse {
|
|
|
775
775
|
id: string;
|
|
776
776
|
transactionNumber: string;
|
|
777
777
|
date: string;
|
|
778
|
-
kind:
|
|
779
|
-
status:
|
|
778
|
+
kind: "product" | "service";
|
|
779
|
+
status: "pending" | "on_time" | "late";
|
|
780
780
|
label: string;
|
|
781
781
|
provider: string | null;
|
|
782
782
|
amount: number;
|
|
@@ -809,7 +809,7 @@ export interface NetworkChildProfileMonthlyResultsResponse {
|
|
|
809
809
|
}
|
|
810
810
|
export interface NetworkChildProfileRequestsResponse {
|
|
811
811
|
data: {
|
|
812
|
-
filter:
|
|
812
|
+
filter: "all" | "open";
|
|
813
813
|
page: number;
|
|
814
814
|
pageSize: number;
|
|
815
815
|
total: number;
|
|
@@ -850,7 +850,7 @@ export interface ChildPaymentPreviewAllocation {
|
|
|
850
850
|
remainingAfter: number;
|
|
851
851
|
amount: number;
|
|
852
852
|
complete: boolean;
|
|
853
|
-
statusAfter:
|
|
853
|
+
statusAfter: "PAID" | "PARTIALLY_PAID" | "PENDING";
|
|
854
854
|
}
|
|
855
855
|
export interface ChildPaymentPreviewResponse {
|
|
856
856
|
amount: number;
|
|
@@ -889,12 +889,92 @@ export interface PublicCarrier {
|
|
|
889
889
|
id: string;
|
|
890
890
|
/** Send this as `carrier` (child join) or `brand` (PATCH /user/phone-number). */
|
|
891
891
|
name: string;
|
|
892
|
-
type:
|
|
893
|
-
hostNetwork:
|
|
892
|
+
type: "MNO" | "MVNO";
|
|
893
|
+
hostNetwork: "Telcel" | "AT&T" | "Movistar" | "Altán Redes" | null;
|
|
894
894
|
aliases: string[];
|
|
895
895
|
}
|
|
896
896
|
/** GET /public/carriers */
|
|
897
897
|
export interface PublicCarriersResponse {
|
|
898
898
|
data: PublicCarrier[];
|
|
899
899
|
}
|
|
900
|
+
export interface PagaquiAmount {
|
|
901
|
+
/** Amount sent to the provider. */
|
|
902
|
+
monto: number;
|
|
903
|
+
/** Customer fee on top of the amount (Product.serviceFee). */
|
|
904
|
+
serviceFee: number;
|
|
905
|
+
/** Charged to wallet/rewards: monto + serviceFee. Base of the debt. */
|
|
906
|
+
total: number;
|
|
907
|
+
currency: "MXN";
|
|
908
|
+
}
|
|
909
|
+
export interface PagaquiCheckSkuResult {
|
|
910
|
+
rcode: number;
|
|
911
|
+
monto: number;
|
|
912
|
+
mensaje: string;
|
|
913
|
+
}
|
|
914
|
+
/** POST /store/pagaqui/quote */
|
|
915
|
+
export interface PagaquiQuoteResponse {
|
|
916
|
+
payable: boolean;
|
|
917
|
+
message: string;
|
|
918
|
+
productId: string;
|
|
919
|
+
sku: string;
|
|
920
|
+
/** Endpoint to buy with after confirming the quote. */
|
|
921
|
+
purchaseEndpoint: string;
|
|
922
|
+
/** Null when not payable. */
|
|
923
|
+
amount: PagaquiAmount | null;
|
|
924
|
+
amountSource: string | null;
|
|
925
|
+
checkSku: PagaquiCheckSkuResult | null;
|
|
926
|
+
}
|
|
927
|
+
/**
|
|
928
|
+
* COMPLETED: delivered and recorded. PENDING: not settled yet (funds stay debited),
|
|
929
|
+
* poll checkPagaquiPurchase. FAILED: declined and refunded.
|
|
930
|
+
*/
|
|
931
|
+
export type PagaquiPurchaseStatus = "COMPLETED" | "PENDING" | "FAILED";
|
|
932
|
+
export interface PagaquiPurchaseProviderInfo {
|
|
933
|
+
transactionId: string | null;
|
|
934
|
+
tRequestId: string | null;
|
|
935
|
+
/** Carrier folio / authorization. */
|
|
936
|
+
opAuthorization: string | null;
|
|
937
|
+
rcode: number | null;
|
|
938
|
+
rcodeDescription: string | null;
|
|
939
|
+
}
|
|
940
|
+
export interface PagaquiPurchasePin {
|
|
941
|
+
/**
|
|
942
|
+
* DELIVERED: `code` has the pin. FAILED: completed but pin not retrieved, call getPagaquiPurchasePin.
|
|
943
|
+
* PENDING: the purchase is not completed yet.
|
|
944
|
+
*/
|
|
945
|
+
status: "DELIVERED" | "FAILED" | "PENDING";
|
|
946
|
+
/** Pin / redemption code. Only returned to the buyer. */
|
|
947
|
+
code: string | null;
|
|
948
|
+
}
|
|
949
|
+
/**
|
|
950
|
+
* Shared 200/202 body for POST /store/pagaqui/topup-or-service, /electronic-pin,
|
|
951
|
+
* /{purchaseId}/check and /{purchaseId}/pin.
|
|
952
|
+
*/
|
|
953
|
+
export interface PagaquiPurchaseResponse {
|
|
954
|
+
success: boolean;
|
|
955
|
+
message: string;
|
|
956
|
+
/** Use with checkPagaquiPurchase and getPagaquiPurchasePin. */
|
|
957
|
+
purchaseId: string;
|
|
958
|
+
status: PagaquiPurchaseStatus;
|
|
959
|
+
/** True when the purchase needs manual reconciliation. */
|
|
960
|
+
needsReview: boolean;
|
|
961
|
+
product: {
|
|
962
|
+
id: string;
|
|
963
|
+
sku: string;
|
|
964
|
+
name: string;
|
|
965
|
+
};
|
|
966
|
+
opAccount: string;
|
|
967
|
+
amount: PagaquiAmount;
|
|
968
|
+
provider: PagaquiPurchaseProviderInfo;
|
|
969
|
+
/** Null for products without a pin code. */
|
|
970
|
+
pin: PagaquiPurchasePin | null;
|
|
971
|
+
topUpRequest?: unknown;
|
|
972
|
+
}
|
|
973
|
+
/** Error body (400/404/409/500/502) for the Pagaqui store endpoints. */
|
|
974
|
+
export interface PagaquiPurchaseErrorResponse {
|
|
975
|
+
message: string;
|
|
976
|
+
code?: string;
|
|
977
|
+
purchaseId?: string;
|
|
978
|
+
status?: PagaquiPurchaseStatus;
|
|
979
|
+
}
|
|
900
980
|
//# sourceMappingURL=responses.d.ts.map
|