Skip to content
This repository was archived by the owner on Mar 19, 2024. It is now read-only.

4.0.0

Choose a tag to compare

@IngenicoEPayments IngenicoEPayments released this 06 Jan 14:46
· 24 commits to master since this release
  • Added:
    • Added property productSku to request type OrderLineDetails.
    • Added call captures.refund.
  • Changed:
    • Rewrote the SDK in TypeScript. This adds types to parameters and response values. For domain objects, all properties are marked as optional. This is done to prevent issues like #5.

      The rewrite is almost fully backward compatible, even if you're already using TypeScript. For this reason, the response body has type any. You can cast it to the right type using the as keyword if necessary. Since all properties are marked as optional, this may require using the ! or ? operators, depending on your TypeScript settings. For instance: paymentResponse.payment!.id!.

      Despite our attempts to prevent any breaking changes, the following changes are still breaking:
      • require or import statements for anything other than connect-sdk-nodejs need to have an additional lib added. For instance, require("connect-sdk-nodejs/lib/utils/context"). The same objects are exported; export assignments are used instead of default exports.
      • The API version is no longer available on the context or webhooks helper as property API_VERSION, as it was intended for internal use only. If this is still needed, it can be imported using require("connect-sdk-nodejs/lib/utils/versions").apiVersion or import { apiVersion } from "connect-sdk-nodejs/lib/utils/versions".
    • The integrator has been made required when initializing the SDK. This must be done using property integrator, which could already be used; the old incorrectly named intergrator property is no longer supported.
    • Replaced dependency node-uuid with uuid.