@ingenx-io/valets-schema-mcp-server 0.1.2 → 0.1.4
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/data/docs/collections/firestore-paths.md +22 -2
- package/data/docs/enums/attention-status.md +24 -0
- package/data/docs/enums/booking-status.md +2 -2
- package/data/docs/enums/customer-payment-status.md +2 -2
- package/data/docs/enums/customer-payment-target-type.md +2 -2
- package/data/docs/enums/delivery-type.md +2 -2
- package/data/docs/enums/event-status.md +2 -2
- package/data/docs/enums/fulfillment-status.md +2 -2
- package/data/docs/enums/loyalty-transaction-type.md +2 -2
- package/data/docs/enums/order-status.md +2 -2
- package/data/docs/enums/payment-method.md +2 -2
- package/data/docs/enums/payment-proof-status.md +2 -2
- package/data/docs/enums/payment-status.md +2 -2
- package/data/docs/enums/pending-issue.md +31 -0
- package/data/docs/enums/return-status.md +2 -2
- package/data/docs/enums/session-status.md +2 -2
- package/data/docs/enums/ticket-status.md +2 -2
- package/data/docs/index.md +15 -2
- package/data/docs/models/allowed-user.md +188 -0
- package/data/docs/models/analytics-event.md +533 -0
- package/data/docs/models/booking-version.md +2 -2
- package/data/docs/models/booking.md +2 -2
- package/data/docs/models/customer-payment-allocation.md +2 -2
- package/data/docs/models/customer-payment.md +2 -2
- package/data/docs/models/customer.md +2 -2
- package/data/docs/models/event.md +2 -2
- package/data/docs/models/loyalty-config.md +2 -2
- package/data/docs/models/loyalty-reward.md +2 -2
- package/data/docs/models/loyalty-status.md +2 -2
- package/data/docs/models/loyalty-transaction.md +2 -2
- package/data/docs/models/magic-link-request.md +285 -0
- package/data/docs/models/metrics-current.md +2 -2
- package/data/docs/models/metrics-daily.md +2 -2
- package/data/docs/models/metrics-monthly.md +2 -2
- package/data/docs/models/order-item.md +2 -2
- package/data/docs/models/order.md +2 -2
- package/data/docs/models/payment-summary.md +123 -0
- package/data/docs/models/sale.md +2 -2
- package/data/docs/models/site-payment.md +200 -0
- package/data/docs/models/ticket.md +2 -2
- package/data/static/llms.txt +174 -1
- package/data/static/openapi.yaml +451 -0
- package/data/static/schemas.json +511 -1
- package/package.json +1 -1
|
@@ -6,7 +6,7 @@ sidebar_position: 1
|
|
|
6
6
|
|
|
7
7
|
# Firestore Collection Paths
|
|
8
8
|
|
|
9
|
-
All collections are scoped under a company document.
|
|
9
|
+
All collections are scoped under a company document. Per **D40**, a `sites/{siteId}/` sub-tenant scope sits below `companies/{companyId}/` for site-specific collections (ING-304).
|
|
10
10
|
|
|
11
11
|
```
|
|
12
12
|
companies/{companyId}/
|
|
@@ -19,17 +19,37 @@ companies/{companyId}/
|
|
|
19
19
|
├── sales/{saleId}
|
|
20
20
|
├── purchases/{purchaseId}
|
|
21
21
|
├── customerPayments/{paymentId}
|
|
22
|
+
├── paymentSummaries/{period}
|
|
22
23
|
├── loyaltyTransactions/{transactionId}
|
|
23
|
-
|
|
24
|
+
├── loyaltyConfig (singleton document)
|
|
25
|
+
└── sites/{siteId}/ ← D40 sub-tenant scope
|
|
26
|
+
├── magic_link_requests/{requestId} ← 16-byte hex; auth audit log
|
|
27
|
+
├── allowed_users/{contactId} ← access allowlist; doc ID = email / E.164 phone (URL-escaped)
|
|
28
|
+
├── payments/{paymentId} ← SitePayment — immutable transaction ledger
|
|
29
|
+
└── analytics_events/{eventId} ← append-only product/behavior event stream
|
|
24
30
|
```
|
|
25
31
|
|
|
26
32
|
## Path conventions
|
|
27
33
|
|
|
28
34
|
- All paths are **tenant-scoped** under `companies/{companyId}/`
|
|
35
|
+
- Site-specific collections live under `companies/{companyId}/sites/{siteId}/` (D40)
|
|
29
36
|
- Sub-collections (sessions, tickets) are nested under their parent
|
|
30
37
|
- `loyaltyConfig` is a singleton document, not a collection
|
|
31
38
|
- Document IDs are auto-generated Firestore IDs unless specified
|
|
32
39
|
|
|
40
|
+
## D40 — Site sub-tenant scope
|
|
41
|
+
|
|
42
|
+
Introduced for ING-304 (canonical Firestore models derived from the SR Single site reference). The four site-scoped collections share one rationale: they belong to a *site* (a per-company product surface), not to the company as a whole. A company may host many sites.
|
|
43
|
+
|
|
44
|
+
| Collection | Purpose | Write pattern |
|
|
45
|
+
|---|---|---|
|
|
46
|
+
| `magic_link_requests` | Authentication audit log — every access request | Two-stage PATCH (request → verify) |
|
|
47
|
+
| `allowed_users` | Authoritative paid-access allowlist; referral-code resolution table | Upsert by contact ID |
|
|
48
|
+
| `payments` | Immutable SitePayment ledger (distinct from `customerPayments`) | Append-only; dual-write (redirect + webhook) |
|
|
49
|
+
| `analytics_events` | Product/behavior event stream (page views, funnel, forms, orders, identity, errors) | Append-only, immutable |
|
|
50
|
+
|
|
51
|
+
Related follow-ups: [ING-340](https://linear.app/ingenx/issue/ING-340) (retention/TTL), [ING-341](https://linear.app/ingenx/issue/ING-341) (PII redaction convention).
|
|
52
|
+
|
|
33
53
|
## Security rules pattern
|
|
34
54
|
|
|
35
55
|
```
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "AttentionStatus"
|
|
3
|
+
sidebar_label: "AttentionStatus"
|
|
4
|
+
sidebar_position: 1
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# AttentionStatus
|
|
8
|
+
|
|
9
|
+
| | |
|
|
10
|
+
| -------------- | ------------------------------ |
|
|
11
|
+
| **Type** | `enum (of string)` |
|
|
12
|
+
| **Required** | No |
|
|
13
|
+
| **Defined in** | #/definitions/attention-status |
|
|
14
|
+
|
|
15
|
+
**Description:** Operational attention status for Order and Booking (D39). Controls home-page queue assignment. Server-owned — set via triggers or callable fn only.
|
|
16
|
+
|
|
17
|
+
Must be one of:
|
|
18
|
+
* "ACTIVE"
|
|
19
|
+
* "STALE"
|
|
20
|
+
* "ON_HOLD"
|
|
21
|
+
* "ESCALATED"
|
|
22
|
+
|
|
23
|
+
----------------------------------------------------------------------------------------------------------------------------
|
|
24
|
+
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-04-18 at 21:21:09 +0000
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "BookingStatus"
|
|
3
3
|
sidebar_label: "BookingStatus"
|
|
4
|
-
sidebar_position:
|
|
4
|
+
sidebar_position: 2
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# BookingStatus
|
|
@@ -23,4 +23,4 @@ Must be one of:
|
|
|
23
23
|
* "COMPLETED_MIXED"
|
|
24
24
|
|
|
25
25
|
----------------------------------------------------------------------------------------------------------------------------
|
|
26
|
-
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-
|
|
26
|
+
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-04-18 at 21:21:09 +0000
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "CustomerPaymentStatus"
|
|
3
3
|
sidebar_label: "CustomerPaymentStatus"
|
|
4
|
-
sidebar_position:
|
|
4
|
+
sidebar_position: 3
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# CustomerPaymentStatus
|
|
@@ -23,4 +23,4 @@ Must be one of:
|
|
|
23
23
|
* "CANCELLED"
|
|
24
24
|
|
|
25
25
|
----------------------------------------------------------------------------------------------------------------------------
|
|
26
|
-
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-
|
|
26
|
+
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-04-18 at 21:21:09 +0000
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "CustomerPaymentTargetType"
|
|
3
3
|
sidebar_label: "CustomerPaymentTargetType"
|
|
4
|
-
sidebar_position:
|
|
4
|
+
sidebar_position: 4
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# CustomerPaymentTargetType
|
|
@@ -20,4 +20,4 @@ Must be one of:
|
|
|
20
20
|
* "PURCHASE"
|
|
21
21
|
|
|
22
22
|
----------------------------------------------------------------------------------------------------------------------------
|
|
23
|
-
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-
|
|
23
|
+
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-04-18 at 21:21:09 +0000
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "DeliveryType"
|
|
3
3
|
sidebar_label: "DeliveryType"
|
|
4
|
-
sidebar_position:
|
|
4
|
+
sidebar_position: 5
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# DeliveryType
|
|
@@ -20,4 +20,4 @@ Must be one of:
|
|
|
20
20
|
* "DELIVERY"
|
|
21
21
|
|
|
22
22
|
----------------------------------------------------------------------------------------------------------------------------
|
|
23
|
-
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-
|
|
23
|
+
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-04-18 at 21:21:09 +0000
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "EventStatus"
|
|
3
3
|
sidebar_label: "EventStatus"
|
|
4
|
-
sidebar_position:
|
|
4
|
+
sidebar_position: 6
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# EventStatus
|
|
@@ -21,7 +21,7 @@ Must be one of:
|
|
|
21
21
|
* "COMPLETED"
|
|
22
22
|
|
|
23
23
|
----------------------------------------------------------------------------------------------------------------------------
|
|
24
|
-
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-
|
|
24
|
+
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-04-18 at 21:21:09 +0000
|
|
25
25
|
|
|
26
26
|
## Related Decisions
|
|
27
27
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "FulfillmentStatus"
|
|
3
3
|
sidebar_label: "FulfillmentStatus"
|
|
4
|
-
sidebar_position:
|
|
4
|
+
sidebar_position: 7
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# FulfillmentStatus
|
|
@@ -23,7 +23,7 @@ Must be one of:
|
|
|
23
23
|
* "PICKED_UP"
|
|
24
24
|
|
|
25
25
|
----------------------------------------------------------------------------------------------------------------------------
|
|
26
|
-
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-
|
|
26
|
+
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-04-18 at 21:21:09 +0000
|
|
27
27
|
|
|
28
28
|
## Related Decisions
|
|
29
29
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "LoyaltyTransactionType"
|
|
3
3
|
sidebar_label: "LoyaltyTransactionType"
|
|
4
|
-
sidebar_position:
|
|
4
|
+
sidebar_position: 8
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# LoyaltyTransactionType
|
|
@@ -23,7 +23,7 @@ Must be one of:
|
|
|
23
23
|
* "REFUND"
|
|
24
24
|
|
|
25
25
|
----------------------------------------------------------------------------------------------------------------------------
|
|
26
|
-
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-
|
|
26
|
+
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-04-18 at 21:21:09 +0000
|
|
27
27
|
|
|
28
28
|
## Related Decisions
|
|
29
29
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "OrderStatus"
|
|
3
3
|
sidebar_label: "OrderStatus"
|
|
4
|
-
sidebar_position:
|
|
4
|
+
sidebar_position: 9
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# OrderStatus
|
|
@@ -24,7 +24,7 @@ Must be one of:
|
|
|
24
24
|
* "EXPIRED"
|
|
25
25
|
|
|
26
26
|
----------------------------------------------------------------------------------------------------------------------------
|
|
27
|
-
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-
|
|
27
|
+
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-04-18 at 21:21:09 +0000
|
|
28
28
|
|
|
29
29
|
## Related Decisions
|
|
30
30
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "PaymentMethod"
|
|
3
3
|
sidebar_label: "PaymentMethod"
|
|
4
|
-
sidebar_position:
|
|
4
|
+
sidebar_position: 10
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# PaymentMethod
|
|
@@ -27,7 +27,7 @@ Must be one of:
|
|
|
27
27
|
* "OTHER"
|
|
28
28
|
|
|
29
29
|
----------------------------------------------------------------------------------------------------------------------------
|
|
30
|
-
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-
|
|
30
|
+
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-04-18 at 21:21:09 +0000
|
|
31
31
|
|
|
32
32
|
## Related Decisions
|
|
33
33
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "PaymentProofStatus"
|
|
3
3
|
sidebar_label: "PaymentProofStatus"
|
|
4
|
-
sidebar_position:
|
|
4
|
+
sidebar_position: 11
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# PaymentProofStatus
|
|
@@ -20,4 +20,4 @@ Must be one of:
|
|
|
20
20
|
* "REJECTED"
|
|
21
21
|
|
|
22
22
|
----------------------------------------------------------------------------------------------------------------------------
|
|
23
|
-
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-
|
|
23
|
+
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-04-18 at 21:21:09 +0000
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "PaymentStatus"
|
|
3
3
|
sidebar_label: "PaymentStatus"
|
|
4
|
-
sidebar_position:
|
|
4
|
+
sidebar_position: 12
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# PaymentStatus
|
|
@@ -24,7 +24,7 @@ Must be one of:
|
|
|
24
24
|
* "PARTIALLY_REFUNDED"
|
|
25
25
|
|
|
26
26
|
----------------------------------------------------------------------------------------------------------------------------
|
|
27
|
-
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-
|
|
27
|
+
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-04-18 at 21:21:09 +0000
|
|
28
28
|
|
|
29
29
|
## Related Decisions
|
|
30
30
|
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "PendingIssue"
|
|
3
|
+
sidebar_label: "PendingIssue"
|
|
4
|
+
sidebar_position: 13
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# PendingIssue
|
|
8
|
+
|
|
9
|
+
| | |
|
|
10
|
+
| -------------- | --------------------------- |
|
|
11
|
+
| **Type** | `enum (of string)` |
|
|
12
|
+
| **Required** | No |
|
|
13
|
+
| **Defined in** | #/definitions/pending-issue |
|
|
14
|
+
|
|
15
|
+
**Description:** Specific detected conditions on an Order or Booking requiring human action (D39). Stored as an array — multiple issues can be active simultaneously. Server-owned.
|
|
16
|
+
|
|
17
|
+
Must be one of:
|
|
18
|
+
* "PAYMENT_PROOF_PENDING"
|
|
19
|
+
* "PAYMENT_PROOF_REJECTED"
|
|
20
|
+
* "AMOUNT_DISCREPANCY"
|
|
21
|
+
* "RETURN_UNRESOLVED"
|
|
22
|
+
* "OVERDUE_DELIVERY"
|
|
23
|
+
* "SESSION_OVERDUE"
|
|
24
|
+
* "PAYMENT_INCOMPLETE"
|
|
25
|
+
* "CANCELLATION_REQUESTED"
|
|
26
|
+
* "UNREFUNDED_CANCELLATION"
|
|
27
|
+
* "UPCOMING_UNPAID"
|
|
28
|
+
* "NO_SHOW_UNRESOLVED"
|
|
29
|
+
|
|
30
|
+
----------------------------------------------------------------------------------------------------------------------------
|
|
31
|
+
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-04-18 at 21:21:09 +0000
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "ReturnStatus"
|
|
3
3
|
sidebar_label: "ReturnStatus"
|
|
4
|
-
sidebar_position:
|
|
4
|
+
sidebar_position: 14
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# ReturnStatus
|
|
@@ -23,7 +23,7 @@ Must be one of:
|
|
|
23
23
|
* "EXCHANGE_COMPLETED"
|
|
24
24
|
|
|
25
25
|
----------------------------------------------------------------------------------------------------------------------------
|
|
26
|
-
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-
|
|
26
|
+
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-04-18 at 21:21:09 +0000
|
|
27
27
|
|
|
28
28
|
## Related Decisions
|
|
29
29
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "SessionStatus"
|
|
3
3
|
sidebar_label: "SessionStatus"
|
|
4
|
-
sidebar_position:
|
|
4
|
+
sidebar_position: 15
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# SessionStatus
|
|
@@ -23,7 +23,7 @@ Must be one of:
|
|
|
23
23
|
* "CANCELLED"
|
|
24
24
|
|
|
25
25
|
----------------------------------------------------------------------------------------------------------------------------
|
|
26
|
-
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-
|
|
26
|
+
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-04-18 at 21:21:09 +0000
|
|
27
27
|
|
|
28
28
|
## Related Decisions
|
|
29
29
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "TicketStatus"
|
|
3
3
|
sidebar_label: "TicketStatus"
|
|
4
|
-
sidebar_position:
|
|
4
|
+
sidebar_position: 16
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# TicketStatus
|
|
@@ -20,7 +20,7 @@ Must be one of:
|
|
|
20
20
|
* "CANCELLED"
|
|
21
21
|
|
|
22
22
|
----------------------------------------------------------------------------------------------------------------------------
|
|
23
|
-
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-
|
|
23
|
+
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-04-18 at 21:21:09 +0000
|
|
24
24
|
|
|
25
25
|
## Related Decisions
|
|
26
26
|
|
package/data/docs/index.md
CHANGED
|
@@ -19,12 +19,13 @@ Developers own the Zod source in `packages/schema/src/`. When schemas change, th
|
|
|
19
19
|
|
|
20
20
|
## What's documented
|
|
21
21
|
|
|
22
|
-
### Enums (
|
|
22
|
+
### Enums (16)
|
|
23
23
|
|
|
24
24
|
Status enums that drive business logic across Order, Booking, Event, and Loyalty domains:
|
|
25
25
|
|
|
26
26
|
| Enum | Values | Description |
|
|
27
27
|
|------|--------|-------------|
|
|
28
|
+
| [AttentionStatus](enums/attention-status) | 4 values | Operational attention status for Order and Booking (D39). Controls home-page queue assignment. Server-owned — set via triggers or callable fn only. |
|
|
28
29
|
| [BookingStatus](enums/booking-status) | 6 values | Booking lifecycle status. COMPLETED_MIXED = some sessions completed, others cancelled/no-show. |
|
|
29
30
|
| [CustomerPaymentStatus](enums/customer-payment-status) | 6 values | Customer payment lifecycle status (D22). Tracks allocation progress of received payments. |
|
|
30
31
|
| [CustomerPaymentTargetType](enums/customer-payment-target-type) | 3 values | Target document type for customer payment allocation. |
|
|
@@ -36,17 +37,20 @@ Status enums that drive business logic across Order, Booking, Event, and Loyalty
|
|
|
36
37
|
| [PaymentMethod](enums/payment-method) | 10 values | Unified payment method set with African + global methods (D02). |
|
|
37
38
|
| [PaymentProofStatus](enums/payment-proof-status) | 3 values | Payment proof review status. Used by Order and Booking payment proof workflows. |
|
|
38
39
|
| [PaymentStatus](enums/payment-status) | 7 values | Payment lifecycle status (D01 amended). Used by Order, Sale/Purchase, Booking. |
|
|
40
|
+
| [PendingIssue](enums/pending-issue) | 11 values | Specific detected conditions on an Order or Booking requiring human action (D39). Stored as an array — multiple issues can be active simultaneously. Server-owned. |
|
|
39
41
|
| [ReturnStatus](enums/return-status) | 6 values | Post-sale return/exchange lifecycle (D34). Optional — null until return or exchange initiated. |
|
|
40
42
|
| [SessionStatus](enums/session-status) | 6 values | Per-date/per-slot booking session status (D19). Dashboard is sole writer; Mobile is read-only. |
|
|
41
43
|
| [TicketStatus](enums/ticket-status) | 3 values | Event ticket status (D32). VALID = active and unused. |
|
|
42
44
|
|
|
43
45
|
|
|
44
|
-
### Models (
|
|
46
|
+
### Models (21)
|
|
45
47
|
|
|
46
48
|
Core Firestore document schemas:
|
|
47
49
|
|
|
48
50
|
| Model | Fields | Required | Description |
|
|
49
51
|
|-------|--------|----------|-------------|
|
|
52
|
+
| [AllowedUser](models/allowed-user) | 9 | 8 | — |
|
|
53
|
+
| [AnalyticsEvent](models/analytics-event) | 12 | 10 | — |
|
|
50
54
|
| [Booking](models/booking) | 52 | 7 | — |
|
|
51
55
|
| [BookingVersion](models/booking-version) | 9 | 6 | — |
|
|
52
56
|
| [Customer](models/customer) | 17 | 4 | — |
|
|
@@ -57,12 +61,14 @@ Core Firestore document schemas:
|
|
|
57
61
|
| [LoyaltyReward](models/loyalty-reward) | 11 | 5 | — |
|
|
58
62
|
| [LoyaltyStatus](models/loyalty-status) | 9 | 2 | — |
|
|
59
63
|
| [LoyaltyTransaction](models/loyalty-transaction) | 16 | 4 | — |
|
|
64
|
+
| [MagicLinkRequest](models/magic-link-request) | 15 | 11 | — |
|
|
60
65
|
| [MetricsCurrent](models/metrics-current) | 25 | 25 | — |
|
|
61
66
|
| [MetricsDaily](models/metrics-daily) | 26 | 26 | — |
|
|
62
67
|
| [MetricsMonthly](models/metrics-monthly) | 26 | 26 | — |
|
|
63
68
|
| [Order](models/order) | 47 | 8 | — |
|
|
64
69
|
| [OrderItem](models/order-item) | 12 | 3 | — |
|
|
65
70
|
| [Sale](models/sale) | 12 | 1 | — |
|
|
71
|
+
| [SitePayment](models/site-payment) | 10 | 9 | — |
|
|
66
72
|
| [Ticket](models/ticket) | 16 | 6 | — |
|
|
67
73
|
|
|
68
74
|
|
|
@@ -79,6 +85,13 @@ Core Firestore document schemas:
|
|
|
79
85
|
|
|
80
86
|
|
|
81
87
|
|
|
88
|
+
| Enum | Values | Description |
|
|
89
|
+
|------|--------|-------------|
|
|
90
|
+
| [AttentionStatus](proposed/enums/attention-status) | 4 values | Operational attention status for Order and Booking (D39). Controls home-page queue assignment. Server-owned — set via triggers or callable fn only. |
|
|
91
|
+
| [PendingIssue](proposed/enums/pending-issue) | 11 values | Specific detected conditions on an Order or Booking requiring human action (D39). Stored as an array — multiple issues can be active simultaneously. Server-owned. |
|
|
92
|
+
|
|
93
|
+
|
|
94
|
+
|
|
82
95
|
|
|
83
96
|
## Machine-friendly formats
|
|
84
97
|
|
|
@@ -0,0 +1,188 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "AllowedUser"
|
|
3
|
+
sidebar_label: "AllowedUser"
|
|
4
|
+
sidebar_position: 1
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# AllowedUser
|
|
8
|
+
|
|
9
|
+
<details>
|
|
10
|
+
<summary>Example JSON</summary>
|
|
11
|
+
|
|
12
|
+
```json
|
|
13
|
+
{
|
|
14
|
+
"id": null,
|
|
15
|
+
"companyId": "comp_xyz789",
|
|
16
|
+
"siteId": "sit_ref123",
|
|
17
|
+
"contact": "contact",
|
|
18
|
+
"tier": "Gold",
|
|
19
|
+
"amount": 45000,
|
|
20
|
+
"currency": "XOF",
|
|
21
|
+
"transactionId": "tra_ref123",
|
|
22
|
+
"paidAt": "pai_ref123"
|
|
23
|
+
}
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
</details>
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
- [1. Property `id`](#id)
|
|
30
|
+
- [2. Property `companyId`](#companyId)
|
|
31
|
+
- [3. Property `siteId`](#siteId)
|
|
32
|
+
- [4. Property `contact`](#contact)
|
|
33
|
+
- [5. Property `tier`](#tier)
|
|
34
|
+
- [6. Property `amount`](#amount)
|
|
35
|
+
- [7. Property `currency`](#currency)
|
|
36
|
+
- [8. Property `transactionId`](#transactionId)
|
|
37
|
+
- [9. Property `paidAt`](#paidAt)
|
|
38
|
+
- [9.1. Property `_seconds`](#paidAt__seconds)
|
|
39
|
+
- [9.2. Property `_nanoseconds`](#paidAt__nanoseconds)
|
|
40
|
+
|
|
41
|
+
| | |
|
|
42
|
+
| ------------------------- | -------------------------- |
|
|
43
|
+
| **Type** | `object` |
|
|
44
|
+
| **Required** | No |
|
|
45
|
+
| **Additional properties** | Not allowed |
|
|
46
|
+
| **Defined in** | #/definitions/allowed-user |
|
|
47
|
+
|
|
48
|
+
**Description:** AllowedUser model (D40 / ING-304). Collection: companies/\{companyId\}/sites/\{siteId\}/allowed_users/\{contactId\}. Authoritative paid-access allowlist. Upsert semantics — tier upgrades overwrite. Source of truth for access checks and referral code resolution.
|
|
49
|
+
|
|
50
|
+
| Property | Pattern | Type | Deprecated | Definition | Title/Description |
|
|
51
|
+
| ---------------------------------- | ------- | -------------- | ---------- | ------------------------------------ | ------------------------------------------------------------------------------------------------ |
|
|
52
|
+
| - [id](#id ) | No | string or null | No | - | (Read-only) Firestore document ID = contact identifier (email or E.164 phone), URL-escaped. |
|
|
53
|
+
| + [companyId](#companyId ) | No | string | No | - | (Immutable) FK → Company document ID. |
|
|
54
|
+
| + [siteId](#siteId ) | No | string | No | - | (Immutable) FK → Site document ID (D40 sub-tenant scope). |
|
|
55
|
+
| + [contact](#contact ) | No | string | No | - | Email or E.164 phone number. Canonical identifier for this user within the site. |
|
|
56
|
+
| + [tier](#tier ) | No | string | No | - | Access tier. Free string per site (ING-304 open question — tier values are site-specific today). |
|
|
57
|
+
| + [amount](#amount ) | No | number | No | - | Amount paid. Generalized from amount_xof per D40 decision. |
|
|
58
|
+
| + [currency](#currency ) | No | string | No | - | Currency code (ISO 4217). Defaults to XOF for legacy SR-Single parity. |
|
|
59
|
+
| + [transactionId](#transactionId ) | No | string | No | - | Payment provider transaction ID (e.g. Wave). |
|
|
60
|
+
| + [paidAt](#paidAt ) | No | object | No | In #/definitions/firestore-timestamp | RFC3339Nano UTC when payment was completed. |
|
|
61
|
+
|
|
62
|
+
## <a name="id"></a>1. Property `id`
|
|
63
|
+
|
|
64
|
+
| | |
|
|
65
|
+
| ------------ | ---------------- |
|
|
66
|
+
| **Type** | `string or null` |
|
|
67
|
+
| **Required** | No |
|
|
68
|
+
|
|
69
|
+
**Description:** (Read-only) Firestore document ID = contact identifier (email or E.164 phone), URL-escaped.
|
|
70
|
+
|
|
71
|
+
:::warning Server-set
|
|
72
|
+
Do not include in write requests. This field is set exclusively by the server (Firestore trigger or Admin SDK). Clients that send it will have the value silently ignored or may receive a validation error.
|
|
73
|
+
:::
|
|
74
|
+
|
|
75
|
+
## <a name="companyId"></a>2. Property `companyId`
|
|
76
|
+
|
|
77
|
+
| | |
|
|
78
|
+
| ------------ | -------- |
|
|
79
|
+
| **Type** | `string` |
|
|
80
|
+
| **Required** | Yes |
|
|
81
|
+
|
|
82
|
+
**Description:** (Immutable) FK → Company document ID.
|
|
83
|
+
|
|
84
|
+
:::info Immutable
|
|
85
|
+
Set at creation only. This field cannot be modified after the document is created. Include it in CREATE payloads; omit it (or leave unchanged) in UPDATE payloads.
|
|
86
|
+
:::
|
|
87
|
+
|
|
88
|
+
## <a name="siteId"></a>3. Property `siteId`
|
|
89
|
+
|
|
90
|
+
| | |
|
|
91
|
+
| ------------ | -------- |
|
|
92
|
+
| **Type** | `string` |
|
|
93
|
+
| **Required** | Yes |
|
|
94
|
+
|
|
95
|
+
**Description:** (Immutable) FK → Site document ID (D40 sub-tenant scope).
|
|
96
|
+
|
|
97
|
+
:::info Immutable
|
|
98
|
+
Set at creation only. This field cannot be modified after the document is created. Include it in CREATE payloads; omit it (or leave unchanged) in UPDATE payloads.
|
|
99
|
+
:::
|
|
100
|
+
|
|
101
|
+
## <a name="contact"></a>4. Property `contact`
|
|
102
|
+
|
|
103
|
+
| | |
|
|
104
|
+
| ------------ | -------- |
|
|
105
|
+
| **Type** | `string` |
|
|
106
|
+
| **Required** | Yes |
|
|
107
|
+
|
|
108
|
+
**Description:** Email or E.164 phone number. Canonical identifier for this user within the site.
|
|
109
|
+
|
|
110
|
+
## <a name="tier"></a>5. Property `tier`
|
|
111
|
+
|
|
112
|
+
| | |
|
|
113
|
+
| ------------ | -------- |
|
|
114
|
+
| **Type** | `string` |
|
|
115
|
+
| **Required** | Yes |
|
|
116
|
+
|
|
117
|
+
**Description:** Access tier. Free string per site (ING-304 open question — tier values are site-specific today).
|
|
118
|
+
|
|
119
|
+
## <a name="amount"></a>6. Property `amount`
|
|
120
|
+
|
|
121
|
+
| | |
|
|
122
|
+
| ------------ | -------- |
|
|
123
|
+
| **Type** | `number` |
|
|
124
|
+
| **Required** | Yes |
|
|
125
|
+
|
|
126
|
+
**Description:** Amount paid. Generalized from amount_xof per D40 decision.
|
|
127
|
+
|
|
128
|
+
## <a name="currency"></a>7. Property `currency`
|
|
129
|
+
|
|
130
|
+
| | |
|
|
131
|
+
| ------------ | -------- |
|
|
132
|
+
| **Type** | `string` |
|
|
133
|
+
| **Required** | Yes |
|
|
134
|
+
| **Default** | `"XOF"` |
|
|
135
|
+
|
|
136
|
+
**Description:** Currency code (ISO 4217). Defaults to XOF for legacy SR-Single parity.
|
|
137
|
+
|
|
138
|
+
## <a name="transactionId"></a>8. Property `transactionId`
|
|
139
|
+
|
|
140
|
+
| | |
|
|
141
|
+
| ------------ | -------- |
|
|
142
|
+
| **Type** | `string` |
|
|
143
|
+
| **Required** | Yes |
|
|
144
|
+
|
|
145
|
+
**Description:** Payment provider transaction ID (e.g. Wave).
|
|
146
|
+
|
|
147
|
+
## <a name="paidAt"></a>9. Property `paidAt`
|
|
148
|
+
|
|
149
|
+
| | |
|
|
150
|
+
| ------------------------- | --------------------------------- |
|
|
151
|
+
| **Type** | `object` |
|
|
152
|
+
| **Required** | Yes |
|
|
153
|
+
| **Additional properties** | Not allowed |
|
|
154
|
+
| **Defined in** | #/definitions/firestore-timestamp |
|
|
155
|
+
|
|
156
|
+
**Description:** RFC3339Nano UTC when payment was completed.
|
|
157
|
+
|
|
158
|
+
| Property | Pattern | Type | Deprecated | Definition | Title/Description |
|
|
159
|
+
| --------------------------------------- | ------- | ------- | ---------- | ---------- | ----------------- |
|
|
160
|
+
| + [_seconds](#paidAt__seconds ) | No | integer | No | - | - |
|
|
161
|
+
| + [_nanoseconds](#paidAt__nanoseconds ) | No | integer | No | - | - |
|
|
162
|
+
|
|
163
|
+
### <a name="paidAt__seconds"></a>9.1. Property `_seconds`
|
|
164
|
+
|
|
165
|
+
| | |
|
|
166
|
+
| ------------ | --------- |
|
|
167
|
+
| **Type** | `integer` |
|
|
168
|
+
| **Required** | Yes |
|
|
169
|
+
|
|
170
|
+
| Restrictions | |
|
|
171
|
+
| ------------ | ---------------------- |
|
|
172
|
+
| **Minimum** | ≥ -9007199254740991 |
|
|
173
|
+
| **Maximum** | ≤ 9007199254740991 |
|
|
174
|
+
|
|
175
|
+
### <a name="paidAt__nanoseconds"></a>9.2. Property `_nanoseconds`
|
|
176
|
+
|
|
177
|
+
| | |
|
|
178
|
+
| ------------ | --------- |
|
|
179
|
+
| **Type** | `integer` |
|
|
180
|
+
| **Required** | Yes |
|
|
181
|
+
|
|
182
|
+
| Restrictions | |
|
|
183
|
+
| ------------ | ---------------------- |
|
|
184
|
+
| **Minimum** | ≥ -9007199254740991 |
|
|
185
|
+
| **Maximum** | ≤ 9007199254740991 |
|
|
186
|
+
|
|
187
|
+
----------------------------------------------------------------------------------------------------------------------------
|
|
188
|
+
Generated using [json-schema-for-humans](https://github.com/coveooss/json-schema-for-humans) on 2026-04-18 at 21:21:09 +0000
|