@openplanr/protocol 0.11.0 → 0.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.
@@ -0,0 +1,169 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://openplanr.dev/schemas/v1.19.0/enterprise-project-lifecycle.schema.json",
4
+ "x-openplanr-contract": {
5
+ "id": "enterprise-project-lifecycle",
6
+ "version": "1.19.0"
7
+ },
8
+ "type": "object",
9
+ "additionalProperties": false,
10
+ "properties": {
11
+ "kind": {
12
+ "const": "openplanr-enterprise-project-lifecycle"
13
+ },
14
+ "schemaVersion": {
15
+ "const": "1.0.0"
16
+ },
17
+ "protocolVersion": {
18
+ "const": "1.19.0"
19
+ },
20
+ "organizationId": {
21
+ "type": "string",
22
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}(?![\\s\\S])"
23
+ },
24
+ "projectId": {
25
+ "type": "string",
26
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}(?![\\s\\S])"
27
+ },
28
+ "status": {
29
+ "enum": [
30
+ "active",
31
+ "archiving",
32
+ "archived",
33
+ "restoring"
34
+ ]
35
+ },
36
+ "version": {
37
+ "type": "integer",
38
+ "minimum": 0,
39
+ "maximum": 9007199254740991
40
+ },
41
+ "epoch": {
42
+ "type": "integer",
43
+ "minimum": 1,
44
+ "maximum": 9007199254740991
45
+ },
46
+ "updatedAt": {
47
+ "type": "string",
48
+ "format": "date-time",
49
+ "maxLength": 40,
50
+ "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d{3})?Z(?![\\s\\S])"
51
+ },
52
+ "operation": {
53
+ "type": "object",
54
+ "additionalProperties": false,
55
+ "properties": {
56
+ "operationId": {
57
+ "type": "string",
58
+ "pattern": "^[A-Za-z0-9_-]{22,64}(?![\\s\\S])"
59
+ },
60
+ "action": {
61
+ "enum": [
62
+ "archive",
63
+ "restore"
64
+ ]
65
+ },
66
+ "expectedVersion": {
67
+ "type": "integer",
68
+ "minimum": 0,
69
+ "maximum": 9007199254740991
70
+ },
71
+ "previousEpoch": {
72
+ "type": "integer",
73
+ "minimum": 1,
74
+ "maximum": 9007199254740991
75
+ },
76
+ "inventoryDigest": {
77
+ "type": "string",
78
+ "pattern": "^sha256:[a-f0-9]{64}(?![\\s\\S])"
79
+ },
80
+ "artifactCount": {
81
+ "type": "integer",
82
+ "minimum": 0,
83
+ "maximum": 9007199254740991
84
+ },
85
+ "acknowledgedCount": {
86
+ "type": "integer",
87
+ "minimum": 0,
88
+ "maximum": 9007199254740991
89
+ },
90
+ "acknowledgedInventoryDigest": {
91
+ "oneOf": [
92
+ {
93
+ "type": "string",
94
+ "pattern": "^sha256:[a-f0-9]{64}(?![\\s\\S])"
95
+ },
96
+ {
97
+ "type": "null"
98
+ }
99
+ ]
100
+ }
101
+ },
102
+ "required": [
103
+ "operationId",
104
+ "action",
105
+ "expectedVersion",
106
+ "previousEpoch",
107
+ "inventoryDigest",
108
+ "artifactCount",
109
+ "acknowledgedCount",
110
+ "acknowledgedInventoryDigest"
111
+ ]
112
+ },
113
+ "receipt": {
114
+ "type": "object",
115
+ "additionalProperties": false,
116
+ "properties": {
117
+ "receiptId": {
118
+ "type": "string",
119
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}(?![\\s\\S])"
120
+ },
121
+ "operationId": {
122
+ "type": "string",
123
+ "pattern": "^[A-Za-z0-9_-]{22,64}(?![\\s\\S])"
124
+ },
125
+ "action": {
126
+ "enum": [
127
+ "archive",
128
+ "restore"
129
+ ]
130
+ },
131
+ "version": {
132
+ "type": "integer",
133
+ "minimum": 0,
134
+ "maximum": 9007199254740991
135
+ },
136
+ "epoch": {
137
+ "type": "integer",
138
+ "minimum": 1,
139
+ "maximum": 9007199254740991
140
+ },
141
+ "completedAt": {
142
+ "type": "string",
143
+ "format": "date-time",
144
+ "maxLength": 40,
145
+ "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d{3})?Z(?![\\s\\S])"
146
+ }
147
+ },
148
+ "required": [
149
+ "receiptId",
150
+ "operationId",
151
+ "action",
152
+ "version",
153
+ "epoch",
154
+ "completedAt"
155
+ ]
156
+ }
157
+ },
158
+ "required": [
159
+ "kind",
160
+ "schemaVersion",
161
+ "protocolVersion",
162
+ "organizationId",
163
+ "projectId",
164
+ "status",
165
+ "version",
166
+ "epoch",
167
+ "updatedAt"
168
+ ]
169
+ }
@@ -0,0 +1,164 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://openplanr.dev/schemas/v1.19.0/enterprise-project-page.schema.json",
4
+ "x-openplanr-contract": {
5
+ "id": "enterprise-project-page",
6
+ "version": "1.19.0"
7
+ },
8
+ "type": "object",
9
+ "additionalProperties": false,
10
+ "properties": {
11
+ "kind": {
12
+ "const": "openplanr-enterprise-project-page"
13
+ },
14
+ "schemaVersion": {
15
+ "const": "1.0.0"
16
+ },
17
+ "protocolVersion": {
18
+ "const": "1.19.0"
19
+ },
20
+ "query": {
21
+ "type": "object",
22
+ "additionalProperties": false,
23
+ "properties": {
24
+ "organizationId": {
25
+ "type": "string",
26
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}(?![\\s\\S])"
27
+ },
28
+ "actorId": {
29
+ "type": "string",
30
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}(?![\\s\\S])"
31
+ },
32
+ "scope": {
33
+ "const": "projects"
34
+ },
35
+ "filter": {
36
+ "type": "object",
37
+ "additionalProperties": false,
38
+ "properties": {
39
+ "status": {
40
+ "enum": [
41
+ "all",
42
+ "active",
43
+ "archived"
44
+ ]
45
+ },
46
+ "search": {
47
+ "type": "string",
48
+ "maxLength": 240
49
+ }
50
+ },
51
+ "required": [
52
+ "status",
53
+ "search"
54
+ ]
55
+ }
56
+ },
57
+ "required": [
58
+ "organizationId",
59
+ "actorId",
60
+ "scope",
61
+ "filter"
62
+ ]
63
+ },
64
+ "items": {
65
+ "type": "array",
66
+ "items": {
67
+ "type": "object",
68
+ "additionalProperties": false,
69
+ "properties": {
70
+ "organizationId": {
71
+ "type": "string",
72
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}(?![\\s\\S])"
73
+ },
74
+ "projectId": {
75
+ "type": "string",
76
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}(?![\\s\\S])"
77
+ },
78
+ "slug": {
79
+ "type": "string",
80
+ "pattern": "^[A-Za-z0-9_-]{1,150}(?![\\s\\S])"
81
+ },
82
+ "name": {
83
+ "type": "string",
84
+ "minLength": 1,
85
+ "maxLength": 240
86
+ },
87
+ "status": {
88
+ "enum": [
89
+ "active",
90
+ "archiving",
91
+ "archived",
92
+ "restoring"
93
+ ]
94
+ },
95
+ "capabilities": {
96
+ "type": "array",
97
+ "items": {
98
+ "enum": [
99
+ "organization.manage",
100
+ "ownership.transfer",
101
+ "billing.manage",
102
+ "audit.read",
103
+ "project.create",
104
+ "project.manage",
105
+ "artifact.read",
106
+ "artifact.author",
107
+ "artifact.export",
108
+ "review.write",
109
+ "review.resolve"
110
+ ]
111
+ },
112
+ "maxItems": 11,
113
+ "minItems": 0,
114
+ "uniqueItems": true
115
+ }
116
+ },
117
+ "required": [
118
+ "organizationId",
119
+ "projectId",
120
+ "slug",
121
+ "name",
122
+ "status",
123
+ "capabilities"
124
+ ]
125
+ },
126
+ "maxItems": 100,
127
+ "minItems": 0
128
+ },
129
+ "nextCursor": {
130
+ "oneOf": [
131
+ {
132
+ "type": "object",
133
+ "additionalProperties": false,
134
+ "properties": {
135
+ "token": {
136
+ "type": "string",
137
+ "minLength": 1,
138
+ "maxLength": 2048
139
+ },
140
+ "queryDigest": {
141
+ "type": "string",
142
+ "pattern": "^[a-f0-9]{64}(?![\\s\\S])"
143
+ }
144
+ },
145
+ "required": [
146
+ "token",
147
+ "queryDigest"
148
+ ]
149
+ },
150
+ {
151
+ "type": "null"
152
+ }
153
+ ]
154
+ }
155
+ },
156
+ "required": [
157
+ "kind",
158
+ "schemaVersion",
159
+ "protocolVersion",
160
+ "query",
161
+ "items",
162
+ "nextCursor"
163
+ ]
164
+ }
@@ -0,0 +1,65 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://openplanr.dev/schemas/v1.19.0/enterprise-project-transition.schema.json",
4
+ "x-openplanr-contract": {
5
+ "id": "enterprise-project-transition",
6
+ "version": "1.19.0"
7
+ },
8
+ "type": "object",
9
+ "additionalProperties": false,
10
+ "properties": {
11
+ "kind": {
12
+ "const": "openplanr-enterprise-project-transition"
13
+ },
14
+ "schemaVersion": {
15
+ "const": "1.0.0"
16
+ },
17
+ "protocolVersion": {
18
+ "const": "1.19.0"
19
+ },
20
+ "organizationId": {
21
+ "type": "string",
22
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}(?![\\s\\S])"
23
+ },
24
+ "projectId": {
25
+ "type": "string",
26
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}(?![\\s\\S])"
27
+ },
28
+ "operationId": {
29
+ "type": "string",
30
+ "pattern": "^[A-Za-z0-9_-]{22,64}(?![\\s\\S])"
31
+ },
32
+ "actorId": {
33
+ "type": "string",
34
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}(?![\\s\\S])"
35
+ },
36
+ "action": {
37
+ "enum": [
38
+ "archive",
39
+ "restore"
40
+ ]
41
+ },
42
+ "expectedVersion": {
43
+ "type": "integer",
44
+ "minimum": 0,
45
+ "maximum": 9007199254740991
46
+ },
47
+ "expectedEpoch": {
48
+ "type": "integer",
49
+ "minimum": 1,
50
+ "maximum": 9007199254740991
51
+ }
52
+ },
53
+ "required": [
54
+ "kind",
55
+ "schemaVersion",
56
+ "protocolVersion",
57
+ "organizationId",
58
+ "projectId",
59
+ "operationId",
60
+ "actorId",
61
+ "action",
62
+ "expectedVersion",
63
+ "expectedEpoch"
64
+ ]
65
+ }
@@ -0,0 +1,178 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://openplanr.dev/schemas/v1.19.0/enterprise-review-mention.schema.json",
4
+ "x-openplanr-contract": {
5
+ "id": "enterprise-review-mention",
6
+ "version": "1.19.0"
7
+ },
8
+ "type": "object",
9
+ "additionalProperties": false,
10
+ "properties": {
11
+ "kind": {
12
+ "const": "openplanr-enterprise-review-mention"
13
+ },
14
+ "schemaVersion": {
15
+ "const": "1.0.0"
16
+ },
17
+ "protocolVersion": {
18
+ "const": "1.19.0"
19
+ },
20
+ "organizationId": {
21
+ "type": "string",
22
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}(?![\\s\\S])"
23
+ },
24
+ "projectId": {
25
+ "type": "string",
26
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}(?![\\s\\S])"
27
+ },
28
+ "artifactId": {
29
+ "type": "string",
30
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}(?![\\s\\S])"
31
+ },
32
+ "operationId": {
33
+ "type": "string",
34
+ "pattern": "^[A-Za-z0-9_-]{22,64}(?![\\s\\S])"
35
+ },
36
+ "actorId": {
37
+ "type": "string",
38
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}(?![\\s\\S])"
39
+ },
40
+ "threadId": {
41
+ "type": "string",
42
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}(?![\\s\\S])"
43
+ },
44
+ "anchor": {
45
+ "type": "object",
46
+ "additionalProperties": false,
47
+ "properties": {
48
+ "revisionId": {
49
+ "anyOf": [
50
+ {
51
+ "type": "string",
52
+ "pattern": "^[A-Za-z0-9_-]{22,64}$"
53
+ },
54
+ {
55
+ "type": "string",
56
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9_-]{0,127}(?![\\s\\S])"
57
+ }
58
+ ]
59
+ },
60
+ "elementId": {
61
+ "type": "string",
62
+ "minLength": 1,
63
+ "maxLength": 512,
64
+ "pattern": "^[^\\s\\u0000-\\u001f\\u007f]+$"
65
+ },
66
+ "screenId": {
67
+ "type": "string",
68
+ "minLength": 1,
69
+ "maxLength": 512,
70
+ "pattern": "^[^\\s\\u0000-\\u001f\\u007f]+$"
71
+ },
72
+ "frameId": {
73
+ "type": "string",
74
+ "minLength": 1,
75
+ "maxLength": 512,
76
+ "pattern": "^[^\\s\\u0000-\\u001f\\u007f]+$"
77
+ },
78
+ "x": {
79
+ "type": "number",
80
+ "minimum": 0,
81
+ "maximum": 1
82
+ },
83
+ "y": {
84
+ "type": "number",
85
+ "minimum": 0,
86
+ "maximum": 1
87
+ }
88
+ },
89
+ "required": [
90
+ "revisionId"
91
+ ],
92
+ "anyOf": [
93
+ {
94
+ "required": [
95
+ "elementId"
96
+ ]
97
+ },
98
+ {
99
+ "required": [
100
+ "screenId",
101
+ "frameId"
102
+ ]
103
+ },
104
+ {
105
+ "required": [
106
+ "x",
107
+ "y"
108
+ ]
109
+ }
110
+ ],
111
+ "allOf": [
112
+ {
113
+ "if": {
114
+ "required": [
115
+ "x"
116
+ ]
117
+ },
118
+ "then": {
119
+ "required": [
120
+ "y"
121
+ ]
122
+ }
123
+ },
124
+ {
125
+ "if": {
126
+ "required": [
127
+ "y"
128
+ ]
129
+ },
130
+ "then": {
131
+ "required": [
132
+ "x"
133
+ ]
134
+ }
135
+ },
136
+ {
137
+ "if": {
138
+ "required": [
139
+ "frameId"
140
+ ]
141
+ },
142
+ "then": {
143
+ "required": [
144
+ "screenId"
145
+ ]
146
+ }
147
+ }
148
+ ]
149
+ },
150
+ "recipients": {
151
+ "type": "array",
152
+ "items": {
153
+ "type": "string",
154
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}(?![\\s\\S])"
155
+ },
156
+ "maxItems": 50,
157
+ "minItems": 1,
158
+ "uniqueItems": true
159
+ },
160
+ "authority": {
161
+ "const": "notification-only"
162
+ }
163
+ },
164
+ "required": [
165
+ "kind",
166
+ "schemaVersion",
167
+ "protocolVersion",
168
+ "organizationId",
169
+ "projectId",
170
+ "artifactId",
171
+ "operationId",
172
+ "actorId",
173
+ "threadId",
174
+ "anchor",
175
+ "recipients",
176
+ "authority"
177
+ ]
178
+ }