@kard-financial/sdk 12.3.0 → 12.4.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.
- package/README.md +106 -15
- package/dist/cjs/BaseClient.d.ts +7 -8
- package/dist/cjs/BaseClient.js +3 -3
- package/dist/cjs/Client.d.ts +13 -2
- package/dist/cjs/Client.js +67 -0
- package/dist/cjs/api/resources/auth/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/auth/client/Client.js +3 -23
- package/dist/cjs/api/resources/auth/exports.d.ts +2 -0
- package/dist/cjs/api/resources/auth/exports.js +21 -0
- package/dist/cjs/api/resources/commons/errors/ConflictError.js +5 -1
- package/dist/cjs/api/resources/commons/errors/DoesNotExistError.js +5 -1
- package/dist/cjs/api/resources/commons/errors/ForbiddenError.js +5 -1
- package/dist/cjs/api/resources/commons/errors/InternalServerError.js +5 -1
- package/dist/cjs/api/resources/commons/errors/InvalidRequest.js +5 -1
- package/dist/cjs/api/resources/commons/errors/UnauthorizedError.js +5 -1
- package/dist/cjs/api/resources/commons/exports.d.ts +1 -0
- package/dist/cjs/api/resources/commons/exports.js +18 -0
- package/dist/cjs/api/resources/commons/types/ErrorObject.d.ts +2 -2
- package/dist/cjs/api/resources/commons/types/ErrorSource.d.ts +3 -3
- package/dist/cjs/api/resources/commons/types/Links.d.ts +2 -2
- package/dist/cjs/api/resources/files/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/files/client/Client.js +11 -47
- package/dist/cjs/api/resources/files/exports.d.ts +2 -0
- package/dist/cjs/api/resources/files/exports.js +21 -0
- package/dist/cjs/api/resources/notifications/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/notifications/exports.d.ts +3 -0
- package/dist/cjs/api/resources/notifications/exports.js +22 -0
- package/dist/cjs/api/resources/notifications/resources/subscriptions/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/notifications/resources/subscriptions/client/Client.js +7 -64
- package/dist/cjs/api/resources/notifications/resources/subscriptions/exports.d.ts +2 -0
- package/dist/cjs/api/resources/notifications/resources/subscriptions/exports.js +21 -0
- package/dist/cjs/api/resources/notifications/resources/subscriptions/types/UpdateSubscriptionRequestAttributes.d.ts +3 -3
- package/dist/cjs/api/resources/notifications/types/AuditUpdateAttributes.d.ts +3 -3
- package/dist/cjs/api/resources/notifications/types/FailedTransactionAttributes.d.ts +1 -1
- package/dist/cjs/api/resources/notifications/types/NotificationPayload.d.ts +2 -2
- package/dist/cjs/api/resources/notifications/types/RewardNotificationAttributes.d.ts +2 -2
- package/dist/cjs/api/resources/ping/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/ping/client/Client.js +2 -20
- package/dist/cjs/api/resources/ping/errors/NetworkBlockedError.js +5 -1
- package/dist/cjs/api/resources/ping/exports.d.ts +2 -0
- package/dist/cjs/api/resources/ping/exports.js +21 -0
- package/dist/cjs/api/resources/transactions/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/transactions/client/Client.js +12 -113
- package/dist/cjs/api/resources/transactions/errors/CreateAuditMultiStatus.js +5 -1
- package/dist/cjs/api/resources/transactions/errors/CreateIncomingTransactionsMultiStatus.js +5 -1
- package/dist/cjs/api/resources/transactions/errors/FraudMultiStatus.js +5 -1
- package/dist/cjs/api/resources/transactions/exports.d.ts +2 -0
- package/dist/cjs/api/resources/transactions/exports.js +21 -0
- package/dist/cjs/api/resources/transactions/types/CoreTransactionAttributes.d.ts +3 -3
- package/dist/cjs/api/resources/transactions/types/CreateAuditMultiStatusResponse.d.ts +1 -1
- package/dist/cjs/api/resources/transactions/types/GetEarnedRewardsResponse.d.ts +1 -1
- package/dist/cjs/api/resources/transactions/types/MatchedTransactionsAttributes.d.ts +14 -14
- package/dist/cjs/api/resources/transactions/types/Merchant.d.ts +9 -9
- package/dist/cjs/api/resources/transactions/types/RewardedTransactionAttributes.d.ts +3 -3
- package/dist/cjs/api/resources/transactions/types/TransactionsAttributes.d.ts +18 -18
- package/dist/cjs/api/resources/users/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/users/client/Client.js +5 -80
- package/dist/cjs/api/resources/users/errors/MultiStatus.js +5 -1
- package/dist/cjs/api/resources/users/exports.d.ts +3 -0
- package/dist/cjs/api/resources/users/exports.js +22 -0
- package/dist/cjs/api/resources/users/resources/attributions/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/users/resources/attributions/client/Client.js +20 -94
- package/dist/cjs/api/resources/users/resources/attributions/exports.d.ts +2 -0
- package/dist/cjs/api/resources/users/resources/attributions/exports.js +21 -0
- package/dist/cjs/api/resources/users/resources/attributions/types/ActivateOfferResponse.d.ts +1 -1
- package/dist/cjs/api/resources/users/resources/attributions/types/AttributionState.d.ts +2 -2
- package/dist/cjs/api/resources/users/resources/attributions/types/BoostOfferResponse.d.ts +1 -1
- package/dist/cjs/api/resources/users/resources/attributions/types/NotificationAttributionAttributes.d.ts +1 -1
- package/dist/cjs/api/resources/users/resources/attributions/types/OfferAttributionAttributes.d.ts +1 -1
- package/dist/cjs/api/resources/users/resources/auth/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/users/resources/auth/client/Client.js +2 -20
- package/dist/cjs/api/resources/users/resources/auth/exports.d.ts +2 -0
- package/dist/cjs/api/resources/users/resources/auth/exports.js +21 -0
- package/dist/cjs/api/resources/users/resources/rewards/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/users/resources/rewards/client/Client.js +39 -144
- package/dist/cjs/api/resources/users/resources/rewards/exports.d.ts +2 -0
- package/dist/cjs/api/resources/users/resources/rewards/exports.js +21 -0
- package/dist/cjs/api/resources/users/resources/rewards/types/CtaComponent.d.ts +2 -2
- package/dist/cjs/api/resources/users/resources/rewards/types/LocationData.d.ts +1 -1
- package/dist/cjs/api/resources/users/resources/rewards/types/LocationsResponseObject.d.ts +1 -1
- package/dist/cjs/api/resources/users/resources/rewards/types/LogoFlare.d.ts +1 -1
- package/dist/cjs/api/resources/users/resources/rewards/types/OfferCommonFields.d.ts +8 -8
- package/dist/cjs/api/resources/users/resources/rewards/types/OfferComponents.d.ts +9 -9
- package/dist/cjs/api/resources/users/resources/rewards/types/OffersMeta.d.ts +1 -1
- package/dist/cjs/api/resources/users/resources/rewards/types/OffersResponseObject.d.ts +2 -2
- package/dist/cjs/api/resources/users/resources/rewards/types/ProgressBar.d.ts +1 -1
- package/dist/cjs/api/resources/users/resources/rewards/types/ProgressBarLabelPair.d.ts +2 -2
- package/dist/cjs/api/resources/users/resources/rewards/types/ProgressBarLabels.d.ts +1 -1
- package/dist/cjs/api/resources/users/resources/rewards/types/ProgressBarSegment.d.ts +1 -1
- package/dist/cjs/api/resources/users/resources/rewards/types/ProgressBarSegments.d.ts +1 -1
- package/dist/cjs/api/resources/users/resources/rewards/types/StandardOffer.d.ts +1 -1
- package/dist/cjs/api/resources/users/resources/uploads/client/Client.d.ts +1 -2
- package/dist/cjs/api/resources/users/resources/uploads/client/Client.js +4 -60
- package/dist/cjs/api/resources/users/resources/uploads/errors/UploadPartMultiStatus.js +5 -1
- package/dist/cjs/api/resources/users/resources/uploads/exports.d.ts +2 -0
- package/dist/cjs/api/resources/users/resources/uploads/exports.js +21 -0
- package/dist/cjs/api/resources/users/resources/uploads/types/CreateUploadPartMultiStatusResponse.d.ts +1 -1
- package/dist/cjs/api/resources/users/types/CreateUsersMultiStatusResponse.d.ts +1 -1
- package/dist/cjs/api/resources/users/types/UpdateUserRequestAttributes.d.ts +5 -5
- package/dist/cjs/api/resources/users/types/UserRequestAttributes.d.ts +6 -6
- package/dist/cjs/auth/OAuthAuthProvider.d.ts +36 -14
- package/dist/cjs/auth/OAuthAuthProvider.js +108 -40
- package/dist/cjs/core/auth/BasicAuth.d.ts +2 -2
- package/dist/cjs/core/auth/BasicAuth.js +7 -1
- package/dist/cjs/core/fetcher/BinaryResponse.d.ts +1 -1
- package/dist/cjs/core/fetcher/EndpointSupplier.d.ts +2 -2
- package/dist/cjs/core/fetcher/Fetcher.d.ts +3 -2
- package/dist/cjs/core/fetcher/Fetcher.js +12 -2
- package/dist/cjs/core/fetcher/index.d.ts +2 -0
- package/dist/cjs/core/fetcher/index.js +3 -1
- package/dist/cjs/core/fetcher/makePassthroughRequest.d.ts +49 -0
- package/dist/cjs/core/fetcher/makePassthroughRequest.js +135 -0
- package/dist/cjs/core/fetcher/makeRequest.d.ts +6 -1
- package/dist/cjs/core/fetcher/makeRequest.js +30 -9
- package/dist/cjs/core/headers.d.ts +2 -2
- package/dist/cjs/core/runtime/runtime.js +8 -7
- package/dist/cjs/errors/KardApiError.d.ts +3 -1
- package/dist/cjs/errors/KardApiError.js +9 -2
- package/dist/cjs/errors/KardApiTimeoutError.d.ts +4 -1
- package/dist/cjs/errors/KardApiTimeoutError.js +9 -2
- package/dist/cjs/errors/handleNonStatusCodeError.d.ts +2 -0
- package/dist/cjs/errors/handleNonStatusCodeError.js +68 -0
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/BaseClient.d.mts +7 -8
- package/dist/esm/BaseClient.mjs +3 -3
- package/dist/esm/Client.d.mts +13 -2
- package/dist/esm/Client.mjs +34 -0
- package/dist/esm/api/resources/auth/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/auth/client/Client.mjs +3 -23
- package/dist/esm/api/resources/auth/exports.d.mts +2 -0
- package/dist/esm/api/resources/auth/exports.mjs +3 -0
- package/dist/esm/api/resources/commons/errors/ConflictError.mjs +5 -1
- package/dist/esm/api/resources/commons/errors/DoesNotExistError.mjs +5 -1
- package/dist/esm/api/resources/commons/errors/ForbiddenError.mjs +5 -1
- package/dist/esm/api/resources/commons/errors/InternalServerError.mjs +5 -1
- package/dist/esm/api/resources/commons/errors/InvalidRequest.mjs +5 -1
- package/dist/esm/api/resources/commons/errors/UnauthorizedError.mjs +5 -1
- package/dist/esm/api/resources/commons/exports.d.mts +1 -0
- package/dist/esm/api/resources/commons/exports.mjs +2 -0
- package/dist/esm/api/resources/commons/types/ErrorObject.d.mts +2 -2
- package/dist/esm/api/resources/commons/types/ErrorSource.d.mts +3 -3
- package/dist/esm/api/resources/commons/types/Links.d.mts +2 -2
- package/dist/esm/api/resources/files/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/files/client/Client.mjs +11 -47
- package/dist/esm/api/resources/files/exports.d.mts +2 -0
- package/dist/esm/api/resources/files/exports.mjs +3 -0
- package/dist/esm/api/resources/notifications/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/notifications/exports.d.mts +3 -0
- package/dist/esm/api/resources/notifications/exports.mjs +4 -0
- package/dist/esm/api/resources/notifications/resources/subscriptions/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/notifications/resources/subscriptions/client/Client.mjs +7 -64
- package/dist/esm/api/resources/notifications/resources/subscriptions/exports.d.mts +2 -0
- package/dist/esm/api/resources/notifications/resources/subscriptions/exports.mjs +3 -0
- package/dist/esm/api/resources/notifications/resources/subscriptions/types/UpdateSubscriptionRequestAttributes.d.mts +3 -3
- package/dist/esm/api/resources/notifications/types/AuditUpdateAttributes.d.mts +3 -3
- package/dist/esm/api/resources/notifications/types/FailedTransactionAttributes.d.mts +1 -1
- package/dist/esm/api/resources/notifications/types/NotificationPayload.d.mts +2 -2
- package/dist/esm/api/resources/notifications/types/RewardNotificationAttributes.d.mts +2 -2
- package/dist/esm/api/resources/ping/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/ping/client/Client.mjs +2 -20
- package/dist/esm/api/resources/ping/errors/NetworkBlockedError.mjs +5 -1
- package/dist/esm/api/resources/ping/exports.d.mts +2 -0
- package/dist/esm/api/resources/ping/exports.mjs +3 -0
- package/dist/esm/api/resources/transactions/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/transactions/client/Client.mjs +12 -113
- package/dist/esm/api/resources/transactions/errors/CreateAuditMultiStatus.mjs +5 -1
- package/dist/esm/api/resources/transactions/errors/CreateIncomingTransactionsMultiStatus.mjs +5 -1
- package/dist/esm/api/resources/transactions/errors/FraudMultiStatus.mjs +5 -1
- package/dist/esm/api/resources/transactions/exports.d.mts +2 -0
- package/dist/esm/api/resources/transactions/exports.mjs +3 -0
- package/dist/esm/api/resources/transactions/types/CoreTransactionAttributes.d.mts +3 -3
- package/dist/esm/api/resources/transactions/types/CreateAuditMultiStatusResponse.d.mts +1 -1
- package/dist/esm/api/resources/transactions/types/GetEarnedRewardsResponse.d.mts +1 -1
- package/dist/esm/api/resources/transactions/types/MatchedTransactionsAttributes.d.mts +14 -14
- package/dist/esm/api/resources/transactions/types/Merchant.d.mts +9 -9
- package/dist/esm/api/resources/transactions/types/RewardedTransactionAttributes.d.mts +3 -3
- package/dist/esm/api/resources/transactions/types/TransactionsAttributes.d.mts +18 -18
- package/dist/esm/api/resources/users/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/users/client/Client.mjs +5 -80
- package/dist/esm/api/resources/users/errors/MultiStatus.mjs +5 -1
- package/dist/esm/api/resources/users/exports.d.mts +3 -0
- package/dist/esm/api/resources/users/exports.mjs +4 -0
- package/dist/esm/api/resources/users/resources/attributions/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/users/resources/attributions/client/Client.mjs +20 -94
- package/dist/esm/api/resources/users/resources/attributions/exports.d.mts +2 -0
- package/dist/esm/api/resources/users/resources/attributions/exports.mjs +3 -0
- package/dist/esm/api/resources/users/resources/attributions/types/ActivateOfferResponse.d.mts +1 -1
- package/dist/esm/api/resources/users/resources/attributions/types/AttributionState.d.mts +2 -2
- package/dist/esm/api/resources/users/resources/attributions/types/BoostOfferResponse.d.mts +1 -1
- package/dist/esm/api/resources/users/resources/attributions/types/NotificationAttributionAttributes.d.mts +1 -1
- package/dist/esm/api/resources/users/resources/attributions/types/OfferAttributionAttributes.d.mts +1 -1
- package/dist/esm/api/resources/users/resources/auth/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/users/resources/auth/client/Client.mjs +2 -20
- package/dist/esm/api/resources/users/resources/auth/exports.d.mts +2 -0
- package/dist/esm/api/resources/users/resources/auth/exports.mjs +3 -0
- package/dist/esm/api/resources/users/resources/rewards/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/users/resources/rewards/client/Client.mjs +39 -144
- package/dist/esm/api/resources/users/resources/rewards/exports.d.mts +2 -0
- package/dist/esm/api/resources/users/resources/rewards/exports.mjs +3 -0
- package/dist/esm/api/resources/users/resources/rewards/types/CtaComponent.d.mts +2 -2
- package/dist/esm/api/resources/users/resources/rewards/types/LocationData.d.mts +1 -1
- package/dist/esm/api/resources/users/resources/rewards/types/LocationsResponseObject.d.mts +1 -1
- package/dist/esm/api/resources/users/resources/rewards/types/LogoFlare.d.mts +1 -1
- package/dist/esm/api/resources/users/resources/rewards/types/OfferCommonFields.d.mts +8 -8
- package/dist/esm/api/resources/users/resources/rewards/types/OfferComponents.d.mts +9 -9
- package/dist/esm/api/resources/users/resources/rewards/types/OffersMeta.d.mts +1 -1
- package/dist/esm/api/resources/users/resources/rewards/types/OffersResponseObject.d.mts +2 -2
- package/dist/esm/api/resources/users/resources/rewards/types/ProgressBar.d.mts +1 -1
- package/dist/esm/api/resources/users/resources/rewards/types/ProgressBarLabelPair.d.mts +2 -2
- package/dist/esm/api/resources/users/resources/rewards/types/ProgressBarLabels.d.mts +1 -1
- package/dist/esm/api/resources/users/resources/rewards/types/ProgressBarSegment.d.mts +1 -1
- package/dist/esm/api/resources/users/resources/rewards/types/ProgressBarSegments.d.mts +1 -1
- package/dist/esm/api/resources/users/resources/rewards/types/StandardOffer.d.mts +1 -1
- package/dist/esm/api/resources/users/resources/uploads/client/Client.d.mts +1 -2
- package/dist/esm/api/resources/users/resources/uploads/client/Client.mjs +4 -60
- package/dist/esm/api/resources/users/resources/uploads/errors/UploadPartMultiStatus.mjs +5 -1
- package/dist/esm/api/resources/users/resources/uploads/exports.d.mts +2 -0
- package/dist/esm/api/resources/users/resources/uploads/exports.mjs +3 -0
- package/dist/esm/api/resources/users/resources/uploads/types/CreateUploadPartMultiStatusResponse.d.mts +1 -1
- package/dist/esm/api/resources/users/types/CreateUsersMultiStatusResponse.d.mts +1 -1
- package/dist/esm/api/resources/users/types/UpdateUserRequestAttributes.d.mts +5 -5
- package/dist/esm/api/resources/users/types/UserRequestAttributes.d.mts +6 -6
- package/dist/esm/auth/OAuthAuthProvider.d.mts +36 -14
- package/dist/esm/auth/OAuthAuthProvider.mjs +106 -39
- package/dist/esm/core/auth/BasicAuth.d.mts +2 -2
- package/dist/esm/core/auth/BasicAuth.mjs +7 -1
- package/dist/esm/core/fetcher/BinaryResponse.d.mts +1 -1
- package/dist/esm/core/fetcher/EndpointSupplier.d.mts +2 -2
- package/dist/esm/core/fetcher/Fetcher.d.mts +3 -2
- package/dist/esm/core/fetcher/Fetcher.mjs +12 -2
- package/dist/esm/core/fetcher/index.d.mts +2 -0
- package/dist/esm/core/fetcher/index.mjs +1 -0
- package/dist/esm/core/fetcher/makePassthroughRequest.d.mts +49 -0
- package/dist/esm/core/fetcher/makePassthroughRequest.mjs +132 -0
- package/dist/esm/core/fetcher/makeRequest.d.mts +6 -1
- package/dist/esm/core/fetcher/makeRequest.mjs +28 -9
- package/dist/esm/core/headers.d.mts +2 -2
- package/dist/esm/core/runtime/runtime.mjs +8 -7
- package/dist/esm/errors/KardApiError.d.mts +3 -1
- package/dist/esm/errors/KardApiError.mjs +9 -2
- package/dist/esm/errors/KardApiTimeoutError.d.mts +4 -1
- package/dist/esm/errors/KardApiTimeoutError.mjs +9 -2
- package/dist/esm/errors/handleNonStatusCodeError.d.mts +2 -0
- package/dist/esm/errors/handleNonStatusCodeError.mjs +32 -0
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +134 -10
- package/reference.md +1 -0
|
@@ -13,6 +13,7 @@ import { mergeHeaders } from "../../../../../../core/headers.mjs";
|
|
|
13
13
|
import * as core from "../../../../../../core/index.mjs";
|
|
14
14
|
import { toJson } from "../../../../../../core/json.mjs";
|
|
15
15
|
import * as environments from "../../../../../../environments.mjs";
|
|
16
|
+
import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.mjs";
|
|
16
17
|
import * as errors from "../../../../../../errors/index.mjs";
|
|
17
18
|
import * as KardApi from "../../../../../index.mjs";
|
|
18
19
|
export class RewardsClient {
|
|
@@ -49,52 +50,22 @@ export class RewardsClient {
|
|
|
49
50
|
return __awaiter(this, arguments, void 0, function* (organizationId, userId, request = {}, requestOptions) {
|
|
50
51
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
51
52
|
const { "page[size]": pageSize, "page[after]": pageAfter, "page[before]": pageBefore, "filter[search]": filterSearch, "filter[purchaseChannel]": filterPurchaseChannel, "filter[category]": filterCategory, "filter[isTargeted]": filterIsTargeted, sort, include, supportedComponents, } = request;
|
|
52
|
-
const _queryParams = {
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
}
|
|
68
|
-
if (filterCategory != null) {
|
|
69
|
-
_queryParams["filter[category]"] = filterCategory;
|
|
70
|
-
}
|
|
71
|
-
if (filterIsTargeted != null) {
|
|
72
|
-
_queryParams["filter[isTargeted]"] = filterIsTargeted.toString();
|
|
73
|
-
}
|
|
74
|
-
if (sort != null) {
|
|
75
|
-
if (Array.isArray(sort)) {
|
|
76
|
-
_queryParams.sort = sort.map((item) => item);
|
|
77
|
-
}
|
|
78
|
-
else {
|
|
79
|
-
_queryParams.sort = sort;
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
|
-
if (include != null) {
|
|
83
|
-
if (Array.isArray(include)) {
|
|
84
|
-
_queryParams.include = include.map((item) => item);
|
|
85
|
-
}
|
|
86
|
-
else {
|
|
87
|
-
_queryParams.include = include;
|
|
88
|
-
}
|
|
89
|
-
}
|
|
90
|
-
if (supportedComponents != null) {
|
|
91
|
-
if (Array.isArray(supportedComponents)) {
|
|
92
|
-
_queryParams.supportedComponents = supportedComponents.map((item) => item);
|
|
93
|
-
}
|
|
94
|
-
else {
|
|
95
|
-
_queryParams.supportedComponents = supportedComponents;
|
|
96
|
-
}
|
|
97
|
-
}
|
|
53
|
+
const _queryParams = {
|
|
54
|
+
"page[size]": pageSize,
|
|
55
|
+
"page[after]": pageAfter,
|
|
56
|
+
"page[before]": pageBefore,
|
|
57
|
+
"filter[search]": filterSearch,
|
|
58
|
+
"filter[purchaseChannel]": filterPurchaseChannel != null ? toJson(filterPurchaseChannel) : undefined,
|
|
59
|
+
"filter[category]": filterCategory != null ? filterCategory : undefined,
|
|
60
|
+
"filter[isTargeted]": filterIsTargeted,
|
|
61
|
+
sort: Array.isArray(sort) ? sort.map((item) => item) : sort != null ? sort : undefined,
|
|
62
|
+
include,
|
|
63
|
+
supportedComponents: Array.isArray(supportedComponents)
|
|
64
|
+
? supportedComponents.map((item) => item)
|
|
65
|
+
: supportedComponents != null
|
|
66
|
+
? supportedComponents
|
|
67
|
+
: undefined,
|
|
68
|
+
};
|
|
98
69
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
99
70
|
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
100
71
|
const _response = yield core.fetcher({
|
|
@@ -129,26 +100,7 @@ export class RewardsClient {
|
|
|
129
100
|
});
|
|
130
101
|
}
|
|
131
102
|
}
|
|
132
|
-
|
|
133
|
-
case "non-json":
|
|
134
|
-
throw new errors.KardApiError({
|
|
135
|
-
statusCode: _response.error.statusCode,
|
|
136
|
-
body: _response.error.rawBody,
|
|
137
|
-
rawResponse: _response.rawResponse,
|
|
138
|
-
});
|
|
139
|
-
case "body-is-null":
|
|
140
|
-
throw new errors.KardApiError({
|
|
141
|
-
statusCode: _response.error.statusCode,
|
|
142
|
-
rawResponse: _response.rawResponse,
|
|
143
|
-
});
|
|
144
|
-
case "timeout":
|
|
145
|
-
throw new errors.KardApiTimeoutError("Timeout exceeded when calling GET /v2/issuers/{organizationId}/users/{userId}/offers.");
|
|
146
|
-
case "unknown":
|
|
147
|
-
throw new errors.KardApiError({
|
|
148
|
-
message: _response.error.errorMessage,
|
|
149
|
-
rawResponse: _response.rawResponse,
|
|
150
|
-
});
|
|
151
|
-
}
|
|
103
|
+
return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/v2/issuers/{organizationId}/users/{userId}/offers");
|
|
152
104
|
});
|
|
153
105
|
}
|
|
154
106
|
/**
|
|
@@ -185,64 +137,26 @@ export class RewardsClient {
|
|
|
185
137
|
return __awaiter(this, arguments, void 0, function* (organizationId, userId, request = {}, requestOptions) {
|
|
186
138
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
187
139
|
const { "page[size]": pageSize, "page[after]": pageAfter, "page[before]": pageBefore, "filter[name]": filterName, "filter[city]": filterCity, "filter[zipCode]": filterZipCode, "filter[state]": filterState, "filter[category]": filterCategory, "filter[longitude]": filterLongitude, "filter[latitude]": filterLatitude, "filter[radius]": filterRadius, sort, include, supportedComponents, } = request;
|
|
188
|
-
const _queryParams = {
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
_queryParams["filter[state]"] = filterState;
|
|
209
|
-
}
|
|
210
|
-
if (filterCategory != null) {
|
|
211
|
-
_queryParams["filter[category]"] = filterCategory;
|
|
212
|
-
}
|
|
213
|
-
if (filterLongitude != null) {
|
|
214
|
-
_queryParams["filter[longitude]"] = filterLongitude.toString();
|
|
215
|
-
}
|
|
216
|
-
if (filterLatitude != null) {
|
|
217
|
-
_queryParams["filter[latitude]"] = filterLatitude.toString();
|
|
218
|
-
}
|
|
219
|
-
if (filterRadius != null) {
|
|
220
|
-
_queryParams["filter[radius]"] = filterRadius.toString();
|
|
221
|
-
}
|
|
222
|
-
if (sort != null) {
|
|
223
|
-
if (Array.isArray(sort)) {
|
|
224
|
-
_queryParams.sort = sort.map((item) => item);
|
|
225
|
-
}
|
|
226
|
-
else {
|
|
227
|
-
_queryParams.sort = sort;
|
|
228
|
-
}
|
|
229
|
-
}
|
|
230
|
-
if (include != null) {
|
|
231
|
-
if (Array.isArray(include)) {
|
|
232
|
-
_queryParams.include = include.map((item) => item);
|
|
233
|
-
}
|
|
234
|
-
else {
|
|
235
|
-
_queryParams.include = include;
|
|
236
|
-
}
|
|
237
|
-
}
|
|
238
|
-
if (supportedComponents != null) {
|
|
239
|
-
if (Array.isArray(supportedComponents)) {
|
|
240
|
-
_queryParams.supportedComponents = supportedComponents.map((item) => item);
|
|
241
|
-
}
|
|
242
|
-
else {
|
|
243
|
-
_queryParams.supportedComponents = supportedComponents;
|
|
244
|
-
}
|
|
245
|
-
}
|
|
140
|
+
const _queryParams = {
|
|
141
|
+
"page[size]": pageSize,
|
|
142
|
+
"page[after]": pageAfter,
|
|
143
|
+
"page[before]": pageBefore,
|
|
144
|
+
"filter[name]": filterName,
|
|
145
|
+
"filter[city]": filterCity,
|
|
146
|
+
"filter[zipCode]": filterZipCode,
|
|
147
|
+
"filter[state]": filterState != null ? filterState : undefined,
|
|
148
|
+
"filter[category]": filterCategory != null ? filterCategory : undefined,
|
|
149
|
+
"filter[longitude]": filterLongitude,
|
|
150
|
+
"filter[latitude]": filterLatitude,
|
|
151
|
+
"filter[radius]": filterRadius,
|
|
152
|
+
sort: Array.isArray(sort) ? sort.map((item) => item) : sort != null ? sort : undefined,
|
|
153
|
+
include,
|
|
154
|
+
supportedComponents: Array.isArray(supportedComponents)
|
|
155
|
+
? supportedComponents.map((item) => item)
|
|
156
|
+
: supportedComponents != null
|
|
157
|
+
? supportedComponents
|
|
158
|
+
: undefined,
|
|
159
|
+
};
|
|
246
160
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
247
161
|
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
248
162
|
const _response = yield core.fetcher({
|
|
@@ -280,26 +194,7 @@ export class RewardsClient {
|
|
|
280
194
|
});
|
|
281
195
|
}
|
|
282
196
|
}
|
|
283
|
-
|
|
284
|
-
case "non-json":
|
|
285
|
-
throw new errors.KardApiError({
|
|
286
|
-
statusCode: _response.error.statusCode,
|
|
287
|
-
body: _response.error.rawBody,
|
|
288
|
-
rawResponse: _response.rawResponse,
|
|
289
|
-
});
|
|
290
|
-
case "body-is-null":
|
|
291
|
-
throw new errors.KardApiError({
|
|
292
|
-
statusCode: _response.error.statusCode,
|
|
293
|
-
rawResponse: _response.rawResponse,
|
|
294
|
-
});
|
|
295
|
-
case "timeout":
|
|
296
|
-
throw new errors.KardApiTimeoutError("Timeout exceeded when calling GET /v2/issuers/{organizationId}/users/{userId}/locations.");
|
|
297
|
-
case "unknown":
|
|
298
|
-
throw new errors.KardApiError({
|
|
299
|
-
message: _response.error.errorMessage,
|
|
300
|
-
rawResponse: _response.rawResponse,
|
|
301
|
-
});
|
|
302
|
-
}
|
|
197
|
+
return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/v2/issuers/{organizationId}/users/{userId}/locations");
|
|
303
198
|
});
|
|
304
199
|
}
|
|
305
200
|
}
|
|
@@ -8,7 +8,7 @@ export interface CtaComponent {
|
|
|
8
8
|
/** Style of the button */
|
|
9
9
|
buttonStyle: KardApi.users.ButtonStyle;
|
|
10
10
|
/** Action to perform when the button is clicked */
|
|
11
|
-
action?: KardApi.users.CtaAction;
|
|
11
|
+
action?: KardApi.users.CtaAction | undefined;
|
|
12
12
|
/** Icon identifier to display on the button */
|
|
13
|
-
startIcon?: string;
|
|
13
|
+
startIcon?: string | undefined;
|
|
14
14
|
}
|
|
@@ -142,5 +142,5 @@ import type * as KardApi from "../../../../../index.mjs";
|
|
|
142
142
|
export interface LocationsResponseObject {
|
|
143
143
|
data: KardApi.users.LocationData[];
|
|
144
144
|
links: KardApi.Links;
|
|
145
|
-
included?: KardApi.users.EligibilityLocationIncluded[];
|
|
145
|
+
included?: KardApi.users.EligibilityLocationIncluded[] | undefined;
|
|
146
146
|
}
|
|
@@ -3,7 +3,7 @@ export interface OfferCommonFields {
|
|
|
3
3
|
/** Terms and conditions on offer */
|
|
4
4
|
terms: string;
|
|
5
5
|
/** Maximum times cardholder can redeem offer, if applicable */
|
|
6
|
-
maxRedemptions?: number;
|
|
6
|
+
maxRedemptions?: number | undefined;
|
|
7
7
|
/** Name of offer */
|
|
8
8
|
name: string;
|
|
9
9
|
purchaseChannel: KardApi.PurchaseChannel[];
|
|
@@ -17,17 +17,17 @@ export interface OfferCommonFields {
|
|
|
17
17
|
/** True returns only targeted offers, false returns only non-targeted offers */
|
|
18
18
|
isTargeted: boolean;
|
|
19
19
|
/** Minimum Transaction Amount required to redeem offer, if available on offer */
|
|
20
|
-
minTransactionAmount?: KardApi.users.Amount;
|
|
20
|
+
minTransactionAmount?: KardApi.users.Amount | undefined;
|
|
21
21
|
/** Maximum Transaction Amount allowed to redeem offer, if available on offer */
|
|
22
|
-
maxTransactionAmount?: KardApi.users.Amount;
|
|
22
|
+
maxTransactionAmount?: KardApi.users.Amount | undefined;
|
|
23
23
|
/** Minimum Reward Amount, if available on offer */
|
|
24
|
-
minRewardAmount?: KardApi.users.Amount;
|
|
24
|
+
minRewardAmount?: KardApi.users.Amount | undefined;
|
|
25
25
|
/** Maximum Reward Amount, if available on offer */
|
|
26
|
-
maxRewardAmount?: KardApi.users.Amount;
|
|
26
|
+
maxRewardAmount?: KardApi.users.Amount | undefined;
|
|
27
27
|
/** URL to the website of the offer provider */
|
|
28
|
-
websiteUrl?: string;
|
|
28
|
+
websiteUrl?: string | undefined;
|
|
29
29
|
/** Description of the offer */
|
|
30
|
-
description?: string;
|
|
30
|
+
description?: string | undefined;
|
|
31
31
|
/** UI component data for the offer, returned when supportedComponents query parameter is provided */
|
|
32
|
-
components?: KardApi.users.OfferComponents;
|
|
32
|
+
components?: KardApi.users.OfferComponents | undefined;
|
|
33
33
|
}
|
|
@@ -4,21 +4,21 @@ import type * as KardApi from "../../../../../index.mjs";
|
|
|
4
4
|
*/
|
|
5
5
|
export interface OfferComponents {
|
|
6
6
|
/** Short description for the offer */
|
|
7
|
-
shortDescription?: string;
|
|
7
|
+
shortDescription?: string | undefined;
|
|
8
8
|
/** Long description for the offer */
|
|
9
|
-
longDescription?: string;
|
|
9
|
+
longDescription?: string | undefined;
|
|
10
10
|
/** Formatted reward string */
|
|
11
|
-
baseReward?: string;
|
|
11
|
+
baseReward?: string | undefined;
|
|
12
12
|
/** Formatted boosted reward string */
|
|
13
|
-
boostedReward?: string;
|
|
13
|
+
boostedReward?: string | undefined;
|
|
14
14
|
/** Call-to-action button component */
|
|
15
|
-
cta?: KardApi.users.CtaComponent;
|
|
15
|
+
cta?: KardApi.users.CtaComponent | undefined;
|
|
16
16
|
/** Tags for the offer */
|
|
17
|
-
tags?: string[];
|
|
17
|
+
tags?: string[] | undefined;
|
|
18
18
|
/** Detail tags for the offer */
|
|
19
|
-
detailTags?: string[];
|
|
19
|
+
detailTags?: string[] | undefined;
|
|
20
20
|
/** Logo flare configuration for the offer */
|
|
21
|
-
logoFlare?: KardApi.users.LogoFlare;
|
|
21
|
+
logoFlare?: KardApi.users.LogoFlare | undefined;
|
|
22
22
|
/** Progress bar component for tracking offer redemptions */
|
|
23
|
-
progressBar?: KardApi.users.ProgressBar;
|
|
23
|
+
progressBar?: KardApi.users.ProgressBar | undefined;
|
|
24
24
|
}
|
|
@@ -4,5 +4,5 @@ import type * as KardApi from "../../../../../index.mjs";
|
|
|
4
4
|
*/
|
|
5
5
|
export interface OffersMeta {
|
|
6
6
|
/** All distinct categories available across the entire filtered result set, not just the current page */
|
|
7
|
-
availableCategories?: KardApi.users.CategoryIncluded[];
|
|
7
|
+
availableCategories?: KardApi.users.CategoryIncluded[] | undefined;
|
|
8
8
|
}
|
|
@@ -94,6 +94,6 @@ import type * as KardApi from "../../../../../index.mjs";
|
|
|
94
94
|
export interface OffersResponseObject {
|
|
95
95
|
data: KardApi.users.OfferDataUnion[];
|
|
96
96
|
links: KardApi.Links;
|
|
97
|
-
included?: KardApi.users.EligibilityOfferIncluded[];
|
|
98
|
-
meta?: KardApi.users.OffersMeta;
|
|
97
|
+
included?: KardApi.users.EligibilityOfferIncluded[] | undefined;
|
|
98
|
+
meta?: KardApi.users.OffersMeta | undefined;
|
|
99
99
|
}
|
|
@@ -12,7 +12,7 @@ export interface ProgressBar {
|
|
|
12
12
|
/** Whether the progress bar should be displayed as segmented */
|
|
13
13
|
segmented: boolean;
|
|
14
14
|
/** Segment configuration for the progress bar in different layouts */
|
|
15
|
-
segments?: KardApi.users.ProgressBarSegments;
|
|
15
|
+
segments?: KardApi.users.ProgressBarSegments | undefined;
|
|
16
16
|
/** Labels to render around the progress bar in different layouts */
|
|
17
17
|
labels: KardApi.users.ProgressBarLabels;
|
|
18
18
|
}
|
|
@@ -4,7 +4,7 @@ import type * as KardApi from "../../../../../index.mjs";
|
|
|
4
4
|
*/
|
|
5
5
|
export interface ProgressBarLabels {
|
|
6
6
|
/** Label configuration for the details view */
|
|
7
|
-
details?: KardApi.users.ProgressBarLabelPair;
|
|
7
|
+
details?: KardApi.users.ProgressBarLabelPair | undefined;
|
|
8
8
|
/** Label configuration for the default view */
|
|
9
9
|
default: KardApi.users.ProgressBarLabelPair;
|
|
10
10
|
}
|
|
@@ -4,7 +4,7 @@ import type * as KardApi from "../../../../../index.mjs";
|
|
|
4
4
|
*/
|
|
5
5
|
export interface ProgressBarSegment {
|
|
6
6
|
/** SVG icon to use for each segment */
|
|
7
|
-
icon?: string;
|
|
7
|
+
icon?: string | undefined;
|
|
8
8
|
/** Position of the segment within the layout */
|
|
9
9
|
position: KardApi.users.ProgressBarSegmentPosition;
|
|
10
10
|
}
|
|
@@ -4,7 +4,7 @@ import type * as KardApi from "../../../../../index.mjs";
|
|
|
4
4
|
*/
|
|
5
5
|
export interface ProgressBarSegments {
|
|
6
6
|
/** Segment configuration for the details view */
|
|
7
|
-
details?: KardApi.users.ProgressBarSegment;
|
|
7
|
+
details?: KardApi.users.ProgressBarSegment | undefined;
|
|
8
8
|
/** Segment configuration for the default view */
|
|
9
9
|
default: KardApi.users.ProgressBarSegment;
|
|
10
10
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import type * as KardApi from "../../../../../index.mjs";
|
|
2
2
|
export interface StandardOffer extends KardApi.users.StandardOfferCore {
|
|
3
|
-
relationships?: KardApi.users.EligibilityOfferRelationship;
|
|
3
|
+
relationships?: KardApi.users.EligibilityOfferRelationship | undefined;
|
|
4
4
|
}
|
|
@@ -3,8 +3,7 @@ import { type NormalizedClientOptionsWithAuth } from "../../../../../../BaseClie
|
|
|
3
3
|
import * as core from "../../../../../../core/index.mjs";
|
|
4
4
|
import * as KardApi from "../../../../../index.mjs";
|
|
5
5
|
export declare namespace UploadsClient {
|
|
6
|
-
|
|
7
|
-
}
|
|
6
|
+
type Options = BaseClientOptions;
|
|
8
7
|
interface RequestOptions extends BaseRequestOptions {
|
|
9
8
|
}
|
|
10
9
|
}
|
|
@@ -12,6 +12,7 @@ import { normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.mjs
|
|
|
12
12
|
import { mergeHeaders } from "../../../../../../core/headers.mjs";
|
|
13
13
|
import * as core from "../../../../../../core/index.mjs";
|
|
14
14
|
import * as environments from "../../../../../../environments.mjs";
|
|
15
|
+
import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.mjs";
|
|
15
16
|
import * as errors from "../../../../../../errors/index.mjs";
|
|
16
17
|
import * as KardApi from "../../../../../index.mjs";
|
|
17
18
|
export class UploadsClient {
|
|
@@ -84,26 +85,7 @@ export class UploadsClient {
|
|
|
84
85
|
});
|
|
85
86
|
}
|
|
86
87
|
}
|
|
87
|
-
|
|
88
|
-
case "non-json":
|
|
89
|
-
throw new errors.KardApiError({
|
|
90
|
-
statusCode: _response.error.statusCode,
|
|
91
|
-
body: _response.error.rawBody,
|
|
92
|
-
rawResponse: _response.rawResponse,
|
|
93
|
-
});
|
|
94
|
-
case "body-is-null":
|
|
95
|
-
throw new errors.KardApiError({
|
|
96
|
-
statusCode: _response.error.statusCode,
|
|
97
|
-
rawResponse: _response.rawResponse,
|
|
98
|
-
});
|
|
99
|
-
case "timeout":
|
|
100
|
-
throw new errors.KardApiTimeoutError("Timeout exceeded when calling POST /v2/issuers/{organizationId}/users/{userId}/uploads.");
|
|
101
|
-
case "unknown":
|
|
102
|
-
throw new errors.KardApiError({
|
|
103
|
-
message: _response.error.errorMessage,
|
|
104
|
-
rawResponse: _response.rawResponse,
|
|
105
|
-
});
|
|
106
|
-
}
|
|
88
|
+
return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/v2/issuers/{organizationId}/users/{userId}/uploads");
|
|
107
89
|
});
|
|
108
90
|
}
|
|
109
91
|
/**
|
|
@@ -208,26 +190,7 @@ export class UploadsClient {
|
|
|
208
190
|
});
|
|
209
191
|
}
|
|
210
192
|
}
|
|
211
|
-
|
|
212
|
-
case "non-json":
|
|
213
|
-
throw new errors.KardApiError({
|
|
214
|
-
statusCode: _response.error.statusCode,
|
|
215
|
-
body: _response.error.rawBody,
|
|
216
|
-
rawResponse: _response.rawResponse,
|
|
217
|
-
});
|
|
218
|
-
case "body-is-null":
|
|
219
|
-
throw new errors.KardApiError({
|
|
220
|
-
statusCode: _response.error.statusCode,
|
|
221
|
-
rawResponse: _response.rawResponse,
|
|
222
|
-
});
|
|
223
|
-
case "timeout":
|
|
224
|
-
throw new errors.KardApiTimeoutError("Timeout exceeded when calling PUT /v2/issuers/{organizationId}/users/{userId}/uploads/{uploadId}/parts.");
|
|
225
|
-
case "unknown":
|
|
226
|
-
throw new errors.KardApiError({
|
|
227
|
-
message: _response.error.errorMessage,
|
|
228
|
-
rawResponse: _response.rawResponse,
|
|
229
|
-
});
|
|
230
|
-
}
|
|
193
|
+
return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/v2/issuers/{organizationId}/users/{userId}/uploads/{uploadId}/parts");
|
|
231
194
|
});
|
|
232
195
|
}
|
|
233
196
|
/**
|
|
@@ -300,26 +263,7 @@ export class UploadsClient {
|
|
|
300
263
|
});
|
|
301
264
|
}
|
|
302
265
|
}
|
|
303
|
-
|
|
304
|
-
case "non-json":
|
|
305
|
-
throw new errors.KardApiError({
|
|
306
|
-
statusCode: _response.error.statusCode,
|
|
307
|
-
body: _response.error.rawBody,
|
|
308
|
-
rawResponse: _response.rawResponse,
|
|
309
|
-
});
|
|
310
|
-
case "body-is-null":
|
|
311
|
-
throw new errors.KardApiError({
|
|
312
|
-
statusCode: _response.error.statusCode,
|
|
313
|
-
rawResponse: _response.rawResponse,
|
|
314
|
-
});
|
|
315
|
-
case "timeout":
|
|
316
|
-
throw new errors.KardApiTimeoutError("Timeout exceeded when calling PUT /v2/issuers/{organizationId}/users/{userId}/uploads/{uploadId}.");
|
|
317
|
-
case "unknown":
|
|
318
|
-
throw new errors.KardApiError({
|
|
319
|
-
message: _response.error.errorMessage,
|
|
320
|
-
rawResponse: _response.rawResponse,
|
|
321
|
-
});
|
|
322
|
-
}
|
|
266
|
+
return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/v2/issuers/{organizationId}/users/{userId}/uploads/{uploadId}");
|
|
323
267
|
});
|
|
324
268
|
}
|
|
325
269
|
}
|
|
@@ -8,6 +8,10 @@ export class UploadPartMultiStatus extends errors.KardApiError {
|
|
|
8
8
|
body: body,
|
|
9
9
|
rawResponse: rawResponse,
|
|
10
10
|
});
|
|
11
|
-
Object.setPrototypeOf(this,
|
|
11
|
+
Object.setPrototypeOf(this, new.target.prototype);
|
|
12
|
+
if (Error.captureStackTrace) {
|
|
13
|
+
Error.captureStackTrace(this, this.constructor);
|
|
14
|
+
}
|
|
15
|
+
this.name = this.constructor.name;
|
|
12
16
|
}
|
|
13
17
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import type * as KardApi from "../../../../../index.mjs";
|
|
2
2
|
export interface CreateUploadPartMultiStatusResponse extends KardApi.ErrorResponse {
|
|
3
|
-
data?: KardApi.users.CreateUploadPartResponseDataUnion[];
|
|
3
|
+
data?: KardApi.users.CreateUploadPartResponseDataUnion[] | undefined;
|
|
4
4
|
}
|
|
@@ -3,13 +3,13 @@ export interface UpdateUserRequestAttributes {
|
|
|
3
3
|
/** Rewards programs to enroll the user in. If an empty array is supplied, the user will not be enrolled in any programs. */
|
|
4
4
|
enrolledRewards: KardApi.EnrolledRewardsType[];
|
|
5
5
|
/** Zipcode of user */
|
|
6
|
-
zipCode?: string;
|
|
6
|
+
zipCode?: string | undefined;
|
|
7
7
|
/** Email address of user */
|
|
8
|
-
email?: string;
|
|
8
|
+
email?: string | undefined;
|
|
9
9
|
/** Hashed email address of user (using SHA-256) */
|
|
10
|
-
hashedEmail?: string;
|
|
10
|
+
hashedEmail?: string | undefined;
|
|
11
11
|
/** Phone number of user in E.164 format */
|
|
12
|
-
phoneNumber?: string;
|
|
12
|
+
phoneNumber?: string | undefined;
|
|
13
13
|
/** Birth year of user */
|
|
14
|
-
birthYear?: string;
|
|
14
|
+
birthYear?: string | undefined;
|
|
15
15
|
}
|
|
@@ -3,15 +3,15 @@ export interface UserRequestAttributes {
|
|
|
3
3
|
/** Rewards programs to enroll the user in. If an empty array is supplied, the user will not be enrolled in any programs. */
|
|
4
4
|
enrolledRewards: KardApi.EnrolledRewardsType[];
|
|
5
5
|
/** Zipcode of user */
|
|
6
|
-
zipCode?: string;
|
|
6
|
+
zipCode?: string | undefined;
|
|
7
7
|
/** Email address of user */
|
|
8
|
-
email?: string;
|
|
8
|
+
email?: string | undefined;
|
|
9
9
|
/** Hashed email address of user (using SHA-256) */
|
|
10
|
-
hashedEmail?: string;
|
|
10
|
+
hashedEmail?: string | undefined;
|
|
11
11
|
/** Phone number of user in E.164 format */
|
|
12
|
-
phoneNumber?: string;
|
|
12
|
+
phoneNumber?: string | undefined;
|
|
13
13
|
/** Birth year of user */
|
|
14
|
-
birthYear?: string;
|
|
14
|
+
birthYear?: string | undefined;
|
|
15
15
|
/** Indicates whether historical transactions have been sent for this user */
|
|
16
|
-
historicalTransactionsSent?: boolean;
|
|
16
|
+
historicalTransactionsSent?: boolean | undefined;
|
|
17
17
|
}
|