@openengio/cli 0.37.0 → 0.39.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.
- package/README.md +24 -9
- package/bin/public/openeng.js +505 -192
- package/package.json +1 -1
- package/skill/conventions/SKILL.md +5 -4
- package/skill/openeng/SKILL.md +35 -11
package/bin/public/openeng.js
CHANGED
|
@@ -104,6 +104,10 @@ var RULE_ENTRIES = {
|
|
|
104
104
|
"too-many-links": entry("The review chain or aggregate exceeds 100 contributing objects or links.", { option: "Reduce the chain or the contributing links before reading or clearing again." }),
|
|
105
105
|
"unsupported-content": entry("The file's content or name is not an admitted attachment format.", FIX_REQUEST),
|
|
106
106
|
"too-large": entry("The attachment exceeds the per-file byte limit.", FIX_REQUEST),
|
|
107
|
+
"storage-limit-reached": entry("The organisation has no room left for a file of this size.", ASK_ADMINISTRATOR),
|
|
108
|
+
"upload-not-found": entry("No finished upload of yours matches this identifier.", { option: "Open a new upload and send the file again." }),
|
|
109
|
+
"upload-length-mismatch": entry("The stored file is not the length the upload declared.", { option: "Open a new upload and send the whole file again." }),
|
|
110
|
+
"attachment-collision": entry("A different file is already stored under this file's name in the store.", { option: "Open a new upload and send the file again; if it recurs, tell an administrator." }),
|
|
107
111
|
"not-an-attachment-property": entry("The object's stored type version does not declare this property as an attachment.", FIX_REQUEST),
|
|
108
112
|
"no-attachment": entry("The property holds no attachment."),
|
|
109
113
|
"attachment-unavailable": entry("The attachment's stored bytes are unavailable.", { option: "Ask an administrator to restore the attachment." }),
|
|
@@ -434,8 +438,9 @@ var ROUTE_DOCS = Object.freeze({
|
|
|
434
438
|
enterHumanMode: doc("Switches the presenting CLI session to human mode after one web confirmation. Already-human sessions return their current state without another write; web sessions are refused. CLI: openeng session human prints the confirm address, polls and retries once with unchanged bytes and key, then prints the stored state. Human mode lasts for this session; a new CLI sign-in starts in agent mode.", SIGNED_IN),
|
|
435
439
|
readSessionStatus: doc("Reads the presenting person's stored session channel, mode and sign-in time, without organisation attachment. CLI: openeng session status prints { channel, mode, issuedAt } under --json; it never reads a local mode.", SIGNED_IN),
|
|
436
440
|
readStepUpProof: doc("Polls as the requesting person session or run. Only that actor receives a confirmed live proof. Without an eligible confirmation it answers awaiting. No organisation attachment is required.", SIGNED_IN),
|
|
437
|
-
|
|
438
|
-
|
|
441
|
+
openAttachmentUpload: doc("Opens an upload session for a file of a declared length on an existing object after its guard admits the caller on the selected ref. The answer carries the upload identifier and a session address that accepts the bytes with no other credential. Admits person, service, app:client and agent:apply actors.", [...ATTACHMENT_SCOPED, "not-permitted", "frozen", "protected", "unsupported-content", "too-large", "storage-limit-reached"]),
|
|
442
|
+
completeAttachmentUpload: doc("Finishes an upload the caller opened: checks the stored file and stages it for the caller, then answers its descriptor. The object's guard is asked again. A repeated call for the same upload answers the same descriptor. Admits person, service, app:client and agent:apply actors.", [...ATTACHMENT_SCOPED, "not-permitted", "frozen", "protected", "unsupported-content", "upload-not-found", "upload-length-mismatch", "attachment-collision"]),
|
|
443
|
+
readAttachment: doc("Downloads the attachment held by an object's property at its stored type version. A file within the download threshold is streamed in the answer; a larger file is answered with a redirect whose Location is a short-lived link to the stored file. Admits person, service, app:client, agent:explore and agent:apply actors.", [...ATTACHMENT_SCOPED, "organisation-not-ready", "branch-needs-schema-update", "not-an-attachment-property", "no-attachment", "attachment-unavailable"]),
|
|
439
444
|
readObject: doc("Reads one object at a branch or baseline.", REF_READ),
|
|
440
445
|
queryObjects: doc(`Runs a filtered, ordered, paged query over the objects of a branch or baseline, or pages the union, intersection or difference of two plain object-set descriptions on that ref. A top-level type filter {kind:"type",op:"in",values:["part","system"]} selects any of 1 to 100 published type keys and may be combined with a text filter; continuation binds to the entire selection. ${QUERY_PROJECT_SCOPE}`, [
|
|
441
446
|
...REF_READ,
|
|
@@ -451,8 +456,8 @@ var ROUTE_DOCS = Object.freeze({
|
|
|
451
456
|
aggregateObjects: doc(`Deprecated: use queryRows for graph aggregates. Runs an aggregate over the objects of a branch or baseline: a count, or a minimum, maximum, sum or average of one numeric property, answered as one value (an average also carries its count), or, with groupBy, a count, sum or average grouped by type or by a property's value, or a count grouped by structural parent, answered as groups. ${QUERY_PROJECT_SCOPE}`, [...REF_READ, "malformed-query", "over-bound", "text-search-unavailable", "search-too-wide"]),
|
|
452
457
|
discoverVerbs: doc("Lists the verbs an object may be given.", REF_READ),
|
|
453
458
|
readHistory: doc("Reads one object's history of changes.", [...REF_READ, "invalid-continuation", "stale-continuation", "malformed-history-request"]),
|
|
454
|
-
mutate: doc('Creates, changes or deletes an object on the selected writable branch. A protected refusal means the change needs a branch and a merge. For a property update, `from` is the value the caller expects now; a mismatch is refused as `conflict`, and `{"
|
|
455
|
-
mutateBatch: doc('Applies a list of object and edge operations in one save and commit, with one audit record. A batch with no change makes no commit; a refused batch writes no engineering data, but its refusal is audited. An edge may name an object created earlier in the same batch. A batch with more operations than the maximum is refused as invalid-request naming input.operations, before any write. For a property update, `from` is the value the caller expects now; a mismatch is refused as `conflict`, and `{"
|
|
459
|
+
mutate: doc('Creates, changes or deletes an object on the selected writable branch. A protected refusal means the change needs a branch and a merge. For a property update, `from` is the value the caller expects now; a mismatch is refused as `conflict`, and `{"kind": "absent"}` clears the property; a present state is `{"kind": "value", "value": ...}`.', [...OBJECT_WRITE, "plan-closed"]),
|
|
460
|
+
mutateBatch: doc('Applies a list of object and edge operations in one save and commit, with one audit record. A batch with no change makes no commit; a refused batch writes no engineering data, but its refusal is audited. An edge may name an object created earlier in the same batch. A batch with more operations than the maximum is refused as invalid-request naming input.operations, before any write. For a property update, `from` is the value the caller expects now; a mismatch is refused as `conflict`, and `{"kind": "absent"}` clears the property; a present state is `{"kind": "value", "value": ...}`.', [...OBJECT_WRITE, "plan-closed"]),
|
|
456
461
|
createConnection: doc("Creates a connection to an external source system for the signed-in person: its mirror project and its service identity. The connection commits whether or not its types could be drafted, and the answer says which.", [...SIGNED_IN, "not-permitted", "organisation-not-active", "connection-exists"]),
|
|
457
462
|
listConnections: doc("Lists the connections whose mirror project the caller reads, each with its last run and whether the caller may start a run.", SIGNED_IN),
|
|
458
463
|
setConnectionCredential: doc("Stores the credential the connection reads the source system with, after the source system accepts it, and answers the upstream account and the time it was stored. The credential is never answered.", [...SCOPED, "credential-not-valid"]),
|
|
@@ -480,7 +485,7 @@ var ROUTE_DOCS = Object.freeze({
|
|
|
480
485
|
previewDelete: doc("Previews deleting an object: the links the delete would remove, or the refusal it would meet. Changes nothing.", [...OBJECT_WRITE, "plan-closed"]),
|
|
481
486
|
recover: doc("Finds what an interrupted mutation did and finishes its record.", REF_READ),
|
|
482
487
|
executeVerb: doc("Runs a verb on an object and records its result.", [...OBJECT_WRITE, "plan-closed"]),
|
|
483
|
-
createBranch: doc("Creates a project branch from a branch, a baseline or an admitted current head.", [
|
|
488
|
+
createBranch: doc("Creates a project branch from a branch, a baseline or an admitted current head. The optional from is tagged kind ref with ref, or kind hash with hash.", [
|
|
484
489
|
...REF_WRITE,
|
|
485
490
|
"plan-closed",
|
|
486
491
|
"ref-exists",
|
|
@@ -542,7 +547,7 @@ var ROUTE_DOCS = Object.freeze({
|
|
|
542
547
|
releaseDraft: doc("Releases an unchanged draft.", [...REF_WRITE, "ref-not-found", "draft-lock-lost", "draft-changed"]),
|
|
543
548
|
discardDraft: doc("Discards the holder\u2019s draft.", [...REF_WRITE, "ref-not-found", "draft-lock-lost"]),
|
|
544
549
|
breakDraftLock: doc("Breaks a draft lock as a project administrator; person-only objects.draftAdmin capability.", [...REF_WRITE, "ref-not-found"]),
|
|
545
|
-
readDraftLock: doc("
|
|
550
|
+
readDraftLock: doc('Returns { kind: "held", holderDisplayName, expiresAt } for a live lock, or { kind: "free" }.', [...REF_READ, "ref-not-found"]),
|
|
546
551
|
restoreDraft: doc("Restores a saved draft onto a new branch using its saved body; person-only objects.draftAdmin capability.", [...REF_WRITE, "plan-closed", "ref-exists", "read-only-ref", "concurrent-change", "lock-unavailable", "ref-not-found", "frozen", "protected", "not-a-saver", "draft-locked", "draft-changed", "object-not-found", "body-not-declared"]),
|
|
547
552
|
setCommentResolved: doc("Resolves or reopens a comment.", WRITE),
|
|
548
553
|
addComment: doc("Adds a comment to an object, naming the people it mentions and optionally anchoring a quoted block.", [...REF_WRITE, "invalid-body", "invalid-mention", "unknown-person", "invalid-ref", "anchor-invalid"]),
|
|
@@ -641,7 +646,7 @@ var ROUTE_DOCS = Object.freeze({
|
|
|
641
646
|
]),
|
|
642
647
|
readApp: doc("Reads a published version of an app, the latest where none is named, with the app's history of versions.", [...SIGNED_IN, "not-found"]),
|
|
643
648
|
openAppDraft: doc("Opens the one draft of an app, creating the app where the key has none.", [...SIGNED_IN, "not-permitted", "not-found", "invalid-app", "app-draft-open"]),
|
|
644
|
-
readAppDraft: doc("Reads an app draft's state and its latest revision.", [...SIGNED_IN, "not-found", "not-permitted"]),
|
|
649
|
+
readAppDraft: doc("Reads an app draft's state and its latest revision. The input is tagged kind draft with appDraftId, or kind app with appKey.", [...SIGNED_IN, "not-found", "not-permitted"]),
|
|
645
650
|
reviseAppDraft: doc("Saves a whole app document as the successor of the revision the caller last read.", [...CHANGE_SET, "not-found", "invalid-app"]),
|
|
646
651
|
acceptAppDraft: doc("Publishes an app draft's revision as the app's next version.", [...CHANGE_SET, "not-found", "invalid-app"]),
|
|
647
652
|
listApps: doc("Lists the organisation's apps, each with its latest version's number, title and rail placement.", SIGNED_IN),
|
|
@@ -660,13 +665,6 @@ function deepFreeze(value) {
|
|
|
660
665
|
return value;
|
|
661
666
|
}
|
|
662
667
|
var BINARY_REQUESTS = {
|
|
663
|
-
stageAttachment: {
|
|
664
|
-
"contentType": "application/octet-stream",
|
|
665
|
-
"selectorHeader": "x-oe2-selector",
|
|
666
|
-
"selectorEncoding": "json",
|
|
667
|
-
"nameHeader": "x-oe2-attachment-name",
|
|
668
|
-
"nameEncoding": "rfc8187"
|
|
669
|
-
},
|
|
670
668
|
publishHostedVersion: {
|
|
671
669
|
"contentType": "application/octet-stream",
|
|
672
670
|
"selectorHeader": "x-oe2-selector",
|
|
@@ -679,7 +677,8 @@ var BINARY_REQUEST_INPUTS = deepFreeze(BINARY_REQUESTS);
|
|
|
679
677
|
var BINARY_RESPONSES = {
|
|
680
678
|
readAttachment: {
|
|
681
679
|
"contentType": "attachment",
|
|
682
|
-
"headers": "attachmentResponseHeaders"
|
|
680
|
+
"headers": "attachmentResponseHeaders",
|
|
681
|
+
"redirect": "see-other"
|
|
683
682
|
}
|
|
684
683
|
};
|
|
685
684
|
var BINARY_RESPONSE_OUTPUTS = deepFreeze(BINARY_RESPONSES);
|
|
@@ -687,17 +686,17 @@ var SCHEMAS = {
|
|
|
687
686
|
createObjectSet: { "type": "object", "properties": { "name": { "type": "string" }, "members": { "type": "array", "items": { "type": "object", "properties": { "objectId": { "type": "string" }, "projectId": { "type": "string" } }, "required": ["objectId", "projectId"], "additionalProperties": false } } }, "required": ["name", "members"], "additionalProperties": false },
|
|
688
687
|
listObjectSets: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
689
688
|
readObjectSet: { "type": "object", "properties": { "setId": { "type": "string" } }, "required": ["setId"], "additionalProperties": false },
|
|
690
|
-
updateObjectSet: { "type": "object", "properties": { "setId": { "type": "string" }, "revision": { "type": "
|
|
691
|
-
deleteObjectSet: { "type": "object", "properties": { "setId": { "type": "string" }, "revision": { "type": "
|
|
689
|
+
updateObjectSet: { "type": "object", "properties": { "setId": { "type": "string" }, "revision": { "type": "integer" }, "name": { "type": "string" }, "members": { "type": "array", "items": { "type": "object", "properties": { "objectId": { "type": "string" }, "projectId": { "type": "string" } }, "required": ["objectId", "projectId"], "additionalProperties": false } } }, "required": ["setId", "revision"], "additionalProperties": false },
|
|
690
|
+
deleteObjectSet: { "type": "object", "properties": { "setId": { "type": "string" }, "revision": { "type": "integer" } }, "required": ["setId", "revision"], "additionalProperties": false },
|
|
692
691
|
health: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
693
692
|
webSignInStart: { "type": "object", "properties": { "state": { "type": "string" }, "loopback": { "type": "string" }, "code_challenge": { "type": "string" }, "code_challenge_method": { "const": "S256" } }, "required": ["state", "loopback", "code_challenge", "code_challenge_method"], "additionalProperties": false },
|
|
694
|
-
webRedeem: { "type": "object", "properties": { "code": { "type": "string" }, "state": { "type": "string" }, "code_verifier": { "type": "string" }, "invitation_code": { "type": "string" } }, "required": ["code", "state", "code_verifier"], "additionalProperties": false },
|
|
693
|
+
webRedeem: { "type": "object", "properties": { "code": { "type": "string", "format": "password", "writeOnly": true }, "state": { "type": "string" }, "code_verifier": { "type": "string", "format": "password", "writeOnly": true }, "invitation_code": { "type": "string", "format": "password", "writeOnly": true } }, "required": ["code", "state", "code_verifier"], "additionalProperties": false },
|
|
695
694
|
signInStart: { "type": "object", "properties": { "state": { "type": "string" }, "loopback": { "type": "string" }, "code_challenge": { "type": "string" }, "code_challenge_method": { "const": "S256" } }, "required": ["state", "loopback", "code_challenge", "code_challenge_method"], "additionalProperties": false },
|
|
696
|
-
signInCallback: { "
|
|
697
|
-
redeem: { "type": "object", "properties": { "code": { "type": "string" }, "state": { "type": "string" }, "code_verifier": { "type": "string" }, "invitation_code": { "type": "string" } }, "required": ["code", "state", "code_verifier"], "additionalProperties": false },
|
|
698
|
-
refresh: { "type": "object", "properties": { "refreshToken": { "type": "string" } }, "required": ["refreshToken"], "additionalProperties": false },
|
|
695
|
+
signInCallback: { "anyOf": [{ "type": "object", "properties": { "state": { "type": "string" }, "code": { "type": "string", "format": "password", "writeOnly": true } }, "required": ["state", "code"], "additionalProperties": {} }, { "type": "object", "properties": { "state": { "type": "string" }, "error": { "type": "string" } }, "required": ["state", "error"], "additionalProperties": {} }] },
|
|
696
|
+
redeem: { "type": "object", "properties": { "code": { "type": "string", "format": "password", "writeOnly": true }, "state": { "type": "string" }, "code_verifier": { "type": "string", "format": "password", "writeOnly": true }, "invitation_code": { "type": "string", "format": "password", "writeOnly": true } }, "required": ["code", "state", "code_verifier"], "additionalProperties": false },
|
|
697
|
+
refresh: { "type": "object", "properties": { "refreshToken": { "type": "string", "format": "password", "writeOnly": true } }, "required": ["refreshToken"], "additionalProperties": false },
|
|
699
698
|
logout: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
700
|
-
serviceCredential: { "type": "object", "properties": { "credentialId": { "type": "string" }, "secret": { "type": "string" } }, "required": ["credentialId", "secret"], "additionalProperties": false },
|
|
699
|
+
serviceCredential: { "type": "object", "properties": { "credentialId": { "type": "string" }, "secret": { "type": "string", "format": "password", "writeOnly": true } }, "required": ["credentialId", "secret"], "additionalProperties": false },
|
|
701
700
|
attachOrganisation: { "type": "object", "properties": { "organisationId": { "type": "string" } }, "required": ["organisationId"], "additionalProperties": false },
|
|
702
701
|
detachOrganisation: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
703
702
|
listOrganisations: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
@@ -714,6 +713,8 @@ var SCHEMAS = {
|
|
|
714
713
|
enterHumanMode: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
715
714
|
readSessionStatus: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
716
715
|
readStepUpProof: { "type": "object", "properties": { "pendingId": { "type": "string" } }, "required": ["pendingId"], "additionalProperties": false },
|
|
716
|
+
openAttachmentUpload: { "type": "object", "properties": { "name": { "type": "string" }, "declaredLength": { "type": "integer" } }, "required": ["name", "declaredLength"], "additionalProperties": false },
|
|
717
|
+
completeAttachmentUpload: { "type": "object", "properties": { "uploadId": { "type": "string" } }, "required": ["uploadId"], "additionalProperties": false },
|
|
717
718
|
readAttachment: {
|
|
718
719
|
"type": "object",
|
|
719
720
|
"properties": {
|
|
@@ -731,17 +732,17 @@ var SCHEMAS = {
|
|
|
731
732
|
"additionalProperties": false
|
|
732
733
|
},
|
|
733
734
|
readObject: { "type": "object", "properties": { "objectId": { "type": "string" } }, "required": ["objectId"], "additionalProperties": false },
|
|
734
|
-
queryObjects: { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "objects" }, "typeKey": { "oneOf": [{ "type": "string" }, { "type": "null" }] }, "projects": { "type": "array", "items": { "type": "string" } }, "filters": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } }, "steps": { "type": "array", "items": { "type": "object", "properties": { "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "targetTypeKey": { "type": "string" }, "filters": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } } }, "required": ["edgeTypeKey", "direction", "targetTypeKey"], "additionalProperties": false } }, "sort": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["kind", "property", "direction"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["kind", "direction"], "additionalProperties": false }] }, "limit": { "type": "number" }, "continuation": { "oneOf": [{ "type": "string" }, { "type": "null" }] } }, "required": ["kind", "typeKey", "limit", "continuation"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "set" }, "op": { "enum": ["union", "intersection", "difference"] }, "left": { "type": "object", "properties": { "kind": { "const": "objects" }, "typeKey": { "oneOf": [{ "type": "string" }, { "type": "null" }] }, "projects": { "type": "array", "items": { "type": "string" } }, "filters": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } }, "steps": { "type": "array", "items": { "type": "object", "properties": { "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "targetTypeKey": { "type": "string" }, "filters": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } } }, "required": ["edgeTypeKey", "direction", "targetTypeKey"], "additionalProperties": false } }, "sort": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["kind", "property", "direction"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["kind", "direction"], "additionalProperties": false }] } }, "required": ["kind", "typeKey"], "additionalProperties": false }, "right": { "type": "object", "properties": { "kind": { "const": "objects" }, "typeKey": { "oneOf": [{ "type": "string" }, { "type": "null" }] }, "projects": { "type": "array", "items": { "type": "string" } }, "filters": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } }, "steps": { "type": "array", "items": { "type": "object", "properties": { "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "targetTypeKey": { "type": "string" }, "filters": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } } }, "required": ["edgeTypeKey", "direction", "targetTypeKey"], "additionalProperties": false } }, "sort": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["kind", "property", "direction"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["kind", "direction"], "additionalProperties": false }] } }, "required": ["kind", "typeKey"], "additionalProperties": false }, "limit": { "type": "number" }, "continuation": { "oneOf": [{ "type": "string" }, { "type": "null" }] } }, "required": ["kind", "op", "left", "right", "limit", "continuation"], "additionalProperties": false }] },
|
|
735
|
-
queryRows: { "type": "object", "properties": { "kind": { "const": "graph-query" }, "start": { "type": "object", "properties": { "typeKey": { "oneOf": [{ "type": "string" }, { "type": "null" }] }, "projects": { "type": "array", "items": { "type": "string" } }, "filters": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } } }, "required": ["typeKey"], "additionalProperties": false }, "path": { "type": "array", "items": { "type": "object", "properties": { "alias": { "type": "string" }, "edgeTypeKeys": { "oneOf": [{ "const": "any" }, { "type": "array", "items": { "type": "string" } }] }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "targetTypeKeys": { "type": "array", "items": { "type": "string" } }, "filters": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } }, "repeat": { "type": "object", "properties": { "depth": { "type": "number" } }, "required": ["depth"], "additionalProperties": false } }, "required": ["alias", "edgeTypeKeys", "direction"], "additionalProperties": false } }, "answer": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "rows" }, "columns": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "enum": ["identity", "typeKey"] }, "alias": { "type": "string" } }, "required": ["kind", "alias"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "alias": { "type": "string" }, "property": { "type": "string" } }, "required": ["kind", "alias", "property"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "alias": { "type": "string" }, "field": { "enum": ["identity", "typeKey"] } }, "required": ["kind", "alias", "field"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge-property" }, "alias": { "type": "string" }, "property": { "type": "string" } }, "required": ["kind", "alias", "property"], "additionalProperties": false }] } }, "order": { "type": "object", "properties": { "alias": { "type": "string" }, "property": { "type": "string" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["alias", "property", "direction"], "additionalProperties": false }, "limit": { "type": "number" }, "continuation": { "oneOf": [{ "type": "string" }, { "type": "null" }] } }, "required": ["kind", "columns", "limit", "continuation"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "groups" }, "keys": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "enum": ["identity", "typeKey"] }, "alias": { "type": "string" } }, "required": ["kind", "alias"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "alias": { "type": "string" }, "property": { "type": "string" } }, "required": ["kind", "alias", "property"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "parent" }, "alias": { "type": "string" }, "edgeTypeKeys": { "type": "array", "items": { "type": "string" } }, "parents": { "type": "array", "items": { "type": "object", "properties": { "objectId": { "type": "string" }, "projectId": { "type": "string" } }, "required": ["objectId", "projectId"], "additionalProperties": false } } }, "required": ["kind", "alias", "edgeTypeKeys"], "additionalProperties": false }] } }, "measures": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "count" }, "over": { "type": "array", "items": { "type": "string" } }, "ends": { "enum": ["visible", "all"] } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "countDistinct" }, "alias": { "type": "string" }, "over": { "type": "array", "items": { "type": "string" } }, "ends": { "enum": ["visible", "all"] } }, "required": ["kind", "alias"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "sum" }, "alias": { "type": "string" }, "property": { "type": "string" }, "over": { "type": "array", "items": { "type": "string" } }, "multiplicity": { "enum": ["per-path", "distinct"] }, "ends": { "enum": ["visible", "all"] } }, "required": ["kind", "alias", "property"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "enum": ["min", "max"] }, "alias": { "type": "string" }, "property": { "type": "string" }, "over": { "type": "array", "items": { "type": "string" } }, "ends": { "enum": ["visible", "all"] } }, "required": ["kind", "alias", "property"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "weightedSum" }, "alias": { "type": "string" }, "property": { "type": "string" }, "weight": { "type": "string" }, "over": { "type": "array", "items": { "type": "string" } }, "multiplicity": { "enum": ["per-path", "distinct"] }, "ends": { "enum": ["visible", "all"] } }, "required": ["kind", "alias", "weight", "over", "multiplicity", "ends"], "additionalProperties": false }] } }, "having": { "type": "array", "items": { "type": "object", "properties": { "measure": { "type": "number" }, "op": { "enum": ["=", ">", ">=", "<", "<="] }, "value": { "type": "number" } }, "required": ["measure", "op", "value"], "additionalProperties": false } }, "order": { "type": "object", "properties": { "by": { "enum": ["key", "measure"] }, "index": { "type": "number" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["by", "index", "direction"], "additionalProperties": false }, "limit": { "type": "number" } }, "required": ["kind", "keys", "measures"], "additionalProperties": false }] } }, "required": ["kind", "start", "answer"], "additionalProperties": false },
|
|
736
|
-
aggregateObjects: { "type": "object", "properties": { "kind": { "const": "aggregate" }, "typeKey": { "oneOf": [{ "type": "string" }, { "type": "null" }] }, "projects": { "type": "array", "items": { "type": "string" } }, "filters": { "type": "array", "items": { "
|
|
735
|
+
queryObjects: { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "objects" }, "typeKey": { "oneOf": [{ "type": "string" }, { "type": "null" }] }, "projects": { "type": "array", "items": { "type": "string" } }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } }, "steps": { "type": "array", "items": { "type": "object", "properties": { "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "targetTypeKey": { "type": "string" }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } } }, "required": ["edgeTypeKey", "direction", "targetTypeKey"], "additionalProperties": false } }, "sort": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["kind", "property", "direction"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["kind", "direction"], "additionalProperties": false }] }, "limit": { "type": "integer" }, "continuation": { "oneOf": [{ "type": "string" }, { "type": "null" }] } }, "required": ["kind", "typeKey", "limit", "continuation"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "set" }, "op": { "enum": ["union", "intersection", "difference"] }, "left": { "type": "object", "properties": { "kind": { "const": "objects" }, "typeKey": { "oneOf": [{ "type": "string" }, { "type": "null" }] }, "projects": { "type": "array", "items": { "type": "string" } }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } }, "steps": { "type": "array", "items": { "type": "object", "properties": { "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "targetTypeKey": { "type": "string" }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } } }, "required": ["edgeTypeKey", "direction", "targetTypeKey"], "additionalProperties": false } }, "sort": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["kind", "property", "direction"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["kind", "direction"], "additionalProperties": false }] } }, "required": ["kind", "typeKey"], "additionalProperties": false }, "right": { "type": "object", "properties": { "kind": { "const": "objects" }, "typeKey": { "oneOf": [{ "type": "string" }, { "type": "null" }] }, "projects": { "type": "array", "items": { "type": "string" } }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } }, "steps": { "type": "array", "items": { "type": "object", "properties": { "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "targetTypeKey": { "type": "string" }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } } }, "required": ["edgeTypeKey", "direction", "targetTypeKey"], "additionalProperties": false } }, "sort": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["kind", "property", "direction"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["kind", "direction"], "additionalProperties": false }] } }, "required": ["kind", "typeKey"], "additionalProperties": false }, "limit": { "type": "integer" }, "continuation": { "oneOf": [{ "type": "string" }, { "type": "null" }] } }, "required": ["kind", "op", "left", "right", "limit", "continuation"], "additionalProperties": false }] },
|
|
736
|
+
queryRows: { "type": "object", "properties": { "kind": { "const": "graph-query" }, "start": { "type": "object", "properties": { "typeKey": { "oneOf": [{ "type": "string" }, { "type": "null" }] }, "projects": { "type": "array", "items": { "type": "string" } }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } } }, "required": ["typeKey"], "additionalProperties": false }, "path": { "type": "array", "items": { "type": "object", "properties": { "alias": { "type": "string" }, "edgeTypeKeys": { "oneOf": [{ "const": "any" }, { "type": "array", "items": { "type": "string" } }] }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "targetTypeKeys": { "type": "array", "items": { "type": "string" } }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } }, "repeat": { "type": "object", "properties": { "depth": { "type": "integer" } }, "required": ["depth"], "additionalProperties": false } }, "required": ["alias", "edgeTypeKeys", "direction"], "additionalProperties": false } }, "answer": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "rows" }, "columns": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "enum": ["identity", "typeKey"] }, "alias": { "type": "string" } }, "required": ["kind", "alias"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "alias": { "type": "string" }, "property": { "type": "string" } }, "required": ["kind", "alias", "property"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "alias": { "type": "string" }, "field": { "enum": ["identity", "typeKey"] } }, "required": ["kind", "alias", "field"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge-property" }, "alias": { "type": "string" }, "property": { "type": "string" } }, "required": ["kind", "alias", "property"], "additionalProperties": false }] } }, "order": { "type": "object", "properties": { "alias": { "type": "string" }, "property": { "type": "string" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["alias", "property", "direction"], "additionalProperties": false }, "limit": { "type": "integer" }, "continuation": { "oneOf": [{ "type": "string" }, { "type": "null" }] } }, "required": ["kind", "columns", "limit", "continuation"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "groups" }, "keys": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "enum": ["identity", "typeKey"] }, "alias": { "type": "string" } }, "required": ["kind", "alias"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "alias": { "type": "string" }, "property": { "type": "string" } }, "required": ["kind", "alias", "property"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "parent" }, "alias": { "type": "string" }, "edgeTypeKeys": { "type": "array", "items": { "type": "string" } }, "parents": { "type": "array", "items": { "type": "object", "properties": { "objectId": { "type": "string" }, "projectId": { "type": "string" } }, "required": ["objectId", "projectId"], "additionalProperties": false } } }, "required": ["kind", "alias", "edgeTypeKeys"], "additionalProperties": false }] } }, "measures": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "count" }, "over": { "type": "array", "items": { "type": "string" } }, "ends": { "enum": ["visible", "all"] } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "countDistinct" }, "alias": { "type": "string" }, "over": { "type": "array", "items": { "type": "string" } }, "ends": { "enum": ["visible", "all"] } }, "required": ["kind", "alias"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "sum" }, "alias": { "type": "string" }, "property": { "type": "string" }, "over": { "type": "array", "items": { "type": "string" } }, "multiplicity": { "enum": ["per-path", "distinct"] }, "ends": { "enum": ["visible", "all"] } }, "required": ["kind", "alias", "property"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "enum": ["min", "max"] }, "alias": { "type": "string" }, "property": { "type": "string" }, "over": { "type": "array", "items": { "type": "string" } }, "ends": { "enum": ["visible", "all"] } }, "required": ["kind", "alias", "property"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "weightedSum" }, "alias": { "type": "string" }, "property": { "type": "string" }, "weight": { "type": "string" }, "over": { "type": "array", "items": { "type": "string" } }, "multiplicity": { "enum": ["per-path", "distinct"] }, "ends": { "enum": ["visible", "all"] } }, "required": ["kind", "alias", "weight", "over", "multiplicity", "ends"], "additionalProperties": false }] } }, "having": { "type": "array", "items": { "type": "object", "properties": { "measure": { "type": "integer" }, "op": { "enum": ["=", ">", ">=", "<", "<="] }, "value": { "type": "number" } }, "required": ["measure", "op", "value"], "additionalProperties": false } }, "order": { "type": "object", "properties": { "by": { "enum": ["key", "measure"] }, "index": { "type": "integer" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["by", "index", "direction"], "additionalProperties": false }, "limit": { "type": "integer" } }, "required": ["kind", "keys", "measures"], "additionalProperties": false }] } }, "required": ["kind", "start", "answer"], "additionalProperties": false },
|
|
737
|
+
aggregateObjects: { "type": "object", "properties": { "kind": { "const": "aggregate" }, "typeKey": { "oneOf": [{ "type": "string" }, { "type": "null" }] }, "projects": { "type": "array", "items": { "type": "string" } }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } }, "steps": { "type": "array", "items": { "type": "object", "properties": { "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "targetTypeKey": { "type": "string" }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } } }, "required": ["edgeTypeKey", "direction", "targetTypeKey"], "additionalProperties": false } }, "operation": { "enum": ["count", "min", "max", "sum", "average"] }, "property": { "type": "string" }, "groupBy": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "type" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" } }, "required": ["kind", "property"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "parent" }, "edgeTypeKeys": { "type": "array", "items": { "type": "string" } }, "multiplicity": { "enum": ["per-path", "distinct"] }, "ends": { "enum": ["visible", "all"] }, "parents": { "type": "array", "items": { "type": "object", "properties": { "objectId": { "type": "string" }, "projectId": { "type": "string" } }, "required": ["objectId", "projectId"], "additionalProperties": false } } }, "required": ["kind", "edgeTypeKeys", "multiplicity", "ends"], "additionalProperties": false }] } }, "required": ["kind", "typeKey", "operation"], "additionalProperties": false },
|
|
737
738
|
discoverVerbs: { "type": "object", "properties": { "objectId": { "type": "string" } }, "required": ["objectId"], "additionalProperties": false },
|
|
738
|
-
readHistory: { "type": "object", "properties": { "objectId": { "type": "string" }, "limit": { "type": "
|
|
739
|
-
mutate: { "type": "object", "properties": { "correlation": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "mint" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "sent" }, "correlationId": { "type": "string" } }, "required": ["kind", "correlationId"], "additionalProperties": false }] }, "operation": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "create-object" }, "typeKey": { "type": "string" }, "typeVersion": { "type": "
|
|
740
|
-
mutateBatch: { "type": "object", "properties": { "correlation": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "mint" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "sent" }, "correlationId": { "type": "string" } }, "required": ["kind", "correlationId"], "additionalProperties": false }] }, "operations": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "create-object" }, "typeKey": { "type": "string" }, "typeVersion": { "type": "
|
|
739
|
+
readHistory: { "type": "object", "properties": { "objectId": { "type": "string" }, "limit": { "type": "integer" }, "continuation": { "oneOf": [{ "type": "string" }, { "type": "null" }] } }, "required": ["objectId", "limit", "continuation"], "additionalProperties": false },
|
|
740
|
+
mutate: { "type": "object", "properties": { "correlation": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "mint" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "sent" }, "correlationId": { "type": "string" } }, "required": ["kind", "correlationId"], "additionalProperties": false }] }, "operation": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "create-object" }, "typeKey": { "type": "string" }, "typeVersion": { "type": "integer" }, "properties": { "type": "object", "additionalProperties": {} } }, "required": ["kind", "typeKey", "typeVersion", "properties"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "update-object" }, "objectId": { "type": "string" }, "typeVersion": { "type": "integer" }, "changes": { "type": "object", "additionalProperties": { "type": "object", "properties": { "from": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "absent" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "value" }, "value": {} }, "required": ["kind", "value"], "additionalProperties": false }] }, "to": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "absent" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "value" }, "value": {} }, "required": ["kind", "value"], "additionalProperties": false }] } }, "required": ["from", "to"], "additionalProperties": false } } }, "required": ["kind", "objectId", "typeVersion", "changes"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "delete-object" }, "objectId": { "type": "string" } }, "required": ["kind", "objectId"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "create-edge" }, "typeKey": { "type": "string" }, "typeVersion": { "type": "integer" }, "sourceObjectId": { "type": "string" }, "targetObjectId": { "type": "string" }, "properties": { "type": "object", "additionalProperties": {} } }, "required": ["kind", "typeKey", "typeVersion", "sourceObjectId", "targetObjectId", "properties"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "update-edge" }, "edgeId": { "type": "string" }, "typeVersion": { "type": "integer" }, "changes": { "type": "object", "additionalProperties": { "type": "object", "properties": { "from": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "absent" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "value" }, "value": {} }, "required": ["kind", "value"], "additionalProperties": false }] }, "to": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "absent" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "value" }, "value": {} }, "required": ["kind", "value"], "additionalProperties": false }] } }, "required": ["from", "to"], "additionalProperties": false } } }, "required": ["kind", "edgeId", "typeVersion", "changes"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "delete-edge" }, "edgeId": { "type": "string" } }, "required": ["kind", "edgeId"], "additionalProperties": false }] } }, "required": ["correlation", "operation"], "additionalProperties": false },
|
|
741
|
+
mutateBatch: { "type": "object", "properties": { "correlation": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "mint" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "sent" }, "correlationId": { "type": "string" } }, "required": ["kind", "correlationId"], "additionalProperties": false }] }, "operations": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "create-object" }, "typeKey": { "type": "string" }, "typeVersion": { "type": "integer" }, "properties": { "type": "object", "additionalProperties": {} } }, "required": ["kind", "typeKey", "typeVersion", "properties"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "update-object" }, "objectId": { "type": "string" }, "typeVersion": { "type": "integer" }, "changes": { "type": "object", "additionalProperties": { "type": "object", "properties": { "from": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "absent" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "value" }, "value": {} }, "required": ["kind", "value"], "additionalProperties": false }] }, "to": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "absent" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "value" }, "value": {} }, "required": ["kind", "value"], "additionalProperties": false }] } }, "required": ["from", "to"], "additionalProperties": false } } }, "required": ["kind", "objectId", "typeVersion", "changes"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "delete-object" }, "objectId": { "type": "string" } }, "required": ["kind", "objectId"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "create-edge" }, "typeKey": { "type": "string" }, "typeVersion": { "type": "integer" }, "source": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "existing" }, "objectId": { "type": "string" } }, "required": ["kind", "objectId"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "created" }, "operation": { "type": "integer" } }, "required": ["kind", "operation"], "additionalProperties": false }] }, "target": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "existing" }, "objectId": { "type": "string" } }, "required": ["kind", "objectId"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "created" }, "operation": { "type": "integer" } }, "required": ["kind", "operation"], "additionalProperties": false }] }, "properties": { "type": "object", "additionalProperties": {} } }, "required": ["kind", "typeKey", "typeVersion", "source", "target", "properties"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "update-edge" }, "edgeId": { "type": "string" }, "typeVersion": { "type": "integer" }, "changes": { "type": "object", "additionalProperties": { "type": "object", "properties": { "from": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "absent" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "value" }, "value": {} }, "required": ["kind", "value"], "additionalProperties": false }] }, "to": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "absent" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "value" }, "value": {} }, "required": ["kind", "value"], "additionalProperties": false }] } }, "required": ["from", "to"], "additionalProperties": false } } }, "required": ["kind", "edgeId", "typeVersion", "changes"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "delete-edge" }, "edgeId": { "type": "string" } }, "required": ["kind", "edgeId"], "additionalProperties": false }] } } }, "required": ["correlation", "operations"], "additionalProperties": false },
|
|
741
742
|
previewDelete: { "type": "object", "properties": { "objectId": { "type": "string" } }, "required": ["objectId"], "additionalProperties": false },
|
|
742
743
|
recover: { "type": "object", "properties": { "correlationId": { "type": "string" } }, "required": ["correlationId"], "additionalProperties": false },
|
|
743
|
-
executeVerb: { "type": "object", "properties": { "correlation": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "mint" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "sent" }, "correlationId": { "type": "string" } }, "required": ["kind", "correlationId"], "additionalProperties": false }] }, "verb": { "type": "object", "properties": { "typeKey": { "type": "string" }, "typeVersion": { "type": "
|
|
744
|
-
createBranch: { "type": "object", "properties": { "correlation": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "mint" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "sent" }, "correlationId": { "type": "string" } }, "required": ["kind", "correlationId"], "additionalProperties": false }] }, "name": { "type": "string" }, "from": { "oneOf": [{ "type": "object", "properties": { "ref": { "type": "string" } }, "required": ["ref"], "additionalProperties": false }, { "type": "object", "properties": { "hash": { "type": "string" } }, "required": ["hash"], "additionalProperties": false }] } }, "required": ["correlation", "name"], "additionalProperties": false },
|
|
744
|
+
executeVerb: { "type": "object", "properties": { "correlation": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "mint" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "sent" }, "correlationId": { "type": "string" } }, "required": ["kind", "correlationId"], "additionalProperties": false }] }, "verb": { "type": "object", "properties": { "typeKey": { "type": "string" }, "typeVersion": { "type": "integer" } }, "required": ["typeKey", "typeVersion"], "additionalProperties": false }, "subjectIds": { "type": "array", "items": { "type": "string" } }, "input": {} }, "required": ["correlation", "verb", "subjectIds", "input"], "additionalProperties": false },
|
|
745
|
+
createBranch: { "type": "object", "properties": { "correlation": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "mint" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "sent" }, "correlationId": { "type": "string" } }, "required": ["kind", "correlationId"], "additionalProperties": false }] }, "name": { "type": "string" }, "from": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "ref" }, "ref": { "type": "string" } }, "required": ["kind", "ref"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "hash" }, "hash": { "type": "string" } }, "required": ["kind", "hash"], "additionalProperties": false }] } }, "required": ["correlation", "name"], "additionalProperties": false },
|
|
745
746
|
merge: { "type": "object", "properties": { "correlation": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "mint" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "sent" }, "correlationId": { "type": "string" } }, "required": ["kind", "correlationId"], "additionalProperties": false }] }, "sourceHash": { "type": "string" }, "message": { "type": "string" }, "name": { "type": "string" }, "source": { "type": "string" }, "target": { "type": "string" } }, "required": ["correlation", "sourceHash", "message"], "additionalProperties": false },
|
|
746
747
|
readMergeConflicts: { "type": "object", "properties": { "name": { "type": "string" } }, "required": ["name"], "additionalProperties": false },
|
|
747
748
|
disposeRef: { "type": "object", "properties": { "deleteDrafts": { "type": "boolean" }, "correlation": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "mint" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "sent" }, "correlationId": { "type": "string" } }, "required": ["kind", "correlationId"], "additionalProperties": false }] }, "name": { "type": "string" }, "atHash": { "type": "string" } }, "required": ["correlation", "name", "atHash"], "additionalProperties": false },
|
|
@@ -756,7 +757,7 @@ var SCHEMAS = {
|
|
|
756
757
|
revokeServiceCredential: { "type": "object", "properties": { "credentialId": { "type": "string" } }, "required": ["credentialId"], "additionalProperties": false },
|
|
757
758
|
grantMembership: { "type": "object", "properties": { "principalId": { "type": "string" }, "scopeKind": { "enum": ["organisation", "project"] }, "scopeId": { "type": "string" }, "roleKey": { "type": "string" } }, "required": ["principalId", "scopeKind", "scopeId", "roleKey"], "additionalProperties": false },
|
|
758
759
|
revokeMembership: { "type": "object", "properties": { "principalId": { "type": "string" }, "scopeKind": { "enum": ["organisation", "project"] }, "scopeId": { "type": "string" } }, "required": ["principalId", "scopeKind", "scopeId"], "additionalProperties": false },
|
|
759
|
-
setModelConfiguration: { "type": "object", "properties": { "model": { "type": "string" }, "apiKey": { "type": "string" } }, "required": ["model", "apiKey"], "additionalProperties": false },
|
|
760
|
+
setModelConfiguration: { "type": "object", "properties": { "model": { "type": "string" }, "apiKey": { "type": "string", "format": "password", "writeOnly": true } }, "required": ["model", "apiKey"], "additionalProperties": false },
|
|
760
761
|
setModelId: { "type": "object", "properties": { "model": { "type": "string" } }, "required": ["model"], "additionalProperties": false },
|
|
761
762
|
readDisplayNames: { "type": "object", "properties": { "principalIds": { "type": "array", "items": { "type": "string" } } }, "required": ["principalIds"], "additionalProperties": false },
|
|
762
763
|
listMembers: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
@@ -777,9 +778,9 @@ var SCHEMAS = {
|
|
|
777
778
|
reissuePlatformInvitation: { "type": "object", "properties": { "invitationId": { "type": "string" } }, "required": ["invitationId"], "additionalProperties": false },
|
|
778
779
|
readWebOrigin: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
779
780
|
readCallerCapabilities: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
780
|
-
queryGraph: { "type": "object", "properties": { "kind": { "const": "graph" }, "start": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "objects" }, "objects": { "type": "array", "items": { "type": "object", "properties": { "objectId": { "type": "string" }, "projectId": { "type": "string" } }, "required": ["objectId", "projectId"], "additionalProperties": false } } }, "required": ["kind", "objects"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "set" }, "set": { "type": "object", "properties": { "kind": { "const": "objects" }, "typeKey": { "oneOf": [{ "type": "string" }, { "type": "null" }] }, "projects": { "type": "array", "items": { "type": "string" } }, "filters": { "type": "array", "items": { "
|
|
781
|
-
readStructure: { "type": "object", "properties": { "typeKey": { "type": "string" }, "structure": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "declared" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "relationship" }, "edgeTypeKey": { "type": "string" } }, "required": ["kind", "edgeTypeKey"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "view" }, "viewKey": { "type": "string" } }, "required": ["kind", "viewKey"], "additionalProperties": false }] }, "anchor": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "forest" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "subtree" }, "object": { "type": "object", "properties": { "objectId": { "type": "string" }, "projectId": { "type": "string" } }, "required": ["objectId", "projectId"], "additionalProperties": false } }, "required": ["kind", "object"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "ancestors" }, "object": { "type": "object", "properties": { "objectId": { "type": "string" }, "projectId": { "type": "string" } }, "required": ["objectId", "projectId"], "additionalProperties": false } }, "required": ["kind", "object"], "additionalProperties": false }] }, "maxDepth": { "type": "
|
|
782
|
-
findPaths: { "type": "object", "properties": { "from": { "type": "object", "properties": { "objectId": { "type": "string" }, "projectId": { "type": "string" } }, "required": ["objectId", "projectId"], "additionalProperties": false }, "to": { "type": "object", "properties": { "objectId": { "type": "string" }, "projectId": { "type": "string" } }, "required": ["objectId", "projectId"], "additionalProperties": false }, "edgeTypeKeys": { "type": "array", "items": { "type": "string" } }, "direction": { "enum": ["outgoing", "incoming"] }, "maxLength": { "type": "
|
|
781
|
+
queryGraph: { "type": "object", "properties": { "kind": { "const": "graph" }, "start": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "objects" }, "objects": { "type": "array", "items": { "type": "object", "properties": { "objectId": { "type": "string" }, "projectId": { "type": "string" } }, "required": ["objectId", "projectId"], "additionalProperties": false } } }, "required": ["kind", "objects"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "set" }, "set": { "type": "object", "properties": { "kind": { "const": "objects" }, "typeKey": { "oneOf": [{ "type": "string" }, { "type": "null" }] }, "projects": { "type": "array", "items": { "type": "string" } }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } }, "steps": { "type": "array", "items": { "type": "object", "properties": { "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "targetTypeKey": { "type": "string" }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "or" }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "=" }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": [">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "string" }, { "type": "number" }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "edge" }, "edgeTypeKey": { "type": "string" }, "direction": { "enum": ["outgoing", "incoming", "to-children", "to-parent"] }, "has": { "type": "boolean" } }, "required": ["kind", "edgeTypeKey", "direction", "has"], "additionalProperties": false }] } } }, "required": ["kind", "filters"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "type": "string" }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "type" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "op", "values"], "additionalProperties": false }] } } }, "required": ["edgeTypeKey", "direction", "targetTypeKey"], "additionalProperties": false } }, "sort": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["kind", "property", "direction"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["kind", "direction"], "additionalProperties": false }] } }, "required": ["kind", "typeKey"], "additionalProperties": false } }, "required": ["kind", "set"], "additionalProperties": false }] }, "steps": { "type": "array", "items": { "type": "object", "properties": { "edgeTypeKeys": { "type": "array", "items": { "type": "string" } }, "direction": { "enum": ["outgoing", "incoming"] }, "depth": { "type": "integer" }, "targetTypeKeys": { "type": "array", "items": { "type": "string" } } }, "required": ["depth"], "additionalProperties": false } }, "closeOver": { "type": "array", "items": { "type": "string" } }, "keep": { "enum": ["all", "last"] }, "objectLimit": { "type": "integer" }, "hopLimit": { "type": "integer" }, "continuation": { "oneOf": [{ "type": "string" }, { "type": "null" }] } }, "required": ["kind", "start", "steps"], "additionalProperties": false },
|
|
782
|
+
readStructure: { "type": "object", "properties": { "typeKey": { "type": "string" }, "structure": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "declared" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "relationship" }, "edgeTypeKey": { "type": "string" } }, "required": ["kind", "edgeTypeKey"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "view" }, "viewKey": { "type": "string" } }, "required": ["kind", "viewKey"], "additionalProperties": false }] }, "anchor": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "forest" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "subtree" }, "object": { "type": "object", "properties": { "objectId": { "type": "string" }, "projectId": { "type": "string" } }, "required": ["objectId", "projectId"], "additionalProperties": false } }, "required": ["kind", "object"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "ancestors" }, "object": { "type": "object", "properties": { "objectId": { "type": "string" }, "projectId": { "type": "string" } }, "required": ["objectId", "projectId"], "additionalProperties": false } }, "required": ["kind", "object"], "additionalProperties": false }] }, "maxDepth": { "type": "integer" }, "occurrenceLimit": { "type": "integer" } }, "required": ["typeKey", "structure", "anchor"], "additionalProperties": false },
|
|
783
|
+
findPaths: { "type": "object", "properties": { "from": { "type": "object", "properties": { "objectId": { "type": "string" }, "projectId": { "type": "string" } }, "required": ["objectId", "projectId"], "additionalProperties": false }, "to": { "type": "object", "properties": { "objectId": { "type": "string" }, "projectId": { "type": "string" } }, "required": ["objectId", "projectId"], "additionalProperties": false }, "edgeTypeKeys": { "type": "array", "items": { "type": "string" } }, "direction": { "enum": ["outgoing", "incoming"] }, "maxLength": { "type": "integer" }, "maxPaths": { "type": "integer" } }, "required": ["from", "to", "maxLength"], "additionalProperties": false },
|
|
783
784
|
listProposals: { "type": "object", "properties": { "state": { "enum": ["pending", "merged", "refused", "discarded", "all"] }, "cursor": { "type": "string" } }, "required": ["state"], "additionalProperties": false },
|
|
784
785
|
readProposal: { "type": "object", "properties": { "proposalId": { "type": "string" } }, "required": ["proposalId"], "additionalProperties": false },
|
|
785
786
|
refuseProposal: { "type": "object", "properties": { "proposalId": { "type": "string" }, "reason": { "type": "string" } }, "required": ["proposalId", "reason"], "additionalProperties": false },
|
|
@@ -790,19 +791,19 @@ var SCHEMAS = {
|
|
|
790
791
|
readChangeImpact: { "type": "object", "properties": { "ref": { "type": "string" }, "base": { "type": "string" } }, "required": ["ref", "base"], "additionalProperties": false },
|
|
791
792
|
diffBranches: { "type": "object", "properties": { "ref": { "type": "string" }, "base": { "type": "string" }, "cursor": { "type": "string" } }, "required": ["ref", "base"], "additionalProperties": false },
|
|
792
793
|
readBranchHistory: { "type": "object", "properties": { "name": { "type": "string" }, "cursor": { "type": "string" } }, "required": ["name"], "additionalProperties": false },
|
|
793
|
-
listAudit: { "type": "object", "properties": { "limit": { "type": "
|
|
794
|
-
listOrganisationAudit: { "type": "object", "properties": { "limit": { "type": "
|
|
794
|
+
listAudit: { "type": "object", "properties": { "limit": { "type": "integer" }, "cursor": { "type": "string" } }, "required": ["limit"], "additionalProperties": false },
|
|
795
|
+
listOrganisationAudit: { "type": "object", "properties": { "limit": { "type": "integer" }, "verbPrefix": { "type": "string" }, "cursor": { "type": "string" } }, "required": ["limit", "verbPrefix"], "additionalProperties": false },
|
|
795
796
|
readRefHead: { "type": "object", "properties": { "name": { "type": "string" } }, "required": ["name"], "additionalProperties": false },
|
|
796
797
|
inspectBranchOperation: { "type": "object", "properties": { "correlationId": { "type": "string" } }, "required": ["correlationId"], "additionalProperties": false },
|
|
797
798
|
abandonBranch: { "type": "object", "properties": { "correlation": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "mint" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "sent" }, "correlationId": { "type": "string" } }, "required": ["kind", "correlationId"], "additionalProperties": false }] }, "name": { "type": "string" }, "atHash": { "type": "string" } }, "required": ["correlation", "name", "atHash"], "additionalProperties": false },
|
|
798
|
-
addRefRule: { "type": "object", "properties": { "extent": { "enum": ["ref", "rows"] }, "pattern": { "type": "string" }, "settings": { "type": "object", "properties": { "consequence": { "enum": ["open", "merge-only", "locked-rows-only"] }, "requireProposal": { "type": "boolean" }, "requiredApprovals": { "type": "
|
|
799
|
+
addRefRule: { "type": "object", "properties": { "extent": { "enum": ["ref", "rows"] }, "pattern": { "type": "string" }, "settings": { "type": "object", "properties": { "consequence": { "enum": ["open", "merge-only", "locked-rows-only"] }, "requireProposal": { "type": "boolean" }, "requiredApprovals": { "type": "integer" }, "approverMinRole": { "oneOf": [{ "const": "contributor" }, { "const": "maintainer" }, { "const": "owner" }, { "type": "null" }] }, "restrictDeletions": { "type": "boolean" }, "approvers": { "type": "array", "items": { "type": "string" } }, "bypass": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "role" }, "roleKey": { "enum": ["contributor", "maintainer", "owner"] } }, "required": ["kind", "roleKey"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "person" }, "personId": { "type": "string" } }, "required": ["kind", "personId"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "service" }, "serviceIdentityId": { "type": "string" } }, "required": ["kind", "serviceIdentityId"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "client" }, "clientId": { "type": "string" } }, "required": ["kind", "clientId"], "additionalProperties": false }] } } }, "required": [], "additionalProperties": false } }, "required": ["extent", "pattern"], "additionalProperties": false },
|
|
799
800
|
listRefRules: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
800
801
|
removeRefRule: { "type": "object", "properties": { "ruleId": { "type": "string" } }, "required": ["ruleId"], "additionalProperties": false },
|
|
801
|
-
updateRefRule: { "type": "object", "properties": { "ruleId": { "type": "string" }, "settings": { "type": "object", "properties": { "consequence": { "enum": ["open", "merge-only", "locked-rows-only"] }, "requireProposal": { "type": "boolean" }, "requiredApprovals": { "type": "
|
|
802
|
-
addOrganisationRule: { "type": "object", "properties": { "extent": { "enum": ["ref", "rows"] }, "pattern": { "type": "string" }, "settings": { "type": "object", "properties": { "consequence": { "enum": ["open", "merge-only", "locked-rows-only"] }, "requireProposal": { "type": "boolean" }, "requiredApprovals": { "type": "
|
|
802
|
+
updateRefRule: { "type": "object", "properties": { "ruleId": { "type": "string" }, "settings": { "type": "object", "properties": { "consequence": { "enum": ["open", "merge-only", "locked-rows-only"] }, "requireProposal": { "type": "boolean" }, "requiredApprovals": { "type": "integer" }, "approverMinRole": { "oneOf": [{ "const": "contributor" }, { "const": "maintainer" }, { "const": "owner" }, { "type": "null" }] }, "restrictDeletions": { "type": "boolean" }, "approvers": { "type": "array", "items": { "type": "string" } }, "bypass": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "role" }, "roleKey": { "enum": ["contributor", "maintainer", "owner"] } }, "required": ["kind", "roleKey"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "person" }, "personId": { "type": "string" } }, "required": ["kind", "personId"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "service" }, "serviceIdentityId": { "type": "string" } }, "required": ["kind", "serviceIdentityId"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "client" }, "clientId": { "type": "string" } }, "required": ["kind", "clientId"], "additionalProperties": false }] } } }, "required": [], "additionalProperties": false } }, "required": ["ruleId", "settings"], "additionalProperties": false },
|
|
803
|
+
addOrganisationRule: { "type": "object", "properties": { "extent": { "enum": ["ref", "rows"] }, "pattern": { "type": "string" }, "settings": { "type": "object", "properties": { "consequence": { "enum": ["open", "merge-only", "locked-rows-only"] }, "requireProposal": { "type": "boolean" }, "requiredApprovals": { "type": "integer" }, "approverMinRole": { "oneOf": [{ "const": "contributor" }, { "const": "maintainer" }, { "const": "owner" }, { "type": "null" }] }, "restrictDeletions": { "type": "boolean" }, "approvers": { "type": "array", "items": { "type": "string" } }, "bypass": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "role" }, "roleKey": { "enum": ["contributor", "maintainer", "owner"] } }, "required": ["kind", "roleKey"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "person" }, "personId": { "type": "string" } }, "required": ["kind", "personId"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "service" }, "serviceIdentityId": { "type": "string" } }, "required": ["kind", "serviceIdentityId"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "client" }, "clientId": { "type": "string" } }, "required": ["kind", "clientId"], "additionalProperties": false }] } } }, "required": [], "additionalProperties": false } }, "required": ["extent", "pattern"], "additionalProperties": false },
|
|
803
804
|
listOrganisationRules: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
804
805
|
removeOrganisationRule: { "type": "object", "properties": { "ruleId": { "type": "string" } }, "required": ["ruleId"], "additionalProperties": false },
|
|
805
|
-
updateOrganisationRule: { "type": "object", "properties": { "ruleId": { "type": "string" }, "settings": { "type": "object", "properties": { "consequence": { "enum": ["open", "merge-only", "locked-rows-only"] }, "requireProposal": { "type": "boolean" }, "requiredApprovals": { "type": "
|
|
806
|
+
updateOrganisationRule: { "type": "object", "properties": { "ruleId": { "type": "string" }, "settings": { "type": "object", "properties": { "consequence": { "enum": ["open", "merge-only", "locked-rows-only"] }, "requireProposal": { "type": "boolean" }, "requiredApprovals": { "type": "integer" }, "approverMinRole": { "oneOf": [{ "const": "contributor" }, { "const": "maintainer" }, { "const": "owner" }, { "type": "null" }] }, "restrictDeletions": { "type": "boolean" }, "approvers": { "type": "array", "items": { "type": "string" } }, "bypass": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "role" }, "roleKey": { "enum": ["contributor", "maintainer", "owner"] } }, "required": ["kind", "roleKey"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "person" }, "personId": { "type": "string" } }, "required": ["kind", "personId"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "service" }, "serviceIdentityId": { "type": "string" } }, "required": ["kind", "serviceIdentityId"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "client" }, "clientId": { "type": "string" } }, "required": ["kind", "clientId"], "additionalProperties": false }] } } }, "required": [], "additionalProperties": false } }, "required": ["ruleId", "settings"], "additionalProperties": false },
|
|
806
807
|
createOrganisationRef: { "type": "object", "properties": { "name": { "type": "string" }, "readOnly": { "type": "boolean" } }, "required": ["name"], "additionalProperties": false },
|
|
807
808
|
listOrganisationRefs: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
808
809
|
deleteOrganisationRef: { "type": "object", "properties": { "name": { "type": "string" } }, "required": ["name"], "additionalProperties": false },
|
|
@@ -827,17 +828,17 @@ var SCHEMAS = {
|
|
|
827
828
|
readCurrentChangeSet: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
828
829
|
readChangeSet: { "type": "object", "properties": { "changeSetId": { "type": "string" } }, "required": ["changeSetId"], "additionalProperties": false },
|
|
829
830
|
readChangeSetState: { "type": "object", "properties": { "changeSetId": { "type": "string" } }, "required": ["changeSetId"], "additionalProperties": false },
|
|
830
|
-
reviseChangeSet: { "type": "object", "properties": { "changeSetId": { "type": "string" }, "expectedRevision": { "type": "string" }, "changes": { "type": "object", "additionalProperties": { "oneOf": [{ "type": "object", "properties": { "typeCategory": { "const": "object" }, "typeKey": { "type": "string" }, "version": { "type": "number" }, "displayName": { "type": "string" }, "description": { "oneOf": [{ "type": "string" }, { "type": "null" }] }, "schemaLanguageVersion": { "type": "string" }, "propertyDefinitions": { "type": "object", "additionalProperties": {} }, "requiredPropertyKeys": { "type": "array", "items": { "type": "string" } }, "presentationBindings": { "type": "object", "properties": { "views": { "type": "object", "properties": { "object": { "type": "object", "properties": { "root": { "type": "string" }, "elements": { "type": "object", "additionalProperties": { "type": "object", "properties": { "type": { "type": "string" }, "props": { "type": "object", "additionalProperties": {} }, "children": { "type": "array", "items": { "type": "string" } }, "repeat": { "type": "object", "properties": { "statePath": { "type": "string" }, "key": { "type": "string" } }, "required": ["statePath"], "additionalProperties": false }, "on": { "type": "object", "properties": { "press": { "oneOf": [{ "type": "object", "properties": { "action": { "const": "set-properties" }, "params": { "type": "object", "properties": { "properties": { "type": "object", "additionalProperties": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }, { "type": "null" }, { "type": "object", "properties": { "$state": { "type": "string" } }, "required": ["$state"], "additionalProperties": false }] } } }, "required": ["properties"], "additionalProperties": false } }, "required": ["action", "params"], "additionalProperties": false }, { "type": "object", "properties": { "action": { "const": "run-verb" }, "params": { "type": "object", "properties": { "verb": { "type": "string" } }, "required": ["verb"], "additionalProperties": false } }, "required": ["action", "params"], "additionalProperties": false }] } }, "required": ["press"], "additionalProperties": false } }, "required": ["type", "props", "children"], "additionalProperties": false } } }, "required": ["root", "elements"], "additionalProperties": false }, "app": { "type": "object", "properties": { "root": { "type": "string" }, "elements": { "type": "object", "additionalProperties": { "type": "object", "properties": { "type": { "type": "string" }, "props": { "type": "object", "additionalProperties": {} }, "children": { "type": "array", "items": { "type": "string" } }, "repeat": { "type": "object", "properties": { "statePath": { "type": "string" }, "key": { "type": "string" } }, "required": ["statePath"], "additionalProperties": false }, "on": { "type": "object", "properties": { "press": { "oneOf": [{ "type": "object", "properties": { "action": { "const": "set-properties" }, "params": { "type": "object", "properties": { "properties": { "type": "object", "additionalProperties": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }, { "type": "null" }, { "type": "object", "properties": { "$state": { "type": "string" } }, "required": ["$state"], "additionalProperties": false }] } } }, "required": ["properties"], "additionalProperties": false } }, "required": ["action", "params"], "additionalProperties": false }, { "type": "object", "properties": { "action": { "const": "run-verb" }, "params": { "type": "object", "properties": { "verb": { "type": "string" } }, "required": ["verb"], "additionalProperties": false } }, "required": ["action", "params"], "additionalProperties": false }] } }, "required": ["press"], "additionalProperties": false } }, "required": ["type", "props", "children"], "additionalProperties": false } } }, "required": ["root", "elements"], "additionalProperties": false }, "card": { "type": "object", "properties": { "root": { "type": "string" }, "elements": { "type": "object", "additionalProperties": { "type": "object", "properties": { "type": { "type": "string" }, "props": { "type": "object", "additionalProperties": {} }, "children": { "type": "array", "items": { "type": "string" } }, "repeat": { "type": "object", "properties": { "statePath": { "type": "string" }, "key": { "type": "string" } }, "required": ["statePath"], "additionalProperties": false }, "on": { "type": "object", "properties": { "press": { "oneOf": [{ "type": "object", "properties": { "action": { "const": "set-properties" }, "params": { "type": "object", "properties": { "properties": { "type": "object", "additionalProperties": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }, { "type": "null" }, { "type": "object", "properties": { "$state": { "type": "string" } }, "required": ["$state"], "additionalProperties": false }] } } }, "required": ["properties"], "additionalProperties": false } }, "required": ["action", "params"], "additionalProperties": false }, { "type": "object", "properties": { "action": { "const": "run-verb" }, "params": { "type": "object", "properties": { "verb": { "type": "string" } }, "required": ["verb"], "additionalProperties": false } }, "required": ["action", "params"], "additionalProperties": false }] } }, "required": ["press"], "additionalProperties": false } }, "required": ["type", "props", "children"], "additionalProperties": false } } }, "required": ["root", "elements"], "additionalProperties": false } }, "required": [], "additionalProperties": false }, "title": { "type": "string" }, "summary": { "type": "string" }, "icon": { "type": "string" }, "typeIcon": { "type": "string" }, "propertyLabels": { "type": "object", "additionalProperties": { "type": "string" } }, "propertyOrder": { "type": "array", "items": { "type": "string" } }, "rail": { "type": "object", "properties": { "group": { "type": "string" }, "order": { "type": "number" } }, "required": ["group", "order"], "additionalProperties": false } }, "required": [], "additionalProperties": false }, "structureDeclaration": { "type": "object", "properties": { "relationships": { "type": "array", "items": { "type": "string" } }, "views": { "type": "array", "items": { "type": "object", "properties": { "key": { "type": "string" }, "label": { "type": "string" }, "steps": { "type": "array", "items": { "type": "string" } }, "decoration": { "type": "array", "items": { "type": "object", "properties": { "key": { "type": "string" }, "label": { "type": "string" } }, "required": ["key", "label"], "additionalProperties": false } } }, "required": ["key", "label", "steps"], "additionalProperties": false } } }, "required": [], "additionalProperties": false }, "bodyFormat": { "const": "markdown" }, "subscriptionRoles": { "type": "object", "properties": { "owner": { "type": "object", "properties": { "max": { "type": "number" } }, "required": [], "additionalProperties": false }, "approver": { "type": "object", "properties": { "max": { "type": "number" } }, "required": [], "additionalProperties": false }, "watcher": { "type": "object", "properties": { "max": { "type": "number" } }, "required": [], "additionalProperties": false } }, "required": [], "additionalProperties": false } }, "required": ["typeCategory", "typeKey", "version", "displayName", "description", "schemaLanguageVersion", "propertyDefinitions", "requiredPropertyKeys"], "additionalProperties": false }, { "type": "object", "properties": { "typeCategory": { "const": "edge" }, "typeKey": { "type": "string" }, "version": { "type": "number" }, "displayName": { "type": "string" }, "sourceObjectType": { "type": "string" }, "targetObjectType": { "type": "string" }, "kind": { "enum": ["structural", "traceability"] }, "subjectEnd": { "enum": ["source", "target"] }, "parentEnd": { "oneOf": [{ "const": "source" }, { "const": "target" }, { "type": "null" }] }, "sourceLabel": { "type": "string" }, "targetLabel": { "type": "string" }, "schemaLanguageVersion": { "type": "string" }, "propertyDefinitions": { "type": "object", "additionalProperties": {} }, "requiredPropertyKeys": { "type": "array", "items": { "type": "string" } }, "readRule": { "enum": ["both-endpoints", "either-endpoint"] }, "writeRule": { "enum": ["both-endpoints", "either-endpoint"] }, "review": { "type": "object", "properties": { "upstream": { "enum": ["source", "target"] }, "significant": { "type": "array", "items": { "type": "string" } }, "newLinks": { "enum": ["cleared", "unreviewed"] }, "propagation": { "enum": ["direct", "chain"] }, "chainDepth": { "type": "number" } }, "required": ["upstream"], "additionalProperties": false } }, "required": ["typeCategory", "typeKey", "version", "displayName", "sourceObjectType", "targetObjectType", "kind", "subjectEnd", "parentEnd", "sourceLabel", "targetLabel", "schemaLanguageVersion", "propertyDefinitions", "requiredPropertyKeys", "readRule", "writeRule"], "additionalProperties": false }, { "type": "object", "properties": { "typeCategory": { "const": "verb" }, "typeKey": { "type": "string" }, "version": { "type": "number" }, "displayName": { "type": "string" }, "description": { "oneOf": [{ "type": "string" }, { "type": "null" }] }, "allowedSubjectTypes": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "none" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "types" }, "types": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "types"], "additionalProperties": false }] }, "inputSchema": {}, "resultSchema": {}, "handlerKey": { "type": "string" }, "template": { "type": "object", "properties": { "query": { "type": "object", "properties": { "typeKey": { "type": "string" }, "filters": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": ["=", ">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "literal" }, "value": {} }, "required": ["slot", "value"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "literal" }, "value": {} }, "required": ["slot", "value"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "literal" }, "value": {} }, "required": ["slot", "value"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }] }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }] } }, "sort": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["kind", "property", "direction"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["kind", "direction"], "additionalProperties": false }] }, "limit": { "type": "number" } }, "required": ["typeKey", "limit"], "additionalProperties": false }, "operations": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "create-object" }, "typeKey": { "type": "string" }, "properties": { "type": "object", "additionalProperties": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "literal" }, "value": {} }, "required": ["slot", "value"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "item" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "step" }, "index": { "type": "number" } }, "required": ["slot", "index"], "additionalProperties": false }] } } }, "required": ["kind", "typeKey", "properties"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "update-object" }, "typeKey": { "type": "string" }, "target": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "item" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "step" }, "index": { "type": "number" } }, "required": ["slot", "index"], "additionalProperties": false }] }, "changes": { "type": "object", "additionalProperties": { "type": "object", "properties": { "from": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "literal" }, "value": {} }, "required": ["slot", "value"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "item" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "step" }, "index": { "type": "number" } }, "required": ["slot", "index"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "absent" } }, "required": ["slot"], "additionalProperties": false }] }, "to": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "literal" }, "value": {} }, "required": ["slot", "value"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "item" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "step" }, "index": { "type": "number" } }, "required": ["slot", "index"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "absent" } }, "required": ["slot"], "additionalProperties": false }] } }, "required": ["from", "to"], "additionalProperties": false } } }, "required": ["kind", "typeKey", "target", "changes"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "delete-object" }, "typeKey": { "type": "string" }, "target": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "item" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "step" }, "index": { "type": "number" } }, "required": ["slot", "index"], "additionalProperties": false }] } }, "required": ["kind", "typeKey", "target"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "create-edge" }, "typeKey": { "type": "string" }, "source": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "item" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "step" }, "index": { "type": "number" } }, "required": ["slot", "index"], "additionalProperties": false }] }, "target": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "item" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "step" }, "index": { "type": "number" } }, "required": ["slot", "index"], "additionalProperties": false }] }, "properties": { "type": "object", "additionalProperties": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "literal" }, "value": {} }, "required": ["slot", "value"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "item" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "step" }, "index": { "type": "number" } }, "required": ["slot", "index"], "additionalProperties": false }] } } }, "required": ["kind", "typeKey", "source", "target", "properties"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "delete-edge" }, "typeKey": { "type": "string" }, "target": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "item" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "step" }, "index": { "type": "number" } }, "required": ["slot", "index"], "additionalProperties": false }] } }, "required": ["kind", "typeKey", "target"], "additionalProperties": false }] } } }, "required": ["operations"], "additionalProperties": false }, "schemaLanguageVersion": { "type": "string" } }, "required": ["typeCategory", "typeKey", "version", "displayName", "description", "allowedSubjectTypes", "inputSchema", "resultSchema", "schemaLanguageVersion"], "additionalProperties": false }] } }, "railGroups": { "type": "array", "items": { "type": "string" } } }, "required": ["changeSetId", "expectedRevision", "changes"], "additionalProperties": false },
|
|
831
|
+
reviseChangeSet: { "type": "object", "properties": { "changeSetId": { "type": "string" }, "expectedRevision": { "type": "string" }, "changes": { "type": "object", "additionalProperties": { "oneOf": [{ "type": "object", "properties": { "typeCategory": { "const": "object" }, "typeKey": { "type": "string" }, "version": { "type": "integer" }, "displayName": { "type": "string" }, "description": { "oneOf": [{ "type": "string" }, { "type": "null" }] }, "schemaLanguageVersion": { "type": "string" }, "propertyDefinitions": { "type": "object", "additionalProperties": {} }, "requiredPropertyKeys": { "type": "array", "items": { "type": "string" } }, "presentationBindings": { "type": "object", "properties": { "views": { "type": "object", "properties": { "object": { "type": "object", "properties": { "root": { "type": "string" }, "elements": { "type": "object", "additionalProperties": { "type": "object", "properties": { "type": { "type": "string" }, "props": { "type": "object", "additionalProperties": {} }, "children": { "type": "array", "items": { "type": "string" } }, "repeat": { "type": "object", "properties": { "statePath": { "type": "string" }, "key": { "type": "string" } }, "required": ["statePath"], "additionalProperties": false }, "on": { "type": "object", "properties": { "press": { "oneOf": [{ "type": "object", "properties": { "action": { "const": "set-properties" }, "params": { "type": "object", "properties": { "properties": { "type": "object", "additionalProperties": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }, { "type": "null" }, { "type": "object", "properties": { "$state": { "type": "string" } }, "required": ["$state"], "additionalProperties": false }] } } }, "required": ["properties"], "additionalProperties": false } }, "required": ["action", "params"], "additionalProperties": false }, { "type": "object", "properties": { "action": { "const": "run-verb" }, "params": { "type": "object", "properties": { "verb": { "type": "string" } }, "required": ["verb"], "additionalProperties": false } }, "required": ["action", "params"], "additionalProperties": false }] } }, "required": ["press"], "additionalProperties": false } }, "required": ["type", "props", "children"], "additionalProperties": false } } }, "required": ["root", "elements"], "additionalProperties": false }, "app": { "type": "object", "properties": { "root": { "type": "string" }, "elements": { "type": "object", "additionalProperties": { "type": "object", "properties": { "type": { "type": "string" }, "props": { "type": "object", "additionalProperties": {} }, "children": { "type": "array", "items": { "type": "string" } }, "repeat": { "type": "object", "properties": { "statePath": { "type": "string" }, "key": { "type": "string" } }, "required": ["statePath"], "additionalProperties": false }, "on": { "type": "object", "properties": { "press": { "oneOf": [{ "type": "object", "properties": { "action": { "const": "set-properties" }, "params": { "type": "object", "properties": { "properties": { "type": "object", "additionalProperties": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }, { "type": "null" }, { "type": "object", "properties": { "$state": { "type": "string" } }, "required": ["$state"], "additionalProperties": false }] } } }, "required": ["properties"], "additionalProperties": false } }, "required": ["action", "params"], "additionalProperties": false }, { "type": "object", "properties": { "action": { "const": "run-verb" }, "params": { "type": "object", "properties": { "verb": { "type": "string" } }, "required": ["verb"], "additionalProperties": false } }, "required": ["action", "params"], "additionalProperties": false }] } }, "required": ["press"], "additionalProperties": false } }, "required": ["type", "props", "children"], "additionalProperties": false } } }, "required": ["root", "elements"], "additionalProperties": false }, "card": { "type": "object", "properties": { "root": { "type": "string" }, "elements": { "type": "object", "additionalProperties": { "type": "object", "properties": { "type": { "type": "string" }, "props": { "type": "object", "additionalProperties": {} }, "children": { "type": "array", "items": { "type": "string" } }, "repeat": { "type": "object", "properties": { "statePath": { "type": "string" }, "key": { "type": "string" } }, "required": ["statePath"], "additionalProperties": false }, "on": { "type": "object", "properties": { "press": { "oneOf": [{ "type": "object", "properties": { "action": { "const": "set-properties" }, "params": { "type": "object", "properties": { "properties": { "type": "object", "additionalProperties": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }, { "type": "null" }, { "type": "object", "properties": { "$state": { "type": "string" } }, "required": ["$state"], "additionalProperties": false }] } } }, "required": ["properties"], "additionalProperties": false } }, "required": ["action", "params"], "additionalProperties": false }, { "type": "object", "properties": { "action": { "const": "run-verb" }, "params": { "type": "object", "properties": { "verb": { "type": "string" } }, "required": ["verb"], "additionalProperties": false } }, "required": ["action", "params"], "additionalProperties": false }] } }, "required": ["press"], "additionalProperties": false } }, "required": ["type", "props", "children"], "additionalProperties": false } } }, "required": ["root", "elements"], "additionalProperties": false } }, "required": [], "additionalProperties": false }, "title": { "type": "string" }, "summary": { "type": "string" }, "icon": { "type": "string" }, "typeIcon": { "type": "string" }, "propertyLabels": { "type": "object", "additionalProperties": { "type": "string" } }, "propertyOrder": { "type": "array", "items": { "type": "string" } }, "rail": { "type": "object", "properties": { "group": { "type": "string" }, "order": { "type": "number" } }, "required": ["group", "order"], "additionalProperties": false } }, "required": [], "additionalProperties": false }, "structureDeclaration": { "type": "object", "properties": { "relationships": { "type": "array", "items": { "type": "string" } }, "views": { "type": "array", "items": { "type": "object", "properties": { "key": { "type": "string" }, "label": { "type": "string" }, "steps": { "type": "array", "items": { "type": "string" } }, "decoration": { "type": "array", "items": { "type": "object", "properties": { "key": { "type": "string" }, "label": { "type": "string" } }, "required": ["key", "label"], "additionalProperties": false } } }, "required": ["key", "label", "steps"], "additionalProperties": false } } }, "required": [], "additionalProperties": false }, "bodyFormat": { "const": "markdown" }, "subscriptionRoles": { "type": "object", "properties": { "owner": { "type": "object", "properties": { "max": { "type": "number" } }, "required": [], "additionalProperties": false }, "approver": { "type": "object", "properties": { "max": { "type": "number" } }, "required": [], "additionalProperties": false }, "watcher": { "type": "object", "properties": { "max": { "type": "number" } }, "required": [], "additionalProperties": false } }, "required": [], "additionalProperties": false } }, "required": ["typeCategory", "typeKey", "version", "displayName", "description", "schemaLanguageVersion", "propertyDefinitions", "requiredPropertyKeys"], "additionalProperties": false }, { "type": "object", "properties": { "typeCategory": { "const": "edge" }, "typeKey": { "type": "string" }, "version": { "type": "integer" }, "displayName": { "type": "string" }, "sourceObjectType": { "type": "string" }, "targetObjectType": { "type": "string" }, "kind": { "enum": ["structural", "traceability"] }, "subjectEnd": { "enum": ["source", "target"] }, "parentEnd": { "oneOf": [{ "const": "source" }, { "const": "target" }, { "type": "null" }] }, "sourceLabel": { "type": "string" }, "targetLabel": { "type": "string" }, "schemaLanguageVersion": { "type": "string" }, "propertyDefinitions": { "type": "object", "additionalProperties": {} }, "requiredPropertyKeys": { "type": "array", "items": { "type": "string" } }, "readRule": { "enum": ["both-endpoints", "either-endpoint"] }, "writeRule": { "enum": ["both-endpoints", "either-endpoint"] }, "review": { "type": "object", "properties": { "upstream": { "enum": ["source", "target"] }, "significant": { "type": "array", "items": { "type": "string" } }, "newLinks": { "enum": ["cleared", "unreviewed"] }, "propagation": { "enum": ["direct", "chain"] }, "chainDepth": { "type": "number" } }, "required": ["upstream"], "additionalProperties": false } }, "required": ["typeCategory", "typeKey", "version", "displayName", "sourceObjectType", "targetObjectType", "kind", "subjectEnd", "parentEnd", "sourceLabel", "targetLabel", "schemaLanguageVersion", "propertyDefinitions", "requiredPropertyKeys", "readRule", "writeRule"], "additionalProperties": false }, { "type": "object", "properties": { "typeCategory": { "const": "verb" }, "typeKey": { "type": "string" }, "version": { "type": "integer" }, "displayName": { "type": "string" }, "description": { "oneOf": [{ "type": "string" }, { "type": "null" }] }, "allowedSubjectTypes": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "none" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "types" }, "types": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "types"], "additionalProperties": false }] }, "inputSchema": {}, "resultSchema": {}, "handlerKey": { "type": "string" }, "template": { "type": "object", "properties": { "query": { "type": "object", "properties": { "typeKey": { "type": "string" }, "filters": { "type": "array", "items": { "anyOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "enum": ["=", ">", ">=", "<", "<="] }, "value": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "literal" }, "value": {} }, "required": ["slot", "value"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }] } }, "required": ["kind", "property", "op", "value"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "op": { "const": "in" }, "values": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "literal" }, "value": {} }, "required": ["slot", "value"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }] } } }, "required": ["kind", "property", "op", "values"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "text" }, "term": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "literal" }, "value": {} }, "required": ["slot", "value"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }] }, "properties": { "type": "array", "items": { "type": "string" } } }, "required": ["kind", "term"], "additionalProperties": false }] } }, "sort": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "property" }, "property": { "type": "string" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["kind", "property", "direction"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "identity" }, "direction": { "enum": ["asc", "desc"] } }, "required": ["kind", "direction"], "additionalProperties": false }] }, "limit": { "type": "integer" } }, "required": ["typeKey", "limit"], "additionalProperties": false }, "operations": { "type": "array", "items": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "create-object" }, "typeKey": { "type": "string" }, "properties": { "type": "object", "additionalProperties": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "literal" }, "value": {} }, "required": ["slot", "value"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "item" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "step" }, "index": { "type": "integer" } }, "required": ["slot", "index"], "additionalProperties": false }] } } }, "required": ["kind", "typeKey", "properties"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "update-object" }, "typeKey": { "type": "string" }, "target": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "item" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "step" }, "index": { "type": "integer" } }, "required": ["slot", "index"], "additionalProperties": false }] }, "changes": { "type": "object", "additionalProperties": { "type": "object", "properties": { "from": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "literal" }, "value": {} }, "required": ["slot", "value"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "item" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "step" }, "index": { "type": "integer" } }, "required": ["slot", "index"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "absent" } }, "required": ["slot"], "additionalProperties": false }] }, "to": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "literal" }, "value": {} }, "required": ["slot", "value"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "item" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "step" }, "index": { "type": "integer" } }, "required": ["slot", "index"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "absent" } }, "required": ["slot"], "additionalProperties": false }] } }, "required": ["from", "to"], "additionalProperties": false } } }, "required": ["kind", "typeKey", "target", "changes"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "delete-object" }, "typeKey": { "type": "string" }, "target": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "item" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "step" }, "index": { "type": "integer" } }, "required": ["slot", "index"], "additionalProperties": false }] } }, "required": ["kind", "typeKey", "target"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "create-edge" }, "typeKey": { "type": "string" }, "source": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "item" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "step" }, "index": { "type": "integer" } }, "required": ["slot", "index"], "additionalProperties": false }] }, "target": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "item" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "step" }, "index": { "type": "integer" } }, "required": ["slot", "index"], "additionalProperties": false }] }, "properties": { "type": "object", "additionalProperties": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "literal" }, "value": {} }, "required": ["slot", "value"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "item" }, "property": { "type": "string" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "step" }, "index": { "type": "integer" } }, "required": ["slot", "index"], "additionalProperties": false }] } } }, "required": ["kind", "typeKey", "source", "target", "properties"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "delete-edge" }, "typeKey": { "type": "string" }, "target": { "oneOf": [{ "type": "object", "properties": { "slot": { "const": "input" }, "key": { "type": "string" } }, "required": ["slot", "key"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "subject" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "item" } }, "required": ["slot"], "additionalProperties": false }, { "type": "object", "properties": { "slot": { "const": "step" }, "index": { "type": "integer" } }, "required": ["slot", "index"], "additionalProperties": false }] } }, "required": ["kind", "typeKey", "target"], "additionalProperties": false }] } } }, "required": ["operations"], "additionalProperties": false }, "schemaLanguageVersion": { "type": "string" } }, "required": ["typeCategory", "typeKey", "version", "displayName", "description", "allowedSubjectTypes", "inputSchema", "resultSchema", "schemaLanguageVersion"], "additionalProperties": false }] } }, "railGroups": { "type": "array", "items": { "type": "string" } } }, "required": ["changeSetId", "expectedRevision", "changes"], "additionalProperties": false },
|
|
831
832
|
validateChangeSet: { "type": "object", "properties": { "changeSetId": { "type": "string" }, "revision": { "type": "string" } }, "required": ["changeSetId", "revision"], "additionalProperties": false },
|
|
832
833
|
discardChangeSet: { "type": "object", "properties": { "changeSetId": { "type": "string" } }, "required": ["changeSetId"], "additionalProperties": false },
|
|
833
834
|
acceptChangeSet: { "type": "object", "properties": { "changeSetId": { "type": "string" }, "revision": { "type": "string" }, "correlationId": { "type": "string" } }, "required": ["changeSetId", "revision"], "additionalProperties": false },
|
|
834
|
-
readApp: { "type": "object", "properties": { "appKey": { "type": "string" }, "version": { "type": "
|
|
835
|
+
readApp: { "type": "object", "properties": { "appKey": { "type": "string" }, "version": { "type": "integer" } }, "required": ["appKey"], "additionalProperties": false },
|
|
835
836
|
openAppDraft: { "type": "object", "properties": { "appKey": { "type": "string" } }, "required": ["appKey"], "additionalProperties": false },
|
|
836
|
-
readAppDraft: { "oneOf": [{ "type": "object", "properties": { "appDraftId": { "type": "string" } }, "required": ["appDraftId"], "additionalProperties": false }, { "type": "object", "properties": { "appKey": { "type": "string" } }, "required": ["appKey"], "additionalProperties": false }] },
|
|
837
|
-
reviseAppDraft: { "type": "object", "properties": { "appDraftId": { "type": "string" }, "revision": { "type": "
|
|
838
|
-
acceptAppDraft: { "type": "object", "properties": { "appDraftId": { "type": "string" }, "revision": { "type": "
|
|
837
|
+
readAppDraft: { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "draft" }, "appDraftId": { "type": "string" } }, "required": ["kind", "appDraftId"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "app" }, "appKey": { "type": "string" } }, "required": ["kind", "appKey"], "additionalProperties": false }] },
|
|
838
|
+
reviseAppDraft: { "type": "object", "properties": { "appDraftId": { "type": "string" }, "revision": { "type": "integer" }, "document": { "type": "object", "properties": { "title": { "type": "string" }, "rail": { "type": "object", "properties": { "group": { "type": "string" }, "order": { "type": "number" } }, "required": ["group", "order"], "additionalProperties": false }, "pages": { "type": "array", "items": { "type": "object", "properties": { "key": { "type": "string" }, "title": { "type": "string" }, "view": { "type": "object", "properties": { "root": { "type": "string" }, "elements": { "type": "object", "additionalProperties": { "type": "object", "properties": { "type": { "type": "string" }, "props": { "type": "object", "additionalProperties": {} }, "children": { "type": "array", "items": { "type": "string" } }, "repeat": { "type": "object", "properties": { "statePath": { "type": "string" }, "key": { "type": "string" } }, "required": ["statePath"], "additionalProperties": false }, "on": { "type": "object", "properties": { "press": { "oneOf": [{ "type": "object", "properties": { "action": { "const": "set-properties" }, "params": { "type": "object", "properties": { "properties": { "type": "object", "additionalProperties": { "oneOf": [{ "type": "string" }, { "type": "number" }, { "type": "boolean" }, { "type": "null" }, { "type": "object", "properties": { "$state": { "type": "string" } }, "required": ["$state"], "additionalProperties": false }] } } }, "required": ["properties"], "additionalProperties": false } }, "required": ["action", "params"], "additionalProperties": false }, { "type": "object", "properties": { "action": { "const": "run-verb" }, "params": { "type": "object", "properties": { "verb": { "type": "string" } }, "required": ["verb"], "additionalProperties": false } }, "required": ["action", "params"], "additionalProperties": false }] } }, "required": ["press"], "additionalProperties": false } }, "required": ["type", "props", "children"], "additionalProperties": false } } }, "required": ["root", "elements"], "additionalProperties": false } }, "required": ["key", "title", "view"], "additionalProperties": false } } }, "required": ["title", "pages"], "additionalProperties": false } }, "required": ["appDraftId", "revision", "document"], "additionalProperties": false },
|
|
839
|
+
acceptAppDraft: { "type": "object", "properties": { "appDraftId": { "type": "string" }, "revision": { "type": "integer" } }, "required": ["appDraftId", "revision"], "additionalProperties": false },
|
|
839
840
|
listApps: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
840
|
-
validateAppDraft: { "type": "object", "properties": { "appDraftId": { "type": "string" }, "revision": { "type": "
|
|
841
|
+
validateAppDraft: { "type": "object", "properties": { "appDraftId": { "type": "string" }, "revision": { "type": "integer" } }, "required": ["appDraftId", "revision"], "additionalProperties": false },
|
|
841
842
|
discardAppDraft: { "type": "object", "properties": { "appDraftId": { "type": "string" } }, "required": ["appDraftId"], "additionalProperties": false },
|
|
842
843
|
searchPeople: { "type": "object", "properties": { "query": { "type": "string" } }, "required": ["query"], "additionalProperties": false },
|
|
843
844
|
searchObjectReaders: { "type": "object", "properties": { "objectId": { "type": "string" }, "prefix": { "type": "string" } }, "required": ["objectId"], "additionalProperties": false },
|
|
@@ -854,16 +855,16 @@ var SCHEMAS = {
|
|
|
854
855
|
readDraftLock: { "type": "object", "properties": { "objectId": { "type": "string" } }, "required": ["objectId"], "additionalProperties": false },
|
|
855
856
|
restoreDraft: { "type": "object", "properties": { "trashId": { "type": "string" }, "newRefName": { "type": "string" } }, "required": ["trashId", "newRefName"], "additionalProperties": false },
|
|
856
857
|
setCommentResolved: { "type": "object", "properties": { "commentId": { "type": "string" }, "resolved": { "type": "boolean" } }, "required": ["commentId", "resolved"], "additionalProperties": false },
|
|
857
|
-
addComment: { "type": "object", "properties": { "objectId": { "type": "string" }, "body": { "type": "string" }, "mentions": { "type": "array", "items": { "type": "object", "properties": { "from": { "type": "
|
|
858
|
+
addComment: { "type": "object", "properties": { "objectId": { "type": "string" }, "body": { "type": "string" }, "mentions": { "type": "array", "items": { "type": "object", "properties": { "from": { "type": "integer" }, "to": { "type": "integer" }, "person": { "type": "object", "properties": { "kind": { "const": "person" }, "id": { "type": "string" } }, "required": ["kind", "id"], "additionalProperties": false } }, "required": ["from", "to", "person"], "additionalProperties": false } }, "anchor": { "type": "object", "properties": { "blockId": { "type": "string" }, "from": { "type": "integer" }, "to": { "type": "integer" }, "exact": { "type": "string" }, "prefix": { "type": "string" }, "suffix": { "type": "string" } }, "required": ["blockId", "from", "to", "exact", "prefix", "suffix"], "additionalProperties": false }, "correlationId": { "type": "string" } }, "required": ["objectId", "body", "mentions"], "additionalProperties": false },
|
|
858
859
|
createConnection: { "type": "object", "properties": { "name": { "type": "string" }, "system": { "const": "onshape" }, "stack": { "type": "string" }, "companyId": { "oneOf": [{ "type": "string" }, { "type": "null" }] }, "selection": { "oneOf": [{ "type": "object", "properties": { "kind": { "const": "company" }, "label": { "type": "string" } }, "required": ["kind"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "team" }, "teamId": { "type": "string" }, "label": { "type": "string" } }, "required": ["kind", "teamId"], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "const": "owner" }, "ownerId": { "type": "string" }, "label": { "type": "string" } }, "required": ["kind", "ownerId"], "additionalProperties": false }] } }, "required": ["name", "system", "stack", "companyId", "selection"], "additionalProperties": false },
|
|
859
860
|
listConnections: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
860
|
-
setConnectionCredential: { "type": "object", "properties": { "credential": { "type": "object", "properties": { "kind": { "const": "api-key" }, "accessKey": { "type": "string" }, "secretKey": { "type": "string" } }, "required": ["kind", "accessKey", "secretKey"], "additionalProperties": false } }, "required": ["credential"], "additionalProperties": false },
|
|
861
|
+
setConnectionCredential: { "type": "object", "properties": { "credential": { "type": "object", "properties": { "kind": { "const": "api-key" }, "accessKey": { "type": "string", "format": "password", "writeOnly": true }, "secretKey": { "type": "string", "format": "password", "writeOnly": true } }, "required": ["kind", "accessKey", "secretKey"], "additionalProperties": false } }, "required": ["credential"], "additionalProperties": false },
|
|
861
862
|
readConnectionIdentity: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
862
863
|
draftConnectorTypes: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
863
864
|
revokeConnection: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
864
865
|
startImportRun: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
865
866
|
listImportRuns: { "type": "object", "properties": { "runId": { "type": "string" } }, "required": [], "additionalProperties": false },
|
|
866
|
-
closeImportRun: { "oneOf": [{ "type": "object", "properties": { "runId": { "type": "string" }, "outcome": { "const": "succeeded" }, "commits": { "type": "array", "items": { "type": "string" } }, "complete": { "type": "boolean" }, "sourceCheckpoint": { "oneOf": [{ "type": "
|
|
867
|
+
closeImportRun: { "oneOf": [{ "type": "object", "properties": { "runId": { "type": "string" }, "outcome": { "const": "succeeded" }, "commits": { "type": "array", "items": { "type": "string" } }, "complete": { "type": "boolean" }, "sourceCheckpoint": { "oneOf": [{ "type": "integer" }, { "type": "null" }] }, "counts": { "type": "object", "properties": { "created": { "type": "integer" }, "updated": { "type": "integer" }, "unchanged": { "type": "integer" }, "withdrawn": { "type": "integer" }, "carried": { "type": "integer" }, "overwritten": { "type": "integer" } }, "required": ["created", "updated", "unchanged", "withdrawn", "carried", "overwritten"], "additionalProperties": false } }, "required": ["runId", "outcome", "commits", "complete", "sourceCheckpoint", "counts"], "additionalProperties": false }, { "type": "object", "properties": { "runId": { "type": "string" }, "outcome": { "const": "failed" }, "failure": { "enum": ["auth", "timeout", "size", "shape", "upstream-error", "unreachable", "allowance-spent", "duplicate-identifier", "dangling-reference", "undeclared-type", "credential-unreadable", "connection-revoked", "abandoned", "apply-refused", "apply-conflict", "apply-unknown", "duplicate-upstream", "types-not-approved", "internal", "mirror-row-unreadable"] } }, "required": ["runId", "outcome", "failure"], "additionalProperties": false }] },
|
|
867
868
|
createHostedApp: { "type": "object", "properties": { "key": { "type": "string" } }, "required": ["key"], "additionalProperties": false },
|
|
868
869
|
readHostedBundle: { "type": "object", "properties": { "launchId": { "type": "string" } }, "required": ["launchId"], "additionalProperties": false },
|
|
869
870
|
listHostedApps: { "type": "object", "properties": {}, "required": [], "additionalProperties": false },
|
|
@@ -918,6 +919,8 @@ var EXAMPLES = {
|
|
|
918
919
|
enterHumanMode: {},
|
|
919
920
|
readSessionStatus: {},
|
|
920
921
|
readStepUpProof: { "pendingId": "<pendingId>" },
|
|
922
|
+
openAttachmentUpload: { "name": "<name>", "declaredLength": 1 },
|
|
923
|
+
completeAttachmentUpload: { "uploadId": "<uploadId>" },
|
|
921
924
|
readAttachment: {
|
|
922
925
|
"objectId": "<objectId>",
|
|
923
926
|
"property": "<property>"
|
|
@@ -1025,7 +1028,7 @@ var EXAMPLES = {
|
|
|
1025
1028
|
acceptChangeSet: { "changeSetId": "<changeSetId>", "revision": "<revision>" },
|
|
1026
1029
|
readApp: { "appKey": "<appKey>" },
|
|
1027
1030
|
openAppDraft: { "appKey": "<appKey>" },
|
|
1028
|
-
readAppDraft: { "appDraftId": "<appDraftId>" },
|
|
1031
|
+
readAppDraft: { "kind": "draft", "appDraftId": "<appDraftId>" },
|
|
1029
1032
|
reviseAppDraft: { "appDraftId": "<appDraftId>", "revision": 1, "document": { "title": "Example app", "pages": [{ "key": "home", "title": "Home", "view": { "root": "root", "elements": { "root": { "type": "AppBody", "props": {}, "children": ["text"] }, "text": { "type": "Text", "props": { "text": "Example page" }, "children": [] } } } }] } },
|
|
1030
1033
|
acceptAppDraft: { "appDraftId": "<appDraftId>", "revision": 1 },
|
|
1031
1034
|
listApps: {},
|
|
@@ -1072,9 +1075,10 @@ var EXAMPLES = {
|
|
|
1072
1075
|
listHostedOneWallGrants: {}
|
|
1073
1076
|
};
|
|
1074
1077
|
var ROUTE_INPUT_EXAMPLES = deepFreeze(EXAMPLES);
|
|
1078
|
+
var DESCRIPTION_ROUTES = Object.freeze(["queryRows", "queryObjects", "aggregateObjects", "queryGraph", "readStructure", "findPaths"]);
|
|
1075
1079
|
|
|
1076
1080
|
// packages/api-contract/dist/routes.js
|
|
1077
|
-
var PROTOCOL_VERSION =
|
|
1081
|
+
var PROTOCOL_VERSION = 39;
|
|
1078
1082
|
var VERSION_HEADER = "oe2-protocol-version";
|
|
1079
1083
|
var TOKEN_HEADER = "authorization";
|
|
1080
1084
|
var IDEMPOTENCY_HEADER = "oe2-idempotency-key";
|
|
@@ -1082,7 +1086,9 @@ var STEP_UP_HEADER = "oe2-step-up";
|
|
|
1082
1086
|
var STEP_UP_KEY_HEADER = "oe2-step-up-key";
|
|
1083
1087
|
var IDEMPOTENCY_KEY_PATTERN = /^[A-Za-z0-9._~-]{1,128}$/;
|
|
1084
1088
|
var STREAMED_ROUTE_NAMES = Object.freeze(["sendMessageStreamed", "answerPlanStreamed"]);
|
|
1085
|
-
var BINARY_REQUEST_ROUTE_NAMES = Object.freeze([
|
|
1089
|
+
var BINARY_REQUEST_ROUTE_NAMES = Object.freeze([
|
|
1090
|
+
"publishHostedVersion"
|
|
1091
|
+
]);
|
|
1086
1092
|
var BINARY_RESPONSE_ROUTE_NAMES = Object.freeze(["readAttachment"]);
|
|
1087
1093
|
function isBinaryRequestRoute(name) {
|
|
1088
1094
|
return BINARY_REQUEST_ROUTE_NAMES.some((binary) => binary === name);
|
|
@@ -1136,7 +1142,8 @@ var STEP_UP_ROUTE_GROUPS = Object.freeze({
|
|
|
1136
1142
|
readStepUpProof: "unmarked",
|
|
1137
1143
|
enterHumanMode: "marked",
|
|
1138
1144
|
readSessionStatus: "unmarked",
|
|
1139
|
-
|
|
1145
|
+
openAttachmentUpload: "unmarked",
|
|
1146
|
+
completeAttachmentUpload: "unmarked",
|
|
1140
1147
|
readAttachment: "unmarked",
|
|
1141
1148
|
readObject: "unmarked",
|
|
1142
1149
|
queryObjects: "unmarked",
|
|
@@ -1444,10 +1451,23 @@ var ROUTES = Object.freeze({
|
|
|
1444
1451
|
module: "sdk-core",
|
|
1445
1452
|
capability: "core.sessionStatus"
|
|
1446
1453
|
}),
|
|
1447
|
-
|
|
1448
|
-
name: "
|
|
1454
|
+
openAttachmentUpload: route({
|
|
1455
|
+
name: "openAttachmentUpload",
|
|
1456
|
+
method: "POST",
|
|
1457
|
+
path: "/attachments/upload/open",
|
|
1458
|
+
group: "write",
|
|
1459
|
+
selector: "existingObject",
|
|
1460
|
+
subject: "project",
|
|
1461
|
+
idempotent: false,
|
|
1462
|
+
policy: admittingActors("person", "service", "app:client", "agent:apply"),
|
|
1463
|
+
versioned: true,
|
|
1464
|
+
module: "objects-sdk",
|
|
1465
|
+
capability: "objects.write"
|
|
1466
|
+
}),
|
|
1467
|
+
completeAttachmentUpload: route({
|
|
1468
|
+
name: "completeAttachmentUpload",
|
|
1449
1469
|
method: "POST",
|
|
1450
|
-
path: "/attachments/
|
|
1470
|
+
path: "/attachments/upload/complete",
|
|
1451
1471
|
group: "write",
|
|
1452
1472
|
selector: "existingObject",
|
|
1453
1473
|
subject: "project",
|
|
@@ -1915,7 +1935,8 @@ var ROUTE_CARRIES_CREDENTIAL = Object.freeze({
|
|
|
1915
1935
|
readStepUpProof: true,
|
|
1916
1936
|
enterHumanMode: false,
|
|
1917
1937
|
readSessionStatus: false,
|
|
1918
|
-
|
|
1938
|
+
openAttachmentUpload: true,
|
|
1939
|
+
completeAttachmentUpload: false,
|
|
1919
1940
|
readAttachment: false,
|
|
1920
1941
|
readObject: false,
|
|
1921
1942
|
queryObjects: false,
|
|
@@ -2138,10 +2159,10 @@ var CLIENT_SCOPES = Object.freeze({
|
|
|
2138
2159
|
|
|
2139
2160
|
// packages/api-contract/dist/attachment-headers.js
|
|
2140
2161
|
var ATTACHMENT_SELECTOR_HEADER = "x-oe2-selector";
|
|
2141
|
-
var ATTACHMENT_NAME_HEADER = "x-oe2-attachment-name";
|
|
2142
2162
|
function attachmentNameHeader(name) {
|
|
2143
2163
|
return `UTF-8''${encodeURIComponent(name).replace(/[!'()*]/g, (character) => `%${character.charCodeAt(0).toString(16).toUpperCase()}`)}`;
|
|
2144
2164
|
}
|
|
2165
|
+
var ATTACHMENT_NAME_HEADER = "x-oe2-attachment-name";
|
|
2145
2166
|
|
|
2146
2167
|
// packages/api-contract/dist/actor-kind-label.js
|
|
2147
2168
|
var ACTOR_KIND_LABELS = Object.freeze({
|
|
@@ -2153,63 +2174,6 @@ var ACTOR_KIND_LABELS = Object.freeze({
|
|
|
2153
2174
|
// packages/api-contract/dist/links.js
|
|
2154
2175
|
var MAX_CLEAR_ENTRIES = 100;
|
|
2155
2176
|
|
|
2156
|
-
// packages/sdk-dispatch/dist/response.js
|
|
2157
|
-
function responseOf(status, body, reason, headers = {}) {
|
|
2158
|
-
let read = false;
|
|
2159
|
-
const claim = () => {
|
|
2160
|
-
if (read)
|
|
2161
|
-
throw new Error("the response body has already been read");
|
|
2162
|
-
read = true;
|
|
2163
|
-
};
|
|
2164
|
-
const source = async function* () {
|
|
2165
|
-
if (typeof body === "string")
|
|
2166
|
-
yield Buffer.from(body, "utf8");
|
|
2167
|
-
else if (body instanceof Uint8Array)
|
|
2168
|
-
yield body;
|
|
2169
|
-
else
|
|
2170
|
-
yield* body;
|
|
2171
|
-
};
|
|
2172
|
-
const members = {
|
|
2173
|
-
status,
|
|
2174
|
-
...reason === void 0 || reason === "" ? {} : { reason },
|
|
2175
|
-
header: (name) => {
|
|
2176
|
-
const entry2 = Object.entries(headers).find(([key]) => key.toLowerCase() === name.toLowerCase());
|
|
2177
|
-
const value = entry2?.[1];
|
|
2178
|
-
return value === void 0 ? null : typeof value === "string" || typeof value === "number" ? String(value) : value.join(", ");
|
|
2179
|
-
},
|
|
2180
|
-
bytes: () => {
|
|
2181
|
-
claim();
|
|
2182
|
-
let iterated = false;
|
|
2183
|
-
return {
|
|
2184
|
-
async *[Symbol.asyncIterator]() {
|
|
2185
|
-
if (iterated)
|
|
2186
|
-
throw new Error("the response body has already been read");
|
|
2187
|
-
iterated = true;
|
|
2188
|
-
yield* source();
|
|
2189
|
-
}
|
|
2190
|
-
};
|
|
2191
|
-
},
|
|
2192
|
-
json: async () => {
|
|
2193
|
-
claim();
|
|
2194
|
-
const chunks = [];
|
|
2195
|
-
for await (const chunk of source())
|
|
2196
|
-
chunks.push(chunk);
|
|
2197
|
-
const value = JSON.parse(Buffer.concat(chunks).toString("utf8"));
|
|
2198
|
-
return value;
|
|
2199
|
-
}
|
|
2200
|
-
};
|
|
2201
|
-
return new Proxy(members, {
|
|
2202
|
-
get(target, member) {
|
|
2203
|
-
if (member === "status" || member === "reason" || member === "json" || member === "header" || member === "bytes") {
|
|
2204
|
-
return target[member];
|
|
2205
|
-
}
|
|
2206
|
-
if (member === "then" || typeof member === "symbol")
|
|
2207
|
-
return void 0;
|
|
2208
|
-
throw new Error(`the response member ${String(member)} is not implemented`);
|
|
2209
|
-
}
|
|
2210
|
-
});
|
|
2211
|
-
}
|
|
2212
|
-
|
|
2213
2177
|
// packages/sdk-dispatch/dist/step-up.js
|
|
2214
2178
|
function stepUpHeaders(route2, attempt) {
|
|
2215
2179
|
if (!owesStepUp(route2.policy)) {
|
|
@@ -2369,6 +2333,65 @@ function unauthenticatedEnvelope() {
|
|
|
2369
2333
|
|
|
2370
2334
|
// packages/sdk-dispatch/dist/socket-transport.js
|
|
2371
2335
|
import { request } from "node:http";
|
|
2336
|
+
|
|
2337
|
+
// packages/sdk-dispatch/dist/response.js
|
|
2338
|
+
function responseOf(status, body, reason, headers = {}) {
|
|
2339
|
+
let read = false;
|
|
2340
|
+
const claim = () => {
|
|
2341
|
+
if (read)
|
|
2342
|
+
throw new Error("the response body has already been read");
|
|
2343
|
+
read = true;
|
|
2344
|
+
};
|
|
2345
|
+
const source = async function* () {
|
|
2346
|
+
if (typeof body === "string")
|
|
2347
|
+
yield Buffer.from(body, "utf8");
|
|
2348
|
+
else if (body instanceof Uint8Array)
|
|
2349
|
+
yield body;
|
|
2350
|
+
else
|
|
2351
|
+
yield* body;
|
|
2352
|
+
};
|
|
2353
|
+
const members = {
|
|
2354
|
+
status,
|
|
2355
|
+
...reason === void 0 || reason === "" ? {} : { reason },
|
|
2356
|
+
header: (name) => {
|
|
2357
|
+
const entry2 = Object.entries(headers).find(([key]) => key.toLowerCase() === name.toLowerCase());
|
|
2358
|
+
const value = entry2?.[1];
|
|
2359
|
+
return value === void 0 ? null : typeof value === "string" || typeof value === "number" ? String(value) : value.join(", ");
|
|
2360
|
+
},
|
|
2361
|
+
bytes: () => {
|
|
2362
|
+
claim();
|
|
2363
|
+
let iterated = false;
|
|
2364
|
+
return {
|
|
2365
|
+
async *[Symbol.asyncIterator]() {
|
|
2366
|
+
if (iterated)
|
|
2367
|
+
throw new Error("the response body has already been read");
|
|
2368
|
+
iterated = true;
|
|
2369
|
+
yield* source();
|
|
2370
|
+
}
|
|
2371
|
+
};
|
|
2372
|
+
},
|
|
2373
|
+
json: async () => {
|
|
2374
|
+
claim();
|
|
2375
|
+
const chunks = [];
|
|
2376
|
+
for await (const chunk of source())
|
|
2377
|
+
chunks.push(chunk);
|
|
2378
|
+
const value = JSON.parse(Buffer.concat(chunks).toString("utf8"));
|
|
2379
|
+
return value;
|
|
2380
|
+
}
|
|
2381
|
+
};
|
|
2382
|
+
return new Proxy(members, {
|
|
2383
|
+
get(target, member) {
|
|
2384
|
+
if (member === "status" || member === "reason" || member === "json" || member === "header" || member === "bytes") {
|
|
2385
|
+
return target[member];
|
|
2386
|
+
}
|
|
2387
|
+
if (member === "then" || typeof member === "symbol")
|
|
2388
|
+
return void 0;
|
|
2389
|
+
throw new Error(`the response member ${String(member)} is not implemented`);
|
|
2390
|
+
}
|
|
2391
|
+
});
|
|
2392
|
+
}
|
|
2393
|
+
|
|
2394
|
+
// packages/sdk-dispatch/dist/socket-transport.js
|
|
2372
2395
|
var REQUEST_DEADLINE_MS = 1e4;
|
|
2373
2396
|
function requestDeadlineOf(path, method, override) {
|
|
2374
2397
|
if (override !== void 0)
|
|
@@ -2410,7 +2433,7 @@ var HostStatusNotEnvelope = class extends Error {
|
|
|
2410
2433
|
};
|
|
2411
2434
|
var INIT_MEMBERS = Object.freeze(["method", "headers", "body", "signal"]);
|
|
2412
2435
|
function unsupported(member) {
|
|
2413
|
-
return new Error(`the
|
|
2436
|
+
return new Error(`the request function does not implement ${member}`);
|
|
2414
2437
|
}
|
|
2415
2438
|
function isPlainObject2(value) {
|
|
2416
2439
|
return typeof value === "object" && value !== null && Object.getPrototypeOf(value) === Object.prototype;
|
|
@@ -2541,6 +2564,13 @@ function createHostFetch(socketPath, deadlineMs) {
|
|
|
2541
2564
|
};
|
|
2542
2565
|
}
|
|
2543
2566
|
function createHostStreamFetch(socketPath, headDeadlineMs = REQUEST_DEADLINE_MS) {
|
|
2567
|
+
return streamFetchOver(headDeadlineMs, (url) => {
|
|
2568
|
+
if (url.protocol !== "http:") {
|
|
2569
|
+
throw unsupported(`the protocol ${url.protocol}`);
|
|
2570
|
+
}
|
|
2571
|
+
}, (url, checked, onResponse) => request({ socketPath, method: checked.method, path: `${url.pathname}${url.search}`, headers: checked.headers }, onResponse));
|
|
2572
|
+
}
|
|
2573
|
+
function streamFetchOver(headDeadlineMs, admit, open2) {
|
|
2544
2574
|
return async (input, init) => {
|
|
2545
2575
|
if (typeof input !== "string") {
|
|
2546
2576
|
throw unsupported("an input that is not a string URL");
|
|
@@ -2550,9 +2580,7 @@ function createHostStreamFetch(socketPath, headDeadlineMs = REQUEST_DEADLINE_MS)
|
|
|
2550
2580
|
throw unsupported("an input that is not a URL");
|
|
2551
2581
|
}
|
|
2552
2582
|
const url = new URL(input);
|
|
2553
|
-
|
|
2554
|
-
throw unsupported(`the protocol ${url.protocol}`);
|
|
2555
|
-
}
|
|
2583
|
+
admit(url);
|
|
2556
2584
|
const path = `${url.pathname}${url.search}`;
|
|
2557
2585
|
return new Promise((resolve, reject) => {
|
|
2558
2586
|
let headSettled = false;
|
|
@@ -2564,7 +2592,7 @@ function createHostStreamFetch(socketPath, headDeadlineMs = REQUEST_DEADLINE_MS)
|
|
|
2564
2592
|
outgoing.destroy();
|
|
2565
2593
|
reject(new HostOutcomeUnknown(path, "deadline", `the host did not answer the head of ${path} within the deadline of ${String(headDeadlineMs)} ms`));
|
|
2566
2594
|
}, headDeadlineMs);
|
|
2567
|
-
const outgoing =
|
|
2595
|
+
const outgoing = open2(url, checked, (incoming) => {
|
|
2568
2596
|
if (headSettled) {
|
|
2569
2597
|
return;
|
|
2570
2598
|
}
|
|
@@ -2823,14 +2851,14 @@ async function* callStreamed(transport, origin, route2, body, token, signal) {
|
|
|
2823
2851
|
yield JSON.parse(line);
|
|
2824
2852
|
}
|
|
2825
2853
|
}
|
|
2826
|
-
function
|
|
2854
|
+
function attachmentFactsOf(response, length) {
|
|
2827
2855
|
const fault = () => new Error("the host answered /attachments/read with invalid attachment headers");
|
|
2828
|
-
const
|
|
2829
|
-
const
|
|
2830
|
-
const
|
|
2856
|
+
const digest = response.header("x-oe2-attachment-digest");
|
|
2857
|
+
const sha256 = digest === null ? null : /^sha256:([0-9a-f]{64})$/.exec(digest);
|
|
2858
|
+
const md5 = digest === null ? null : /^md5:([0-9a-f]{32})$/.exec(digest);
|
|
2831
2859
|
const disposition = response.header("content-disposition");
|
|
2832
2860
|
const encodedName = disposition === null ? null : /;\s*filename\*=UTF-8''([^;]+)/i.exec(disposition)?.[1];
|
|
2833
|
-
if (sha256 === null
|
|
2861
|
+
if (sha256 === null && md5 === null || length === null || !/^(0|[1-9][0-9]*)$/.test(length) || !Number.isSafeInteger(Number(length)) || encodedName === null || encodedName === void 0)
|
|
2834
2862
|
throw fault();
|
|
2835
2863
|
let name;
|
|
2836
2864
|
try {
|
|
@@ -2840,13 +2868,94 @@ function attachmentDescriptorOf(response) {
|
|
|
2840
2868
|
throw error;
|
|
2841
2869
|
throw fault();
|
|
2842
2870
|
}
|
|
2843
|
-
|
|
2871
|
+
if (sha256 !== null)
|
|
2872
|
+
return { digest: { algorithm: "sha256", hex: sha256[1] }, bytes: Number(length), name };
|
|
2873
|
+
if (md5 !== null)
|
|
2874
|
+
return { digest: { algorithm: "md5", hex: md5[1] }, bytes: Number(length), name };
|
|
2875
|
+
throw fault();
|
|
2844
2876
|
}
|
|
2845
|
-
|
|
2877
|
+
function descriptorOf(facts, mediaType) {
|
|
2878
|
+
const { digest, name, bytes } = facts;
|
|
2879
|
+
return digest.algorithm === "sha256" ? { digest: "sha256", sha256: digest.hex, name, mediaType, bytes } : { digest: "md5", md5: digest.hex, name, mediaType, bytes };
|
|
2880
|
+
}
|
|
2881
|
+
function streamDescriptorOf(response) {
|
|
2882
|
+
const mediaType = response.header("content-type");
|
|
2883
|
+
if (mediaType === null || mediaType.length === 0) {
|
|
2884
|
+
throw new Error("the host answered /attachments/read with invalid attachment headers");
|
|
2885
|
+
}
|
|
2886
|
+
const contentLength = response.header("content-length");
|
|
2887
|
+
return descriptorOf(attachmentFactsOf(response, contentLength === null ? response.header("x-oe2-attachment-bytes") : contentLength), mediaType);
|
|
2888
|
+
}
|
|
2889
|
+
var DEFAULT_ATTACHMENT_DEADLINES = Object.freeze({ headerMs: 12e4, gapMs: 6e4 });
|
|
2890
|
+
async function cancelBody(response) {
|
|
2891
|
+
const iterator = response.bytes()[Symbol.asyncIterator]();
|
|
2892
|
+
try {
|
|
2893
|
+
await iterator.next();
|
|
2894
|
+
} finally {
|
|
2895
|
+
await iterator.return?.();
|
|
2896
|
+
}
|
|
2897
|
+
}
|
|
2898
|
+
async function readWithin(reader, gapMs, controller) {
|
|
2899
|
+
return new Promise((resolve, reject) => {
|
|
2900
|
+
const timer = setTimeout(() => {
|
|
2901
|
+
controller.abort();
|
|
2902
|
+
reject(new Error("the stored file stopped sending"));
|
|
2903
|
+
}, gapMs);
|
|
2904
|
+
reader.read().then((piece) => {
|
|
2905
|
+
clearTimeout(timer);
|
|
2906
|
+
resolve(piece);
|
|
2907
|
+
}, (error) => {
|
|
2908
|
+
clearTimeout(timer);
|
|
2909
|
+
reject(error);
|
|
2910
|
+
});
|
|
2911
|
+
});
|
|
2912
|
+
}
|
|
2913
|
+
async function* storeBytes(body, gapMs, controller) {
|
|
2914
|
+
const reader = body.getReader();
|
|
2915
|
+
try {
|
|
2916
|
+
for (; ; ) {
|
|
2917
|
+
const piece = await readWithin(reader, gapMs, controller);
|
|
2918
|
+
if (piece.done)
|
|
2919
|
+
return;
|
|
2920
|
+
yield piece.value;
|
|
2921
|
+
}
|
|
2922
|
+
} finally {
|
|
2923
|
+
controller.abort();
|
|
2924
|
+
}
|
|
2925
|
+
}
|
|
2926
|
+
async function followLink(href, deadlines) {
|
|
2927
|
+
const controller = new AbortController();
|
|
2928
|
+
const headerTimer = setTimeout(() => controller.abort(), deadlines.headerMs);
|
|
2929
|
+
let redirected;
|
|
2930
|
+
try {
|
|
2931
|
+
redirected = await fetch(href, { redirect: "follow", credentials: "omit", signal: controller.signal });
|
|
2932
|
+
} catch (error) {
|
|
2933
|
+
if (!(error instanceof TypeError) && !controller.signal.aborted)
|
|
2934
|
+
throw error;
|
|
2935
|
+
throw new Error(controller.signal.aborted ? "the stored file did not answer in time" : "the stored file could not be fetched");
|
|
2936
|
+
} finally {
|
|
2937
|
+
clearTimeout(headerTimer);
|
|
2938
|
+
}
|
|
2939
|
+
if (redirected.status !== 200) {
|
|
2940
|
+
controller.abort();
|
|
2941
|
+
throw new Error(`the stored file answered with status ${String(redirected.status)}`);
|
|
2942
|
+
}
|
|
2943
|
+
const mediaType = redirected.headers.get("content-type");
|
|
2944
|
+
if (mediaType === null || mediaType.length === 0) {
|
|
2945
|
+
controller.abort();
|
|
2946
|
+
throw new Error("the stored file answered without a content type");
|
|
2947
|
+
}
|
|
2948
|
+
if (redirected.body === null) {
|
|
2949
|
+
throw new Error("the attachment redirect answered without a body");
|
|
2950
|
+
}
|
|
2951
|
+
return { mediaType, body: storeBytes(redirected.body, deadlines.gapMs, controller) };
|
|
2952
|
+
}
|
|
2953
|
+
async function callAttachment(transport, origin, selector, input, token, options = {}) {
|
|
2846
2954
|
if (token === null)
|
|
2847
2955
|
return unauthenticatedEnvelope();
|
|
2956
|
+
const deadlines = options.deadlines === void 0 ? DEFAULT_ATTACHMENT_DEADLINES : options.deadlines;
|
|
2848
2957
|
const entry2 = ROUTES.readAttachment;
|
|
2849
|
-
|
|
2958
|
+
const response = await transport(`${origin}${entry2.path}`, {
|
|
2850
2959
|
method: entry2.method,
|
|
2851
2960
|
headers: {
|
|
2852
2961
|
"content-type": "application/json",
|
|
@@ -2856,6 +2965,7 @@ async function callAttachment(transport, origin, selector, input, token) {
|
|
|
2856
2965
|
body: JSON.stringify({ selector, input })
|
|
2857
2966
|
});
|
|
2858
2967
|
if ([302, 303, 307].includes(response.status)) {
|
|
2968
|
+
await cancelBody(response);
|
|
2859
2969
|
const location = response.header("location");
|
|
2860
2970
|
if (location === null)
|
|
2861
2971
|
throw new Error("the host answered /attachments/read with a redirect without Location");
|
|
@@ -2863,19 +2973,16 @@ async function callAttachment(transport, origin, selector, input, token) {
|
|
|
2863
2973
|
if (target.origin === new URL(origin).origin) {
|
|
2864
2974
|
throw new Error("the host answered /attachments/read with a same-origin redirect");
|
|
2865
2975
|
}
|
|
2866
|
-
const
|
|
2867
|
-
|
|
2868
|
-
|
|
2869
|
-
|
|
2870
|
-
|
|
2871
|
-
|
|
2872
|
-
throw new Error("the attachment redirect answered without a body");
|
|
2873
|
-
response = responseOf(redirected.status, redirected.body, redirected.statusText, Object.fromEntries(redirected.headers));
|
|
2976
|
+
const facts = attachmentFactsOf(response, response.header("x-oe2-attachment-bytes"));
|
|
2977
|
+
if (options.follow === false) {
|
|
2978
|
+
return { version: PROTOCOL_VERSION, result: { kind: "link", link: target.href, ...facts } };
|
|
2979
|
+
}
|
|
2980
|
+
const stored = await followLink(target.href, deadlines);
|
|
2981
|
+
return { version: PROTOCOL_VERSION, result: { kind: "stream", descriptor: descriptorOf(facts, stored.mediaType), body: stored.body } };
|
|
2874
2982
|
}
|
|
2875
2983
|
if (response.status !== 200)
|
|
2876
2984
|
return explainedEnvelopeOf(await readEnvelope(response, entry2.path));
|
|
2877
|
-
|
|
2878
|
-
return { version: PROTOCOL_VERSION, result: { descriptor: descriptor2, body: response.bytes() } };
|
|
2985
|
+
return { version: PROTOCOL_VERSION, result: { kind: "stream", descriptor: streamDescriptorOf(response), body: response.bytes() } };
|
|
2879
2986
|
}
|
|
2880
2987
|
|
|
2881
2988
|
// packages/sdk-dispatch/dist/module-factory.js
|
|
@@ -2972,7 +3079,7 @@ function createHttpsTransport(origin, options = {}, deadlineMs) {
|
|
|
2972
3079
|
});
|
|
2973
3080
|
};
|
|
2974
3081
|
const outgoing = request2({
|
|
2975
|
-
hostname: url.hostname,
|
|
3082
|
+
hostname: url.hostname.replace(/^\[|\]$/g, ""),
|
|
2976
3083
|
port: url.port === "" ? 443 : Number(url.port),
|
|
2977
3084
|
path,
|
|
2978
3085
|
method: init.method,
|
|
@@ -3159,6 +3266,107 @@ function enterHumanMode(transport, origin, token, body, stepUp) {
|
|
|
3159
3266
|
return call(transport, origin, "enterHumanMode", body, token, null, stepUp);
|
|
3160
3267
|
}
|
|
3161
3268
|
|
|
3269
|
+
// packages/sdk-dispatch/dist/upload.js
|
|
3270
|
+
var ATTACHMENT_UPLOAD_PIECE_BYTES = 8 * 1024 * 1024;
|
|
3271
|
+
async function uploadPieces(sessionUri, source, fetchStore, onProgress) {
|
|
3272
|
+
if (!Number.isSafeInteger(source.size) || source.size <= 0) {
|
|
3273
|
+
throw new TypeError("an upload needs a positive safe integer size");
|
|
3274
|
+
}
|
|
3275
|
+
const failed = () => new Error("the stored file could not be uploaded");
|
|
3276
|
+
async function put(range, body) {
|
|
3277
|
+
try {
|
|
3278
|
+
const response = await fetchStore(sessionUri, {
|
|
3279
|
+
// Follow exposes a 308 without Location in both Node and browsers; manual hides it in browsers.
|
|
3280
|
+
method: "PUT",
|
|
3281
|
+
credentials: "omit",
|
|
3282
|
+
redirect: "follow",
|
|
3283
|
+
headers: { "Content-Range": range },
|
|
3284
|
+
...body === void 0 ? {} : { body: new Uint8Array(body) }
|
|
3285
|
+
});
|
|
3286
|
+
await response.body?.cancel();
|
|
3287
|
+
if (response.redirected)
|
|
3288
|
+
throw failed();
|
|
3289
|
+
return response;
|
|
3290
|
+
} catch (error) {
|
|
3291
|
+
if (!(error instanceof TypeError))
|
|
3292
|
+
throw failed();
|
|
3293
|
+
return null;
|
|
3294
|
+
}
|
|
3295
|
+
}
|
|
3296
|
+
async function read(offset2, end) {
|
|
3297
|
+
const piece = await source.read(offset2, end - offset2);
|
|
3298
|
+
if (piece.byteLength !== end - offset2)
|
|
3299
|
+
throw new Error("the upload source returned an incorrect piece length");
|
|
3300
|
+
return piece;
|
|
3301
|
+
}
|
|
3302
|
+
let offset = 0;
|
|
3303
|
+
let reported = 0;
|
|
3304
|
+
const pending = /* @__PURE__ */ new Map();
|
|
3305
|
+
while (offset < source.size) {
|
|
3306
|
+
const end = Math.min(offset + ATTACHMENT_UPLOAD_PIECE_BYTES, source.size);
|
|
3307
|
+
for (let ahead = offset; ahead < Math.min(end + ATTACHMENT_UPLOAD_PIECE_BYTES, source.size); ahead += ATTACHMENT_UPLOAD_PIECE_BYTES) {
|
|
3308
|
+
if (!pending.has(ahead)) {
|
|
3309
|
+
const piece2 = read(ahead, Math.min(ahead + ATTACHMENT_UPLOAD_PIECE_BYTES, source.size)).then((bytes) => ({ bytes }), (error) => ({ error }));
|
|
3310
|
+
pending.set(ahead, piece2);
|
|
3311
|
+
}
|
|
3312
|
+
}
|
|
3313
|
+
const ready = await pending.get(offset);
|
|
3314
|
+
pending.delete(offset);
|
|
3315
|
+
if ("error" in ready)
|
|
3316
|
+
throw ready.error;
|
|
3317
|
+
let piece = ready.bytes;
|
|
3318
|
+
let resumes = 0;
|
|
3319
|
+
while (offset < end) {
|
|
3320
|
+
const response = await put(`bytes ${String(offset)}-${String(end - 1)}/${String(source.size)}`, piece);
|
|
3321
|
+
let status = response;
|
|
3322
|
+
if (status === null || status.status >= 500) {
|
|
3323
|
+
if (resumes === 3)
|
|
3324
|
+
throw failed();
|
|
3325
|
+
resumes++;
|
|
3326
|
+
status = await put(`bytes */${String(source.size)}`);
|
|
3327
|
+
while (status === null || status.status >= 500) {
|
|
3328
|
+
if (resumes === 3)
|
|
3329
|
+
throw failed();
|
|
3330
|
+
resumes++;
|
|
3331
|
+
status = await put(`bytes */${String(source.size)}`);
|
|
3332
|
+
}
|
|
3333
|
+
if (status.status === 200 || status.status === 201) {
|
|
3334
|
+
offset = source.size;
|
|
3335
|
+
break;
|
|
3336
|
+
}
|
|
3337
|
+
if (status.status !== 308)
|
|
3338
|
+
throw failed();
|
|
3339
|
+
} else {
|
|
3340
|
+
if (end === source.size && (status.status === 200 || status.status === 201)) {
|
|
3341
|
+
offset = end;
|
|
3342
|
+
break;
|
|
3343
|
+
}
|
|
3344
|
+
if (status.status !== 308) {
|
|
3345
|
+
throw new Error(`the stored file answered with status ${String(status.status)}`);
|
|
3346
|
+
}
|
|
3347
|
+
}
|
|
3348
|
+
const range = status.headers.get("Range");
|
|
3349
|
+
const matched = range === null ? null : /^bytes=0-(\d+)$/.exec(range);
|
|
3350
|
+
if (range !== null && matched === null)
|
|
3351
|
+
throw failed();
|
|
3352
|
+
const committed = matched === null ? 0 : Number(matched[1]) + 1;
|
|
3353
|
+
if (!Number.isSafeInteger(committed) || committed < offset || committed > end)
|
|
3354
|
+
throw failed();
|
|
3355
|
+
if (status === response && committed === offset) {
|
|
3356
|
+
if (resumes === 3)
|
|
3357
|
+
throw failed();
|
|
3358
|
+
resumes++;
|
|
3359
|
+
}
|
|
3360
|
+
offset = committed;
|
|
3361
|
+
if (offset < end)
|
|
3362
|
+
piece = await read(offset, end);
|
|
3363
|
+
}
|
|
3364
|
+
for (; reported < offset; reported = Math.min(reported + ATTACHMENT_UPLOAD_PIECE_BYTES, source.size)) {
|
|
3365
|
+
onProgress?.(Math.min(reported + ATTACHMENT_UPLOAD_PIECE_BYTES, source.size), source.size);
|
|
3366
|
+
}
|
|
3367
|
+
}
|
|
3368
|
+
}
|
|
3369
|
+
|
|
3162
3370
|
// packages/sdk-core/dist/index.js
|
|
3163
3371
|
var SDK_CORE_ROUTE_ENTRIES = routeEntriesOf("sdk-core");
|
|
3164
3372
|
|
|
@@ -3501,10 +3709,28 @@ function displayPropertyValue(value, definition) {
|
|
|
3501
3709
|
return JSON.stringify(value);
|
|
3502
3710
|
}
|
|
3503
3711
|
|
|
3712
|
+
// packages/objects-sdk/dist/upload.js
|
|
3713
|
+
async function uploadAttachment(transport, origin, token, selector, source, options) {
|
|
3714
|
+
const opened = await call(transport, origin, "openAttachmentUpload", {
|
|
3715
|
+
selector,
|
|
3716
|
+
input: { name: source.name, declaredLength: source.size }
|
|
3717
|
+
}, token, null);
|
|
3718
|
+
if ("refusal" in opened)
|
|
3719
|
+
return opened;
|
|
3720
|
+
if (opened.replayed === true)
|
|
3721
|
+
throw new Error("the host replayed an upload open");
|
|
3722
|
+
await uploadPieces(opened.result.sessionUri, source, fetch, options?.onProgress);
|
|
3723
|
+
return call(transport, origin, "completeAttachmentUpload", {
|
|
3724
|
+
selector,
|
|
3725
|
+
input: { uploadId: opened.result.uploadId }
|
|
3726
|
+
}, token, null);
|
|
3727
|
+
}
|
|
3728
|
+
|
|
3504
3729
|
// packages/objects-sdk/dist/transport-client.js
|
|
3505
3730
|
var OBJECTS_ROUTE_ENTRIES = routeEntriesOf("objects-sdk");
|
|
3506
3731
|
var OBJECTS_ROUTE_NAMES = [
|
|
3507
|
-
"
|
|
3732
|
+
"openAttachmentUpload",
|
|
3733
|
+
"completeAttachmentUpload",
|
|
3508
3734
|
"readAttachment",
|
|
3509
3735
|
"createObjectSet",
|
|
3510
3736
|
"listObjectSets",
|
|
@@ -3555,15 +3781,13 @@ function entries4() {
|
|
|
3555
3781
|
return JSON_OBJECTS_ROUTE_NAMES.map((name) => ROUTES[name]);
|
|
3556
3782
|
}
|
|
3557
3783
|
function createObjectsTransportClient(transport, origin, token) {
|
|
3784
|
+
function readAttachment(selector, input, options) {
|
|
3785
|
+
return options === void 0 ? callAttachment(transport, origin, selector, input, token) : callAttachment(transport, origin, selector, input, token, options);
|
|
3786
|
+
}
|
|
3558
3787
|
return Object.freeze({
|
|
3559
3788
|
...createTypedClient(JSON_OBJECTS_ROUTE_NAMES, entries4(), transport, origin, token),
|
|
3560
|
-
readAttachment
|
|
3561
|
-
|
|
3562
|
-
selector,
|
|
3563
|
-
input: { name: file.name, body: (async function* () {
|
|
3564
|
-
yield file.bytes;
|
|
3565
|
-
})() }
|
|
3566
|
-
}, token, null)
|
|
3789
|
+
readAttachment,
|
|
3790
|
+
uploadAttachment: (selector, source, options) => uploadAttachment(transport, origin, token, selector, source, options)
|
|
3567
3791
|
});
|
|
3568
3792
|
}
|
|
3569
3793
|
|
|
@@ -3770,7 +3994,7 @@ function walk(schema, value, path, violations, ownerProperties) {
|
|
|
3770
3994
|
return;
|
|
3771
3995
|
}
|
|
3772
3996
|
case "attachment": {
|
|
3773
|
-
if (!
|
|
3997
|
+
if (!isAttachmentWireDescriptor(value))
|
|
3774
3998
|
violations.push({ path, rule: "invalid-attachment" });
|
|
3775
3999
|
return;
|
|
3776
4000
|
}
|
|
@@ -3922,14 +4146,25 @@ function checkBoundReference(reference, count, path, violations, ownerProperties
|
|
|
3922
4146
|
violations.push({ path: [...path, "value"], rule: "count-bound-unit" });
|
|
3923
4147
|
}
|
|
3924
4148
|
}
|
|
3925
|
-
function
|
|
3926
|
-
if (
|
|
4149
|
+
function isAttachmentWireDescriptor(value) {
|
|
4150
|
+
if (!isRecord(value) || Object.keys(value).length !== 5 || !["digest", "name", "mediaType", "bytes"].every((key) => Object.hasOwn(value, key)))
|
|
3927
4151
|
return false;
|
|
3928
|
-
if (
|
|
4152
|
+
if (value.digest === "sha256") {
|
|
4153
|
+
if (!Object.hasOwn(value, "sha256") || typeof value.sha256 !== "string" || value.sha256.length !== 64 || !/^[a-f0-9]{64}$/.test(value.sha256))
|
|
4154
|
+
return false;
|
|
4155
|
+
} else if (value.digest === "md5") {
|
|
4156
|
+
if (!Object.hasOwn(value, "md5") || typeof value.md5 !== "string" || value.md5.length !== 32 || !/^[a-f0-9]{32}$/.test(value.md5))
|
|
4157
|
+
return false;
|
|
4158
|
+
} else
|
|
4159
|
+
return false;
|
|
4160
|
+
if (typeof value.name !== "string" || !attachmentNameRuleHolds(value.name) || typeof value.mediaType !== "string" || typeof value.bytes !== "number" || !Number.isSafeInteger(value.bytes) || value.bytes <= 0)
|
|
3929
4161
|
return false;
|
|
3930
4162
|
const name = value.name.toLowerCase();
|
|
3931
4163
|
return Object.values(ATTACHMENT_CLASSES).some((formats) => formats.some((format) => format.mediaType === value.mediaType && format.extensions.some((extension) => name.endsWith(extension))));
|
|
3932
4164
|
}
|
|
4165
|
+
function attachmentNameRuleHolds(name) {
|
|
4166
|
+
return name.length >= 1 && name.length <= 255 && !name.startsWith(".") && !hasForbiddenNameCharacter(name);
|
|
4167
|
+
}
|
|
3933
4168
|
function hasForbiddenNameCharacter(name) {
|
|
3934
4169
|
for (let index = 0; index < name.length; index++) {
|
|
3935
4170
|
const code = name.charCodeAt(index);
|
|
@@ -4601,6 +4836,15 @@ var VERB_TEMPLATE = deepFreeze3({
|
|
|
4601
4836
|
}
|
|
4602
4837
|
});
|
|
4603
4838
|
|
|
4839
|
+
// packages/schema-language/dist/attachment-viewer-limits.js
|
|
4840
|
+
var ATTACHMENT_VIEWER_LIMITS = Object.freeze({
|
|
4841
|
+
image: 52428800,
|
|
4842
|
+
pdf: 104857600,
|
|
4843
|
+
mesh: 67108864,
|
|
4844
|
+
step: 33554432,
|
|
4845
|
+
text: 33554432
|
|
4846
|
+
});
|
|
4847
|
+
|
|
4604
4848
|
// packages/objects-sdk/dist/validation.js
|
|
4605
4849
|
function validateLocally(schema, languageVersion, value, category) {
|
|
4606
4850
|
const checked = validateSchema(schema, languageVersion, category);
|
|
@@ -4986,8 +5230,9 @@ function describe(schema, root, depth) {
|
|
|
4986
5230
|
if (kinds !== null) {
|
|
4987
5231
|
return `kinds: ${[...new Set(kinds.map((candidate) => candidate.kind))].join(" | ")}`;
|
|
4988
5232
|
}
|
|
4989
|
-
|
|
4990
|
-
|
|
5233
|
+
const union = node.oneOf ?? node.anyOf;
|
|
5234
|
+
if (union !== void 0) {
|
|
5235
|
+
return [...new Set(union.map((member) => describe(member, root, depth + 1)))].join(" | ");
|
|
4991
5236
|
}
|
|
4992
5237
|
if (node.const !== void 0) {
|
|
4993
5238
|
return JSON.stringify(node.const);
|
|
@@ -5013,7 +5258,7 @@ function objectShapes(node, root) {
|
|
|
5013
5258
|
if (typeof node.additionalProperties === "object") {
|
|
5014
5259
|
return objectShapes(deref(node.additionalProperties, root), root);
|
|
5015
5260
|
}
|
|
5016
|
-
return (node.oneOf ?? []).map((member) => deref(member, root)).filter((member) => member.properties !== void 0);
|
|
5261
|
+
return (node.oneOf ?? node.anyOf ?? []).map((member) => deref(member, root)).filter((member) => member.properties !== void 0);
|
|
5017
5262
|
}
|
|
5018
5263
|
function propertyLines(shape, root, indent, depth) {
|
|
5019
5264
|
const lines = [];
|
|
@@ -5778,11 +6023,11 @@ var createFileStore = (configDirectory) => {
|
|
|
5778
6023
|
try {
|
|
5779
6024
|
mkdirSync(directory, { recursive: true, mode: 448 });
|
|
5780
6025
|
chmodSync(directory, 448);
|
|
5781
|
-
const
|
|
6026
|
+
const descriptor = openSync(temporary, "wx", 384);
|
|
5782
6027
|
try {
|
|
5783
|
-
writeSync(
|
|
6028
|
+
writeSync(descriptor, secretOf(hostKey, session, organisation));
|
|
5784
6029
|
} finally {
|
|
5785
|
-
closeSync(
|
|
6030
|
+
closeSync(descriptor);
|
|
5786
6031
|
}
|
|
5787
6032
|
renameSync(temporary, final);
|
|
5788
6033
|
} catch (error) {
|
|
@@ -5826,6 +6071,8 @@ var storedSummary = async (store, hostKey) => {
|
|
|
5826
6071
|
};
|
|
5827
6072
|
|
|
5828
6073
|
// packages/cli/src/host-binding.ts
|
|
6074
|
+
var DEFAULT_HOST = "https://api.openeng.io";
|
|
6075
|
+
var resolveHostSetting = (flag, environment) => flag ?? environment ?? DEFAULT_HOST;
|
|
5829
6076
|
var UNIX_PREFIX = "unix:";
|
|
5830
6077
|
var LOOPBACK_HOSTNAMES = ["127.0.0.1", "[::1]"];
|
|
5831
6078
|
var parseHost = (host, signInOrigin) => {
|
|
@@ -6162,11 +6409,11 @@ async function takeLock(path, deps) {
|
|
|
6162
6409
|
let unreadableSince = null;
|
|
6163
6410
|
for (; ; ) {
|
|
6164
6411
|
try {
|
|
6165
|
-
const
|
|
6412
|
+
const descriptor = openSync2(path, "wx", 384);
|
|
6166
6413
|
try {
|
|
6167
|
-
writeSync2(
|
|
6414
|
+
writeSync2(descriptor, text);
|
|
6168
6415
|
} finally {
|
|
6169
|
-
closeSync2(
|
|
6416
|
+
closeSync2(descriptor);
|
|
6170
6417
|
}
|
|
6171
6418
|
return () => {
|
|
6172
6419
|
if (readLockText(path) === text) {
|
|
@@ -6806,8 +7053,8 @@ var resolveAliases = (words) => {
|
|
|
6806
7053
|
return group === void 0 ? words : [group, ...rest];
|
|
6807
7054
|
};
|
|
6808
7055
|
var HOST_GUIDANCE = [
|
|
6809
|
-
"
|
|
6810
|
-
"
|
|
7056
|
+
"default host: https://api.openeng.io",
|
|
7057
|
+
"to use another host: --host <origin>, or set OPENENG_HOST=<origin>",
|
|
6811
7058
|
"agents: start with openeng skill, which prints how to work with the platform."
|
|
6812
7059
|
];
|
|
6813
7060
|
function wrapped(names) {
|
|
@@ -13465,7 +13712,8 @@ var typesDraftAccept = {
|
|
|
13465
13712
|
|
|
13466
13713
|
// packages/cli/src/commands/attachment.ts
|
|
13467
13714
|
import { createHash as createHash3, randomUUID as randomUUID5 } from "node:crypto";
|
|
13468
|
-
import {
|
|
13715
|
+
import { renameSync as renameSync2, rmSync } from "node:fs";
|
|
13716
|
+
import { open } from "node:fs/promises";
|
|
13469
13717
|
import { basename } from "node:path";
|
|
13470
13718
|
var usageAdd = "openeng attachment add <object> <property> <file> --project <id> --ref <ref>";
|
|
13471
13719
|
var usageGet = "openeng attachment get <object> <property> [--out <path>] --project <id> --ref <ref>";
|
|
@@ -13490,18 +13738,57 @@ function isSelector(value) {
|
|
|
13490
13738
|
function isRecord4(value) {
|
|
13491
13739
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
13492
13740
|
}
|
|
13493
|
-
function
|
|
13494
|
-
|
|
13741
|
+
async function writeAll(file, chunk) {
|
|
13742
|
+
let offset = 0;
|
|
13743
|
+
while (offset < chunk.byteLength) {
|
|
13744
|
+
const { bytesWritten } = await file.write(chunk, offset, chunk.byteLength - offset);
|
|
13745
|
+
if (bytesWritten === 0) throw new Error("the file system accepted no bytes of the download");
|
|
13746
|
+
offset += bytesWritten;
|
|
13747
|
+
}
|
|
13748
|
+
}
|
|
13749
|
+
var SHA256_HEX = /^[0-9a-f]{64}$/;
|
|
13750
|
+
var MD5_HEX = /^[0-9a-f]{32}$/;
|
|
13751
|
+
function wireDescriptor(value) {
|
|
13752
|
+
if (!isRecord4(value) || typeof value.name !== "string" || typeof value.mediaType !== "string" || typeof value.bytes !== "number" || !Number.isSafeInteger(value.bytes) || value.bytes < 0) return null;
|
|
13753
|
+
const { name, mediaType, bytes } = value;
|
|
13754
|
+
const digest = Object.hasOwn(value, "digest") ? value.digest : "sha256";
|
|
13755
|
+
if (digest === "sha256" && typeof value.sha256 === "string" && SHA256_HEX.test(value.sha256)) {
|
|
13756
|
+
return { digest, sha256: value.sha256, name, mediaType, bytes };
|
|
13757
|
+
}
|
|
13758
|
+
if (digest === "md5" && typeof value.md5 === "string" && MD5_HEX.test(value.md5)) {
|
|
13759
|
+
return { digest, md5: value.md5, name, mediaType, bytes };
|
|
13760
|
+
}
|
|
13761
|
+
return null;
|
|
13495
13762
|
}
|
|
13496
13763
|
async function saveDescriptor(context, selector, objectId, property, file) {
|
|
13497
|
-
const bytes = new Uint8Array(readFileSync6(file));
|
|
13498
13764
|
const name = basename(file);
|
|
13499
13765
|
const settle2 = `openeng attachment get ${objectId} ${property} --project ${selector.projectId} --ref ${selector.ref}`;
|
|
13500
13766
|
const run2 = await runAuthenticated(context.host, context.deps, async (clients) => {
|
|
13501
13767
|
const object = await clients.objects.readObject({ selector, input: { objectId } });
|
|
13502
13768
|
if ("refusal" in object) return { outcome: outcomeOfEnvelope(object, settle2, (value2) => JSON.stringify(value2)) };
|
|
13503
13769
|
if (object.replayed === true) return { outcome: outcomeOfEnvelope(object, settle2, (value2) => JSON.stringify(value2)) };
|
|
13504
|
-
const
|
|
13770
|
+
const handle = await open(file, "r");
|
|
13771
|
+
const staged = await (async () => {
|
|
13772
|
+
try {
|
|
13773
|
+
const { size } = await handle.stat();
|
|
13774
|
+
return await clients.objects.uploadAttachment({ ...selector, objectId }, {
|
|
13775
|
+
name,
|
|
13776
|
+
size,
|
|
13777
|
+
read: async (offset, length) => {
|
|
13778
|
+
const bytes = new Uint8Array(length);
|
|
13779
|
+
let read = 0;
|
|
13780
|
+
while (read < length) {
|
|
13781
|
+
const { bytesRead } = await handle.read(bytes, read, length - read, offset + read);
|
|
13782
|
+
if (bytesRead === 0) throw new Error("the upload file ended before its declared size");
|
|
13783
|
+
read += bytesRead;
|
|
13784
|
+
}
|
|
13785
|
+
return bytes;
|
|
13786
|
+
}
|
|
13787
|
+
}, { onProgress: (committed, total) => context.note(`uploaded ${committed}/${total} bytes`) });
|
|
13788
|
+
} finally {
|
|
13789
|
+
await handle.close();
|
|
13790
|
+
}
|
|
13791
|
+
})();
|
|
13505
13792
|
if ("refusal" in staged) return { outcome: outcomeOfEnvelope(staged, settle2, (value2) => JSON.stringify(value2)) };
|
|
13506
13793
|
if (staged.replayed === true) return { outcome: outcomeOfEnvelope(staged, settle2, (value2) => JSON.stringify(value2)) };
|
|
13507
13794
|
const catalogue = await clients.objects.readCatalogue({ selector: { projectId: selector.projectId }, input: {} });
|
|
@@ -13515,10 +13802,10 @@ async function saveDescriptor(context, selector, objectId, property, file) {
|
|
|
13515
13802
|
if (!isRecord4(object.result.properties)) return { outcome: malformed2("object properties") };
|
|
13516
13803
|
const props = object.result.properties;
|
|
13517
13804
|
const current = props[property];
|
|
13518
|
-
const previous = isRecord4(current) && "value" in current ? { value: current.value } : {
|
|
13805
|
+
const previous = isRecord4(current) && "value" in current ? { kind: "value", value: current.value } : { kind: "absent" };
|
|
13519
13806
|
const saved = await clients.objects.mutate({ selector, input: {
|
|
13520
13807
|
correlation: { kind: "mint" },
|
|
13521
|
-
operation: { kind: "update-object", objectId, typeVersion: type.version, changes: { [property]: { from: previous, to: { value: staged.result } } } }
|
|
13808
|
+
operation: { kind: "update-object", objectId, typeVersion: type.version, changes: { [property]: { from: previous, to: { kind: "value", value: staged.result } } } }
|
|
13522
13809
|
} }, randomUUID5());
|
|
13523
13810
|
if ("refusal" in saved) return { outcome: outcomeOfEnvelope(saved, settle2, (value2) => JSON.stringify(value2)) };
|
|
13524
13811
|
if (saved.replayed === true) return { outcome: outcomeOfEnvelope(saved, settle2, (value2) => JSON.stringify(value2)) };
|
|
@@ -13588,16 +13875,42 @@ var attachmentGet = {
|
|
|
13588
13875
|
const answer = await clients.objects.readAttachment(selector, { objectId, property });
|
|
13589
13876
|
if ("refusal" in answer) return { outcome: outcomeOfEnvelope(answer, settle2, (value) => JSON.stringify(value)) };
|
|
13590
13877
|
if (answer.replayed === true) return { outcome: outcomeOfEnvelope(answer, settle2, (value) => JSON.stringify(value)) };
|
|
13591
|
-
const
|
|
13592
|
-
|
|
13593
|
-
const
|
|
13594
|
-
const
|
|
13595
|
-
|
|
13596
|
-
|
|
13597
|
-
|
|
13598
|
-
|
|
13599
|
-
|
|
13600
|
-
|
|
13878
|
+
const stored = answer.result.descriptor;
|
|
13879
|
+
const algorithm = stored.digest === "sha256" ? "SHA-256" : "MD5";
|
|
13880
|
+
const expected = stored.digest === "sha256" ? stored.sha256 : stored.md5;
|
|
13881
|
+
const hash = createHash3(stored.digest);
|
|
13882
|
+
const path = context.options.out ?? stored.name;
|
|
13883
|
+
const partial = `${path}.part`;
|
|
13884
|
+
const file = await open(partial, "w");
|
|
13885
|
+
let finished = false;
|
|
13886
|
+
try {
|
|
13887
|
+
let committed = 0;
|
|
13888
|
+
let failure2 = null;
|
|
13889
|
+
try {
|
|
13890
|
+
for await (const chunk of answer.result.body) {
|
|
13891
|
+
hash.update(chunk);
|
|
13892
|
+
await writeAll(file, chunk);
|
|
13893
|
+
committed += chunk.byteLength;
|
|
13894
|
+
context.note(`downloaded ${committed}/${stored.bytes} bytes`);
|
|
13895
|
+
}
|
|
13896
|
+
} catch (error) {
|
|
13897
|
+
failure2 = { error };
|
|
13898
|
+
}
|
|
13899
|
+
try {
|
|
13900
|
+
await file.close();
|
|
13901
|
+
} catch (error) {
|
|
13902
|
+
failure2 ??= { error };
|
|
13903
|
+
}
|
|
13904
|
+
if (failure2 !== null) throw failure2.error;
|
|
13905
|
+
if (hash.digest("hex") !== expected) {
|
|
13906
|
+
const outcome2 = { kind: "internal-failure", message: `the downloaded attachment did not match its descriptor's ${algorithm}` };
|
|
13907
|
+
return { outcome: outcome2 };
|
|
13908
|
+
}
|
|
13909
|
+
renameSync2(partial, path);
|
|
13910
|
+
finished = true;
|
|
13911
|
+
} finally {
|
|
13912
|
+
if (!finished) rmSync(partial, { force: true });
|
|
13913
|
+
}
|
|
13601
13914
|
const outcome = { kind: "success", value: { path }, text: path };
|
|
13602
13915
|
return { outcome };
|
|
13603
13916
|
});
|
|
@@ -13611,8 +13924,8 @@ function attachmentProperties(object, propertyDefinitions) {
|
|
|
13611
13924
|
const entries7 = Object.entries(propertyDefinitions).flatMap(([property, definition]) => {
|
|
13612
13925
|
if (!isRecord4(definition) || definition.kind !== "attachment") return [];
|
|
13613
13926
|
const stored = properties[property];
|
|
13614
|
-
|
|
13615
|
-
return [{ property, descriptor:
|
|
13927
|
+
const read = isRecord4(stored) ? wireDescriptor(stored.value) : null;
|
|
13928
|
+
return read === null ? [] : [{ property, descriptor: read }];
|
|
13616
13929
|
});
|
|
13617
13930
|
return { ok: true, entries: entries7 };
|
|
13618
13931
|
}
|
|
@@ -13745,7 +14058,7 @@ var linksClear = {
|
|
|
13745
14058
|
}
|
|
13746
14059
|
return outcomeOfEnvelope(run2.answer, settle2, (answer) => {
|
|
13747
14060
|
if (answer.kind !== "succeeded") throw new Error("a clearing success was required");
|
|
13748
|
-
return `cleared ${entries7.length} ${entries7.length === 1 ? "link" : "links"}; ${
|
|
14061
|
+
return `cleared ${entries7.length} ${entries7.length === 1 ? "link" : "links"}; ${answer.commit.kind === "committed" ? `commit ${answer.commit.hash}` : "no change"}; correlation ${answer.correlationId}`;
|
|
13749
14062
|
});
|
|
13750
14063
|
}
|
|
13751
14064
|
};
|
|
@@ -13790,7 +14103,7 @@ var branchesImpact = {
|
|
|
13790
14103
|
};
|
|
13791
14104
|
|
|
13792
14105
|
// packages/cli/src/commands/hosted-app.ts
|
|
13793
|
-
import { readFileSync as
|
|
14106
|
+
import { readFileSync as readFileSync6 } from "node:fs";
|
|
13794
14107
|
var ONE_WALL_WARNING_LEAD = "Reduced isolation lets an app use React in the normal way, so agents can build better apps. One browser feature, WebRTC, cannot be blocked which creates a security risk if used by a hosted app.";
|
|
13795
14108
|
var ONE_WALL_WARNING_DETAIL = "WebRTC lets a web page connect directly to other computers on the internet, for example for video calls. An app with reduced isolation could use WebRTC to send data out of the viewer's browser. The app runs with the access of each person who opens it, so this data could be anything that person can read. Use of WebRTC in an app with reduced isolation is a security risk. Review the app's code for WebRTC use before you allow it, and again for each new version. A coding agent can do the review. If you remove this permission, the app stops at its next request, but data it already read cannot be recalled.";
|
|
13796
14109
|
var ONE_WALL_WARNING = `${ONE_WALL_WARNING_LEAD}
|
|
@@ -13839,7 +14152,7 @@ var hostedAppPublish = {
|
|
|
13839
14152
|
if (isOutcome2(file)) return file;
|
|
13840
14153
|
const key = context.options.key;
|
|
13841
14154
|
if (key === void 0 || key === "") return invalid2(`openeng hosted-app publish needs --key <app key>; usage: ${usagePublish}`);
|
|
13842
|
-
const bytes = new Uint8Array(
|
|
14155
|
+
const bytes = new Uint8Array(readFileSync6(file));
|
|
13843
14156
|
const settle2 = `openeng hosted-app versions ${key} --project ${project}, which only reads; publish again only if the version is absent`;
|
|
13844
14157
|
const run2 = await runAuthenticated(context.host, context.deps, async (clients) => {
|
|
13845
14158
|
const found = await appOfKey(clients, project, key, settle2);
|
|
@@ -13964,7 +14277,7 @@ var loginCommand = {
|
|
|
13964
14277
|
help: [
|
|
13965
14278
|
"openeng login [--no-open]",
|
|
13966
14279
|
"does: signs the person in through the browser and stores the session; --no-open prints the sign-in address instead of opening it",
|
|
13967
|
-
"example: openeng login
|
|
14280
|
+
"example: openeng login",
|
|
13968
14281
|
"output: one line naming the principal, the host, the store and the expiry; under --json an object with principalId, hostKey, store and expiresAt",
|
|
13969
14282
|
...HOST_GUIDANCE
|
|
13970
14283
|
],
|
|
@@ -14073,7 +14386,7 @@ var PUBLIC_COMMANDS = [
|
|
|
14073
14386
|
|
|
14074
14387
|
// packages/cli/src/main.ts
|
|
14075
14388
|
import { spawn } from "node:child_process";
|
|
14076
|
-
import { readFileSync as
|
|
14389
|
+
import { readFileSync as readFileSync8 } from "node:fs";
|
|
14077
14390
|
import { homedir } from "node:os";
|
|
14078
14391
|
import { parseArgs } from "node:util";
|
|
14079
14392
|
|
|
@@ -14147,7 +14460,7 @@ var createTransport = (host) => host.kind === "unix" ? createHostFetch(host.sock
|
|
|
14147
14460
|
|
|
14148
14461
|
// packages/cli/src/update-check.ts
|
|
14149
14462
|
import { randomUUID as randomUUID7 } from "node:crypto";
|
|
14150
|
-
import { existsSync, mkdirSync as mkdirSync3, readFileSync as
|
|
14463
|
+
import { existsSync, mkdirSync as mkdirSync3, readFileSync as readFileSync7, renameSync as renameSync3, unlinkSync as unlinkSync3, writeFileSync } from "node:fs";
|
|
14151
14464
|
import { join as join4 } from "node:path";
|
|
14152
14465
|
function versionParts(value) {
|
|
14153
14466
|
if (typeof value !== "string" || !/^\d+\.\d+\.\d+$/.test(value)) {
|
|
@@ -14160,7 +14473,7 @@ function readCache(file) {
|
|
|
14160
14473
|
if (!existsSync(file)) {
|
|
14161
14474
|
return null;
|
|
14162
14475
|
}
|
|
14163
|
-
const value = JSON.parse(
|
|
14476
|
+
const value = JSON.parse(readFileSync7(file, "utf8"));
|
|
14164
14477
|
if (typeof value !== "object" || value === null || !("latest" in value) || !("checkedAt" in value)) {
|
|
14165
14478
|
return null;
|
|
14166
14479
|
}
|
|
@@ -14193,8 +14506,8 @@ function writeCache(directory, file, cache) {
|
|
|
14193
14506
|
mkdirSync3(directory, { recursive: true, mode: 448 });
|
|
14194
14507
|
const temporary = `${file}.${randomUUID7()}.tmp`;
|
|
14195
14508
|
try {
|
|
14196
|
-
|
|
14197
|
-
|
|
14509
|
+
writeFileSync(temporary, JSON.stringify(cache), { flag: "wx", mode: 384 });
|
|
14510
|
+
renameSync3(temporary, file);
|
|
14198
14511
|
} finally {
|
|
14199
14512
|
if (existsSync(temporary)) {
|
|
14200
14513
|
unlinkSync3(temporary);
|
|
@@ -14416,7 +14729,7 @@ ${usageLines(commands).join("\n")}` : unknownCommandMessage(commands, invocation
|
|
|
14416
14729
|
return { outcome: await command.run(invocation.words.slice(command.words.length)), json: options.json, scope: null };
|
|
14417
14730
|
}
|
|
14418
14731
|
const environment = readEnvironment();
|
|
14419
|
-
const parsedHost = parseHost(invocation.host
|
|
14732
|
+
const parsedHost = parseHost(resolveHostSetting(invocation.host, environment.OPENENG_HOST), invocation.signInOrigin ?? environment.OPENENG_SIGN_IN_ORIGIN);
|
|
14420
14733
|
if (!parsedHost.ok) {
|
|
14421
14734
|
return { outcome: outcomeOfHostRefusal(parsedHost.refusal), json: options.json, scope: null };
|
|
14422
14735
|
}
|
|
@@ -14458,7 +14771,7 @@ ${usageLines(commands).join("\n")}` : unknownCommandMessage(commands, invocation
|
|
|
14458
14771
|
deps,
|
|
14459
14772
|
options,
|
|
14460
14773
|
args: invocation.words.slice(command.words.length),
|
|
14461
|
-
readStandardInput: () =>
|
|
14774
|
+
readStandardInput: () => readFileSync8(0, "utf8"),
|
|
14462
14775
|
promptSecret,
|
|
14463
14776
|
writeLine: (line) => process.stdout.write(`${line}
|
|
14464
14777
|
`),
|