@contractspec/example.service-business-os 0.0.0-canary-20260113162409
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/LICENSE +21 -0
- package/README.md +16 -0
- package/dist/client/client.operations.d.ts +65 -0
- package/dist/client/client.operations.d.ts.map +1 -0
- package/dist/client/client.operations.js +53 -0
- package/dist/client/client.operations.js.map +1 -0
- package/dist/client/client.schema.d.ts +68 -0
- package/dist/client/client.schema.d.ts.map +1 -0
- package/dist/client/client.schema.js +77 -0
- package/dist/client/client.schema.js.map +1 -0
- package/dist/client/index.d.ts +3 -0
- package/dist/client/index.js +4 -0
- package/dist/docs/index.d.ts +1 -0
- package/dist/docs/index.js +1 -0
- package/dist/docs/service-business-os.docblock.d.ts +1 -0
- package/dist/docs/service-business-os.docblock.js +109 -0
- package/dist/docs/service-business-os.docblock.js.map +1 -0
- package/dist/entities/index.d.ts +168 -0
- package/dist/entities/index.d.ts.map +1 -0
- package/dist/entities/index.js +289 -0
- package/dist/entities/index.js.map +1 -0
- package/dist/events.d.ts +337 -0
- package/dist/events.d.ts.map +1 -0
- package/dist/events.js +230 -0
- package/dist/events.js.map +1 -0
- package/dist/example.d.ts +7 -0
- package/dist/example.d.ts.map +1 -0
- package/dist/example.js +53 -0
- package/dist/example.js.map +1 -0
- package/dist/handlers/index.d.ts +17 -0
- package/dist/handlers/index.d.ts.map +1 -0
- package/dist/handlers/index.js +6 -0
- package/dist/handlers/index.js.map +1 -0
- package/dist/index.d.ts +18 -0
- package/dist/index.js +19 -0
- package/dist/invoice/index.d.ts +3 -0
- package/dist/invoice/index.js +4 -0
- package/dist/invoice/invoice.operations.d.ts +65 -0
- package/dist/invoice/invoice.operations.d.ts.map +1 -0
- package/dist/invoice/invoice.operations.js +57 -0
- package/dist/invoice/invoice.operations.js.map +1 -0
- package/dist/invoice/invoice.schema.d.ts +68 -0
- package/dist/invoice/invoice.schema.d.ts.map +1 -0
- package/dist/invoice/invoice.schema.js +77 -0
- package/dist/invoice/invoice.schema.js.map +1 -0
- package/dist/job/index.d.ts +3 -0
- package/dist/job/index.js +4 -0
- package/dist/job/job.operations.d.ts +238 -0
- package/dist/job/job.operations.d.ts.map +1 -0
- package/dist/job/job.operations.js +175 -0
- package/dist/job/job.operations.js.map +1 -0
- package/dist/job/job.schema.d.ts +85 -0
- package/dist/job/job.schema.d.ts.map +1 -0
- package/dist/job/job.schema.js +98 -0
- package/dist/job/job.schema.js.map +1 -0
- package/dist/operations/index.d.ts +16 -0
- package/dist/operations/index.js +17 -0
- package/dist/payment/index.d.ts +3 -0
- package/dist/payment/index.js +4 -0
- package/dist/payment/payment.operations.d.ts +61 -0
- package/dist/payment/payment.operations.d.ts.map +1 -0
- package/dist/payment/payment.operations.js +53 -0
- package/dist/payment/payment.operations.js.map +1 -0
- package/dist/payment/payment.schema.d.ts +64 -0
- package/dist/payment/payment.schema.d.ts.map +1 -0
- package/dist/payment/payment.schema.js +73 -0
- package/dist/payment/payment.schema.js.map +1 -0
- package/dist/presentations/index.d.ts +9 -0
- package/dist/presentations/index.d.ts.map +1 -0
- package/dist/presentations/index.js +18 -0
- package/dist/presentations/index.js.map +1 -0
- package/dist/presentations.d.ts +13 -0
- package/dist/presentations.d.ts.map +1 -0
- package/dist/presentations.js +179 -0
- package/dist/presentations.js.map +1 -0
- package/dist/quote/index.d.ts +3 -0
- package/dist/quote/index.js +4 -0
- package/dist/quote/quote.operations.d.ts +135 -0
- package/dist/quote/quote.operations.d.ts.map +1 -0
- package/dist/quote/quote.operations.js +99 -0
- package/dist/quote/quote.operations.js.map +1 -0
- package/dist/quote/quote.schema.d.ts +101 -0
- package/dist/quote/quote.schema.d.ts.map +1 -0
- package/dist/quote/quote.schema.js +114 -0
- package/dist/quote/quote.schema.js.map +1 -0
- package/dist/service-business-os.capability.d.ts +8 -0
- package/dist/service-business-os.capability.d.ts.map +1 -0
- package/dist/service-business-os.capability.js +29 -0
- package/dist/service-business-os.capability.js.map +1 -0
- package/dist/service.feature.d.ts +7 -0
- package/dist/service.feature.d.ts.map +1 -0
- package/dist/service.feature.js +166 -0
- package/dist/service.feature.js.map +1 -0
- package/package.json +100 -0
|
@@ -0,0 +1,166 @@
|
|
|
1
|
+
import { defineFeature } from "@contractspec/lib.contracts";
|
|
2
|
+
|
|
3
|
+
//#region src/service.feature.ts
|
|
4
|
+
const ServiceBusinessFeature = defineFeature({
|
|
5
|
+
meta: {
|
|
6
|
+
key: "service-business-os",
|
|
7
|
+
title: "Service Business OS",
|
|
8
|
+
description: "Quotes → jobs → invoices → payments for field services and agencies.",
|
|
9
|
+
domain: "services",
|
|
10
|
+
owners: ["@service-os"],
|
|
11
|
+
tags: [
|
|
12
|
+
"services",
|
|
13
|
+
"quotes",
|
|
14
|
+
"jobs",
|
|
15
|
+
"invoices",
|
|
16
|
+
"payments"
|
|
17
|
+
],
|
|
18
|
+
stability: "experimental",
|
|
19
|
+
version: "1.0.0"
|
|
20
|
+
},
|
|
21
|
+
operations: [
|
|
22
|
+
{
|
|
23
|
+
key: "service.client.create",
|
|
24
|
+
version: "1.0.0"
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
key: "service.quote.create",
|
|
28
|
+
version: "1.0.0"
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
key: "service.quote.accept",
|
|
32
|
+
version: "1.0.0"
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
key: "service.job.schedule",
|
|
36
|
+
version: "1.0.0"
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
key: "service.job.complete",
|
|
40
|
+
version: "1.0.0"
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
key: "service.invoice.issue",
|
|
44
|
+
version: "1.0.0"
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
key: "service.payment.record",
|
|
48
|
+
version: "1.0.0"
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
key: "service.job.list",
|
|
52
|
+
version: "1.0.0"
|
|
53
|
+
}
|
|
54
|
+
],
|
|
55
|
+
events: [
|
|
56
|
+
{
|
|
57
|
+
key: "service.quote.sent",
|
|
58
|
+
version: "1.0.0"
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
key: "service.quote.accepted",
|
|
62
|
+
version: "1.0.0"
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
key: "service.job.scheduled",
|
|
66
|
+
version: "1.0.0"
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
key: "service.job.completed",
|
|
70
|
+
version: "1.0.0"
|
|
71
|
+
},
|
|
72
|
+
{
|
|
73
|
+
key: "service.invoice.issued",
|
|
74
|
+
version: "1.0.0"
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
key: "service.payment.received",
|
|
78
|
+
version: "1.0.0"
|
|
79
|
+
}
|
|
80
|
+
],
|
|
81
|
+
presentations: [
|
|
82
|
+
{
|
|
83
|
+
key: "service-business-os.dashboard",
|
|
84
|
+
version: "1.0.0"
|
|
85
|
+
},
|
|
86
|
+
{
|
|
87
|
+
key: "service-business-os.client.list",
|
|
88
|
+
version: "1.0.0"
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
key: "service-business-os.quote.list",
|
|
92
|
+
version: "1.0.0"
|
|
93
|
+
},
|
|
94
|
+
{
|
|
95
|
+
key: "service-business-os.quote.detail",
|
|
96
|
+
version: "1.0.0"
|
|
97
|
+
},
|
|
98
|
+
{
|
|
99
|
+
key: "service-business-os.job.board",
|
|
100
|
+
version: "1.0.0"
|
|
101
|
+
},
|
|
102
|
+
{
|
|
103
|
+
key: "service-business-os.invoice.list",
|
|
104
|
+
version: "1.0.0"
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
key: "service-business-os.payment.list",
|
|
108
|
+
version: "1.0.0"
|
|
109
|
+
}
|
|
110
|
+
],
|
|
111
|
+
presentationsTargets: [
|
|
112
|
+
{
|
|
113
|
+
key: "service-business-os.dashboard",
|
|
114
|
+
version: "1.0.0",
|
|
115
|
+
targets: ["react", "markdown"]
|
|
116
|
+
},
|
|
117
|
+
{
|
|
118
|
+
key: "service-business-os.quote.list",
|
|
119
|
+
version: "1.0.0",
|
|
120
|
+
targets: ["react", "markdown"]
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
key: "service-business-os.invoice.list",
|
|
124
|
+
version: "1.0.0",
|
|
125
|
+
targets: ["react", "markdown"]
|
|
126
|
+
}
|
|
127
|
+
],
|
|
128
|
+
capabilities: {
|
|
129
|
+
requires: [
|
|
130
|
+
{
|
|
131
|
+
key: "identity",
|
|
132
|
+
version: "1.0.0"
|
|
133
|
+
},
|
|
134
|
+
{
|
|
135
|
+
key: "audit-trail",
|
|
136
|
+
version: "1.0.0"
|
|
137
|
+
},
|
|
138
|
+
{
|
|
139
|
+
key: "notifications",
|
|
140
|
+
version: "1.0.0"
|
|
141
|
+
},
|
|
142
|
+
{
|
|
143
|
+
key: "files",
|
|
144
|
+
version: "1.0.0"
|
|
145
|
+
}
|
|
146
|
+
],
|
|
147
|
+
provides: [
|
|
148
|
+
{
|
|
149
|
+
key: "quotes",
|
|
150
|
+
version: "1.0.0"
|
|
151
|
+
},
|
|
152
|
+
{
|
|
153
|
+
key: "jobs",
|
|
154
|
+
version: "1.0.0"
|
|
155
|
+
},
|
|
156
|
+
{
|
|
157
|
+
key: "invoices",
|
|
158
|
+
version: "1.0.0"
|
|
159
|
+
}
|
|
160
|
+
]
|
|
161
|
+
}
|
|
162
|
+
});
|
|
163
|
+
|
|
164
|
+
//#endregion
|
|
165
|
+
export { ServiceBusinessFeature };
|
|
166
|
+
//# sourceMappingURL=service.feature.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"service.feature.js","names":[],"sources":["../src/service.feature.ts"],"sourcesContent":["import { defineFeature } from '@contractspec/lib.contracts';\n\nexport const ServiceBusinessFeature = defineFeature({\n meta: {\n key: 'service-business-os',\n title: 'Service Business OS',\n description:\n 'Quotes → jobs → invoices → payments for field services and agencies.',\n domain: 'services',\n owners: ['@service-os'],\n tags: ['services', 'quotes', 'jobs', 'invoices', 'payments'],\n stability: 'experimental',\n version: '1.0.0',\n },\n operations: [\n { key: 'service.client.create', version: '1.0.0' },\n { key: 'service.quote.create', version: '1.0.0' },\n { key: 'service.quote.accept', version: '1.0.0' },\n { key: 'service.job.schedule', version: '1.0.0' },\n { key: 'service.job.complete', version: '1.0.0' },\n { key: 'service.invoice.issue', version: '1.0.0' },\n { key: 'service.payment.record', version: '1.0.0' },\n { key: 'service.job.list', version: '1.0.0' },\n ],\n events: [\n { key: 'service.quote.sent', version: '1.0.0' },\n { key: 'service.quote.accepted', version: '1.0.0' },\n { key: 'service.job.scheduled', version: '1.0.0' },\n { key: 'service.job.completed', version: '1.0.0' },\n { key: 'service.invoice.issued', version: '1.0.0' },\n { key: 'service.payment.received', version: '1.0.0' },\n ],\n presentations: [\n { key: 'service-business-os.dashboard', version: '1.0.0' },\n { key: 'service-business-os.client.list', version: '1.0.0' },\n { key: 'service-business-os.quote.list', version: '1.0.0' },\n { key: 'service-business-os.quote.detail', version: '1.0.0' },\n { key: 'service-business-os.job.board', version: '1.0.0' },\n { key: 'service-business-os.invoice.list', version: '1.0.0' },\n { key: 'service-business-os.payment.list', version: '1.0.0' },\n ],\n presentationsTargets: [\n {\n key: 'service-business-os.dashboard',\n version: '1.0.0',\n targets: ['react', 'markdown'],\n },\n {\n key: 'service-business-os.quote.list',\n version: '1.0.0',\n targets: ['react', 'markdown'],\n },\n {\n key: 'service-business-os.invoice.list',\n version: '1.0.0',\n targets: ['react', 'markdown'],\n },\n ],\n capabilities: {\n requires: [\n { key: 'identity', version: '1.0.0' },\n { key: 'audit-trail', version: '1.0.0' },\n { key: 'notifications', version: '1.0.0' },\n { key: 'files', version: '1.0.0' },\n ],\n provides: [\n { key: 'quotes', version: '1.0.0' },\n { key: 'jobs', version: '1.0.0' },\n { key: 'invoices', version: '1.0.0' },\n ],\n },\n});\n"],"mappings":";;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ACF;CACD,cAAc;EACZ,UAAU;GACR;IAAE,KAAK;IAAY,SAAS;IAAS;GACrC;IAAE,KAAK;IAAe,SAAS;IAAS;GACxC;IAAE,KAAK;IAAiB,SAAS;IAAS;GAC1C;IAAE,KAAK;IAAS,SAAS;IAAS;GACnC;EACD,UAAU;GACR;IAAE,KAAK;IAAU,SAAS;IAAS;GACnC;IAAE,KAAK;IAAQ,SAAS;IAAS;GACjC;IAAE,KAAK;IAAY,SAAS;IAAS;GACtC;EACF;CACF,CAAC"}
|
package/package.json
ADDED
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@contractspec/example.service-business-os",
|
|
3
|
+
"version": "0.0.0-canary-20260113162409",
|
|
4
|
+
"description": "Service Business OS example (clients, quotes, jobs, invoices) for ContractSpec",
|
|
5
|
+
"types": "./dist/index.d.ts",
|
|
6
|
+
"type": "module",
|
|
7
|
+
"scripts": {
|
|
8
|
+
"publish:pkg": "bun publish --tolerate-republish --ignore-scripts --verbose",
|
|
9
|
+
"publish:pkg:canary": "bun publish:pkg --tag canary",
|
|
10
|
+
"build": "bun build:types && bun build:bundle",
|
|
11
|
+
"build:bundle": "tsdown",
|
|
12
|
+
"build:types": "tsc --noEmit",
|
|
13
|
+
"dev": "bun build:bundle --watch",
|
|
14
|
+
"clean": "rimraf dist .turbo",
|
|
15
|
+
"lint": "bun lint:fix",
|
|
16
|
+
"lint:fix": "eslint src --fix",
|
|
17
|
+
"lint:check": "eslint src"
|
|
18
|
+
},
|
|
19
|
+
"dependencies": {
|
|
20
|
+
"@contractspec/lib.schema": "0.0.0-canary-20260113162409",
|
|
21
|
+
"@contractspec/lib.contracts": "0.0.0-canary-20260113162409"
|
|
22
|
+
},
|
|
23
|
+
"devDependencies": {
|
|
24
|
+
"@contractspec/tool.typescript": "0.0.0-canary-20260113162409",
|
|
25
|
+
"@contractspec/tool.tsdown": "0.0.0-canary-20260113162409",
|
|
26
|
+
"typescript": "^5.9.3"
|
|
27
|
+
},
|
|
28
|
+
"exports": {
|
|
29
|
+
".": "./dist/index.js",
|
|
30
|
+
"./client": "./dist/client/index.js",
|
|
31
|
+
"./client/client.operations": "./dist/client/client.operations.js",
|
|
32
|
+
"./client/client.schema": "./dist/client/client.schema.js",
|
|
33
|
+
"./docs": "./dist/docs/index.js",
|
|
34
|
+
"./docs/service-business-os.docblock": "./dist/docs/service-business-os.docblock.js",
|
|
35
|
+
"./entities": "./dist/entities/index.js",
|
|
36
|
+
"./events": "./dist/events.js",
|
|
37
|
+
"./example": "./dist/example.js",
|
|
38
|
+
"./handlers": "./dist/handlers/index.js",
|
|
39
|
+
"./invoice": "./dist/invoice/index.js",
|
|
40
|
+
"./invoice/invoice.operations": "./dist/invoice/invoice.operations.js",
|
|
41
|
+
"./invoice/invoice.schema": "./dist/invoice/invoice.schema.js",
|
|
42
|
+
"./job": "./dist/job/index.js",
|
|
43
|
+
"./job/job.operations": "./dist/job/job.operations.js",
|
|
44
|
+
"./job/job.schema": "./dist/job/job.schema.js",
|
|
45
|
+
"./operations": "./dist/operations/index.js",
|
|
46
|
+
"./payment": "./dist/payment/index.js",
|
|
47
|
+
"./payment/payment.operations": "./dist/payment/payment.operations.js",
|
|
48
|
+
"./payment/payment.schema": "./dist/payment/payment.schema.js",
|
|
49
|
+
"./presentations": "./dist/presentations/index.js",
|
|
50
|
+
"./quote": "./dist/quote/index.js",
|
|
51
|
+
"./quote/quote.operations": "./dist/quote/quote.operations.js",
|
|
52
|
+
"./quote/quote.schema": "./dist/quote/quote.schema.js",
|
|
53
|
+
"./service-business-os.capability": "./dist/service-business-os.capability.js",
|
|
54
|
+
"./service.feature": "./dist/service.feature.js",
|
|
55
|
+
"./*": "./*"
|
|
56
|
+
},
|
|
57
|
+
"files": [
|
|
58
|
+
"dist",
|
|
59
|
+
"README.md"
|
|
60
|
+
],
|
|
61
|
+
"publishConfig": {
|
|
62
|
+
"access": "public",
|
|
63
|
+
"exports": {
|
|
64
|
+
".": "./dist/index.js",
|
|
65
|
+
"./client": "./dist/client/index.js",
|
|
66
|
+
"./client/client.contracts": "./dist/client/client.operations.js",
|
|
67
|
+
"./client/client.schema": "./dist/client/client.schema.js",
|
|
68
|
+
"./contracts": "./dist/contracts/index.js",
|
|
69
|
+
"./docs": "./dist/docs/index.js",
|
|
70
|
+
"./docs/service-business-os.docblock": "./dist/docs/service-business-os.docblock.js",
|
|
71
|
+
"./entities": "./dist/entities/index.js",
|
|
72
|
+
"./events": "./dist/events.js",
|
|
73
|
+
"./example": "./dist/example.js",
|
|
74
|
+
"./handlers": "./dist/handlers/index.js",
|
|
75
|
+
"./invoice": "./dist/invoice/index.js",
|
|
76
|
+
"./invoice/invoice.contracts": "./dist/invoice/invoice.operations.js",
|
|
77
|
+
"./invoice/invoice.schema": "./dist/invoice/invoice.schema.js",
|
|
78
|
+
"./job": "./dist/job/index.js",
|
|
79
|
+
"./job/job.contracts": "./dist/job/job.operations.js",
|
|
80
|
+
"./job/job.schema": "./dist/job/job.schema.js",
|
|
81
|
+
"./payment": "./dist/payment/index.js",
|
|
82
|
+
"./payment/payment.contracts": "./dist/payment/payment.operations.js",
|
|
83
|
+
"./payment/payment.schema": "./dist/payment/payment.schema.js",
|
|
84
|
+
"./presentations": "./dist/presentations/index.js",
|
|
85
|
+
"./quote": "./dist/quote/index.js",
|
|
86
|
+
"./quote/quote.contracts": "./dist/quote/quote.operations.js",
|
|
87
|
+
"./quote/quote.schema": "./dist/quote/quote.schema.js",
|
|
88
|
+
"./service.feature": "./dist/service.feature.js",
|
|
89
|
+
"./*": "./*"
|
|
90
|
+
},
|
|
91
|
+
"registry": "https://registry.npmjs.org/"
|
|
92
|
+
},
|
|
93
|
+
"license": "MIT",
|
|
94
|
+
"repository": {
|
|
95
|
+
"type": "git",
|
|
96
|
+
"url": "https://github.com/lssm-tech/contractspec.git",
|
|
97
|
+
"directory": "packages/examples/service-business-os"
|
|
98
|
+
},
|
|
99
|
+
"homepage": "https://contractspec.io"
|
|
100
|
+
}
|