lago-javascript-client 0.30.0-beta → 0.31.0-beta

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.
@@ -148,7 +148,7 @@ export class HttpClient {
148
148
  }
149
149
  /**
150
150
  * @title Lago API documentation
151
- * @version 0.29.0-beta
151
+ * @version 0.30.0-beta
152
152
  * @baseUrl https://api.getlago.com/api/v1
153
153
  * @externalDocs https://github.com/getlago
154
154
  * @contact <tech@getlago.com>
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "types": "./types/mod.d.ts",
5
5
  "name": "lago-javascript-client",
6
6
  "sideEffects": false,
7
- "version": "v0.30.0-beta",
7
+ "version": "v0.31.0-beta",
8
8
  "description": "Lago JavaScript API Client",
9
9
  "repository": {
10
10
  "type": "git",
@@ -152,7 +152,7 @@ class HttpClient {
152
152
  exports.HttpClient = HttpClient;
153
153
  /**
154
154
  * @title Lago API documentation
155
- * @version 0.29.0-beta
155
+ * @version 0.30.0-beta
156
156
  * @baseUrl https://api.getlago.com/api/v1
157
157
  * @externalDocs https://github.com/getlago
158
158
  * @contact <tech@getlago.com>
@@ -947,6 +947,8 @@ export interface CreditObject {
947
947
  amount_cents: number;
948
948
  /** @example "EUR" */
949
949
  amount_currency: string;
950
+ /** @example false */
951
+ before_vat: boolean;
950
952
  item: {
951
953
  /**
952
954
  * @format uuid
@@ -1085,36 +1087,68 @@ export interface InvoiceObject {
1085
1087
  sequential_id: number;
1086
1088
  /** @example "222345" */
1087
1089
  number: string;
1088
- /**
1089
- * @format date-time
1090
- * @example "2022-09-14T16:35:31Z"
1091
- */
1092
- charges_from_date: string;
1093
1090
  /**
1094
1091
  * @format date-time
1095
1092
  * @example "2022-09-14T16:35:31Z"
1096
1093
  */
1097
1094
  issuing_date: string;
1098
- invoice_type?: "subscription" | "add_on" | "credit";
1095
+ invoice_type: "subscription" | "add_on" | "credit";
1099
1096
  status: "draft" | "finalized";
1100
1097
  payment_status: "pending" | "succeeded" | "failed";
1101
- /** @example 1200 */
1102
- amount_cents: number;
1103
1098
  /** @example "EUR" */
1104
- amount_currency: string;
1099
+ currency: string;
1100
+ /** @example 20 */
1101
+ fees_amount_cents: number;
1102
+ /** @example 20 */
1103
+ coupons_amount_cents: number;
1104
+ /** @example 20 */
1105
+ credit_notes_amount_cents: number;
1106
+ /** @example 20 */
1107
+ sub_total_vat_excluded_amount_cents: number;
1105
1108
  /** @example 20 */
1106
1109
  vat_amount_cents: number;
1107
- /** @example "EUR" */
1108
- vat_amount_currency: string;
1109
1110
  /** @example 20 */
1111
+ sub_total_vat_included_amount_cents: number;
1112
+ /** @example 20 */
1113
+ prepaid_credit_amount_cents: number;
1114
+ /** @example 20 */
1115
+ total_amount_cents: number;
1116
+ /** @example 2 */
1117
+ version_number: number;
1118
+ /**
1119
+ * @deprecated
1120
+ * @example 1200
1121
+ */
1122
+ amount_cents: number;
1123
+ /**
1124
+ * @deprecated
1125
+ * @example "EUR"
1126
+ */
1127
+ amount_currency: string;
1128
+ /**
1129
+ * @deprecated
1130
+ * @example "EUR"
1131
+ */
1132
+ vat_amount_currency: string;
1133
+ /**
1134
+ * @deprecated
1135
+ * @example 20
1136
+ */
1110
1137
  credit_amount_cents: number;
1111
- /** @example "EUR" */
1138
+ /**
1139
+ * @deprecated
1140
+ * @example "EUR"
1141
+ */
1112
1142
  credit_amount_currency: string;
1113
- /** @example 1220 */
1114
- total_amount_cents: number;
1115
- /** @example "EUR" */
1143
+ /**
1144
+ * @deprecated
1145
+ * @example "EUR"
1146
+ */
1116
1147
  total_amount_currency: string;
1117
- /** @example true */
1148
+ /**
1149
+ * @deprecated
1150
+ * @example true
1151
+ */
1118
1152
  legacy: boolean;
1119
1153
  /** @example "https://example.com" */
1120
1154
  file_url?: string;
@@ -1139,7 +1173,7 @@ export interface InvoicesPaginated {
1139
1173
  export interface InvoiceInput {
1140
1174
  invoice: {
1141
1175
  /** Status */
1142
- payment_status: "pending" | "succeeded" | "failed";
1176
+ payment_status?: "pending" | "succeeded" | "failed";
1143
1177
  metadata?: {
1144
1178
  /**
1145
1179
  * @format uuid
@@ -1344,30 +1378,52 @@ export interface CreditNoteObject {
1344
1378
  reason: "duplicated_charge" | "product_unsatisfactory" | "order_change" | "order_cancellation" | "fraudulent_charge" | "other";
1345
1379
  /** @example "description" */
1346
1380
  description?: string;
1381
+ /** @example "EUR" */
1382
+ currency: string;
1347
1383
  /** @example 1220 */
1348
1384
  total_amount_cents: number;
1349
- /** @example "EUR" */
1385
+ /**
1386
+ * @deprecated
1387
+ * @example "EUR"
1388
+ */
1350
1389
  total_amount_currency: string;
1351
1390
  /** @example 20 */
1352
1391
  vat_amount_cents: number;
1353
- /** @example "EUR" */
1392
+ /**
1393
+ * @deprecated
1394
+ * @example "EUR"
1395
+ */
1354
1396
  vat_amount_currency: string;
1355
1397
  /** @example 1000 */
1356
1398
  sub_total_vat_excluded_amount_cents: number;
1357
- /** @example "EUR" */
1399
+ /**
1400
+ * @deprecated
1401
+ * @example "EUR"
1402
+ */
1358
1403
  sub_total_vat_excluded_amount_currency: string;
1359
1404
  /** @example 20 */
1360
1405
  balance_amount_cents: number;
1361
- /** @example "EUR" */
1406
+ /**
1407
+ * @deprecated
1408
+ * @example "EUR"
1409
+ */
1362
1410
  balance_amount_currency: string;
1363
1411
  /** @example 20 */
1364
1412
  credit_amount_cents: number;
1365
- /** @example "EUR" */
1413
+ /**
1414
+ * @deprecated
1415
+ * @example "EUR"
1416
+ */
1366
1417
  credit_amount_currency: string;
1367
1418
  /** @example 20 */
1368
1419
  refund_amount_cents: number;
1369
- /** @example "EUR" */
1420
+ /**
1421
+ * @deprecated
1422
+ * @example "EUR"
1423
+ */
1370
1424
  refund_amount_currency: string;
1425
+ /** @example 20 */
1426
+ coupons_adjustement_amount_cents: number;
1371
1427
  /**
1372
1428
  * @format date-time
1373
1429
  * @example "2022-09-14T16:35:31Z"
@@ -1555,7 +1611,7 @@ export declare class HttpClient<SecurityDataType = unknown> {
1555
1611
  }
1556
1612
  /**
1557
1613
  * @title Lago API documentation
1558
- * @version 0.29.0-beta
1614
+ * @version 0.30.0-beta
1559
1615
  * @baseUrl https://api.getlago.com/api/v1
1560
1616
  * @externalDocs https://github.com/getlago
1561
1617
  * @contact <tech@getlago.com>