@openziti/ziti-mcp-server 0.1.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.
Files changed (210) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +868 -0
  3. package/dist/auth/client-credentials-flow.d.ts +21 -0
  4. package/dist/auth/client-credentials-flow.js +63 -0
  5. package/dist/auth/client-credentials-flow.js.map +1 -0
  6. package/dist/auth/device-auth-flow.d.ts +47 -0
  7. package/dist/auth/device-auth-flow.js +291 -0
  8. package/dist/auth/device-auth-flow.js.map +1 -0
  9. package/dist/clients/base.d.ts +74 -0
  10. package/dist/clients/base.js +109 -0
  11. package/dist/clients/base.js.map +1 -0
  12. package/dist/clients/claude.d.ts +22 -0
  13. package/dist/clients/claude.js +40 -0
  14. package/dist/clients/claude.js.map +1 -0
  15. package/dist/clients/cursor.d.ts +22 -0
  16. package/dist/clients/cursor.js +39 -0
  17. package/dist/clients/cursor.js.map +1 -0
  18. package/dist/clients/index.d.ts +33 -0
  19. package/dist/clients/index.js +39 -0
  20. package/dist/clients/index.js.map +1 -0
  21. package/dist/clients/types.d.ts +70 -0
  22. package/dist/clients/types.js +2 -0
  23. package/dist/clients/types.js.map +1 -0
  24. package/dist/clients/utils.d.ts +22 -0
  25. package/dist/clients/utils.js +46 -0
  26. package/dist/clients/utils.js.map +1 -0
  27. package/dist/clients/vscode.d.ts +76 -0
  28. package/dist/clients/vscode.js +159 -0
  29. package/dist/clients/vscode.js.map +1 -0
  30. package/dist/clients/windsurf.d.ts +22 -0
  31. package/dist/clients/windsurf.js +39 -0
  32. package/dist/clients/windsurf.js.map +1 -0
  33. package/dist/commands/init.d.ts +45 -0
  34. package/dist/commands/init.js +133 -0
  35. package/dist/commands/init.js.map +1 -0
  36. package/dist/commands/logout.d.ts +12 -0
  37. package/dist/commands/logout.js +90 -0
  38. package/dist/commands/logout.js.map +1 -0
  39. package/dist/commands/run.d.ts +15 -0
  40. package/dist/commands/run.js +94 -0
  41. package/dist/commands/run.js.map +1 -0
  42. package/dist/commands/session.d.ts +12 -0
  43. package/dist/commands/session.js +99 -0
  44. package/dist/commands/session.js.map +1 -0
  45. package/dist/index.d.ts +2 -0
  46. package/dist/index.js +105 -0
  47. package/dist/index.js.map +1 -0
  48. package/dist/server.d.ts +67 -0
  49. package/dist/server.js +171 -0
  50. package/dist/server.js.map +1 -0
  51. package/dist/tools/api-sessions.d.ts +3 -0
  52. package/dist/tools/api-sessions.js +86 -0
  53. package/dist/tools/api-sessions.js.map +1 -0
  54. package/dist/tools/auth-policies.d.ts +3 -0
  55. package/dist/tools/auth-policies.js +347 -0
  56. package/dist/tools/auth-policies.js.map +1 -0
  57. package/dist/tools/authenticators.d.ts +3 -0
  58. package/dist/tools/authenticators.js +183 -0
  59. package/dist/tools/authenticators.js.map +1 -0
  60. package/dist/tools/certificate-authorities.d.ts +3 -0
  61. package/dist/tools/certificate-authorities.js +288 -0
  62. package/dist/tools/certificate-authorities.js.map +1 -0
  63. package/dist/tools/config-types.d.ts +3 -0
  64. package/dist/tools/config-types.js +194 -0
  65. package/dist/tools/config-types.js.map +1 -0
  66. package/dist/tools/configs.d.ts +3 -0
  67. package/dist/tools/configs.js +203 -0
  68. package/dist/tools/configs.js.map +1 -0
  69. package/dist/tools/controller-settings.d.ts +3 -0
  70. package/dist/tools/controller-settings.js +219 -0
  71. package/dist/tools/controller-settings.js.map +1 -0
  72. package/dist/tools/controllers.d.ts +3 -0
  73. package/dist/tools/controllers.js +89 -0
  74. package/dist/tools/controllers.js.map +1 -0
  75. package/dist/tools/edge-router-policies.d.ts +3 -0
  76. package/dist/tools/edge-router-policies.js +262 -0
  77. package/dist/tools/edge-router-policies.js.map +1 -0
  78. package/dist/tools/edge-routers.d.ts +3 -0
  79. package/dist/tools/edge-routers.js +381 -0
  80. package/dist/tools/edge-routers.js.map +1 -0
  81. package/dist/tools/enrollments.d.ts +3 -0
  82. package/dist/tools/enrollments.js +187 -0
  83. package/dist/tools/enrollments.js.map +1 -0
  84. package/dist/tools/external-jwt-signers.d.ts +3 -0
  85. package/dist/tools/external-jwt-signers.js +242 -0
  86. package/dist/tools/external-jwt-signers.js.map +1 -0
  87. package/dist/tools/identities.d.ts +3 -0
  88. package/dist/tools/identities.js +741 -0
  89. package/dist/tools/identities.js.map +1 -0
  90. package/dist/tools/identity-types.d.ts +3 -0
  91. package/dist/tools/identity-types.js +58 -0
  92. package/dist/tools/identity-types.js.map +1 -0
  93. package/dist/tools/index.d.ts +3 -0
  94. package/dist/tools/index.js +101 -0
  95. package/dist/tools/index.js.map +1 -0
  96. package/dist/tools/posture-checks.d.ts +3 -0
  97. package/dist/tools/posture-checks.js +254 -0
  98. package/dist/tools/posture-checks.js.map +1 -0
  99. package/dist/tools/routers.d.ts +3 -0
  100. package/dist/tools/routers.js +169 -0
  101. package/dist/tools/routers.js.map +1 -0
  102. package/dist/tools/service-edge-router-policies.d.ts +3 -0
  103. package/dist/tools/service-edge-router-policies.js +282 -0
  104. package/dist/tools/service-edge-router-policies.js.map +1 -0
  105. package/dist/tools/service-policies.d.ts +3 -0
  106. package/dist/tools/service-policies.js +311 -0
  107. package/dist/tools/service-policies.js.map +1 -0
  108. package/dist/tools/services.d.ts +3 -0
  109. package/dist/tools/services.js +403 -0
  110. package/dist/tools/services.js.map +1 -0
  111. package/dist/tools/sessions.d.ts +3 -0
  112. package/dist/tools/sessions.js +86 -0
  113. package/dist/tools/sessions.js.map +1 -0
  114. package/dist/tools/terminators.d.ts +3 -0
  115. package/dist/tools/terminators.js +187 -0
  116. package/dist/tools/terminators.js.map +1 -0
  117. package/dist/tools/transit-routers.d.ts +3 -0
  118. package/dist/tools/transit-routers.js +169 -0
  119. package/dist/tools/transit-routers.js.map +1 -0
  120. package/dist/utils/analytics.d.ts +75 -0
  121. package/dist/utils/analytics.js +191 -0
  122. package/dist/utils/analytics.js.map +1 -0
  123. package/dist/utils/auth0-client.d.ts +27 -0
  124. package/dist/utils/auth0-client.js +67 -0
  125. package/dist/utils/auth0-client.js.map +1 -0
  126. package/dist/utils/authenticated-client.d.ts +6 -0
  127. package/dist/utils/authenticated-client.js +55 -0
  128. package/dist/utils/authenticated-client.js.map +1 -0
  129. package/dist/utils/config.d.ts +65 -0
  130. package/dist/utils/config.js +80 -0
  131. package/dist/utils/config.js.map +1 -0
  132. package/dist/utils/constants.d.ts +15 -0
  133. package/dist/utils/constants.js +17 -0
  134. package/dist/utils/constants.js.map +1 -0
  135. package/dist/utils/controller-client/client/client.gen.d.ts +2 -0
  136. package/dist/utils/controller-client/client/client.gen.js +229 -0
  137. package/dist/utils/controller-client/client/client.gen.js.map +1 -0
  138. package/dist/utils/controller-client/client/index.d.ts +8 -0
  139. package/dist/utils/controller-client/client/index.js +7 -0
  140. package/dist/utils/controller-client/client/index.js.map +1 -0
  141. package/dist/utils/controller-client/client/types.gen.d.ts +117 -0
  142. package/dist/utils/controller-client/client/types.gen.js +3 -0
  143. package/dist/utils/controller-client/client/types.gen.js.map +1 -0
  144. package/dist/utils/controller-client/client/utils.gen.d.ts +33 -0
  145. package/dist/utils/controller-client/client/utils.gen.js +232 -0
  146. package/dist/utils/controller-client/client/utils.gen.js.map +1 -0
  147. package/dist/utils/controller-client/client.gen.d.ts +12 -0
  148. package/dist/utils/controller-client/client.gen.js +6 -0
  149. package/dist/utils/controller-client/client.gen.js.map +1 -0
  150. package/dist/utils/controller-client/core/auth.gen.d.ts +18 -0
  151. package/dist/utils/controller-client/core/auth.gen.js +15 -0
  152. package/dist/utils/controller-client/core/auth.gen.js.map +1 -0
  153. package/dist/utils/controller-client/core/bodySerializer.gen.d.ts +25 -0
  154. package/dist/utils/controller-client/core/bodySerializer.gen.js +58 -0
  155. package/dist/utils/controller-client/core/bodySerializer.gen.js.map +1 -0
  156. package/dist/utils/controller-client/core/params.gen.d.ts +43 -0
  157. package/dist/utils/controller-client/core/params.gen.js +101 -0
  158. package/dist/utils/controller-client/core/params.gen.js.map +1 -0
  159. package/dist/utils/controller-client/core/pathSerializer.gen.d.ts +33 -0
  160. package/dist/utils/controller-client/core/pathSerializer.gen.js +115 -0
  161. package/dist/utils/controller-client/core/pathSerializer.gen.js.map +1 -0
  162. package/dist/utils/controller-client/core/queryKeySerializer.gen.d.ts +18 -0
  163. package/dist/utils/controller-client/core/queryKeySerializer.gen.js +100 -0
  164. package/dist/utils/controller-client/core/queryKeySerializer.gen.js.map +1 -0
  165. package/dist/utils/controller-client/core/serverSentEvents.gen.d.ts +71 -0
  166. package/dist/utils/controller-client/core/serverSentEvents.gen.js +136 -0
  167. package/dist/utils/controller-client/core/serverSentEvents.gen.js.map +1 -0
  168. package/dist/utils/controller-client/core/types.gen.d.ts +78 -0
  169. package/dist/utils/controller-client/core/types.gen.js +3 -0
  170. package/dist/utils/controller-client/core/types.gen.js.map +1 -0
  171. package/dist/utils/controller-client/core/utils.gen.d.ts +19 -0
  172. package/dist/utils/controller-client/core/utils.gen.js +88 -0
  173. package/dist/utils/controller-client/core/utils.gen.js.map +1 -0
  174. package/dist/utils/controller-client/index.d.ts +2 -0
  175. package/dist/utils/controller-client/index.js +3 -0
  176. package/dist/utils/controller-client/index.js.map +1 -0
  177. package/dist/utils/controller-client/sdk.gen.d.ts +1302 -0
  178. package/dist/utils/controller-client/sdk.gen.js +4436 -0
  179. package/dist/utils/controller-client/sdk.gen.js.map +1 -0
  180. package/dist/utils/controller-client/types.gen.d.ts +9170 -0
  181. package/dist/utils/controller-client/types.gen.js +3 -0
  182. package/dist/utils/controller-client/types.gen.js.map +1 -0
  183. package/dist/utils/glob.d.ts +75 -0
  184. package/dist/utils/glob.js +110 -0
  185. package/dist/utils/glob.js.map +1 -0
  186. package/dist/utils/http-utility.d.ts +5 -0
  187. package/dist/utils/http-utility.js +68 -0
  188. package/dist/utils/http-utility.js.map +1 -0
  189. package/dist/utils/keychain.d.ts +129 -0
  190. package/dist/utils/keychain.js +193 -0
  191. package/dist/utils/keychain.js.map +1 -0
  192. package/dist/utils/logger.d.ts +4 -0
  193. package/dist/utils/logger.js +28 -0
  194. package/dist/utils/logger.js.map +1 -0
  195. package/dist/utils/package.d.ts +3 -0
  196. package/dist/utils/package.js +9 -0
  197. package/dist/utils/package.js.map +1 -0
  198. package/dist/utils/scopes.d.ts +12 -0
  199. package/dist/utils/scopes.js +19 -0
  200. package/dist/utils/scopes.js.map +1 -0
  201. package/dist/utils/terminal.d.ts +35 -0
  202. package/dist/utils/terminal.js +409 -0
  203. package/dist/utils/terminal.js.map +1 -0
  204. package/dist/utils/tools.d.ts +63 -0
  205. package/dist/utils/tools.js +149 -0
  206. package/dist/utils/tools.js.map +1 -0
  207. package/dist/utils/types.d.ts +55 -0
  208. package/dist/utils/types.js +3 -0
  209. package/dist/utils/types.js.map +1 -0
  210. package/package.json +89 -0
package/README.md ADDED
@@ -0,0 +1,868 @@
1
+ <p align="center">
2
+ <img src="assets/readme-banner.png" alt="OpenZiti MCP Server Banner">
3
+ </p>
4
+ <div align="center">
5
+
6
+ [![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)
7
+ [![Node.js Version](https://img.shields.io/badge/node-%3E%3D18.0.0-brightgreen.svg)](https://nodejs.org/)
8
+ [![NPM Downloads](https://img.shields.io/npm/dw/%40openziti%2Fziti-mcp-server)](https://www.npmjs.com/package/@openziti/ziti-mcp-server)
9
+ [![NPM Version](https://img.shields.io/npm/v/@openziti/ziti-mcp-server)](https://www.npmjs.com/package/@openziti/ziti-mcp-server)
10
+
11
+ </div>
12
+
13
+ <div align="center">
14
+
15
+ 🚀 [Getting Started](#-getting-started) • 🕸️ [Architecture](#%EF%B8%8F-architecture) • 🔐 [Authentication](#-authentication) • 🛠️ [Supported Tools](#%EF%B8%8F-supported-tools) • 🩺 [Troubleshooting](#-troubleshooting) • 📋 [Debug Logs](#-debug-logs) • 👨‍💻 [Development](#-development) • 🔒 [Security](#-security)
16
+
17
+ </div>
18
+
19
+ [MCP (Model Context Protocol)](https://modelcontextprotocol.io/introduction) is an open protocol introduced by Anthropic that standardizes how large language models communicate with external tools, resources or remote services.
20
+
21
+ The Ziti MCP Server integrates with LLMs and AI agents, allowing you to perform various Ziti network management operations using natural language. For instance, you could simply ask Claude Desktop to perform Ziti management operations:
22
+
23
+ - > List which identities exist
24
+ - > Which identities have access to the Demo1 service
25
+ - > Create a new Ziti identity named "Demo" and get its ID
26
+ - > etc.
27
+
28
+ <br/>
29
+
30
+ ## 🚀 Getting Started
31
+
32
+ **Prerequisites:**
33
+
34
+ - [Node.js v18 or higher](https://nodejs.org/en/download)
35
+ - [Claude Desktop](https://claude.ai/download) or any other [MCP Client](https://modelcontextprotocol.io/clients)
36
+ - An IdP account with appropriate permissions ([Auth0](https://auth0.com/) can be used as the IdP)
37
+ - [OpenZiti](https://openziti.io/) network
38
+
39
+ <br/>
40
+
41
+ ### Install the Ziti MCP Server
42
+
43
+ Install Ziti MCP Server and configure it to work with your preferred MCP Client. The `--tools` parameter specifies which tools should be available (defaults to `*` if not provided).
44
+
45
+ **Claude Desktop with all tools**
46
+
47
+ ```bash
48
+ npx @openziti/ziti-mcp-server init
49
+ ```
50
+
51
+ **Claude Desktop with read-only tools**
52
+
53
+ ```bash
54
+ npx @openziti/ziti-mcp-server init --read-only
55
+ ```
56
+
57
+ You can also explicitly select read-only tools:
58
+
59
+ ```bash
60
+ npx @openziti/ziti-mcp-server init --tools 'list*,get*'
61
+ ```
62
+
63
+ **Windsurf**
64
+
65
+ ```bash
66
+ npx @openziti/ziti-mcp-server init --client windsurf
67
+ ```
68
+
69
+ **Cursor**
70
+
71
+ Step 1:
72
+
73
+ [![Install MCP Server](https://cursor.com/deeplink/mcp-install-dark.svg)](cursor://anysphere.cursor-deeplink/mcp/install?name=ziti&config=eyJjb21tYW5kIjoibnB4IC15IEBhdXRoMC9hdXRoMC1tY3Atc2VydmVyIHJ1biIsImNhcGFiaWxpdGllcyI6WyJ0b29scyJdLCJlbnYiOnsiREVCVUciOiJhdXRoMC1tY3AifX0%3D)
74
+
75
+ Step 2:
76
+
77
+ ```bash
78
+ npx @openziti/ziti-mcp-server init --client cursor
79
+ ```
80
+
81
+ **Cursor with limited tools access**
82
+
83
+ ```bash
84
+ npx @openziti/ziti-mcp-server init --client cursor --tools 'listIdentities,listIdentity'
85
+ ```
86
+
87
+ **VS Code**
88
+
89
+ ```bash
90
+ npx @openziti/ziti-mcp-server init --client vscode
91
+ ```
92
+
93
+ You can configure VS Code for either global or workspace scope:
94
+
95
+ - **Global**: Available in all VS Code instances
96
+ - **Workspace**: Available only in a specific project/repository
97
+
98
+ The command will prompt you to choose your preferred scope and automatically configure the appropriate `mcp.json` file.
99
+
100
+ **VS Code with limited tools access**
101
+
102
+ ```bash
103
+ npx @openziti/ziti-mcp-server init --client vscode --tools 'list*,get*' --read-only
104
+ ```
105
+
106
+ **Other MCP Clients**
107
+
108
+ To use Ziti MCP Server with any other MCP Client, you can manually add this configuration to the client and restart for changes to take effect:
109
+
110
+ ```json
111
+ {
112
+ "mcpServers": {
113
+ "ziti": {
114
+ "command": "npx",
115
+ "args": ["-y", "@openziti/ziti-mcp-server", "run"],
116
+ "capabilities": ["tools"],
117
+ "env": {
118
+ "DEBUG": "ziti-mcp"
119
+ }
120
+ }
121
+ }
122
+ }
123
+ ```
124
+
125
+ You can add `--tools '<pattern>'` to the args array to control which tools are available. See [Security Best Practices](#-security-best-practices-for-tool-access) for recommended patterns.
126
+
127
+ ### Authorize with IdP
128
+
129
+ Your browser will automatically open to initiate the OAuth 2.0 device authorization flow. Log into your IdP account and grant the requested permissions.
130
+
131
+ > [!NOTE]
132
+ > Credentials are securely stored in your system's keychain. You can optionally verify storage through your keychain management tool. Check out [Authentication](#-authentication) for more info.
133
+
134
+ ### Verify your integration
135
+
136
+ Restart your MCP Client (Claude Desktop, Windsurf, Cursor, Warp, etc.) and ask it to help you manage your Ziti network
137
+
138
+ ## 🕸️ Architecture
139
+
140
+ The Ziti MCP Server implements the Model Context Protocol, allowing Claude to:
141
+
142
+ 1. Request a list of available Ziti tools
143
+ 2. Call specific tools with parameters
144
+ 3. Receive structured responses from the Ziti Management API
145
+
146
+ The server handles authentication, request validation, and secure communication with the Ziti Management API.
147
+
148
+ <div align="center">
149
+ <img src="assets/arch.jpg" alt="Ziti MCP Server" width="800">
150
+ </div>
151
+
152
+ > [!NOTE]
153
+ > The server operates as a local process that connects to Claude Desktop, enabling secure communication without exposing your Ziti credentials.
154
+
155
+ ## 🔐 Authentication
156
+
157
+ The Ziti MCP Server uses the Ziti Management API and requires authentication to access your Ziti network.
158
+
159
+ ### Initial Setup
160
+
161
+ > [!NOTE]
162
+ > Users should authenticate with [client credentials](https://auth0.com/docs/get-started/authentication-and-authorization-flow/client-credentials-flow). Keep the token lifetime as minimal as possible to reduce security risks. [See more](https://auth0.com/docs/secure/tokens/access-tokens/update-access-token-lifetime)
163
+
164
+ To authenticate the MCP Server:
165
+
166
+ ```bash
167
+ npx @openziti/ziti-mcp-server init --idp-domain <idp-domain> --idp-client-id <idp-client-id> --idp-client-secret <idp-client-secret>
168
+ ```
169
+
170
+ > [!IMPORTANT]
171
+ >
172
+ > The `init` command needs to be run whenever:
173
+ >
174
+ > - You're setting up the MCP Server for the first time
175
+ > - You've logged out from a previous session
176
+ > - You want to switch to a different Ziti network
177
+ > - Your token has expired
178
+ >
179
+ > The `run` command will automatically check for token validity before starting the server and will provide helpful error messages if authentication is needed.
180
+
181
+ ### Session Management
182
+
183
+ To see information about your current authentication session:
184
+
185
+ ```bash
186
+ npx @openziti/ziti-mcp-server session
187
+ ```
188
+
189
+ ### Logging Out
190
+
191
+ For security best practices, always use the logout command when you're done with a session:
192
+
193
+ ```bash
194
+ npx @openziti/ziti-mcp-server logout
195
+ ```
196
+
197
+ This ensures your authentication tokens are properly removed from the system keychain.
198
+
199
+ ### Authentication Flow
200
+
201
+ The Ziti MCP server uses OAuth 2.0 device authorization flow for secure authentication with the IdP. Your credentials are stored securely in your system's keychain and are never exposed in plain text.
202
+
203
+ <div align="center">
204
+ <img src="assets/auth-seq.jpg" alt="Authentication Sequence Diagram" width="800">
205
+ </div>
206
+
207
+ ## 🛠️ Supported Tools
208
+
209
+ The Ziti MCP Server provides **126 tools** for managing your Ziti network through natural language. Tools are organized by resource type.
210
+
211
+ > **Tip:** Use `--read-only` or `--tools` patterns to expose only the tools you need. See [Security Best Practices](#-security-best-practices-for-tool-access).
212
+
213
+ ### Identities
214
+
215
+ CRUD operations, relationship queries, and lifecycle management for Ziti Identities.
216
+
217
+ | Tool | Description |
218
+ | ------------------------------------ | --------------------------------------------------------------------------- |
219
+ | `listIdentities` | List all identities in the Ziti network |
220
+ | `listIdentity` | Get details about a specific identity |
221
+ | `createIdentity` | Create a new identity (name, admin, authPolicy, externalId, roleAttributes) |
222
+ | `deleteIdentity` | Delete an identity |
223
+ | `updateIdentity` | Update an existing identity |
224
+ | `listIdentityServices` | List services accessible by an identity |
225
+ | `listIdentityEdgeRouters` | List edge routers accessible by an identity |
226
+ | `listIdentityServicePolicies` | List service policies that apply to an identity |
227
+ | `listIdentityEdgeRouterPolicies` | List edge router policies that apply to an identity |
228
+ | `listIdentityServiceConfigs` | List service configs associated with an identity |
229
+ | `getIdentityPolicyAdvice` | Check whether an identity can dial/bind a service and get policy advice |
230
+ | `listIdentityRoleAttributes` | List all role attributes in use by identities |
231
+ | `disableIdentity` | Temporarily disable an identity for a specified duration |
232
+ | `enableIdentity` | Re-enable a previously disabled identity |
233
+ | `getIdentityAuthenticators` | List authenticators for an identity |
234
+ | `getIdentityEnrollments` | List enrollments for an identity |
235
+ | `getIdentityFailedServiceRequests` | List failed service requests for an identity |
236
+ | `getIdentityPostureData` | Get posture data for an identity |
237
+ | `removeIdentityMfa` | Remove MFA from an identity |
238
+ | `updateIdentityTracing` | Update tracing configuration for an identity |
239
+ | `associateIdentityServiceConfigs` | Associate service/config pairs with an identity |
240
+ | `disassociateIdentityServiceConfigs` | Remove service/config associations from an identity |
241
+
242
+ **Example prompts:**
243
+
244
+ - `Show me all Ziti identities`
245
+ - `Which identities have access to the Demo1 service?`
246
+ - `Create a new identity called 'demo-admin' and make it an admin`
247
+ - `Disable identity abc123 for 60 minutes`
248
+ - `What posture data does identity xyz have?`
249
+
250
+ ### Services
251
+
252
+ CRUD operations and relationship queries for Ziti Services.
253
+
254
+ | Tool | Description |
255
+ | -------------------------------------- | --------------------------------------------------------------------------------------------------------------- |
256
+ | `listServices` | List all services in the Ziti network |
257
+ | `listService` | Get details about a specific service |
258
+ | `createService` | Create a new service (name, encryptionRequired, configs, roleAttributes, terminatorStrategy, maxIdleTimeMillis) |
259
+ | `deleteService` | Delete a service |
260
+ | `updateService` | Update an existing service |
261
+ | `listServiceIdentities` | List identities that have access to a service |
262
+ | `listServiceEdgeRouters` | List edge routers accessible by a service |
263
+ | `listServiceTerminators` | List terminators for a service |
264
+ | `listServiceConfig` | List configs associated with a service |
265
+ | `listServiceServicePolicies` | List service policies that apply to a service |
266
+ | `listServiceServiceEdgeRouterPolicies` | List service edge router policies that apply to a service |
267
+ | `listServiceRoleAttributes` | List all role attributes in use by services |
268
+
269
+ **Example prompts:**
270
+
271
+ - `Show me all Ziti services`
272
+ - `Which identities can access the 'webapp' service?`
273
+ - `Create a new service called 'my-api' with encryption required`
274
+
275
+ ### Edge Routers
276
+
277
+ CRUD operations, relationship queries, and re-enrollment for Ziti Edge Routers.
278
+
279
+ | Tool | Description |
280
+ | ----------------------------------------- | ----------------------------------------------------------------------------------------------- |
281
+ | `listEdgeRouters` | List all edge routers in the Ziti network |
282
+ | `listEdgeRouter` | Get details about a specific edge router |
283
+ | `createEdgeRouter` | Create a new edge router (name, isTunnelerEnabled, roleAttributes, cost, noTraversal, disabled) |
284
+ | `deleteEdgeRouter` | Delete an edge router |
285
+ | `updateEdgeRouter` | Update an existing edge router |
286
+ | `listEdgeRouterIdentities` | List identities accessible by an edge router |
287
+ | `listEdgeRouterServices` | List services accessible by an edge router |
288
+ | `listEdgeRouterEdgeRouterPolicies` | List edge router policies that apply to an edge router |
289
+ | `listEdgeRouterServiceEdgeRouterPolicies` | List service edge router policies that apply to an edge router |
290
+ | `listEdgeRouterRoleAttributes` | List all role attributes in use by edge routers |
291
+ | `reEnrollEdgeRouter` | Re-enroll an edge router, generating new certificates |
292
+
293
+ **Example prompts:**
294
+
295
+ - `List all edge routers and their status`
296
+ - `Which services are accessible through edge router xyz?`
297
+ - `Re-enroll edge router abc123`
298
+
299
+ ### Edge Router Policies
300
+
301
+ CRUD operations and relationship queries for Edge Router Policies.
302
+
303
+ | Tool | Description |
304
+ | --------------------------------- | -------------------------------------------------------------------------------- |
305
+ | `listEdgeRouterPolicies` | List all edge router policies |
306
+ | `listEdgeRouterPolicy` | Get details about a specific edge router policy |
307
+ | `createEdgeRouterPolicy` | Create a new edge router policy (name, semantic, edgeRouterRoles, identityRoles) |
308
+ | `deleteEdgeRouterPolicy` | Delete an edge router policy |
309
+ | `updateEdgeRouterPolicy` | Update an existing edge router policy |
310
+ | `listEdgeRouterPolicyEdgeRouters` | List edge routers associated with a policy |
311
+ | `listEdgeRouterPolicyIdentities` | List identities associated with a policy |
312
+
313
+ **Example prompts:**
314
+
315
+ - `List all edge router policies`
316
+ - `Which identities are covered by edge router policy xyz?`
317
+ - `Create an edge router policy that gives all identities access to all edge routers`
318
+
319
+ ### Service Edge Router Policies
320
+
321
+ CRUD operations and relationship queries for Service Edge Router Policies.
322
+
323
+ | Tool | Description |
324
+ | ---------------------------------------- | --------------------------------------------------------------------------------------- |
325
+ | `listServiceEdgeRouterPolicies` | List all service edge router policies |
326
+ | `listServiceEdgeRouterPolicy` | Get details about a specific service edge router policy |
327
+ | `createServiceEdgeRouterPolicy` | Create a new service edge router policy (name, semantic, edgeRouterRoles, serviceRoles) |
328
+ | `deleteServiceEdgeRouterPolicy` | Delete a service edge router policy |
329
+ | `updateServiceEdgeRouterPolicy` | Update an existing service edge router policy |
330
+ | `listServiceEdgeRouterPolicyEdgeRouters` | List edge routers associated with a policy |
331
+ | `listServiceEdgeRouterPolicyServices` | List services associated with a policy |
332
+
333
+ **Example prompts:**
334
+
335
+ - `Show me all service edge router policies`
336
+ - `Which edge routers are in the 'public-access' service edge router policy?`
337
+ - `Create a service edge router policy linking all services to all edge routers`
338
+
339
+ ### Service Policies
340
+
341
+ CRUD operations and relationship queries for Service Policies (Dial/Bind).
342
+
343
+ | Tool | Description |
344
+ | -------------------------------- | ------------------------------------------------------------------------------------------------------------ |
345
+ | `listServicePolicies` | List all service policies |
346
+ | `listServicePolicy` | Get details about a specific service policy |
347
+ | `createServicePolicy` | Create a new service policy (name, type Dial/Bind, semantic, identityRoles, serviceRoles, postureCheckRoles) |
348
+ | `deleteServicePolicy` | Delete a service policy |
349
+ | `updateServicePolicy` | Update an existing service policy |
350
+ | `listServicePolicyIdentities` | List identities associated with a policy |
351
+ | `listServicePolicyServices` | List services associated with a policy |
352
+ | `listServicePolicyPostureChecks` | List posture checks associated with a policy |
353
+
354
+ **Example prompts:**
355
+
356
+ - `Show me all Dial service policies`
357
+ - `Which identities are in the 'web-access' service policy?`
358
+ - `Create a Bind policy for the 'my-api' service`
359
+
360
+ ### Configs
361
+
362
+ CRUD operations and relationship queries for Ziti Configs.
363
+
364
+ | Tool | Description |
365
+ | -------------------- | ---------------------------------------------- |
366
+ | `listConfigs` | List all configs |
367
+ | `listConfig` | Get details about a specific config |
368
+ | `createConfig` | Create a new config (name, configTypeId, data) |
369
+ | `deleteConfig` | Delete a config |
370
+ | `updateConfig` | Update an existing config |
371
+ | `listConfigServices` | List services that use a specific config |
372
+
373
+ **Example prompts:**
374
+
375
+ - `List all configs in the network`
376
+ - `Which services use config abc123?`
377
+ - `Create a new intercept.v1 config for my-service`
378
+
379
+ ### Config Types
380
+
381
+ CRUD operations for Ziti Config Types.
382
+
383
+ | Tool | Description |
384
+ | -------------------------- | ------------------------------------------------ |
385
+ | `listConfigTypes` | List all config types |
386
+ | `listConfigType` | Get details about a specific config type |
387
+ | `createConfigType` | Create a new config type (name, schema) |
388
+ | `deleteConfigType` | Delete a config type |
389
+ | `updateConfigType` | Update an existing config type |
390
+ | `listConfigsForConfigType` | List all configs that use a specific config type |
391
+
392
+ **Example prompts:**
393
+
394
+ - `What config types are available?`
395
+ - `Show me all configs using the intercept.v1 config type`
396
+ - `Create a new config type with a custom JSON schema`
397
+
398
+ ### Auth Policies
399
+
400
+ CRUD operations for Auth Policies (primary cert/extJwt/updb and secondary requirements).
401
+
402
+ | Tool | Description |
403
+ | ------------------ | ----------------------------------------------------------------------------------------- |
404
+ | `listAuthPolicies` | List all auth policies |
405
+ | `listAuthPolicy` | Get details about a specific auth policy |
406
+ | `createAuthPolicy` | Create a new auth policy (primary cert, extJwt, updb settings; secondary MFA requirement) |
407
+ | `deleteAuthPolicy` | Delete an auth policy |
408
+ | `updateAuthPolicy` | Update an existing auth policy |
409
+
410
+ **Example prompts:**
411
+
412
+ - `List all auth policies`
413
+ - `Show me the details of the default auth policy`
414
+ - `Create an auth policy that requires MFA as a secondary factor`
415
+
416
+ ### Authenticators
417
+
418
+ CRUD operations for Authenticators (updb/cert).
419
+
420
+ | Tool | Description |
421
+ | --------------------- | ---------------------------------------------------------------------------- |
422
+ | `listAuthenticators` | List all authenticators |
423
+ | `listAuthenticator` | Get details about a specific authenticator |
424
+ | `createAuthenticator` | Create a new authenticator (method, identityId, username, password, certPem) |
425
+ | `deleteAuthenticator` | Delete an authenticator |
426
+ | `updateAuthenticator` | Update an existing authenticator |
427
+
428
+ **Example prompts:**
429
+
430
+ - `List all authenticators in the network`
431
+ - `Show me the authenticators for identity xyz`
432
+ - `Create a new updb authenticator for identity abc123`
433
+
434
+ ### Certificate Authorities
435
+
436
+ CRUD operations, JWT retrieval, and verification for Certificate Authorities.
437
+
438
+ | Tool | Description |
439
+ | ---------- | ---------------------------------------------------------------------------------- |
440
+ | `listCas` | List all certificate authorities |
441
+ | `listCa` | Get details about a specific CA |
442
+ | `createCa` | Create a new CA (name, certPem, isAuthEnabled, enrollment settings, identityRoles) |
443
+ | `deleteCa` | Delete a CA |
444
+ | `updateCa` | Update an existing CA |
445
+ | `getCaJwt` | Get the JWT for a CA (used for enrollment) |
446
+ | `verifyCa` | Verify a CA with a signed PEM certificate |
447
+
448
+ **Example prompts:**
449
+
450
+ - `List all certificate authorities`
451
+ - `Get the JWT for CA abc123`
452
+ - `Verify CA xyz with this PEM certificate`
453
+
454
+ ### External JWT Signers
455
+
456
+ CRUD operations for External JWT Signers.
457
+
458
+ | Tool | Description |
459
+ | ------------------------- | -------------------------------------------------------------------------------------- |
460
+ | `listExternalJwtSigners` | List all external JWT signers |
461
+ | `listExternalJwtSigner` | Get details about a specific external JWT signer |
462
+ | `createExternalJwtSigner` | Create a new external JWT signer (name, issuer, audience, certPem, jwksEndpoint, etc.) |
463
+ | `deleteExternalJwtSigner` | Delete an external JWT signer |
464
+ | `updateExternalJwtSigner` | Update an existing external JWT signer |
465
+
466
+ **Example prompts:**
467
+
468
+ - `List all external JWT signers`
469
+ - `Show me the details of the Demo JWT signer`
470
+ - `Create a new external JWT signer for my IdP`
471
+
472
+ ### Posture Checks
473
+
474
+ CRUD operations, type queries, and role attributes for Posture Checks.
475
+
476
+ | Tool | Description |
477
+ | -------------------------------- | ---------------------------------------------------------------------------------- |
478
+ | `listPostureChecks` | List all posture checks |
479
+ | `listPostureCheck` | Get details about a specific posture check |
480
+ | `createPostureCheck` | Create a new posture check (name, typeId: OS/PROCESS/DOMAIN/MAC/MFA/PROCESS_MULTI) |
481
+ | `deletePostureCheck` | Delete a posture check |
482
+ | `updatePostureCheck` | Update an existing posture check |
483
+ | `listPostureCheckRoleAttributes` | List all role attributes in use by posture checks |
484
+ | `listPostureCheckTypes` | List all available posture check types |
485
+ | `detailPostureCheckType` | Get details about a specific posture check type |
486
+
487
+ **Example prompts:**
488
+
489
+ - `List all posture checks`
490
+ - `What posture check types are available?`
491
+ - `Create a new MFA posture check called 'require-mfa'`
492
+
493
+ ### Routers
494
+
495
+ CRUD operations for fabric Routers.
496
+
497
+ | Tool | Description |
498
+ | -------------- | ------------------------------------------------------- |
499
+ | `listRouters` | List all routers |
500
+ | `listRouter` | Get details about a specific router |
501
+ | `createRouter` | Create a new router (name, cost, noTraversal, disabled) |
502
+ | `deleteRouter` | Delete a router |
503
+ | `updateRouter` | Update an existing router |
504
+
505
+ **Example prompts:**
506
+
507
+ - `List all routers in the network`
508
+ - `Show me details for router xyz`
509
+ - `Create a new router with cost 100`
510
+
511
+ ### Transit Routers
512
+
513
+ CRUD operations for Transit Routers.
514
+
515
+ | Tool | Description |
516
+ | --------------------- | ------------------------------------------- |
517
+ | `listTransitRouters` | List all transit routers |
518
+ | `listTransitRouter` | Get details about a specific transit router |
519
+ | `createTransitRouter` | Create a new transit router |
520
+ | `deleteTransitRouter` | Delete a transit router |
521
+ | `updateTransitRouter` | Update an existing transit router |
522
+
523
+ **Example prompts:**
524
+
525
+ - `List all transit routers`
526
+ - `Show me the details of transit router abc123`
527
+
528
+ ### Terminators
529
+
530
+ CRUD operations for Terminators.
531
+
532
+ | Tool | Description |
533
+ | ------------------ | ----------------------------------------------------------------------------- |
534
+ | `listTerminators` | List all terminators |
535
+ | `listTerminator` | Get details about a specific terminator |
536
+ | `createTerminator` | Create a new terminator (service, router, binding, address, cost, precedence) |
537
+ | `deleteTerminator` | Delete a terminator |
538
+ | `updateTerminator` | Update an existing terminator |
539
+
540
+ **Example prompts:**
541
+
542
+ - `List all terminators`
543
+ - `Show me terminators for the 'my-service' service`
544
+ - `Create a terminator binding my-service to router xyz`
545
+
546
+ ### Enrollments
547
+
548
+ CRUD operations and refresh for Enrollments.
549
+
550
+ | Tool | Description |
551
+ | ------------------- | ----------------------------------------------------------------------- |
552
+ | `listEnrollments` | List all enrollments |
553
+ | `listEnrollment` | Get details about a specific enrollment |
554
+ | `createEnrollment` | Create a new enrollment (identityId, method: ott/ottca/updb, expiresAt) |
555
+ | `deleteEnrollment` | Delete an enrollment |
556
+ | `refreshEnrollment` | Refresh an expired enrollment with a new expiration time |
557
+
558
+ **Example prompts:**
559
+
560
+ - `List all pending enrollments`
561
+ - `Create a new OTT enrollment for identity abc123`
562
+ - `Refresh the expired enrollment xyz with a new expiration date`
563
+
564
+ ### Controller Settings
565
+
566
+ CRUD operations for Controller Settings (OIDC configuration).
567
+
568
+ | Tool | Description |
569
+ | ---------------------------------- | -------------------------------------------------------- |
570
+ | `listControllerSettings` | List all controller settings |
571
+ | `listControllerSetting` | Get details about a specific controller setting |
572
+ | `createControllerSetting` | Create a new controller setting |
573
+ | `deleteControllerSetting` | Delete a controller setting |
574
+ | `updateControllerSetting` | Update an existing controller setting |
575
+ | `detailControllerSettingEffective` | Get the effective (merged) value of a controller setting |
576
+
577
+ **Example prompts:**
578
+
579
+ - `List all controller settings`
580
+ - `Show me the effective value of controller setting xyz`
581
+ - `Update the OIDC redirect URIs for the controller`
582
+
583
+ ### Controllers & System Info
584
+
585
+ | Tool | Description |
586
+ | ---------------------------- | ------------------------------------------------- |
587
+ | `listControllers` | List all controllers in the Ziti network |
588
+ | `listRoot` | Get controller version and root information |
589
+ | `listEnumeratedCapabilities` | List all capabilities supported by the controller |
590
+ | `listSummary` | Get a summary of entity counts across the network |
591
+
592
+ **Example prompts:**
593
+
594
+ - `What version is the Ziti controller running?`
595
+ - `Give me a summary of the network — how many identities, services, and routers exist?`
596
+ - `What capabilities does this controller support?`
597
+
598
+ ### Identity Types
599
+
600
+ | Tool | Description |
601
+ | -------------------- | ------------------------------------------ |
602
+ | `listIdentityTypes` | List all identity types available |
603
+ | `detailIdentityType` | Get details about a specific identity type |
604
+
605
+ **Example prompts:**
606
+
607
+ - `What identity types are available?`
608
+ - `Show me the details of the 'User' identity type`
609
+
610
+ ### Sessions
611
+
612
+ | Tool | Description |
613
+ | --------------- | ------------------------------------ |
614
+ | `listSessions` | List all sessions |
615
+ | `listSession` | Get details about a specific session |
616
+ | `deleteSession` | Delete a session |
617
+
618
+ **Example prompts:**
619
+
620
+ - `List all active sessions`
621
+ - `Show me details for session xyz`
622
+ - `Delete session abc123`
623
+
624
+ ### API Sessions
625
+
626
+ | Tool | Description |
627
+ | ------------------ | ---------------------------------------- |
628
+ | `listApiSessions` | List all API sessions |
629
+ | `listApiSession` | Get details about a specific API session |
630
+ | `deleteApiSession` | Delete an API session |
631
+
632
+ **Example prompts:**
633
+
634
+ - `List all API sessions`
635
+ - `Show me details for API session xyz`
636
+ - `Delete API session abc123`
637
+
638
+ ### 🔒 Security Best Practices for Tool Access
639
+
640
+ When configuring the Ziti MCP Server, it's important to follow security best practices by limiting tool access based on your specific needs. The server provides flexible configuration options that let you control which tools AI assistants can access.
641
+
642
+ You can easily restrict tool access using the `--tools` and `--read-only` flags when starting the server:
643
+
644
+ ```bash
645
+ # Enable only read-only operations
646
+ npx @openziti/ziti-mcp-server run --read-only
647
+
648
+ # Alternative way to enable only read-only operations
649
+ npx @openziti/ziti-mcp-server run --tools 'list*,get*'
650
+
651
+ # Limit to just identity-related tools
652
+ npx @openziti/ziti-mcp-server run --tools '*Identit*'
653
+
654
+ # Limit to read-only identity-related tools
655
+ # Note: --read-only takes priority when used with --tools
656
+ npx @openziti/ziti-mcp-server run --tools '*Identit*' --read-only
657
+
658
+ # Run the server with all tools enabled
659
+ npx @openziti/ziti-mcp-server run --tools '*'
660
+ ```
661
+
662
+ > [!IMPORTANT]
663
+ > When both `--read-only` and `--tools` flags are used together, the `--read-only` flag takes priority for security. This means even if your `--tools` pattern matches non-read-only tools, only read-only operations will be available. This ensures you can rely on the `--read-only` flag as a security guardrail.
664
+
665
+ This approach offers several important benefits:
666
+
667
+ 1. **Enhanced Security**: By limiting available tools to only what's needed, you reduce the potential attack surface and prevent unintended modifications to your Ziti network.
668
+
669
+ 2. **Better Performance**: Providing fewer tools to AI assistants actually improves performance. When models have access to many tools, they use more of their context window to reason about which tools to use. With a focused set of tools, you'll get faster and more relevant responses.
670
+
671
+ 3. **Resource-Based Access Control**: You can configure different instances of the MCP server with different tool sets based on specific needs - development environments might need full access, while production environments could be limited to read operations only.
672
+
673
+ 4. **Simplified Auditing**: With limited tools, it's easier to track which operations were performed through the AI assistant.
674
+
675
+ For most use cases, start with the minimum set of tools needed and add more only when required. This follows the principle of least privilege - a fundamental security best practice.
676
+
677
+ ### 🧪 Security Scanning
678
+
679
+ We recommend regularly scanning this server, and any other MCP-compatible servers you deploy, with community tools built to surface protocol-level risks and misconfigurations.
680
+
681
+ These scanners help identify issues across key vulnerability classes including: server implementation bugs, tool definition and lifecycle risks, interaction and data flow weaknesses, and configuration or environment gaps.
682
+
683
+ Useful tools include:
684
+
685
+ - **[mcpscan.ai](https://mcpscan.ai)**
686
+ Web-based scanner that inspects live MCP endpoints for exposed tools, schema enforcement gaps, and other issues.
687
+
688
+ - **[mcp-scan](https://github.com/invariantlabs-ai/mcp-scan)**
689
+ CLI tool that simulates attack paths and evaluates server behavior from a client perspective.
690
+
691
+ These tools are not a substitute for a full audit, but they offer meaningful guardrails and early warnings. We suggest including them in your regular security review process.
692
+
693
+ ## 🩺 Troubleshooting
694
+
695
+ When encountering issues with the Ziti MCP Server, several troubleshooting options are available to help diagnose and resolve problems.
696
+
697
+ Start troubleshooting by exploring all available commands and options:
698
+
699
+ ```bash
700
+ npx @openziti/ziti-mcp-server help
701
+ ```
702
+
703
+ ### 🚥 Operation Modes
704
+
705
+ #### 🐞 Debug Mode
706
+
707
+ - More detailed logging
708
+ - Enable by setting environment variable: `export DEBUG=ziti-mcp`
709
+
710
+ > [!TIP]
711
+ > Debug mode is particularly useful when troubleshooting connection or authentication issues.
712
+
713
+ #### 🔑 Scope Selection
714
+
715
+ The server provides an interactive scope selection interface during initialization:
716
+
717
+ - **Interactive Selection**: Navigate with arrow keys and toggle selections with spacebar
718
+ - **No Default Scopes**: By default, no scopes are selected for maximum security
719
+ - **Glob Pattern Support**: Quickly select multiple related scopes with patterns:
720
+
721
+ ```bash
722
+ # Select all read scopes
723
+ npx @openziti/ziti-mcp-server init --scopes 'read:*'
724
+
725
+ # Select multiple scope patterns (comma-separated)
726
+ npx @openziti/ziti-mcp-server init --scopes 'read:*,create:identities,update:services'
727
+ ```
728
+
729
+ > [!NOTE]
730
+ > Selected scopes determine what operations the MCP server can perform on your Ziti network.
731
+
732
+ ### ⚙️ Configuration
733
+
734
+ #### Other MCP Clients:
735
+
736
+ To use Ziti MCP Server with any other MCP Client, you can add this configuration to the client and restart for changes to take effect:
737
+
738
+ ```json
739
+ {
740
+ "mcpServers": {
741
+ "ziti": {
742
+ "command": "npx",
743
+ "args": ["-y", "@openziti/ziti-mcp-server", "run"],
744
+ "capabilities": ["tools"],
745
+ "env": {
746
+ "DEBUG": "ziti-mcp"
747
+ }
748
+ }
749
+ }
750
+ }
751
+ ```
752
+
753
+ > [!NOTE]
754
+ > You can manually update if needed or if any unexpected errors occur during the npx init command.
755
+
756
+ ### 🚨 Common Issues
757
+
758
+ 1. **Authentication Failures**
759
+ - Ensure you have the correct permissions in your IdP tenant and Ziti network
760
+ - Try re-initializing with `npx @openziti/ziti-mcp-server init`
761
+
762
+ 2. **Claude Desktop Can't Connect to the Server**
763
+ - Restart Claude Desktop after installation
764
+ - Check that the server is running with `ps aux | grep ziti-mcp`
765
+
766
+ 3. **API Errors or Permission Issues**
767
+ - Enable debug mode with `export DEBUG=ziti-mcp`
768
+ - Check your token status: `npx @openziti/ziti-mcp-server session`
769
+ - Reinitialize with specific scopes: `npx @openziti/ziti-mcp-server init --scopes 'read:*,update:*,create:*'`
770
+ - If a specific operation fails, you may be missing the required scope
771
+
772
+ 4. **Invalid Configuration Error**
773
+ - This typically happens when your authorization token is missing or expired
774
+ - Run `npx @openziti/ziti-mcp-server session` to check your token status
775
+ - If expired or missing, run `npx @openziti/ziti-mcp-server init` to authenticate
776
+
777
+ > [!TIP]
778
+ > Most connection issues can be resolved by restarting both the server and Claude Desktop.
779
+
780
+ ## 📋 Debug logs
781
+
782
+ Enable debug mode to view detailed logs:
783
+
784
+ ```sh
785
+ export DEBUG=ziti-mcp
786
+ ```
787
+
788
+ Get detailed MCP Client logs from Claude Desktop:
789
+
790
+ ```sh
791
+ # Follow logs in real-time
792
+ tail -n 20 -F ~/Library/Logs/Claude/mcp*.log
793
+ ```
794
+
795
+ For advanced troubleshooting, use the MCP Inspector:
796
+
797
+ ```sh
798
+ npx @modelcontextprotocol/inspector -e DEBUG='ziti-mcp' @openziti/ziti-mcp-server run
799
+ ```
800
+
801
+ For detailed MCP Server logs, run the server in debug mode:
802
+
803
+ ```bash
804
+ DEBUG=ziti-mcp npx @openziti/ziti-mcp-server run
805
+ ```
806
+
807
+ ## 👨‍💻 Development
808
+
809
+ ### Building from Source
810
+
811
+ ```bash
812
+ # Clone the repository
813
+ git clone https://github.com/openziti/ziti-mcp-server.git
814
+ cd ziti-mcp-server
815
+
816
+ # Install dependencies
817
+ npm install
818
+
819
+ # Build the project
820
+ npm run build
821
+
822
+ # Initiate device auth flow
823
+ npx . init
824
+
825
+ # Configure your MCP Client (e.g. Claude Desktop) with MCP server path
826
+ npm run setup
827
+ ```
828
+
829
+ ### Development Scripts
830
+
831
+ ```bash
832
+ # Run directly with TypeScript (no build needed)
833
+ npm run dev
834
+
835
+ # Run with debug logs enabled
836
+ npm run dev:debug
837
+
838
+ # Run with MCP inspector for debugging
839
+ npm run dev:inspect
840
+
841
+ # Run the compiled JavaScript version
842
+ npm run start
843
+ ```
844
+
845
+ > [!NOTE]
846
+ > This server requires [Node.js v18 or higher](https://nodejs.org/en/download).
847
+
848
+ ## 🔒 Security
849
+
850
+ The Ziti MCP Server prioritizes security:
851
+
852
+ - Credentials are stored in the system's secure keychain
853
+ - No sensitive information is stored in plain text
854
+ - Authentication uses OAuth 2.0 device authorization flow
855
+ - No permissions (scopes) are requested by default
856
+ - Interactive scope selection allows you to choose exactly which permissions to grant
857
+ - Support for glob patterns to quickly select related scopes (e.g., `read:*`)
858
+ - Easy token removal via `logout` command when no longer needed
859
+
860
+ > [!IMPORTANT]
861
+ > For security best practices, always use `npx @openziti/ziti-mcp-server logout` when you're done with a session or switching between tenants. This ensures your authentication tokens are properly removed from the system keychain.
862
+
863
+ > [!CAUTION]
864
+ > Always review the permissions requested during the authentication process to ensure they align with your security requirements.
865
+
866
+ ### Reporting Issues
867
+
868
+ To provide feedback or report a bug, please [raise an issue on our issue tracker](https://github.com/openziti/ziti-mcp-server/issues).