@delopay/sdk 0.380.0 → 0.383.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.
@@ -16164,6 +16164,68 @@ var CheckoutSession = class {
16164
16164
  headers: this.bearerHeaders(options?.headers)
16165
16165
  });
16166
16166
  }
16167
+ /**
16168
+ * Mail the buyer a code that confirms their email, so the payment can reuse
16169
+ * a verification the merchant already has for them. Offer it only while the
16170
+ * checkout data says `identity_verification_reuse_allowed`. The answer is
16171
+ * the same whether or not the merchant verified anyone with the address.
16172
+ *
16173
+ * Refusals throw a `DelopayError`: `400` with code `DE_26` and the reason as
16174
+ * its message (`IV_REUSE_OFF` when the payment's requirement does not allow
16175
+ * reuse, `IV_REUSE_STEP` when the payment has no verification step a reuse
16176
+ * can stand for, `IV_EMAIL_INVALID`), `429` after too many codes for the
16177
+ * caller or the address.
16178
+ *
16179
+ * `POST /payment-link/{merchantId}/{paymentId}/identity-verification/email-code`
16180
+ */
16181
+ async sendIdentityEmailCode(params, options) {
16182
+ return this.client.request("POST", `${this.linkBase}/identity-verification/email-code`, {
16183
+ body: params,
16184
+ ...options,
16185
+ headers: this.bearerHeaders(options?.headers)
16186
+ });
16187
+ }
16188
+ /**
16189
+ * Check the code the buyer entered. `reusable` says only whether the
16190
+ * merchant has a verification the payment can reuse; then call
16191
+ * {@link CheckoutSession.reuseIdentityVerification}. Otherwise pass the
16192
+ * `challenge_id` as `email_challenge_id` to
16193
+ * {@link CheckoutSession.startIdentityVerification}, so a later payment can
16194
+ * reuse the verification it starts.
16195
+ *
16196
+ * Refusals throw a `DelopayError`: `400` with code `DE_26` and the reason as
16197
+ * its message. `IV_CODE_INCORRECT` is a wrong code, with the tries left in
16198
+ * `data.attempts_left`; `IV_CODE_EXPIRED` is an expired code or one out of
16199
+ * tries; `IV_CHALLENGE_UNKNOWN` names no code of this payment.
16200
+ *
16201
+ * `POST /payment-link/{merchantId}/{paymentId}/identity-verification/email-code/verify`
16202
+ */
16203
+ async verifyIdentityEmailCode(params, options) {
16204
+ return this.client.request("POST", `${this.linkBase}/identity-verification/email-code/verify`, {
16205
+ body: params,
16206
+ ...options,
16207
+ headers: this.bearerHeaders(options?.headers)
16208
+ });
16209
+ }
16210
+ /**
16211
+ * Reuse the merchant's verification for the buyer's confirmed email as the
16212
+ * payment's verification. Needs the challenge confirmed on this payment in
16213
+ * the last 30 minutes, and uses it up. No provider session, provider cost or
16214
+ * DeloPay fee is made. Answers the payment's verification step, verified.
16215
+ *
16216
+ * Refusals throw a `DelopayError`: `400` with code `DE_26` and the reason as
16217
+ * its message (`IV_CHALLENGE_NOT_CONFIRMED`, `IV_REUSE_NOT_ELIGIBLE`,
16218
+ * `IV_REUSE_OFF`, `IV_REUSE_STEP`).
16219
+ *
16220
+ * `POST /payment-link/{merchantId}/{paymentId}/identity-verification/reuse`
16221
+ */
16222
+ async reuseIdentityVerification(params, options) {
16223
+ return this.client.request("POST", `${this.linkBase}/identity-verification/reuse`, {
16224
+ body: params,
16225
+ ...options,
16226
+ headers: this.bearerHeaders(options?.headers)
16227
+ });
16228
+ }
16167
16229
  /**
16168
16230
  * Start the device assessment of the payment's checkout. `required` is
16169
16231
  * `false` when the shop assesses no devices, the payment's device is already
@@ -17259,4 +17321,4 @@ export {
17259
17321
  decodeNativePanes,
17260
17322
  encodeNativePanes
17261
17323
  };
17262
- //# sourceMappingURL=chunk-BSVLB2QZ.js.map
17324
+ //# sourceMappingURL=chunk-JZBJHC2M.js.map