@paddle/paddle-node-sdk 1.6.0 → 1.7.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/CHANGELOG.md CHANGED
@@ -12,6 +12,14 @@ When we make [non-breaking changes](https://developer.paddle.com/api-reference/a
12
12
 
13
13
  This means when upgrading minor versions of the SDK, you may notice type errors. You can safely ignore these or fix by adding additional type guards.
14
14
 
15
+ ## 1.7.0 - 2024-09-18
16
+
17
+ ### Fixed
18
+
19
+ - Marked `paymentMethodId` as nullable in `TransactionPaymentAttempt` as it can be `null`.
20
+
21
+ ---
22
+
15
23
  ## 1.6.0 - 2024-09-16
16
24
 
17
25
  ### Added
@@ -4,8 +4,9 @@ exports.TransactionPaymentAttempt = void 0;
4
4
  const index_1 = require("../index");
5
5
  class TransactionPaymentAttempt {
6
6
  constructor(transactionPaymentAttempt) {
7
+ var _a;
7
8
  this.paymentAttemptId = transactionPaymentAttempt.payment_attempt_id;
8
- this.paymentMethodId = transactionPaymentAttempt.payment_method_id;
9
+ this.paymentMethodId = (_a = transactionPaymentAttempt.payment_method_id) !== null && _a !== void 0 ? _a : null;
9
10
  this.storedPaymentMethodId = transactionPaymentAttempt.stored_payment_method_id;
10
11
  this.amount = transactionPaymentAttempt.amount;
11
12
  this.status = transactionPaymentAttempt.status;
@@ -1,4 +1,4 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.SDK_VERSION = void 0;
4
- exports.SDK_VERSION = '1.6.0';
4
+ exports.SDK_VERSION = '1.7.0';
@@ -1,8 +1,9 @@
1
1
  import { PaymentMethodDetails } from '../index';
2
2
  export class TransactionPaymentAttempt {
3
3
  constructor(transactionPaymentAttempt) {
4
+ var _a;
4
5
  this.paymentAttemptId = transactionPaymentAttempt.payment_attempt_id;
5
- this.paymentMethodId = transactionPaymentAttempt.payment_method_id;
6
+ this.paymentMethodId = (_a = transactionPaymentAttempt.payment_method_id) !== null && _a !== void 0 ? _a : null;
6
7
  this.storedPaymentMethodId = transactionPaymentAttempt.stored_payment_method_id;
7
8
  this.amount = transactionPaymentAttempt.amount;
8
9
  this.status = transactionPaymentAttempt.status;
@@ -1 +1 @@
1
- export const SDK_VERSION = '1.6.0';
1
+ export const SDK_VERSION = '1.7.0';
@@ -3,7 +3,7 @@ import { PaymentMethodDetails } from '../index';
3
3
  import { type PaymentAttemptStatus, type ErrorCode } from '../../enums';
4
4
  export declare class TransactionPaymentAttempt {
5
5
  readonly paymentAttemptId: string;
6
- readonly paymentMethodId: string;
6
+ readonly paymentMethodId: string | null;
7
7
  readonly storedPaymentMethodId: string;
8
8
  readonly amount: string;
9
9
  readonly status: PaymentAttemptStatus;
@@ -3,7 +3,7 @@ import { type PaymentAttemptStatus, type ErrorCode } from '../../enums';
3
3
  export interface ITransactionPaymentAttemptResponse {
4
4
  payment_attempt_id: string;
5
5
  stored_payment_method_id: string;
6
- payment_method_id: string;
6
+ payment_method_id: string | null;
7
7
  amount: string;
8
8
  status: PaymentAttemptStatus;
9
9
  error_code?: ErrorCode | null;
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "1.6.0";
1
+ export declare const SDK_VERSION = "1.7.0";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@paddle/paddle-node-sdk",
3
- "version": "1.6.0",
3
+ "version": "1.7.0",
4
4
  "description": "A Node.js SDK that you can use to integrate Paddle Billing with applications written in server-side JavaScript.",
5
5
  "main": "./dist/cjs/index.js",
6
6
  "module": "./dist/esm/index.js",