opencode-a2a-server 0.2.3__tar.gz → 0.2.4__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (66) hide show
  1. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/CONTRIBUTING.md +33 -9
  2. opencode_a2a_server-0.2.4/PKG-INFO +171 -0
  3. opencode_a2a_server-0.2.4/README.md +133 -0
  4. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/SECURITY.md +8 -5
  5. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/docs/guide.md +139 -153
  6. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/src/opencode_a2a_server/agent.py +36 -2
  7. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/src/opencode_a2a_server/app.py +7 -26
  8. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/src/opencode_a2a_server/config.py +0 -19
  9. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/src/opencode_a2a_server/extension_contracts.py +11 -18
  10. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/src/opencode_a2a_server/opencode_client.py +108 -96
  11. opencode_a2a_server-0.2.4/src/opencode_a2a_server.egg-info/PKG-INFO +171 -0
  12. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/src/opencode_a2a_server.egg-info/SOURCES.txt +0 -2
  13. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_agent_card.py +9 -10
  14. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_extension_contract_consistency.py +5 -6
  15. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_opencode_client_params.py +2 -39
  16. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_opencode_session_extension.py +21 -0
  17. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_settings.py +0 -10
  18. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_streaming_output_contract.py +61 -0
  19. opencode_a2a_server-0.2.3/PKG-INFO +0 -376
  20. opencode_a2a_server-0.2.3/README.md +0 -338
  21. opencode_a2a_server-0.2.3/src/opencode_a2a_server/opencode_upstream.py +0 -122
  22. opencode_a2a_server-0.2.3/src/opencode_a2a_server.egg-info/PKG-INFO +0 -376
  23. opencode_a2a_server-0.2.3/tests/test_opencode_upstream.py +0 -162
  24. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/.github/workflows/ci.yml +0 -0
  25. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/.github/workflows/dependency-health.yml +0 -0
  26. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/.github/workflows/publish.yml +0 -0
  27. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/.gitignore +0 -0
  28. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/.pre-commit-config.yaml +0 -0
  29. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/.secrets.baseline +0 -0
  30. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/AGENTS.md +0 -0
  31. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/LICENSE +0 -0
  32. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/pyproject.toml +0 -0
  33. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/scripts/README.md +0 -0
  34. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/scripts/dependency_health.sh +0 -0
  35. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/scripts/doctor.sh +0 -0
  36. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/scripts/health_common.sh +0 -0
  37. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/scripts/lint.sh +0 -0
  38. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/scripts/smoke_test_built_cli.sh +0 -0
  39. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/setup.cfg +0 -0
  40. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/src/opencode_a2a_server/__init__.py +0 -0
  41. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/src/opencode_a2a_server/cli.py +0 -0
  42. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/src/opencode_a2a_server/jsonrpc_ext.py +4 -4
  43. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/src/opencode_a2a_server/jsonrpc_models.py +0 -0
  44. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/src/opencode_a2a_server/parts_mapper.py +0 -0
  45. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/src/opencode_a2a_server/text_parts.py +0 -0
  46. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/src/opencode_a2a_server.egg-info/dependency_links.txt +0 -0
  47. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/src/opencode_a2a_server.egg-info/entry_points.txt +0 -0
  48. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/src/opencode_a2a_server.egg-info/requires.txt +0 -0
  49. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/src/opencode_a2a_server.egg-info/top_level.txt +0 -0
  50. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/__init__.py +0 -0
  51. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/helpers.py +0 -0
  52. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_agent_errors.py +0 -0
  53. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_call_context_builder.py +0 -0
  54. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_cancel_contract.py +0 -0
  55. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_cancellation.py +0 -0
  56. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_cli.py +0 -0
  57. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_directory_validation.py +0 -0
  58. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_jsonrpc_models.py +0 -0
  59. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_jsonrpc_unsupported_method.py +0 -0
  60. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_metrics.py +0 -0
  61. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_multipart_input.py +0 -0
  62. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_opencode_agent_session_binding.py +0 -0
  63. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_script_health_contract.py +0 -0
  64. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_session_ownership.py +0 -0
  65. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/tests/test_transport_contract.py +0 -0
  66. {opencode_a2a_server-0.2.3 → opencode_a2a_server-0.2.4}/uv.lock +0 -0
@@ -2,9 +2,9 @@
2
2
 
3
3
  Thanks for contributing to `opencode-a2a-server`.
4
4
 
5
- This repository is maintained as a streaming-first A2A wrapper around OpenCode.
6
- Changes should keep runtime behavior, Agent Card declarations, OpenAPI examples,
7
- and machine-readable extension contracts aligned.
5
+ This repository maintains an A2A adapter service around OpenCode. Changes
6
+ should keep runtime behavior, Agent Card declarations, OpenAPI examples, and
7
+ machine-readable extension contracts aligned.
8
8
 
9
9
  ## Before You Start
10
10
 
@@ -26,12 +26,19 @@ Install dependencies:
26
26
  uv sync --all-extras
27
27
  ```
28
28
 
29
- Run the local development server:
29
+ Start OpenCode in one terminal:
30
+
31
+ ```bash
32
+ opencode serve --hostname 127.0.0.1 --port 4096
33
+ ```
34
+
35
+ Then start the A2A server in another terminal:
30
36
 
31
37
  ```bash
32
38
  A2A_BEARER_TOKEN=dev-token \
33
- OPENCODE_DIRECTORY=/abs/path/to/workspace \
34
- uv run opencode-a2a-server
39
+ OPENCODE_BASE_URL=http://127.0.0.1:4096 \
40
+ OPENCODE_WORKSPACE_ROOT=/abs/path/to/workspace \
41
+ uv run opencode-a2a-server serve
35
42
  ```
36
43
 
37
44
  ## Validation
@@ -43,11 +50,20 @@ uv run pre-commit run --all-files
43
50
  uv run pytest
44
51
  ```
45
52
 
46
- If you change shell or deployment scripts, also run:
53
+ If you change shell scripts, also run `bash -n` on each modified script, for
54
+ example:
55
+
56
+ ```bash
57
+ bash -n scripts/doctor.sh
58
+ bash -n scripts/lint.sh
59
+ ```
60
+
61
+ If you change extension methods, extension metadata, or Agent Card/OpenAPI
62
+ contract surfaces, also run:
47
63
 
48
64
  ```bash
49
- bash -n scripts/deploy.sh
50
- bash -n scripts/deploy/setup_instance.sh
65
+ uv run pytest tests/test_extension_contract_consistency.py
66
+ uv run mypy src/opencode_a2a_server
51
67
  ```
52
68
 
53
69
  ## Change Expectations
@@ -77,3 +93,11 @@ Update docs together with code whenever you change:
77
93
 
78
94
  Keep compatibility guidance centralized in [docs/guide.md](docs/guide.md) unless a
79
95
  new standalone document is clearly necessary.
96
+
97
+ When changing extension contracts, update
98
+ [`src/opencode_a2a_server/extension_contracts.py`](src/opencode_a2a_server/extension_contracts.py)
99
+ first and keep these generated/documented surfaces aligned:
100
+
101
+ - Agent Card extension params
102
+ - OpenAPI `POST /` extension metadata and examples
103
+ - JSON-RPC notification behavior (`204 No Content`)
@@ -0,0 +1,171 @@
1
+ Metadata-Version: 2.4
2
+ Name: opencode-a2a-server
3
+ Version: 0.2.4
4
+ Summary: A2A wrapper service for opencode
5
+ Author: liujuanjuan1984@Intelligent-Internet
6
+ License-Expression: Apache-2.0
7
+ Project-URL: Homepage, https://github.com/Intelligent-Internet/opencode-a2a-server
8
+ Project-URL: Repository, https://github.com/Intelligent-Internet/opencode-a2a-server
9
+ Project-URL: Issues, https://github.com/Intelligent-Internet/opencode-a2a-server/issues
10
+ Keywords: a2a,opencode,fastapi,json-rpc,sse
11
+ Classifier: Development Status :: 3 - Alpha
12
+ Classifier: Intended Audience :: Developers
13
+ Classifier: Programming Language :: Python :: 3
14
+ Classifier: Programming Language :: Python :: 3.11
15
+ Classifier: Programming Language :: Python :: 3.12
16
+ Classifier: Programming Language :: Python :: 3.13
17
+ Classifier: Framework :: FastAPI
18
+ Classifier: Topic :: Internet :: WWW/HTTP
19
+ Requires-Python: >=3.11
20
+ Description-Content-Type: text/markdown
21
+ License-File: LICENSE
22
+ Requires-Dist: a2a-sdk==0.3.25
23
+ Requires-Dist: fastapi>=0.110
24
+ Requires-Dist: httpx>=0.27
25
+ Requires-Dist: pydantic>=2.6
26
+ Requires-Dist: pydantic-settings>=2.2
27
+ Requires-Dist: sse-starlette>=2.1
28
+ Requires-Dist: uvicorn>=0.29
29
+ Provides-Extra: dev
30
+ Requires-Dist: mypy>=1.19.1; extra == "dev"
31
+ Requires-Dist: pip-audit>=2.9; extra == "dev"
32
+ Requires-Dist: pre-commit>=3.7; extra == "dev"
33
+ Requires-Dist: pytest>=8.0; extra == "dev"
34
+ Requires-Dist: pytest-asyncio>=0.23; extra == "dev"
35
+ Requires-Dist: pytest-cov>=7.0.0; extra == "dev"
36
+ Requires-Dist: ruff>=0.5; extra == "dev"
37
+ Dynamic: license-file
38
+
39
+ # opencode-a2a-server
40
+
41
+ > Expose OpenCode through A2A.
42
+
43
+ `opencode-a2a-server` adds an A2A service layer to `opencode serve`, with
44
+ auth, streaming, session continuity, interrupt handling, and a clear
45
+ deployment boundary.
46
+
47
+ ## What This Is
48
+
49
+ - An A2A adapter service for `opencode serve`.
50
+ - Use it when you need a stable A2A endpoint for apps, gateways, or A2A
51
+ clients.
52
+
53
+ ```mermaid
54
+ flowchart TD
55
+ Client["a2a-client-hub / any A2A client"]
56
+
57
+ subgraph ServerSide["Server-side"]
58
+ Adapter["opencode-a2a-server\nA2A adapter service"]
59
+ Runtime["opencode serve\nOpenCode runtime"]
60
+
61
+ Adapter <--> Runtime
62
+ end
63
+
64
+ Client <--> Adapter
65
+ ```
66
+
67
+ ## Quick Start
68
+
69
+ Install the released CLI with `uv tool`:
70
+
71
+ ```bash
72
+ uv tool install opencode-a2a-server
73
+ ```
74
+
75
+ Upgrade later with:
76
+
77
+ ```bash
78
+ uv tool upgrade opencode-a2a-server
79
+ ```
80
+
81
+ Make sure provider credentials and a default model are configured on the
82
+ OpenCode side, then start OpenCode:
83
+
84
+ ```bash
85
+ opencode auth login
86
+ opencode models
87
+ opencode serve --hostname 127.0.0.1 --port 4096
88
+ ```
89
+
90
+ Then start `opencode-a2a-server` against that upstream:
91
+
92
+ ```bash
93
+ A2A_BEARER_TOKEN=dev-token \
94
+ OPENCODE_BASE_URL=http://127.0.0.1:4096 \
95
+ A2A_HOST=127.0.0.1 \
96
+ A2A_PORT=8000 \
97
+ A2A_PUBLIC_URL=http://127.0.0.1:8000 \
98
+ OPENCODE_WORKSPACE_ROOT=/abs/path/to/workspace \
99
+ opencode-a2a-server serve
100
+ ```
101
+
102
+ Verify that the service is up:
103
+
104
+ ```bash
105
+ curl http://127.0.0.1:8000/.well-known/agent-card.json
106
+ ```
107
+
108
+ Default local address: `http://127.0.0.1:8000`
109
+
110
+ ## What You Get
111
+
112
+ - A2A HTTP+JSON endpoints such as `/v1/message:send` and
113
+ `/v1/message:stream`
114
+ - A2A JSON-RPC support on `POST /`
115
+ - SSE streaming with normalized `text`, `reasoning`, and `tool_call` blocks
116
+ - Session continuity through `metadata.shared.session.id`
117
+ - Request-scoped model selection through `metadata.shared.model`
118
+ - OpenCode-oriented JSON-RPC extensions for session and model/provider queries
119
+
120
+ Detailed protocol contracts, examples, and extension docs live in
121
+ [`docs/guide.md`](docs/guide.md).
122
+
123
+ ## When To Use It
124
+
125
+ Use this project when:
126
+
127
+ - you want to keep OpenCode as the runtime
128
+ - you need A2A transports and Agent Card discovery
129
+ - you want a thin service boundary instead of building your own adapter
130
+
131
+ Look elsewhere if:
132
+
133
+ - you need hard multi-tenant isolation inside one shared runtime
134
+ - you want this project to manage your process supervisor or host bootstrap
135
+ - you want a general client integration layer rather than a server wrapper
136
+
137
+ For client-side integration, prefer
138
+ [a2a-client-hub](https://github.com/liujuanjuan1984/a2a-client-hub).
139
+
140
+ ## Deployment Boundary
141
+
142
+ This repository improves the service boundary around OpenCode, but it does not
143
+ turn OpenCode into a hardened multi-tenant platform.
144
+
145
+ - `A2A_BEARER_TOKEN` protects the A2A surface.
146
+ - Provider auth and default model configuration remain on the OpenCode side.
147
+ - Deployment supervision is intentionally BYO. Use `systemd`, Docker,
148
+ Kubernetes, or another supervisor if you need long-running operation.
149
+ - For mutually untrusted tenants, run separate instance pairs with isolated
150
+ users, containers, workspaces, credentials, and ports.
151
+
152
+ Read before deployment:
153
+
154
+ - [SECURITY.md](SECURITY.md)
155
+ - [docs/guide.md](docs/guide.md)
156
+
157
+ ## Further Reading
158
+
159
+ - [docs/guide.md](docs/guide.md)
160
+ Usage guide, transport details, streaming behavior, extensions, and examples.
161
+ - [SECURITY.md](SECURITY.md)
162
+ Threat model, deployment caveats, and vulnerability disclosure guidance.
163
+
164
+ ## Development
165
+
166
+ For contributor workflow, local validation, and helper scripts, see
167
+ [CONTRIBUTING.md](CONTRIBUTING.md) and [scripts/README.md](scripts/README.md).
168
+
169
+ ## License
170
+
171
+ Apache-2.0. See [`LICENSE`](LICENSE).
@@ -0,0 +1,133 @@
1
+ # opencode-a2a-server
2
+
3
+ > Expose OpenCode through A2A.
4
+
5
+ `opencode-a2a-server` adds an A2A service layer to `opencode serve`, with
6
+ auth, streaming, session continuity, interrupt handling, and a clear
7
+ deployment boundary.
8
+
9
+ ## What This Is
10
+
11
+ - An A2A adapter service for `opencode serve`.
12
+ - Use it when you need a stable A2A endpoint for apps, gateways, or A2A
13
+ clients.
14
+
15
+ ```mermaid
16
+ flowchart TD
17
+ Client["a2a-client-hub / any A2A client"]
18
+
19
+ subgraph ServerSide["Server-side"]
20
+ Adapter["opencode-a2a-server\nA2A adapter service"]
21
+ Runtime["opencode serve\nOpenCode runtime"]
22
+
23
+ Adapter <--> Runtime
24
+ end
25
+
26
+ Client <--> Adapter
27
+ ```
28
+
29
+ ## Quick Start
30
+
31
+ Install the released CLI with `uv tool`:
32
+
33
+ ```bash
34
+ uv tool install opencode-a2a-server
35
+ ```
36
+
37
+ Upgrade later with:
38
+
39
+ ```bash
40
+ uv tool upgrade opencode-a2a-server
41
+ ```
42
+
43
+ Make sure provider credentials and a default model are configured on the
44
+ OpenCode side, then start OpenCode:
45
+
46
+ ```bash
47
+ opencode auth login
48
+ opencode models
49
+ opencode serve --hostname 127.0.0.1 --port 4096
50
+ ```
51
+
52
+ Then start `opencode-a2a-server` against that upstream:
53
+
54
+ ```bash
55
+ A2A_BEARER_TOKEN=dev-token \
56
+ OPENCODE_BASE_URL=http://127.0.0.1:4096 \
57
+ A2A_HOST=127.0.0.1 \
58
+ A2A_PORT=8000 \
59
+ A2A_PUBLIC_URL=http://127.0.0.1:8000 \
60
+ OPENCODE_WORKSPACE_ROOT=/abs/path/to/workspace \
61
+ opencode-a2a-server serve
62
+ ```
63
+
64
+ Verify that the service is up:
65
+
66
+ ```bash
67
+ curl http://127.0.0.1:8000/.well-known/agent-card.json
68
+ ```
69
+
70
+ Default local address: `http://127.0.0.1:8000`
71
+
72
+ ## What You Get
73
+
74
+ - A2A HTTP+JSON endpoints such as `/v1/message:send` and
75
+ `/v1/message:stream`
76
+ - A2A JSON-RPC support on `POST /`
77
+ - SSE streaming with normalized `text`, `reasoning`, and `tool_call` blocks
78
+ - Session continuity through `metadata.shared.session.id`
79
+ - Request-scoped model selection through `metadata.shared.model`
80
+ - OpenCode-oriented JSON-RPC extensions for session and model/provider queries
81
+
82
+ Detailed protocol contracts, examples, and extension docs live in
83
+ [`docs/guide.md`](docs/guide.md).
84
+
85
+ ## When To Use It
86
+
87
+ Use this project when:
88
+
89
+ - you want to keep OpenCode as the runtime
90
+ - you need A2A transports and Agent Card discovery
91
+ - you want a thin service boundary instead of building your own adapter
92
+
93
+ Look elsewhere if:
94
+
95
+ - you need hard multi-tenant isolation inside one shared runtime
96
+ - you want this project to manage your process supervisor or host bootstrap
97
+ - you want a general client integration layer rather than a server wrapper
98
+
99
+ For client-side integration, prefer
100
+ [a2a-client-hub](https://github.com/liujuanjuan1984/a2a-client-hub).
101
+
102
+ ## Deployment Boundary
103
+
104
+ This repository improves the service boundary around OpenCode, but it does not
105
+ turn OpenCode into a hardened multi-tenant platform.
106
+
107
+ - `A2A_BEARER_TOKEN` protects the A2A surface.
108
+ - Provider auth and default model configuration remain on the OpenCode side.
109
+ - Deployment supervision is intentionally BYO. Use `systemd`, Docker,
110
+ Kubernetes, or another supervisor if you need long-running operation.
111
+ - For mutually untrusted tenants, run separate instance pairs with isolated
112
+ users, containers, workspaces, credentials, and ports.
113
+
114
+ Read before deployment:
115
+
116
+ - [SECURITY.md](SECURITY.md)
117
+ - [docs/guide.md](docs/guide.md)
118
+
119
+ ## Further Reading
120
+
121
+ - [docs/guide.md](docs/guide.md)
122
+ Usage guide, transport details, streaming behavior, extensions, and examples.
123
+ - [SECURITY.md](SECURITY.md)
124
+ Threat model, deployment caveats, and vulnerability disclosure guidance.
125
+
126
+ ## Development
127
+
128
+ For contributor workflow, local validation, and helper scripts, see
129
+ [CONTRIBUTING.md](CONTRIBUTING.md) and [scripts/README.md](scripts/README.md).
130
+
131
+ ## License
132
+
133
+ Apache-2.0. See [`LICENSE`](LICENSE).
@@ -2,10 +2,10 @@
2
2
 
3
3
  ## Scope
4
4
 
5
- This repository is an adapter layer that exposes OpenCode through A2A
6
- HTTP+JSON and JSON-RPC interfaces. It adds authentication, task/session
7
- contracts, streaming, interrupt handling, and runtime guidance, but it does
8
- not fully isolate upstream model credentials from OpenCode runtime behavior.
5
+ This repository wraps OpenCode as an A2A adapter service. It exposes A2A
6
+ HTTP+JSON and JSON-RPC interfaces, and adds authentication, task/session
7
+ contracts, streaming, interrupt handling, and runtime guidance. It does not
8
+ fully isolate upstream model credentials from OpenCode runtime behavior.
9
9
 
10
10
  ## Security Boundary
11
11
 
@@ -13,7 +13,10 @@ not fully isolate upstream model credentials from OpenCode runtime behavior.
13
13
  tenant-isolation boundary inside one deployed instance.
14
14
  - One `OpenCode + opencode-a2a-server` instance pair is treated as a
15
15
  single-tenant trust boundary by design.
16
- - Tenant isolation across consumers is expected to come from parameterized self-deployment of separate instance pairs with distinct Linux users, workspace roots, credentials, and runtime ports.
16
+ - Tenant isolation across consumers is expected to come from parameterized
17
+ self-deployment.
18
+ - For mutually untrusted tenants, use separate instance pairs with distinct
19
+ Linux users, workspace roots, credentials, and runtime ports.
17
20
  - Within one instance, consumers share the same underlying OpenCode
18
21
  workspace/environment by default.
19
22
  - LLM provider keys are consumed by the `opencode` process. Prompt injection or