document-rest 1.4.50 → 1.4.52
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/dist/bin.js +3 -3
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/package.json +5 -5
package/dist/bin.js
CHANGED
|
@@ -80,7 +80,7 @@ function listOperations() {
|
|
|
80
80
|
})) };
|
|
81
81
|
}
|
|
82
82
|
/**
|
|
83
|
-
* Builds a REST API server exposing every document-operations DocumentOperation as `POST /<name>`: the JSON request body is validated against the operation's own inputSchema, `run()` is called with the parsed input, and the result is returned as `{ result }`. `GET /` lists every available operation (name/title/description) for discovery. Never started
|
|
83
|
+
* Builds a REST API server exposing every document-operations DocumentOperation as `POST /<name>`: the JSON request body is validated against the operation's own inputSchema, `run()` is called with the parsed input, and the result is returned as `{ result }`. `GET /` lists every available operation (name/title/description) for discovery. Never started — `src/bin.ts` binds it to a port; a test binds it to an ephemeral one.
|
|
84
84
|
*/
|
|
85
85
|
function createRestServer() {
|
|
86
86
|
return createServer((req, res) => {
|
|
@@ -128,9 +128,9 @@ function parsePort(raw) {
|
|
|
128
128
|
return port;
|
|
129
129
|
}
|
|
130
130
|
/**
|
|
131
|
-
* The real CLI entry logic, shared by both distribution shapes this package ships: `src/bin.ts` (the published npm `bin`, run under a real Node.js install) and `src/sea-entry.ts` (bundled into a Node single-executable application, which embeds its own Node runtime). Node's SEA feature runs only a CommonJS entry with no top-level await (see that file's own comment), so this function itself contains no top-level await of its own
|
|
131
|
+
* The real CLI entry logic, shared by both distribution shapes this package ships: `src/bin.ts` (the published npm `bin`, run under a real Node.js install) and `src/sea-entry.ts` (bundled into a Node single-executable application, which embeds its own Node runtime). Node's SEA feature runs only a CommonJS entry with no top-level await (see that file's own comment), so this function itself contains no top-level await of its own — only `bin.ts` awaits calling it, at its own top level, which SEA never sees.
|
|
132
132
|
*
|
|
133
|
-
* Returns the listening `Server` rather than resolving `void` so a caller with a reason to stop it again (a test binding an ephemeral port for the duration of one assertion) can
|
|
133
|
+
* Returns the listening `Server` rather than resolving `void` so a caller with a reason to stop it again (a test binding an ephemeral port for the duration of one assertion) can — neither real distribution shape needs to, so both simply discard it.
|
|
134
134
|
*/
|
|
135
135
|
async function main() {
|
|
136
136
|
const args = process.argv.slice(2);
|
package/dist/index.cjs
CHANGED
|
@@ -80,7 +80,7 @@ function listOperations() {
|
|
|
80
80
|
})) };
|
|
81
81
|
}
|
|
82
82
|
/**
|
|
83
|
-
* Builds a REST API server exposing every document-operations DocumentOperation as `POST /<name>`: the JSON request body is validated against the operation's own inputSchema, `run()` is called with the parsed input, and the result is returned as `{ result }`. `GET /` lists every available operation (name/title/description) for discovery. Never started
|
|
83
|
+
* Builds a REST API server exposing every document-operations DocumentOperation as `POST /<name>`: the JSON request body is validated against the operation's own inputSchema, `run()` is called with the parsed input, and the result is returned as `{ result }`. `GET /` lists every available operation (name/title/description) for discovery. Never started — `src/bin.ts` binds it to a port; a test binds it to an ephemeral one.
|
|
84
84
|
*/
|
|
85
85
|
function createRestServer() {
|
|
86
86
|
return (0, node_http.createServer)((req, res) => {
|
package/dist/index.d.cts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Server } from "node:http";
|
|
2
2
|
//#region src/server.d.ts
|
|
3
3
|
/**
|
|
4
|
-
* Builds a REST API server exposing every document-operations DocumentOperation as `POST /<name>`: the JSON request body is validated against the operation's own inputSchema, `run()` is called with the parsed input, and the result is returned as `{ result }`. `GET /` lists every available operation (name/title/description) for discovery. Never started
|
|
4
|
+
* Builds a REST API server exposing every document-operations DocumentOperation as `POST /<name>`: the JSON request body is validated against the operation's own inputSchema, `run()` is called with the parsed input, and the result is returned as `{ result }`. `GET /` lists every available operation (name/title/description) for discovery. Never started — `src/bin.ts` binds it to a port; a test binds it to an ephemeral one.
|
|
5
5
|
*/
|
|
6
6
|
declare function createRestServer(): Server;
|
|
7
7
|
//#endregion
|
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Server } from "node:http";
|
|
2
2
|
//#region src/server.d.ts
|
|
3
3
|
/**
|
|
4
|
-
* Builds a REST API server exposing every document-operations DocumentOperation as `POST /<name>`: the JSON request body is validated against the operation's own inputSchema, `run()` is called with the parsed input, and the result is returned as `{ result }`. `GET /` lists every available operation (name/title/description) for discovery. Never started
|
|
4
|
+
* Builds a REST API server exposing every document-operations DocumentOperation as `POST /<name>`: the JSON request body is validated against the operation's own inputSchema, `run()` is called with the parsed input, and the result is returned as `{ result }`. `GET /` lists every available operation (name/title/description) for discovery. Never started — `src/bin.ts` binds it to a port; a test binds it to an ephemeral one.
|
|
5
5
|
*/
|
|
6
6
|
declare function createRestServer(): Server;
|
|
7
7
|
//#endregion
|
package/dist/index.js
CHANGED
|
@@ -79,7 +79,7 @@ function listOperations() {
|
|
|
79
79
|
})) };
|
|
80
80
|
}
|
|
81
81
|
/**
|
|
82
|
-
* Builds a REST API server exposing every document-operations DocumentOperation as `POST /<name>`: the JSON request body is validated against the operation's own inputSchema, `run()` is called with the parsed input, and the result is returned as `{ result }`. `GET /` lists every available operation (name/title/description) for discovery. Never started
|
|
82
|
+
* Builds a REST API server exposing every document-operations DocumentOperation as `POST /<name>`: the JSON request body is validated against the operation's own inputSchema, `run()` is called with the parsed input, and the result is returned as `{ result }`. `GET /` lists every available operation (name/title/description) for discovery. Never started — `src/bin.ts` binds it to a port; a test binds it to an ephemeral one.
|
|
83
83
|
*/
|
|
84
84
|
function createRestServer() {
|
|
85
85
|
return createServer((req, res) => {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "document-rest",
|
|
3
|
-
"version": "1.4.
|
|
4
|
-
"description": "A plain REST API server exposing document-operations' conversion, editing, inspection, and .odb operations as JSON-over-HTTP endpoints
|
|
3
|
+
"version": "1.4.52",
|
|
4
|
+
"description": "A plain REST API server exposing document-operations' conversion, editing, inspection, and .odb operations as JSON-over-HTTP endpoints — one POST route per operation, for a caller with no MCP client and no Node runtime of their own.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"repository": {
|
|
7
7
|
"type": "git",
|
|
@@ -87,8 +87,8 @@
|
|
|
87
87
|
"license": "MIT",
|
|
88
88
|
"packageManager": "pnpm@12.4.1+sha512.2e81e399d73fe8390dab25e06aa788ab7a5908248d2f5a370f82b481147a6a7a367bf8048f9a6fdb6460f21a66f0542dedb8b94ca2c8723596741920b1656d4c",
|
|
89
89
|
"dependencies": {
|
|
90
|
-
"document-operations": "1.1.
|
|
91
|
-
"documents.js": "14.
|
|
90
|
+
"document-operations": "1.1.51",
|
|
91
|
+
"documents.js": "14.1.1",
|
|
92
92
|
"zod": "4.4.3"
|
|
93
93
|
},
|
|
94
94
|
"devDependencies": {
|
|
@@ -97,7 +97,7 @@
|
|
|
97
97
|
"@vitest/coverage-v8": "4.1.11",
|
|
98
98
|
"eslint": "10.8.1",
|
|
99
99
|
"husky": "9.1.7",
|
|
100
|
-
"odf.js": "11.0.
|
|
100
|
+
"odf.js": "11.0.1",
|
|
101
101
|
"publint": "0.3.22",
|
|
102
102
|
"semantic-release": "25.0.9",
|
|
103
103
|
"tsdown": "0.22.14",
|