@qnx/client 0.8.0 → 0.8.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +52 -11
- package/dist/package.json +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
#
|
|
1
|
+
# @qnx/client
|
|
2
2
|
|
|
3
3
|
`@qnx/client` provides utility classes and types to help standardize and simplify handling of API responses on the client side. It supports typed access to data, messages, and errors from server responses.
|
|
4
4
|
|
|
5
|
+
> 🤖 MCP Server: `https://qnx-mcp-server.vercel.app/mcp/client`
|
|
6
|
+
|
|
5
7
|
## ✨ Features
|
|
6
8
|
|
|
7
9
|
- Typed wrappers for API responses
|
|
@@ -11,8 +13,6 @@
|
|
|
11
13
|
|
|
12
14
|
## 📦 Installation
|
|
13
15
|
|
|
14
|
-
You can install via your preferred package manager:
|
|
15
|
-
|
|
16
16
|
```bash
|
|
17
17
|
# npm
|
|
18
18
|
npm install @qnx/client
|
|
@@ -92,9 +92,9 @@ const error = apiRes.getError()
|
|
|
92
92
|
const errorCode = apiRes.getErrorCode()
|
|
93
93
|
```
|
|
94
94
|
|
|
95
|
-
|
|
95
|
+
## 📘 Types
|
|
96
96
|
|
|
97
|
-
|
|
97
|
+
### `ApiResponseValue<T>`
|
|
98
98
|
|
|
99
99
|
```ts
|
|
100
100
|
import type { ApiResponseValue } from '@qnx/client'
|
|
@@ -115,7 +115,7 @@ const response: ApiResponseValue<number> = {
|
|
|
115
115
|
}
|
|
116
116
|
```
|
|
117
117
|
|
|
118
|
-
|
|
118
|
+
### `ApiSuccessResponseValue<T>`
|
|
119
119
|
|
|
120
120
|
```ts
|
|
121
121
|
import type { ApiSuccessResponseValue } from '@qnx/client'
|
|
@@ -126,7 +126,7 @@ const successResponse: ApiSuccessResponseValue<number> = {
|
|
|
126
126
|
}
|
|
127
127
|
```
|
|
128
128
|
|
|
129
|
-
|
|
129
|
+
### `ApiErrorResponseValue`
|
|
130
130
|
|
|
131
131
|
```ts
|
|
132
132
|
import type { ApiErrorResponseValue } from '@qnx/client'
|
|
@@ -141,12 +141,53 @@ const errorResponse: ApiErrorResponseValue = {
|
|
|
141
141
|
}
|
|
142
142
|
```
|
|
143
143
|
|
|
144
|
+
---
|
|
145
|
+
|
|
146
|
+
## 🤖 MCP Server
|
|
147
|
+
|
|
148
|
+
AI tools for this package are available via the [QNX MCP Server](https://qnx-mcp-server.vercel.app).
|
|
149
|
+
|
|
150
|
+
**Endpoint:** `https://qnx-mcp-server.vercel.app/mcp/client`
|
|
151
|
+
|
|
152
|
+
| Tool | Description |
|
|
153
|
+
| ---- | ----------- |
|
|
154
|
+
| `get-client-docs` | Documentation for ApiResponse, ApiSuccessResponse, ApiErrorResponse classes, TypeScript types, and usage patterns |
|
|
155
|
+
| `build-client-response` | Instantiate a response class with real values — see what each method returns |
|
|
156
|
+
|
|
157
|
+
**Supported clients:** Claude Desktop · Claude Code · Cursor · Windsurf · Cline · Continue.dev · Codex CLI · ChatGPT Desktop
|
|
158
|
+
|
|
159
|
+
### HTTP (Streamable HTTP)
|
|
160
|
+
|
|
161
|
+
```json
|
|
162
|
+
{
|
|
163
|
+
"mcpServers": {
|
|
164
|
+
"qnx-client": {
|
|
165
|
+
"url": "https://qnx-mcp-server.vercel.app/mcp/client"
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
```
|
|
170
|
+
|
|
171
|
+
### stdio (via npx)
|
|
172
|
+
|
|
173
|
+
```json
|
|
174
|
+
{
|
|
175
|
+
"mcpServers": {
|
|
176
|
+
"qnx-client": {
|
|
177
|
+
"command": "npx",
|
|
178
|
+
"args": ["-y", "@qnx/mcp", "client"]
|
|
179
|
+
}
|
|
180
|
+
}
|
|
181
|
+
}
|
|
182
|
+
```
|
|
183
|
+
|
|
184
|
+
---
|
|
185
|
+
|
|
144
186
|
## 🤝 Contributing
|
|
145
187
|
|
|
146
|
-
Pull requests are welcome
|
|
147
|
-
|
|
148
|
-
Ensure tests are updated for any feature changes.
|
|
188
|
+
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
|
|
189
|
+
Please make sure to update tests as appropriate.
|
|
149
190
|
|
|
150
191
|
## 📄 License
|
|
151
192
|
|
|
152
|
-
[MIT License](https://github.com/yatendra121/
|
|
193
|
+
[MIT License](https://github.com/yatendra121/qnx/blob/main/LICENSE.md) © 2023-PRESENT [Yatendra Kushwaha](https://github.com/yatendra121)
|
package/dist/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@qnx/client",
|
|
3
3
|
"description": "@qnx/client for handling response",
|
|
4
4
|
"author": "Yatendra Kushwaha <https://github.com/yatendra121>",
|
|
5
|
-
"version": "0.8.
|
|
5
|
+
"version": "0.8.8",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"funding": "https://github.com/sponsors/yatendra121",
|
|
8
8
|
"homepage": "https://github.com/yatendra121/qnx/tree/main/packages/client",
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@qnx/client",
|
|
3
3
|
"description": "@qnx/client for handling response",
|
|
4
4
|
"author": "Yatendra Kushwaha <https://github.com/yatendra121>",
|
|
5
|
-
"version": "0.8.
|
|
5
|
+
"version": "0.8.8",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"funding": "https://github.com/sponsors/yatendra121",
|
|
8
8
|
"homepage": "https://github.com/yatendra121/qnx/tree/main/packages/client",
|