← All procedures
lib.new
Create a new package in the ecosystem
MCPCLI- Package
- @procedures/lib · README
- Path
["lib","new"]- CLI
mark lib new --name <string>- MCP tool
lib.new on the dev-tools server- As data
{"$proc":["lib","new"],"input":{}}
Use it
In TypeScript
import { Client, LocalTransport, PROCEDURE_REGISTRY } from "@procedures/client";
import "@procedures/lib"; // registers its procedures
const client = new Client(new LocalTransport({ registry: PROCEDURE_REGISTRY }));
const result = await client.exec(["lib","new"], { name: "<name>" });
console.log(JSON.stringify(result));From the command line
$ mark lib new --name <string>
As data, in a program
{ "$proc": ["lib", "new"], "input": { "name": "<name>" } }Input
| Field | Type | Required | Default | Description |
|---|
name | string | yes | | Package name (without the @procedures/ scope) |
preset | string | no | "lib" | Feature preset to use |
rootPath | string | no | | Workspace root (defaults to the pnpm workspace that contains client-lib) |
dryRun | boolean | no | false | Preview changes without creating |
Output
| Field | Type | Required | Default | Description |
|---|
success | boolean | yes | | True when the package was made |
packageName | string | yes | | The full package name (@procedures/...) |
packagePath | string | yes | | The folder of the new package |
created | string[] | yes | | The files that the call made |
operations | string[] | yes | | The steps that the call ran |
errors | string[] | yes | | The errors |
JSON Schemas
{
"input": {
"type": "object",
"properties": {
"name": {
"type": "string",
"pattern": "^[a-z][a-z0-9-]*$",
"description": "Package name (without the @procedures/ scope)"
},
"preset": {
"default": "lib",
"description": "Feature preset to use",
"type": "string",
"pattern": "^[a-z][a-z0-9-]*$"
},
"rootPath": {
"description": "Workspace root (defaults to the pnpm workspace that contains client-lib)",
"type": "string"
},
"dryRun": {
"default": false,
"description": "Preview changes without creating",
"type": "boolean"
}
},
"required": [
"name"
]
},
"output": {
"type": "object",
"properties": {
"success": {
"type": "boolean",
"description": "True when the package was made"
},
"packageName": {
"type": "string",
"description": "The full package name (@procedures/...)"
},
"packagePath": {
"type": "string",
"description": "The folder of the new package"
},
"created": {
"type": "array",
"items": {
"type": "string"
},
"description": "The files that the call made"
},
"operations": {
"type": "array",
"items": {
"type": "string"
},
"description": "The steps that the call ran"
},
"errors": {
"type": "array",
"items": {
"type": "string"
},
"description": "The errors"
}
},
"required": [
"success",
"packageName",
"packagePath",
"created",
"operations",
"errors"
],
"additionalProperties": {}
}
}