@managemint-solutions/entities 1.11.0 → 1.12.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.
|
@@ -9,7 +9,10 @@ export type InvoiceLineItem = {
|
|
|
9
9
|
quantity: number;
|
|
10
10
|
amount_minor: number;
|
|
11
11
|
};
|
|
12
|
-
/**
|
|
12
|
+
/**
|
|
13
|
+
* One row of GET /billing/invoices. An invoice is the accounting document a monthly
|
|
14
|
+
* renewal issues; every other charge is a payment only (see ../payments).
|
|
15
|
+
*/
|
|
13
16
|
export type InvoiceSummary = {
|
|
14
17
|
mms_id: string;
|
|
15
18
|
/** Sequential per organization; displayed as INV-000123. */
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export type GetPaymentsDto = {
|
|
2
|
+
page: number;
|
|
3
|
+
page_size: number;
|
|
4
|
+
/** Comma-joined BillingTransactionStatus values on the wire. Absent = all payments. */
|
|
5
|
+
status_in?: string | null;
|
|
6
|
+
/** Comma-joined BillingTransactionType values on the wire. Absent = all payments. */
|
|
7
|
+
type_in?: string | null;
|
|
8
|
+
};
|
|
9
|
+
export type PaymentIdDto = {
|
|
10
|
+
paymentId: string;
|
|
11
|
+
};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { BillingTransactionStatus, BillingTransactionType } from "../enum";
|
|
2
|
+
/**
|
|
3
|
+
* One row of GET /billing/payments: a billing_transactions ledger row as the portal
|
|
4
|
+
* lists it. Every charge is a payment — the initial subscription, a pro-rata seat or
|
|
5
|
+
* module charge, a reinstatement and a monthly renewal alike — whether or not it
|
|
6
|
+
* settled. Invoices are the separate accounting documents that only renewals issue.
|
|
7
|
+
*/
|
|
8
|
+
export type PaymentSummary = {
|
|
9
|
+
mms_id: string;
|
|
10
|
+
created_at: string;
|
|
11
|
+
transaction_type: BillingTransactionType;
|
|
12
|
+
transaction_status: BillingTransactionStatus;
|
|
13
|
+
amount_minor: number;
|
|
14
|
+
currency: string;
|
|
15
|
+
paid_at: string | null;
|
|
16
|
+
failure_reason: string | null;
|
|
17
|
+
};
|
|
18
|
+
/** The full payment record behind GET /billing/payments/:paymentId. */
|
|
19
|
+
export type PaymentEntity = PaymentSummary & {
|
|
20
|
+
updated_at: string | null;
|
|
21
|
+
active_seat_count: number;
|
|
22
|
+
paid_seat_count: number;
|
|
23
|
+
modules: string[];
|
|
24
|
+
/** The per-seat prices the charge was priced from, keyed by module key. */
|
|
25
|
+
module_price_snapshot: Record<string, number> | null;
|
|
26
|
+
proration_start_at: string | null;
|
|
27
|
+
proration_end_at: string | null;
|
|
28
|
+
paystack_reference: string | null;
|
|
29
|
+
/** The invoice this payment issued — renewals only; null for every other type. */
|
|
30
|
+
invoice_id: string | null;
|
|
31
|
+
};
|
package/package.json
CHANGED