@opensoha/contracts 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/COMPATIBILITY.md +306 -0
- package/LICENSE +201 -0
- package/README.md +224 -0
- package/agent/agent-checkpoint.schema.json +19 -0
- package/agent/agent-observation.schema.json +20 -0
- package/agent/agent-protocol.schema.json +717 -0
- package/agent/agent-provider-definition.schema.json +44 -0
- package/agent/agent-provider-registry.schema.json +25 -0
- package/agent/agent-provider-runtime-event.schema.json +26 -0
- package/agent/agent-run-step.schema.json +24 -0
- package/agent/conformance-run.schema.json +19 -0
- package/agent/environment-lease.schema.json +31 -0
- package/agent/environment-snapshot.schema.json +26 -0
- package/agent/environment-template.schema.json +19 -0
- package/agent/fleet-target.schema.json +15 -0
- package/agent/multi-agent-plan.schema.json +18 -0
- package/agent/provider-rollout.schema.json +19 -0
- package/apiresponse/response.go +25 -0
- package/apiresponse/response_test.go +27 -0
- package/auth/token-claims.schema.json +78 -0
- package/capabilities/cluster-capability-matrix.schema.json +87 -0
- package/compat/json-schema-ecosystem-0.1.0.json +59 -0
- package/compat/openapi-0.1.0.snapshot.json +5076 -0
- package/compat/openapi-loose-boundaries-0.1.0.json +769 -0
- package/connectors/connector-event-envelope.schema.json +64 -0
- package/evaluation/evaluation-dataset.schema.json +28 -0
- package/evaluation/evaluation-result.schema.json +18 -0
- package/evaluation/evaluation-run.schema.json +19 -0
- package/evaluation/executor-profile.schema.json +18 -0
- package/evaluation/feedback-sample.schema.json +20 -0
- package/evaluation/gate-decision.schema.json +20 -0
- package/evaluation/gate-policy.schema.json +18 -0
- package/evaluation/replay-plan.schema.json +17 -0
- package/evaluation/sample-attempt.schema.json +22 -0
- package/events/event-envelope.schema.json +58 -0
- package/examples/agent-profile/k8s-sre-readonly.json +16 -0
- package/examples/cluster-capability-matrix/runtime-parity.json +40 -0
- package/examples/connector-event-envelope/feishu-message.json +19 -0
- package/examples/gateway-capability-baseline/minimal.json +61 -0
- package/examples/gateway-manifest/minimal.json +72 -0
- package/examples/governance/approval-request.json +35 -0
- package/examples/governance/audit-log.json +14 -0
- package/examples/marketplace-catalog/default.json +75 -0
- package/examples/mcp-preset/k8s-readonly.json +20 -0
- package/examples/openapi/agent-run-tool-call-request.json +11 -0
- package/examples/openapi/agent-tool-call-result-envelope.json +19 -0
- package/examples/openapi/cloud-extension-point-list-envelope.json +15 -0
- package/examples/openapi/directory-runtime-status-envelope.json +31 -0
- package/examples/openapi/gateway-manifest-envelope.json +53 -0
- package/examples/openapi/tool-invocation-request.json +14 -0
- package/examples/openapi/tool-invocation-result-envelope.json +23 -0
- package/examples/plugin-manifest/compute-provider.json +27 -0
- package/examples/plugin-manifest/connector.json +76 -0
- package/examples/plugin-manifest/skill-pack.json +47 -0
- package/examples/runner-operation-lifecycle/late-callback.json +27 -0
- package/examples/skill-manifest/k8s-sre.json +22 -0
- package/examples/token-claims/service-account.json +15 -0
- package/fixtures/json-schema/agent-checkpoint/invalid/raw-state.json +1 -0
- package/fixtures/json-schema/agent-checkpoint/valid/minimal.json +1 -0
- package/fixtures/json-schema/agent-observation/invalid/extra-secret.json +1 -0
- package/fixtures/json-schema/agent-observation/valid/tool.json +1 -0
- package/fixtures/json-schema/agent-profile/invalid/missing-scope.json +15 -0
- package/fixtures/json-schema/agent-profile/valid/k8s-sre-readonly.json +35 -0
- package/fixtures/json-schema/agent-protocol/invalid/missing-agent-id.json +3 -0
- package/fixtures/json-schema/agent-protocol/valid/agent-run-callback-legacy.json +9 -0
- package/fixtures/json-schema/agent-protocol/valid/agent-run-callback-with-events.json +39 -0
- package/fixtures/json-schema/agent-protocol/valid/execution-task-claim.json +5 -0
- package/fixtures/json-schema/agent-provider-definition/invalid/missing-command.json +1 -0
- package/fixtures/json-schema/agent-provider-definition/valid/cli.json +1 -0
- package/fixtures/json-schema/agent-provider-registry/invalid/zero-revision.json +1 -0
- package/fixtures/json-schema/agent-provider-registry/valid/minimal.json +1 -0
- package/fixtures/json-schema/agent-provider-runtime-event/invalid/health-without-provider.json +1 -0
- package/fixtures/json-schema/agent-provider-runtime-event/valid/ack.json +1 -0
- package/fixtures/json-schema/agent-run-step/invalid/unknown-state.json +1 -0
- package/fixtures/json-schema/agent-run-step/valid/running.json +1 -0
- package/fixtures/json-schema/approval-request/invalid/missing-status.json +12 -0
- package/fixtures/json-schema/approval-request/valid/high-risk-tool.json +56 -0
- package/fixtures/json-schema/audit-log/invalid/extra-field.json +10 -0
- package/fixtures/json-schema/audit-log/valid/tool-denied.json +23 -0
- package/fixtures/json-schema/cluster-capability-matrix/invalid/missing-agent-support.json +16 -0
- package/fixtures/json-schema/cluster-capability-matrix/invalid/partial-without-reason.json +18 -0
- package/fixtures/json-schema/cluster-capability-matrix/valid/runtime-parity.json +59 -0
- package/fixtures/json-schema/conformance-run/invalid/missing.json +1 -0
- package/fixtures/json-schema/conformance-run/valid/passed.json +1 -0
- package/fixtures/json-schema/connector-checkpoint/invalid/missing.json +1 -0
- package/fixtures/json-schema/connector-checkpoint/valid/http.json +1 -0
- package/fixtures/json-schema/connector-definition/invalid/missing.json +1 -0
- package/fixtures/json-schema/connector-definition/valid/http.json +1 -0
- package/fixtures/json-schema/connector-event-envelope/invalid/missing-payload.json +11 -0
- package/fixtures/json-schema/connector-event-envelope/invalid/unknown-top-level-field.json +13 -0
- package/fixtures/json-schema/connector-event-envelope/valid/feishu-message.json +19 -0
- package/fixtures/json-schema/context-envelope/invalid/envelope.json +1 -0
- package/fixtures/json-schema/context-envelope/valid/envelope.json +1 -0
- package/fixtures/json-schema/environment-lease/invalid/unbounded.json +1 -0
- package/fixtures/json-schema/environment-lease/valid/observe.json +1 -0
- package/fixtures/json-schema/environment-snapshot/invalid/negative-usage.json +1 -0
- package/fixtures/json-schema/environment-snapshot/valid/active.json +1 -0
- package/fixtures/json-schema/environment-template/invalid/missing.json +1 -0
- package/fixtures/json-schema/environment-template/valid/container.json +1 -0
- package/fixtures/json-schema/evaluation-dataset/invalid/no-samples.json +1 -0
- package/fixtures/json-schema/evaluation-dataset/valid/minimal.json +1 -0
- package/fixtures/json-schema/evaluation-result/invalid/bad-score.json +1 -0
- package/fixtures/json-schema/evaluation-result/valid/passed.json +1 -0
- package/fixtures/json-schema/evaluation-run/invalid/no-candidate.json +1 -0
- package/fixtures/json-schema/evaluation-run/valid/running.json +1 -0
- package/fixtures/json-schema/event-envelope/invalid/bad-severity.json +7 -0
- package/fixtures/json-schema/event-envelope/valid/minimal.json +14 -0
- package/fixtures/json-schema/executor-profile/invalid/missing.json +1 -0
- package/fixtures/json-schema/executor-profile/valid/readonly.json +1 -0
- package/fixtures/json-schema/feedback-sample/invalid/missing.json +1 -0
- package/fixtures/json-schema/feedback-sample/valid/pending.json +1 -0
- package/fixtures/json-schema/fleet-target/invalid/missing.json +1 -0
- package/fixtures/json-schema/fleet-target/valid/linux.json +1 -0
- package/fixtures/json-schema/gate-decision/invalid/missing.json +1 -0
- package/fixtures/json-schema/gate-decision/valid/pass.json +1 -0
- package/fixtures/json-schema/gate-policy/invalid/missing.json +1 -0
- package/fixtures/json-schema/gate-policy/valid/release.json +1 -0
- package/fixtures/json-schema/gateway-capability-baseline/invalid/missing-owner.json +32 -0
- package/fixtures/json-schema/gateway-capability-baseline/valid/minimal.json +61 -0
- package/fixtures/json-schema/gateway-manifest/invalid/bad-risk-level.json +37 -0
- package/fixtures/json-schema/gateway-manifest/valid/minimal.json +48 -0
- package/fixtures/json-schema/graph-revision/invalid/missing.json +1 -0
- package/fixtures/json-schema/graph-revision/valid/active.json +1 -0
- package/fixtures/json-schema/index-publish/invalid/missing.json +1 -0
- package/fixtures/json-schema/index-publish/valid/publish.json +1 -0
- package/fixtures/json-schema/ingestion-job/invalid/missing.json +1 -0
- package/fixtures/json-schema/ingestion-job/valid/queued.json +1 -0
- package/fixtures/json-schema/ingestion-stage/invalid/missing.json +1 -0
- package/fixtures/json-schema/ingestion-stage/valid/succeeded.json +1 -0
- package/fixtures/json-schema/knowledge-base/invalid/base.json +1 -0
- package/fixtures/json-schema/knowledge-base/valid/base.json +1 -0
- package/fixtures/json-schema/knowledge-search/invalid/search.json +1 -0
- package/fixtures/json-schema/knowledge-search/valid/search.json +1 -0
- package/fixtures/json-schema/knowledge-source/invalid/source.json +1 -0
- package/fixtures/json-schema/knowledge-source/valid/source.json +1 -0
- package/fixtures/json-schema/marketplace-catalog/invalid/missing-source.json +5 -0
- package/fixtures/json-schema/marketplace-catalog/valid/minimal.json +44 -0
- package/fixtures/json-schema/mcp-preset/invalid/bad-risk-level.json +20 -0
- package/fixtures/json-schema/mcp-preset/valid/k8s-readonly.json +40 -0
- package/fixtures/json-schema/memory-policy/invalid/missing.json +1 -0
- package/fixtures/json-schema/memory-policy/valid/explicit.json +1 -0
- package/fixtures/json-schema/memory-record/invalid/missing.json +1 -0
- package/fixtures/json-schema/memory-record/valid/explicit.json +1 -0
- package/fixtures/json-schema/multi-agent-plan/invalid/missing.json +1 -0
- package/fixtures/json-schema/multi-agent-plan/valid/running.json +1 -0
- package/fixtures/json-schema/observability-log-query-v1/invalid/missing-query.json +6 -0
- package/fixtures/json-schema/observability-log-query-v1/valid/request.json +15 -0
- package/fixtures/json-schema/observability-log-query-v1/valid/response.json +13 -0
- package/fixtures/json-schema/plugin-manifest/invalid/bad-type.json +7 -0
- package/fixtures/json-schema/plugin-manifest/invalid/logs-query-without-action.json +28 -0
- package/fixtures/json-schema/plugin-manifest/invalid/manifest-only-observability-provider.json +26 -0
- package/fixtures/json-schema/plugin-manifest/invalid/manifest-only-read-provider.json +23 -0
- package/fixtures/json-schema/plugin-manifest/invalid/write-provider-without-actions.json +23 -0
- package/fixtures/json-schema/plugin-manifest/valid/compute-provider.json +25 -0
- package/fixtures/json-schema/plugin-manifest/valid/minimal.json +14 -0
- package/fixtures/json-schema/plugin-manifest/valid/observability-provider.json +29 -0
- package/fixtures/json-schema/project-manifest/invalid/inline-secret.json +14 -0
- package/fixtures/json-schema/project-manifest/valid/demo.json +21 -0
- package/fixtures/json-schema/provider-rollout/invalid/missing.json +1 -0
- package/fixtures/json-schema/provider-rollout/valid/canary.json +1 -0
- package/fixtures/json-schema/replay-plan/invalid/missing.json +1 -0
- package/fixtures/json-schema/replay-plan/valid/readonly.json +1 -0
- package/fixtures/json-schema/retrieval-trace/invalid/missing.json +1 -0
- package/fixtures/json-schema/retrieval-trace/valid/grounded.json +1 -0
- package/fixtures/json-schema/runner-operation-lifecycle/invalid/bad-state.json +7 -0
- package/fixtures/json-schema/runner-operation-lifecycle/invalid/missing-runner-id.json +6 -0
- package/fixtures/json-schema/runner-operation-lifecycle/valid/final-failed.json +27 -0
- package/fixtures/json-schema/runner-operation-lifecycle/valid/heartbeat.json +19 -0
- package/fixtures/json-schema/sample-attempt/invalid/missing.json +1 -0
- package/fixtures/json-schema/sample-attempt/valid/completed.json +1 -0
- package/fixtures/json-schema/skill-manifest/invalid/bad-id.json +5 -0
- package/fixtures/json-schema/skill-manifest/valid/minimal.json +8 -0
- package/fixtures/json-schema/token-claims/invalid/bad-token-kind.json +9 -0
- package/fixtures/json-schema/token-claims/valid/service-account.json +15 -0
- package/fixtures/openapi/AIGatewayManifestEnvelope/invalid/bad-date.json +28 -0
- package/fixtures/openapi/AIGatewayManifestEnvelope/valid/minimal.json +31 -0
- package/fixtures/openapi/AgentProviderRegistryAcknowledgement/invalid/missing-targeted.json +7 -0
- package/fixtures/openapi/AgentProviderRegistryAcknowledgement/valid/rollout.json +17 -0
- package/fixtures/openapi/AgentRunCallbackRequest/invalid/missing-agent-id.json +6 -0
- package/fixtures/openapi/AgentRunCallbackRequest/valid/succeeded.json +10 -0
- package/fixtures/openapi/AgentRunCallbackRequest/valid/with-events.json +39 -0
- package/fixtures/openapi/AuthResultEnvelope/invalid/missing-tokens.json +13 -0
- package/fixtures/openapi/AuthResultEnvelope/valid/session.json +20 -0
- package/fixtures/openapi/CloudExtensionPointListEnvelope/invalid/missing-exclusions.json +11 -0
- package/fixtures/openapi/CloudExtensionPointListEnvelope/valid/managed-fleet.json +19 -0
- package/fixtures/openapi/ComputeAccessSourceListEnvelope/invalid/bad-source-type.json +15 -0
- package/fixtures/openapi/ComputeAccessSourceListEnvelope/valid/mixed.json +19 -0
- package/fixtures/openapi/ComputeOverviewEnvelope/invalid/bad-section-status.json +9 -0
- package/fixtures/openapi/ComputeOverviewEnvelope/valid/partial.json +33 -0
- package/fixtures/openapi/ComputeProviderListEnvelope/invalid/bad-domain.json +23 -0
- package/fixtures/openapi/ComputeProviderListEnvelope/valid/builtin.json +30 -0
- package/fixtures/openapi/ComputeResourceRelationListEnvelope/invalid/bad-relation.json +29 -0
- package/fixtures/openapi/ComputeResourceRelationListEnvelope/valid/vm-runtime.json +33 -0
- package/fixtures/openapi/ComputeTaskListEnvelope/invalid/missing-source-id.json +19 -0
- package/fixtures/openapi/ComputeTaskListEnvelope/valid/running.json +30 -0
- package/fixtures/openapi/DeliveryDraftInput/invalid/missing-application-key.json +9 -0
- package/fixtures/openapi/DeliveryDraftInput/valid/ai-service.json +25 -0
- package/fixtures/openapi/DirectoryEventListEnvelope/invalid/unknown-status.json +13 -0
- package/fixtures/openapi/DirectoryEventListEnvelope/valid/failed.json +16 -0
- package/fixtures/openapi/DirectoryPersonLifecycle/invalid/unknown-employment-status.json +5 -0
- package/fixtures/openapi/DirectoryPersonLifecycle/valid/departed.json +6 -0
- package/fixtures/openapi/DirectoryRuntimeStatusEnvelope/invalid/negative-event-count.json +11 -0
- package/fixtures/openapi/DirectoryRuntimeStatusEnvelope/valid/verified.json +14 -0
- package/fixtures/openapi/DockerContainerStartInput/invalid/missing-image.json +8 -0
- package/fixtures/openapi/DockerContainerStartInput/valid/git-dockerfile.json +22 -0
- package/fixtures/openapi/DockerOperationCallbackRequest/invalid/logs-not-array.json +7 -0
- package/fixtures/openapi/DockerOperationCallbackRequest/valid/succeeded.json +9 -0
- package/fixtures/openapi/ErrorEnvelope/invalid/extra-field.json +7 -0
- package/fixtures/openapi/ErrorEnvelope/valid/error.json +7 -0
- package/fixtures/openapi/EvaluationGateRequest/invalid/missing-candidate.json +4 -0
- package/fixtures/openapi/EvaluationGateRequest/valid/candidate.json +5 -0
- package/fixtures/openapi/ExecutionCallbackRequest/invalid/extra-field.json +6 -0
- package/fixtures/openapi/ExecutionCallbackRequest/valid/succeeded.json +7 -0
- package/fixtures/openapi/GovernanceStatusEnvelope/invalid/window-hours-string.json +81 -0
- package/fixtures/openapi/GovernanceStatusEnvelope/valid/minimal.json +81 -0
- package/fixtures/openapi/IdentityErrorEnvelope/invalid/raw-assertion.json +7 -0
- package/fixtures/openapi/IdentityErrorEnvelope/valid/invalid-signature.json +7 -0
- package/fixtures/openapi/IdentityOutpostClaimRequest/invalid/missing-protocol-version.json +4 -0
- package/fixtures/openapi/IdentityOutpostClaimRequest/valid/current-version.json +5 -0
- package/fixtures/openapi/IdentityRuntimeCapabilityEnvelope/invalid/missing-runtime-state.json +17 -0
- package/fixtures/openapi/IdentityRuntimeCapabilityEnvelope/valid/available.json +17 -0
- package/fixtures/openapi/KnowledgeIngestionJobInput/invalid/missing-source.json +1 -0
- package/fixtures/openapi/KnowledgeIngestionJobInput/valid/source.json +3 -0
- package/fixtures/openapi/KubernetesResourceAgentCreateRequest/invalid/unresolved-target.json +18 -0
- package/fixtures/openapi/KubernetesResourceAgentCreateRequest/valid/resolved-target.json +25 -0
- package/fixtures/openapi/KubernetesResourceCreateRequest/invalid/unknown-source.json +5 -0
- package/fixtures/openapi/KubernetesResourceCreateRequest/valid/global-multi-document.json +5 -0
- package/fixtures/openapi/KubernetesResourceCreateResultEnvelope/invalid/bad-document-index.json +21 -0
- package/fixtures/openapi/KubernetesResourceCreateResultEnvelope/valid/partial.json +62 -0
- package/fixtures/openapi/KubernetesResourceCreateScopeDecisionEnvelope/invalid/missing-capability.json +12 -0
- package/fixtures/openapi/KubernetesResourceCreateScopeDecisionEnvelope/valid/allowed.json +17 -0
- package/fixtures/openapi/KubernetesResourcePreflightEnvelope/invalid/warning-without-message.json +32 -0
- package/fixtures/openapi/KubernetesResourcePreflightEnvelope/valid/mixed-diagnostics.json +83 -0
- package/fixtures/openapi/LogPage/invalid/missing-entry-source.json +12 -0
- package/fixtures/openapi/LogPage/valid/partial-runtime.json +42 -0
- package/fixtures/openapi/LogQuery/invalid/missing-selector.json +3 -0
- package/fixtures/openapi/LogQuery/invalid/unknown-source-mode.json +6 -0
- package/fixtures/openapi/LogQuery/valid/docker-project.json +12 -0
- package/fixtures/openapi/LogQuery/valid/runtime-workload.json +21 -0
- package/fixtures/openapi/LogStreamEvent/invalid/missing-entry.json +3 -0
- package/fixtures/openapi/LogStreamEvent/invalid/unknown-event-type.json +3 -0
- package/fixtures/openapi/LogStreamEvent/valid/live-entry.json +16 -0
- package/fixtures/openapi/MCPCapabilityListEnvelope/invalid/missing-scopes.json +9 -0
- package/fixtures/openapi/MCPCapabilityListEnvelope/valid/minimal.json +10 -0
- package/fixtures/openapi/MFAAdminResetRequest/invalid/missing-reason.json +3 -0
- package/fixtures/openapi/MFAAdminResetRequest/valid/security-incident.json +4 -0
- package/fixtures/openapi/MFAWebAuthnRequestOptionsEnvelope/invalid/missing-challenge-id.json +9 -0
- package/fixtures/openapi/MFAWebAuthnRequestOptionsEnvelope/valid/step-up.json +11 -0
- package/fixtures/openapi/ManifestDeploymentEnvelope/invalid/bad-condition-status.json +33 -0
- package/fixtures/openapi/ManifestDeploymentEnvelope/valid/converged.json +36 -0
- package/fixtures/openapi/ManifestSourceUpdateInput/invalid/unknown-mode.json +6 -0
- package/fixtures/openapi/ManifestSourceUpdateInput/valid/soha-managed.json +6 -0
- package/fixtures/openapi/ObservabilityDataSource/valid/healthy.json +33 -0
- package/fixtures/openapi/ObservabilityDataSourceInput/invalid/secret-in-config.json +9 -0
- package/fixtures/openapi/ObservabilityDataSourceInput/valid/loki.json +33 -0
- package/fixtures/openapi/ObservabilityDataSourceInput/valid/provider.json +21 -0
- package/fixtures/openapi/PasswordLoginRequest/invalid/extra-field.json +5 -0
- package/fixtures/openapi/PasswordLoginRequest/valid/password-login.json +4 -0
- package/fixtures/openapi/PersonalAccessTokenInput/invalid/extra-field.json +6 -0
- package/fixtures/openapi/PersonalAccessTokenInput/valid/create.json +9 -0
- package/fixtures/openapi/PluginManifest/invalid/bad-type.json +7 -0
- package/fixtures/openapi/PluginManifest/valid/skill-pack.json +12 -0
- package/fixtures/openapi/RepositoryInput/invalid/embedded-token.json +8 -0
- package/fixtures/openapi/RepositoryInput/valid/gitlab.json +11 -0
- package/fixtures/openapi/RuntimeConfigChangeRequest/invalid/missing-version.json +8 -0
- package/fixtures/openapi/RuntimeConfigChangeRequest/valid/feature-flags.json +14 -0
- package/fixtures/openapi/RuntimeConfigSnapshotEnvelope/invalid/editable-secret.json +17 -0
- package/fixtures/openapi/RuntimeConfigSnapshotEnvelope/invalid/exposed-default-secret.json +18 -0
- package/fixtures/openapi/RuntimeConfigSnapshotEnvelope/invalid/exposed-effective-secret.json +18 -0
- package/fixtures/openapi/RuntimeConfigSnapshotEnvelope/valid/effective.json +34 -0
- package/fixtures/openapi/SAMLMetadataInput/invalid/unknown-source.json +4 -0
- package/fixtures/openapi/SAMLMetadataInput/valid/xml.json +4 -0
- package/fixtures/openapi/SecretCreateRequest/invalid/missing-value.json +5 -0
- package/fixtures/openapi/SecretCreateRequest/valid/create.json +13 -0
- package/fixtures/openapi/SecretLeaseRedemptionEnvelope/invalid/invalid-alias.json +9 -0
- package/fixtures/openapi/SecretLeaseRedemptionEnvelope/valid/redeem.json +9 -0
- package/fixtures/openapi/SecretMetadataEnvelope/invalid/plaintext-value.json +15 -0
- package/fixtures/openapi/SecretMetadataEnvelope/valid/metadata.json +20 -0
- package/fixtures/openapi/SecretRotateRequest/invalid/empty-value.json +3 -0
- package/fixtures/openapi/SecretRotateRequest/valid/rotate.json +3 -0
- package/fixtures/openapi/ServiceAccountInput/invalid/missing-status.json +4 -0
- package/fixtures/openapi/ServiceAccountInput/valid/create.json +8 -0
- package/fixtures/openapi/WorkbenchStreamEvent/invalid/extra-field.json +11 -0
- package/fixtures/openapi/WorkbenchStreamEvent/invalid/missing-server-fields.json +5 -0
- package/fixtures/openapi/WorkbenchStreamEvent/valid/message-done.json +13 -0
- package/gen/go/sohaapi/client.go +989 -0
- package/gen/go/sohaapi/client_test.go +2127 -0
- package/gen/go/sohaapi/types.go +21450 -0
- package/gen/ts/sohaapi/index.ts +22869 -0
- package/go.mod +18 -0
- package/go.sum +46 -0
- package/governance/approval-request.schema.json +187 -0
- package/governance/audit-log.schema.json +37 -0
- package/helmrelease/release.go +108 -0
- package/helmrelease/release_test.go +9 -0
- package/knowledge/connector-checkpoint.schema.json +16 -0
- package/knowledge/connector-definition.schema.json +18 -0
- package/knowledge/context-envelope.schema.json +32 -0
- package/knowledge/graph-revision.schema.json +21 -0
- package/knowledge/index-publish.schema.json +17 -0
- package/knowledge/ingestion-job.schema.json +22 -0
- package/knowledge/ingestion-stage.schema.json +19 -0
- package/knowledge/knowledge-base.schema.json +48 -0
- package/knowledge/knowledge-search.schema.json +21 -0
- package/knowledge/knowledge-source.schema.json +28 -0
- package/knowledge/retrieval-trace.schema.json +21 -0
- package/mcp/gateway-capability-baseline.schema.json +290 -0
- package/mcp/gateway-manifest.schema.json +210 -0
- package/memory/memory-policy.schema.json +19 -0
- package/memory/memory-record.schema.json +25 -0
- package/openapi/soha-api.json +42282 -0
- package/openapi/soha-api.yaml +21748 -0
- package/openapi/spec_generated.go +23 -0
- package/openapi/spec_test.go +38 -0
- package/package.json +122 -0
- package/plugins/marketplace-catalog.schema.json +120 -0
- package/plugins/observability-log-query-v1.schema.json +88 -0
- package/plugins/plugin-manifest.schema.json +498 -0
- package/presets/mcp-preset.schema.json +142 -0
- package/profiles/agent-profile.schema.json +154 -0
- package/resource/crd_definition.go +10 -0
- package/resource/gateway_details_test.go +55 -0
- package/resource/models.go +1587 -0
- package/resource/models_test.go +72 -0
- package/runner/operation-lifecycle.schema.json +112 -0
- package/skills/skill-manifest.schema.json +64 -0
- package/streamlimit/limited_buffer.go +58 -0
- package/streamlimit/limited_buffer_test.go +38 -0
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://opensoha.dev/schemas/agent-provider-definition.schema.json",
|
|
4
|
+
"title": "Agent Provider Definition",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["schemaVersion", "id", "kind", "providerVersion", "adapterProtocol", "runtime", "capabilities"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"schemaVersion": { "const": "opensoha.dev/agent-provider-definition/v1" },
|
|
10
|
+
"id": { "type": "string", "pattern": "^[a-z][a-z0-9._-]{1,127}$" },
|
|
11
|
+
"kind": { "type": "string", "minLength": 1, "maxLength": 64 },
|
|
12
|
+
"displayName": { "type": "string", "maxLength": 160 },
|
|
13
|
+
"pluginId": { "type": "string", "maxLength": 128 },
|
|
14
|
+
"pluginVersion": { "type": "string", "maxLength": 64 },
|
|
15
|
+
"providerVersion": { "type": "string", "minLength": 1, "maxLength": 64 },
|
|
16
|
+
"adapterProtocol": { "type": "string", "minLength": 1, "maxLength": 128 },
|
|
17
|
+
"runtime": {
|
|
18
|
+
"type": "object",
|
|
19
|
+
"additionalProperties": false,
|
|
20
|
+
"required": ["kind"],
|
|
21
|
+
"properties": {
|
|
22
|
+
"kind": { "enum": ["cli", "container", "remote"] },
|
|
23
|
+
"command": { "type": "string", "maxLength": 1024 },
|
|
24
|
+
"args": { "type": "array", "maxItems": 64, "items": { "type": "string", "maxLength": 2048 } },
|
|
25
|
+
"promptArg": { "type": "string", "maxLength": 128 },
|
|
26
|
+
"skillArg": { "type": "string", "maxLength": 128 },
|
|
27
|
+
"providerSkillArg": { "type": "string", "maxLength": 128 },
|
|
28
|
+
"image": { "type": "string", "maxLength": 1024 },
|
|
29
|
+
"endpoint": { "type": "string", "format": "uri", "maxLength": 2048 },
|
|
30
|
+
"healthPath": { "type": "string", "maxLength": 512 }
|
|
31
|
+
},
|
|
32
|
+
"allOf": [
|
|
33
|
+
{ "if": { "properties": { "kind": { "const": "cli" } } }, "then": { "required": ["command"] } },
|
|
34
|
+
{ "if": { "properties": { "kind": { "const": "container" } } }, "then": { "required": ["image"] } },
|
|
35
|
+
{ "if": { "properties": { "kind": { "const": "remote" } } }, "then": { "required": ["endpoint"] } }
|
|
36
|
+
]
|
|
37
|
+
},
|
|
38
|
+
"capabilities": { "type": "array", "minItems": 1, "maxItems": 128, "uniqueItems": true, "items": { "type": "string", "minLength": 1, "maxLength": 128 } },
|
|
39
|
+
"requiredGatewayCapabilities": { "type": "array", "maxItems": 128, "uniqueItems": true, "items": { "type": "string", "minLength": 1, "maxLength": 128 } },
|
|
40
|
+
"requiredScopes": { "type": "array", "maxItems": 64, "uniqueItems": true, "items": { "type": "string", "minLength": 1, "maxLength": 128 } },
|
|
41
|
+
"secretRefs": { "type": "array", "maxItems": 64, "uniqueItems": true, "items": { "type": "string", "pattern": "^secret:[^\\s]{1,240}$" } },
|
|
42
|
+
"draining": { "type": "boolean", "default": false }
|
|
43
|
+
}
|
|
44
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://opensoha.dev/schemas/agent-provider-registry.schema.json",
|
|
4
|
+
"title": "Agent Provider Registry Snapshot",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["schemaVersion", "revision", "digest", "issuedAt", "providers"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"schemaVersion": { "const": "opensoha.dev/agent-provider-registry/v1" },
|
|
10
|
+
"revision": { "type": "integer", "minimum": 1 },
|
|
11
|
+
"digest": { "type": "string", "pattern": "^sha256:[a-f0-9]{64}$" },
|
|
12
|
+
"issuedAt": { "type": "string", "format": "date-time" },
|
|
13
|
+
"providers": { "type": "array", "maxItems": 256, "items": { "$ref": "agent-provider-definition.schema.json" } },
|
|
14
|
+
"fleetTarget": {
|
|
15
|
+
"type": "object",
|
|
16
|
+
"additionalProperties": false,
|
|
17
|
+
"properties": {
|
|
18
|
+
"environments": { "type": "array", "maxItems": 32, "items": { "type": "string", "maxLength": 64 } },
|
|
19
|
+
"platforms": { "type": "array", "maxItems": 16, "items": { "type": "string", "maxLength": 32 } },
|
|
20
|
+
"architectures": { "type": "array", "maxItems": 16, "items": { "type": "string", "maxLength": 32 } },
|
|
21
|
+
"labels": { "type": "object", "maxProperties": 32, "additionalProperties": { "type": "string", "maxLength": 128 } }
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://opensoha.dev/schemas/agent-provider-runtime-event.schema.json",
|
|
4
|
+
"title": "Agent Provider Runtime Event",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["schemaVersion", "eventType", "runnerId", "revision", "observedAt"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"schemaVersion": { "const": "opensoha.dev/agent-provider-runtime-event/v1" },
|
|
10
|
+
"eventType": { "enum": ["registry_ack", "registry_nack", "provider_health", "provider_draining"] },
|
|
11
|
+
"runnerId": { "type": "string", "minLength": 1, "maxLength": 128 },
|
|
12
|
+
"revision": { "type": "integer", "minimum": 1 },
|
|
13
|
+
"activeRevision": { "type": "integer", "minimum": 0 },
|
|
14
|
+
"providerId": { "type": "string", "maxLength": 128 },
|
|
15
|
+
"providerVersion": { "type": "string", "maxLength": 64 },
|
|
16
|
+
"health": { "enum": ["healthy", "degraded", "unhealthy"] },
|
|
17
|
+
"draining": { "type": "boolean" },
|
|
18
|
+
"activeRuns": { "type": "integer", "minimum": 0 },
|
|
19
|
+
"reason": { "type": "string", "maxLength": 2048 },
|
|
20
|
+
"observedAt": { "type": "string", "format": "date-time" }
|
|
21
|
+
},
|
|
22
|
+
"allOf": [
|
|
23
|
+
{ "if": { "properties": { "eventType": { "enum": ["registry_ack", "registry_nack"] } } }, "then": { "required": ["activeRevision"] } },
|
|
24
|
+
{ "if": { "properties": { "eventType": { "enum": ["provider_health", "provider_draining"] } } }, "then": { "required": ["providerId", "providerVersion", "health", "draining", "activeRuns"] } }
|
|
25
|
+
]
|
|
26
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://opensoha.dev/schemas/agent-run-step.schema.json",
|
|
4
|
+
"title": "Agent Run Step",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["schemaVersion", "id", "runId", "sequence", "attempt", "state", "contextRef", "startedAt"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"schemaVersion": { "const": "opensoha.dev/agent-run-step/v1" },
|
|
10
|
+
"id": { "type": "string", "minLength": 1, "maxLength": 128 },
|
|
11
|
+
"runId": { "type": "string", "minLength": 1, "maxLength": 128 },
|
|
12
|
+
"sequence": { "type": "integer", "minimum": 1 },
|
|
13
|
+
"attempt": { "type": "integer", "minimum": 1 },
|
|
14
|
+
"state": { "enum": ["queued", "preparing", "running", "waiting_approval", "waiting_environment", "paused", "rejected", "completed", "failed", "cancelled", "budget_exceeded", "timed_out"] },
|
|
15
|
+
"contextRef": { "type": "string", "minLength": 1, "maxLength": 512 },
|
|
16
|
+
"modelCallRef": { "type": "string", "maxLength": 512 },
|
|
17
|
+
"toolCallRefs": { "type": "array", "maxItems": 128, "items": { "type": "string", "maxLength": 512 } },
|
|
18
|
+
"observationRefs": { "type": "array", "maxItems": 256, "items": { "type": "string", "maxLength": 512 } },
|
|
19
|
+
"checkpointRef": { "type": "string", "maxLength": 512 },
|
|
20
|
+
"stopReason": { "enum": ["answer_accepted", "max_steps", "max_tokens", "max_tool_calls", "max_cost", "deadline", "no_progress", "user_cancelled", "policy_denied", "provider_stop", "environment_failure"] },
|
|
21
|
+
"startedAt": { "type": "string", "format": "date-time" },
|
|
22
|
+
"completedAt": { "type": "string", "format": "date-time" }
|
|
23
|
+
}
|
|
24
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://opensoha.dev/schemas/agent/conformance-run.schema.json",
|
|
4
|
+
"title": "Agent Provider Conformance Run",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["schemaVersion", "id", "providerRef", "environmentRef", "suiteVersion", "status", "results", "startedAt"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"schemaVersion": { "const": "opensoha.dev/agent-conformance-run/v1" },
|
|
10
|
+
"id": { "type": "string", "minLength": 1 },
|
|
11
|
+
"providerRef": { "type": "string", "minLength": 1 },
|
|
12
|
+
"environmentRef": { "type": "string", "minLength": 1 },
|
|
13
|
+
"suiteVersion": { "type": "string", "minLength": 1 },
|
|
14
|
+
"status": { "enum": ["queued", "running", "passed", "failed", "cancelled"] },
|
|
15
|
+
"results": { "type": "array", "maxItems": 128, "items": { "type": "object", "required": ["name", "passed"], "properties": { "name": { "type": "string" }, "passed": { "type": "boolean" }, "evidenceRef": { "type": "string" } }, "additionalProperties": false } },
|
|
16
|
+
"startedAt": { "type": "string", "format": "date-time" },
|
|
17
|
+
"completedAt": { "type": "string", "format": "date-time" }
|
|
18
|
+
}
|
|
19
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://opensoha.dev/schemas/environment-lease.schema.json",
|
|
4
|
+
"title": "Agent Environment Lease",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["schemaVersion", "id", "runId", "ownerId", "scopeHash", "mode", "quota", "issuedAt", "expiresAt"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"schemaVersion": { "const": "opensoha.dev/environment-lease/v1" },
|
|
10
|
+
"id": { "type": "string", "minLength": 1, "maxLength": 128 },
|
|
11
|
+
"runId": { "type": "string", "minLength": 1, "maxLength": 128 },
|
|
12
|
+
"ownerId": { "type": "string", "minLength": 1, "maxLength": 128 },
|
|
13
|
+
"scopeHash": { "type": "string", "pattern": "^sha256:[a-f0-9]{64}$" },
|
|
14
|
+
"mode": { "enum": ["observe-only", "restricted-write"] },
|
|
15
|
+
"workspacePath": { "type": "string", "maxLength": 2048 },
|
|
16
|
+
"quota": {
|
|
17
|
+
"type": "object", "additionalProperties": false,
|
|
18
|
+
"required": ["diskBytes", "memoryBytes", "cpuUnits", "maxProcesses", "networkEgress"],
|
|
19
|
+
"properties": {
|
|
20
|
+
"diskBytes": { "type": "integer", "minimum": 1 },
|
|
21
|
+
"memoryBytes": { "type": "integer", "minimum": 1 },
|
|
22
|
+
"cpuUnits": { "type": "integer", "minimum": 1 },
|
|
23
|
+
"maxProcesses": { "type": "integer", "minimum": 1 },
|
|
24
|
+
"networkEgress": { "type": "boolean" }
|
|
25
|
+
}
|
|
26
|
+
},
|
|
27
|
+
"issuedAt": { "type": "string", "format": "date-time" },
|
|
28
|
+
"expiresAt": { "type": "string", "format": "date-time" },
|
|
29
|
+
"releasedAt": { "type": "string", "format": "date-time" }
|
|
30
|
+
}
|
|
31
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://opensoha.dev/schemas/environment-snapshot.schema.json",
|
|
4
|
+
"title": "Agent Environment Snapshot",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["schemaVersion", "leaseId", "runId", "state", "resourceUsage", "observedAt"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"schemaVersion": { "const": "opensoha.dev/environment-snapshot/v1" },
|
|
10
|
+
"leaseId": { "type": "string", "minLength": 1, "maxLength": 128 },
|
|
11
|
+
"runId": { "type": "string", "minLength": 1, "maxLength": 128 },
|
|
12
|
+
"state": { "enum": ["active", "released", "expired", "quota_exceeded"] },
|
|
13
|
+
"resourceUsage": {
|
|
14
|
+
"type": "object", "additionalProperties": false,
|
|
15
|
+
"required": ["diskBytes", "memoryBytes", "cpuTimeNanos", "processes"],
|
|
16
|
+
"properties": {
|
|
17
|
+
"diskBytes": { "type": "integer", "minimum": 0 },
|
|
18
|
+
"memoryBytes": { "type": "integer", "minimum": 0 },
|
|
19
|
+
"cpuTimeNanos": { "type": "integer", "minimum": 0 },
|
|
20
|
+
"processes": { "type": "integer", "minimum": 0 }
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
"artifactRefs": { "type": "array", "maxItems": 128, "uniqueItems": true, "items": { "type": "string", "maxLength": 512 } },
|
|
24
|
+
"observedAt": { "type": "string", "format": "date-time" }
|
|
25
|
+
}
|
|
26
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://opensoha.dev/schemas/agent/environment-template.schema.json",
|
|
4
|
+
"title": "Agent Environment Template",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["schemaVersion", "id", "version", "backend", "isolationMode", "quota", "ttlSeconds", "enabled"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"schemaVersion": { "const": "opensoha.dev/agent-environment-template/v1" },
|
|
10
|
+
"id": { "type": "string", "minLength": 1 },
|
|
11
|
+
"version": { "type": "string", "minLength": 1 },
|
|
12
|
+
"backend": { "enum": ["local-process", "container", "kubernetes"] },
|
|
13
|
+
"isolationMode": { "enum": ["observe-only", "restricted-write", "disposable-write"] },
|
|
14
|
+
"quota": { "type": "object", "required": ["cpuUnits", "memoryBytes", "diskBytes", "maxProcesses"], "properties": { "cpuUnits": { "type": "integer", "minimum": 1 }, "memoryBytes": { "type": "integer", "minimum": 1 }, "diskBytes": { "type": "integer", "minimum": 1 }, "maxProcesses": { "type": "integer", "minimum": 1 } }, "additionalProperties": false },
|
|
15
|
+
"networkEgress": { "type": "boolean" },
|
|
16
|
+
"ttlSeconds": { "type": "integer", "minimum": 1, "maximum": 86400 },
|
|
17
|
+
"enabled": { "type": "boolean" }
|
|
18
|
+
}
|
|
19
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://opensoha.dev/schemas/agent/fleet-target.schema.json",
|
|
4
|
+
"title": "Agent Fleet Target",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["schemaVersion"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"schemaVersion": { "const": "opensoha.dev/agent-fleet-target/v1" },
|
|
10
|
+
"environments": { "type": "array", "maxItems": 32, "uniqueItems": true, "items": { "type": "string", "maxLength": 64 } },
|
|
11
|
+
"platforms": { "type": "array", "maxItems": 16, "uniqueItems": true, "items": { "type": "string", "maxLength": 32 } },
|
|
12
|
+
"architectures": { "type": "array", "maxItems": 16, "uniqueItems": true, "items": { "type": "string", "maxLength": 32 } },
|
|
13
|
+
"labels": { "type": "object", "maxProperties": 32, "additionalProperties": { "type": "string", "maxLength": 128 } }
|
|
14
|
+
}
|
|
15
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://opensoha.dev/schemas/agent/multi-agent-plan.schema.json",
|
|
4
|
+
"title": "Bounded Multi-Agent Plan",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["schemaVersion", "id", "coordinatorRef", "subtasks", "sharedBudget", "status", "createdAt"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"schemaVersion": { "const": "opensoha.dev/multi-agent-plan/v1" },
|
|
10
|
+
"id": { "type": "string", "minLength": 1 },
|
|
11
|
+
"coordinatorRef": { "type": "string", "minLength": 1 },
|
|
12
|
+
"subtasks": { "type": "array", "minItems": 1, "maxItems": 8, "items": { "type": "object", "required": ["id", "agentProfileRef", "input", "permissionKeys", "status"], "properties": { "id": { "type": "string" }, "agentProfileRef": { "type": "string" }, "input": { "type": "string", "maxLength": 16000 }, "permissionKeys": { "type": "array", "maxItems": 64, "items": { "type": "string" } }, "status": { "enum": ["pending", "running", "completed", "failed", "cancelled"] } }, "additionalProperties": false } },
|
|
13
|
+
"sharedBudget": { "type": "object", "required": ["maxSteps", "maxTokens", "maxCost", "deadlineSeconds"], "properties": { "maxSteps": { "type": "integer", "minimum": 1, "maximum": 100 }, "maxTokens": { "type": "integer", "minimum": 1, "maximum": 2000000 }, "maxCost": { "type": "number", "minimum": 0 }, "deadlineSeconds": { "type": "integer", "minimum": 1, "maximum": 86400 } }, "additionalProperties": false },
|
|
14
|
+
"status": { "enum": ["running", "completed", "failed", "cancelled"] },
|
|
15
|
+
"createdAt": { "type": "string", "format": "date-time" },
|
|
16
|
+
"completedAt": { "type": "string", "format": "date-time" }
|
|
17
|
+
}
|
|
18
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://opensoha.dev/schemas/agent/provider-rollout.schema.json",
|
|
4
|
+
"title": "Agent Provider Rollout",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["schemaVersion", "id", "desiredRevision", "previousRevision", "target", "status", "createdAt"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"schemaVersion": { "const": "opensoha.dev/agent-provider-rollout/v1" },
|
|
10
|
+
"id": { "type": "string", "minLength": 1 },
|
|
11
|
+
"desiredRevision": { "type": "integer", "minimum": 1 },
|
|
12
|
+
"previousRevision": { "type": "integer", "minimum": 0 },
|
|
13
|
+
"target": { "type": "object" },
|
|
14
|
+
"status": { "enum": ["draft", "validating", "canary", "rolling_out", "paused", "converged", "rolling_back", "rolled_back", "failed"] },
|
|
15
|
+
"batchSize": { "type": "integer", "minimum": 1, "maximum": 1000 },
|
|
16
|
+
"ackTimeoutSeconds": { "type": "integer", "minimum": 1, "maximum": 86400 },
|
|
17
|
+
"createdAt": { "type": "string", "format": "date-time" }
|
|
18
|
+
}
|
|
19
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
package apiresponse
|
|
2
|
+
|
|
3
|
+
type ErrorBody struct {
|
|
4
|
+
Code string `json:"code"`
|
|
5
|
+
Message string `json:"message"`
|
|
6
|
+
RequestID string `json:"request_id,omitempty"`
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
func Item(data any) map[string]any {
|
|
10
|
+
return map[string]any{"data": data}
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
func Items(items any) map[string]any {
|
|
14
|
+
return map[string]any{"items": items}
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
func Error(code, message, requestID string) map[string]any {
|
|
18
|
+
return map[string]any{
|
|
19
|
+
"error": ErrorBody{
|
|
20
|
+
Code: code,
|
|
21
|
+
Message: message,
|
|
22
|
+
RequestID: requestID,
|
|
23
|
+
},
|
|
24
|
+
}
|
|
25
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
package apiresponse
|
|
2
|
+
|
|
3
|
+
import "testing"
|
|
4
|
+
|
|
5
|
+
func TestItemAndItems(t *testing.T) {
|
|
6
|
+
t.Parallel()
|
|
7
|
+
|
|
8
|
+
if got := Item("value")["data"]; got != "value" {
|
|
9
|
+
t.Fatalf("Item() data = %v, want value", got)
|
|
10
|
+
}
|
|
11
|
+
if got := Items([]string{"a"})["items"]; got == nil {
|
|
12
|
+
t.Fatal("Items() items is nil")
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
func TestError(t *testing.T) {
|
|
17
|
+
t.Parallel()
|
|
18
|
+
|
|
19
|
+
payload := Error("invalid_argument", "bad input", "request-1")
|
|
20
|
+
body, ok := payload["error"].(ErrorBody)
|
|
21
|
+
if !ok {
|
|
22
|
+
t.Fatalf("Error() error body type = %T, want ErrorBody", payload["error"])
|
|
23
|
+
}
|
|
24
|
+
if body.Code != "invalid_argument" || body.Message != "bad input" || body.RequestID != "request-1" {
|
|
25
|
+
t.Fatalf("Error() body = %#v", body)
|
|
26
|
+
}
|
|
27
|
+
}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://contracts.opensoha.dev/auth/token-claims.schema.json",
|
|
4
|
+
"title": "Soha Token Claims",
|
|
5
|
+
"description": "JWT/access-token claims shared by Soha core, CLI, agent runtime, and future cloud edge services.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"required": ["sub", "exp", "iat", "tokenId", "tokenKind", "subjectType", "subjectId"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"iss": { "type": "string" },
|
|
10
|
+
"sub": { "type": "string", "minLength": 1 },
|
|
11
|
+
"aud": {
|
|
12
|
+
"oneOf": [
|
|
13
|
+
{ "type": "string" },
|
|
14
|
+
{
|
|
15
|
+
"type": "array",
|
|
16
|
+
"items": { "type": "string" }
|
|
17
|
+
}
|
|
18
|
+
]
|
|
19
|
+
},
|
|
20
|
+
"exp": { "type": "integer" },
|
|
21
|
+
"nbf": { "type": "integer" },
|
|
22
|
+
"iat": { "type": "integer" },
|
|
23
|
+
"jti": { "type": "string" },
|
|
24
|
+
"tenantId": {
|
|
25
|
+
"type": "string",
|
|
26
|
+
"default": "default"
|
|
27
|
+
},
|
|
28
|
+
"workspaceId": {
|
|
29
|
+
"type": "string",
|
|
30
|
+
"default": "default"
|
|
31
|
+
},
|
|
32
|
+
"tokenId": { "type": "string", "minLength": 1 },
|
|
33
|
+
"tokenKind": {
|
|
34
|
+
"type": "string",
|
|
35
|
+
"enum": [
|
|
36
|
+
"session",
|
|
37
|
+
"personal_access_token",
|
|
38
|
+
"service_account",
|
|
39
|
+
"runtime_execution_runner",
|
|
40
|
+
"stream_ticket"
|
|
41
|
+
]
|
|
42
|
+
},
|
|
43
|
+
"sessionId": { "type": "string" },
|
|
44
|
+
"subjectType": {
|
|
45
|
+
"type": "string",
|
|
46
|
+
"enum": ["user", "service_account", "runner", "anonymous"]
|
|
47
|
+
},
|
|
48
|
+
"subjectId": { "type": "string", "minLength": 1 },
|
|
49
|
+
"userId": { "type": "string" },
|
|
50
|
+
"userName": { "type": "string" },
|
|
51
|
+
"email": { "type": "string" },
|
|
52
|
+
"roles": {
|
|
53
|
+
"type": "array",
|
|
54
|
+
"items": { "type": "string" }
|
|
55
|
+
},
|
|
56
|
+
"teams": {
|
|
57
|
+
"type": "array",
|
|
58
|
+
"items": { "type": "string" }
|
|
59
|
+
},
|
|
60
|
+
"projects": {
|
|
61
|
+
"type": "array",
|
|
62
|
+
"items": { "type": "string" }
|
|
63
|
+
},
|
|
64
|
+
"permissionKeys": {
|
|
65
|
+
"type": "array",
|
|
66
|
+
"items": { "type": "string" }
|
|
67
|
+
},
|
|
68
|
+
"scopes": {
|
|
69
|
+
"type": "array",
|
|
70
|
+
"items": { "type": "string" }
|
|
71
|
+
},
|
|
72
|
+
"aiClientId": { "type": "string" },
|
|
73
|
+
"skillId": { "type": "string" },
|
|
74
|
+
"path": { "type": "string" }
|
|
75
|
+
},
|
|
76
|
+
"additionalProperties": true
|
|
77
|
+
}
|
|
78
|
+
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://contracts.opensoha.dev/capabilities/cluster-capability-matrix.schema.json",
|
|
4
|
+
"title": "OpenSoha Cluster Capability Matrix",
|
|
5
|
+
"description": "Shared capability matrix for Direct and Agent runtime support across Kubernetes, Helm, YAML, logs, exec, port-forward, and Docker capabilities.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"additionalProperties": false,
|
|
8
|
+
"required": ["items"],
|
|
9
|
+
"properties": {
|
|
10
|
+
"generatedAt": {
|
|
11
|
+
"type": "string",
|
|
12
|
+
"format": "date-time"
|
|
13
|
+
},
|
|
14
|
+
"capabilitySetVersion": {
|
|
15
|
+
"type": "string",
|
|
16
|
+
"minLength": 1
|
|
17
|
+
},
|
|
18
|
+
"items": {
|
|
19
|
+
"type": "array",
|
|
20
|
+
"minItems": 1,
|
|
21
|
+
"items": { "$ref": "#/$defs/CapabilityMatrixEntry" }
|
|
22
|
+
}
|
|
23
|
+
},
|
|
24
|
+
"$defs": {
|
|
25
|
+
"CapabilityStatus": {
|
|
26
|
+
"type": "string",
|
|
27
|
+
"enum": ["available", "partial", "unsupported"]
|
|
28
|
+
},
|
|
29
|
+
"RiskLevel": {
|
|
30
|
+
"type": "string",
|
|
31
|
+
"enum": ["read", "analyze", "mutate", "execute", "high"]
|
|
32
|
+
},
|
|
33
|
+
"ModeSupport": {
|
|
34
|
+
"type": "object",
|
|
35
|
+
"additionalProperties": false,
|
|
36
|
+
"required": ["status"],
|
|
37
|
+
"allOf": [
|
|
38
|
+
{
|
|
39
|
+
"if": {
|
|
40
|
+
"required": ["status"],
|
|
41
|
+
"properties": {
|
|
42
|
+
"status": { "enum": ["partial", "unsupported"] }
|
|
43
|
+
}
|
|
44
|
+
},
|
|
45
|
+
"then": { "required": ["reason"] }
|
|
46
|
+
}
|
|
47
|
+
],
|
|
48
|
+
"properties": {
|
|
49
|
+
"status": { "$ref": "#/$defs/CapabilityStatus" },
|
|
50
|
+
"reason": { "type": "string", "minLength": 1 },
|
|
51
|
+
"diagnostic": { "type": "string" },
|
|
52
|
+
"requiredAgentVersion": { "type": "string" },
|
|
53
|
+
"requiredScopes": {
|
|
54
|
+
"type": "array",
|
|
55
|
+
"items": { "type": "string", "minLength": 1 },
|
|
56
|
+
"uniqueItems": true
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
"CapabilityMatrixEntry": {
|
|
61
|
+
"type": "object",
|
|
62
|
+
"additionalProperties": false,
|
|
63
|
+
"required": ["key", "label", "category", "riskLevel", "requiresApproval", "direct", "agent"],
|
|
64
|
+
"properties": {
|
|
65
|
+
"key": {
|
|
66
|
+
"type": "string",
|
|
67
|
+
"minLength": 1,
|
|
68
|
+
"pattern": "^[a-z][a-z0-9]*(\\.[a-z][a-z0-9-]*)+$",
|
|
69
|
+
"description": "Stable capability key such as kubernetes.yaml.apply or docker.logs.stream."
|
|
70
|
+
},
|
|
71
|
+
"label": { "type": "string", "minLength": 1 },
|
|
72
|
+
"category": {
|
|
73
|
+
"type": "string",
|
|
74
|
+
"enum": ["kubernetes", "helm", "yaml", "logs", "exec", "port-forward", "docker", "runtime"]
|
|
75
|
+
},
|
|
76
|
+
"riskLevel": { "$ref": "#/$defs/RiskLevel" },
|
|
77
|
+
"requiresApproval": { "type": "boolean" },
|
|
78
|
+
"direct": { "$ref": "#/$defs/ModeSupport" },
|
|
79
|
+
"agent": { "$ref": "#/$defs/ModeSupport" },
|
|
80
|
+
"metadata": {
|
|
81
|
+
"type": "object",
|
|
82
|
+
"additionalProperties": true
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": "0.1.4",
|
|
3
|
+
"schemas": {
|
|
4
|
+
"plugins/plugin-manifest.schema.json": {
|
|
5
|
+
"rootRequired": ["id", "name", "publisher", "type", "version"],
|
|
6
|
+
"rootProperties": [
|
|
7
|
+
"assets",
|
|
8
|
+
"capabilities",
|
|
9
|
+
"compatibility",
|
|
10
|
+
"description",
|
|
11
|
+
"homepage",
|
|
12
|
+
"id",
|
|
13
|
+
"integrity",
|
|
14
|
+
"metadata",
|
|
15
|
+
"name",
|
|
16
|
+
"permissions",
|
|
17
|
+
"publisher",
|
|
18
|
+
"secrets",
|
|
19
|
+
"type",
|
|
20
|
+
"version"
|
|
21
|
+
],
|
|
22
|
+
"enums": [
|
|
23
|
+
{
|
|
24
|
+
"path": "properties/type",
|
|
25
|
+
"values": [
|
|
26
|
+
"agent-profile",
|
|
27
|
+
"ai-provider-adapter",
|
|
28
|
+
"connector",
|
|
29
|
+
"gateway-policy-pack",
|
|
30
|
+
"mcp-preset",
|
|
31
|
+
"skill",
|
|
32
|
+
"skill-pack"
|
|
33
|
+
]
|
|
34
|
+
}
|
|
35
|
+
]
|
|
36
|
+
},
|
|
37
|
+
"skills/skill-manifest.schema.json": {
|
|
38
|
+
"rootRequired": ["category", "id", "name"],
|
|
39
|
+
"rootProperties": [
|
|
40
|
+
"capabilityRefs",
|
|
41
|
+
"category",
|
|
42
|
+
"description",
|
|
43
|
+
"id",
|
|
44
|
+
"metadata",
|
|
45
|
+
"name",
|
|
46
|
+
"permissionKeys",
|
|
47
|
+
"providerSkillRefs",
|
|
48
|
+
"requiredScopes",
|
|
49
|
+
"version"
|
|
50
|
+
],
|
|
51
|
+
"enums": []
|
|
52
|
+
},
|
|
53
|
+
"connectors/connector-event-envelope.schema.json": {
|
|
54
|
+
"rootRequired": ["connectorId", "events"],
|
|
55
|
+
"rootProperties": ["connectorId", "events"],
|
|
56
|
+
"enums": []
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|