@loxtep/sdk 0.11.1 → 0.13.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.
Files changed (69) hide show
  1. package/CHANGELOG.md +13 -0
  2. package/dist/cli/commands/attach-cmd.d.ts +1 -1
  3. package/dist/cli/commands/attach-cmd.js +1 -1
  4. package/dist/cli/commands/delivery-cmd.d.ts +1 -0
  5. package/dist/cli/commands/delivery-cmd.d.ts.map +1 -1
  6. package/dist/cli/commands/delivery-cmd.js +60 -44
  7. package/dist/cli/commands/delivery-cmd.js.map +1 -1
  8. package/dist/cli/commands/ingest-cmd.d.ts +1 -0
  9. package/dist/cli/commands/ingest-cmd.d.ts.map +1 -1
  10. package/dist/cli/commands/ingest-cmd.js +37 -24
  11. package/dist/cli/commands/ingest-cmd.js.map +1 -1
  12. package/dist/cli/commands/start-cmd.d.ts +25 -0
  13. package/dist/cli/commands/start-cmd.d.ts.map +1 -0
  14. package/dist/cli/commands/start-cmd.js +145 -0
  15. package/dist/cli/commands/start-cmd.js.map +1 -0
  16. package/dist/cli/commands/transform-cmd.d.ts +1 -0
  17. package/dist/cli/commands/transform-cmd.d.ts.map +1 -1
  18. package/dist/cli/commands/transform-cmd.js +36 -23
  19. package/dist/cli/commands/transform-cmd.js.map +1 -1
  20. package/dist/cli/help.d.ts.map +1 -1
  21. package/dist/cli/help.js +9 -3
  22. package/dist/cli/help.js.map +1 -1
  23. package/dist/cli/index.d.ts.map +1 -1
  24. package/dist/cli/index.js +576 -515
  25. package/dist/cli/index.js.map +1 -1
  26. package/dist/cli/setup-prompt.d.ts +2 -0
  27. package/dist/cli/setup-prompt.d.ts.map +1 -0
  28. package/dist/cli/setup-prompt.js +3 -0
  29. package/dist/cli/setup-prompt.js.map +1 -0
  30. package/dist/client/data-products.d.ts +10 -8
  31. package/dist/client/data-products.d.ts.map +1 -1
  32. package/dist/client/data-products.js +142 -93
  33. package/dist/client/data-products.js.map +1 -1
  34. package/dist/client/flow-types.d.ts +16 -6
  35. package/dist/client/flow-types.d.ts.map +1 -1
  36. package/dist/client/flow-types.js +6 -1
  37. package/dist/client/flow-types.js.map +1 -1
  38. package/dist/client/index.d.ts +89 -88
  39. package/dist/client/index.d.ts.map +1 -1
  40. package/dist/client/index.js +13 -12
  41. package/dist/client/index.js.map +1 -1
  42. package/dist/client/projects-types.d.ts +1 -1
  43. package/dist/client/queues.d.ts +5 -3
  44. package/dist/client/queues.d.ts.map +1 -1
  45. package/dist/client/queues.js +26 -21
  46. package/dist/client/queues.js.map +1 -1
  47. package/dist/client/workflows.d.ts +7 -7
  48. package/dist/client/workflows.d.ts.map +1 -1
  49. package/dist/client/workflows.js +71 -63
  50. package/dist/client/workflows.js.map +1 -1
  51. package/dist/lib/sdk-ingest-bundle.d.ts +5 -1
  52. package/dist/lib/sdk-ingest-bundle.d.ts.map +1 -1
  53. package/dist/lib/sdk-ingest-bundle.js +38 -29
  54. package/dist/lib/sdk-ingest-bundle.js.map +1 -1
  55. package/dist/rstreams/event-bridge.d.ts +4 -4
  56. package/dist/rstreams/event-bridge.d.ts.map +1 -1
  57. package/dist/rstreams/event-bridge.js +23 -16
  58. package/dist/rstreams/event-bridge.js.map +1 -1
  59. package/docs/event-writer-transport-modes.md +47 -0
  60. package/docs/getting-started.md +19 -0
  61. package/docs/sdk-first-ingest.md +14 -12
  62. package/docs/sdk-mcp-mapping.md +8 -3
  63. package/package.json +1 -1
  64. package/schemas/entity-json-schemas/SCHEMA_SYNC.md +1 -1
  65. package/schemas/entity-json-schemas/SOURCE.json +5 -4
  66. package/schemas/entity-json-schemas/connection.json +35 -0
  67. package/schemas/entity-json-schemas/data-product.json +16 -0
  68. package/schemas/entity-json-schemas/grant.json +146 -0
  69. package/schemas/entity-json-schemas/transformation.json +19 -0
@@ -0,0 +1,146 @@
1
+ {
2
+ "$schema": "http://json-schema.org/draft-07/schema#",
3
+ "$id": "https://loxtep.io/schemas/entity/grant.json",
4
+ "title": "Delivery Grant Entity",
5
+ "description": "JSON Schema for a Git-backed delivery grant declaration. Materializes into data_product_subscribers (product + consumer + access_method + destination connection). Deploy embeds the active grant into outbound runtime writers (D6).",
6
+ "type": "object",
7
+ "required": [
8
+ "grant_id",
9
+ "organization_id",
10
+ "data_product_id",
11
+ "party_subject_type",
12
+ "access_method",
13
+ "status",
14
+ "created_at",
15
+ "updated_at"
16
+ ],
17
+ "properties": {
18
+ "grant_id": {
19
+ "type": "string",
20
+ "format": "uuid",
21
+ "description": "Stable declaration id; becomes data_product_subscriber_id at materialize time"
22
+ },
23
+ "organization_id": {
24
+ "type": "string",
25
+ "format": "uuid",
26
+ "description": "Organization that owns this grant"
27
+ },
28
+ "project_id": {
29
+ "type": ["string", "null"],
30
+ "format": "uuid",
31
+ "description": "Project that contains this grant declaration"
32
+ },
33
+ "workflow_id": {
34
+ "type": ["string", "null"],
35
+ "format": "uuid",
36
+ "description": "Optional delivery workflow this grant is authored with"
37
+ },
38
+ "data_product_id": {
39
+ "type": "string",
40
+ "format": "uuid",
41
+ "description": "Published data product the grant authorizes delivery for"
42
+ },
43
+ "subscriber_kind": {
44
+ "type": "string",
45
+ "const": "consumer",
46
+ "default": "consumer",
47
+ "description": "Grant subscriber kind (always consumer for delivery grants)"
48
+ },
49
+ "party_subject_type": {
50
+ "type": "string",
51
+ "enum": ["user", "organization", "domain", "external"],
52
+ "description": "Consumer principal type"
53
+ },
54
+ "user_id": {
55
+ "type": ["string", "null"],
56
+ "format": "uuid",
57
+ "description": "Required when party_subject_type is user"
58
+ },
59
+ "domain_id": {
60
+ "type": ["string", "null"],
61
+ "format": "uuid",
62
+ "description": "Required when party_subject_type is domain"
63
+ },
64
+ "party_organization_id": {
65
+ "type": ["string", "null"],
66
+ "format": "uuid",
67
+ "description": "Required when party_subject_type is organization"
68
+ },
69
+ "external_party_label": {
70
+ "type": ["string", "null"],
71
+ "maxLength": 255,
72
+ "description": "Required when party_subject_type is external"
73
+ },
74
+ "access_method": {
75
+ "type": "string",
76
+ "enum": [
77
+ "sql",
78
+ "api_endpoint",
79
+ "event_stream",
80
+ "webhook",
81
+ "export",
82
+ "bi_connect"
83
+ ],
84
+ "description": "Access dialect / delivery method this grant authorizes"
85
+ },
86
+ "connection_id": {
87
+ "type": ["string", "null"],
88
+ "format": "uuid",
89
+ "description": "Destination Target connection id (S3-authoritative). Deploy looks up the grant by data_product_id + connection_id."
90
+ },
91
+ "credential_id": {
92
+ "type": ["string", "null"],
93
+ "format": "uuid",
94
+ "description": "Optional already-issued api_credentials row bound to this grant"
95
+ },
96
+ "destination_config": {
97
+ "type": "object",
98
+ "additionalProperties": true,
99
+ "default": {},
100
+ "description": "Per-consumer destination settings"
101
+ },
102
+ "status": {
103
+ "type": "string",
104
+ "enum": ["active", "paused", "revoked"],
105
+ "default": "active",
106
+ "description": "Runtime grant status. revoked soft-deletes the subscriber row on materialize."
107
+ },
108
+ "linked_contract_party_id": {
109
+ "type": ["string", "null"],
110
+ "format": "uuid",
111
+ "description": "Optional link to a data_contract_parties row"
112
+ },
113
+ "metadata": {
114
+ "type": "object",
115
+ "additionalProperties": true,
116
+ "default": {},
117
+ "description": "Additional declaration metadata"
118
+ },
119
+ "created_by": {
120
+ "type": ["string", "null"],
121
+ "format": "uuid",
122
+ "description": "User who created the declaration"
123
+ },
124
+ "updated_by": {
125
+ "type": ["string", "null"],
126
+ "format": "uuid",
127
+ "description": "User who last updated the declaration"
128
+ },
129
+ "created_at": {
130
+ "type": "string",
131
+ "format": "date-time",
132
+ "description": "ISO 8601 creation timestamp"
133
+ },
134
+ "updated_at": {
135
+ "type": "string",
136
+ "format": "date-time",
137
+ "description": "ISO 8601 last update timestamp"
138
+ },
139
+ "deleted_at": {
140
+ "type": ["string", "null"],
141
+ "format": "date-time",
142
+ "description": "Soft-delete timestamp on the declaration (optional)"
143
+ }
144
+ },
145
+ "additionalProperties": false
146
+ }
@@ -149,6 +149,25 @@
149
149
  "maximum": 10000,
150
150
  "description": "Runtime tuning: events per handler call (rstreams offload batch). Does not cap events read per run; that is bounded by the Lambda timeout and memory thresholds. Unset: 300. Out-of-range values fail deploy."
151
151
  },
152
+ "runtime_settings": {
153
+ "type": ["object", "null"],
154
+ "description": "Native runtime tuning. Event writes use the default durable mode unless explicitly changed.",
155
+ "properties": {
156
+ "event_writer": {
157
+ "type": ["object", "null"],
158
+ "properties": {
159
+ "transport_mode": {
160
+ "type": "string",
161
+ "enum": ["default", "fast", "volume"],
162
+ "default": "default",
163
+ "description": "Event write transport for transformation outputs and errors: default is durable and balanced (recommended); fast has the lowest latency but may cost more; volume is optimized for high throughput and introduces delivery lag."
164
+ }
165
+ },
166
+ "additionalProperties": false
167
+ }
168
+ },
169
+ "additionalProperties": false
170
+ },
152
171
  "runtime_memory_mb": {
153
172
  "description": "Runtime tuning: shared runtimes Lambda memory tier (transformers-{mb}). Unset: derived from transform_type (256/512/1024). Any other value fails deploy.",
154
173
  "oneOf": [