MCP Ready Server 1.2.0

Give your AI
a document tool.

Connect Codex or another MCP client to a focused local bridge that validates structured content and returns a document people can review, edit and control.

Credentials stay in the local process. The model receives tools, never your bearer token.

AI content flowing through the pasteToPrint MCP bridge into a reviewable document
stdio connected AI → MCP → human review
6Focused tools
stdioLocal transport
20+Node.js runtime
OptionalAPI token

Model Context Protocol

A narrow bridge with a clear responsibility.

The server translates a small set of MCP tool calls into validated pasteToPrint document operations. It does not expose the complete API or a general browser.

01

Your AI client

Chooses a focused tool and sends semantic PTDF blocks instead of HTML or CSS.

create_document
03

Human-controlled editor

Receives separate editable and read-only links. Import still requires a human decision.

editorUrl · viewUrl

Six focused capabilities

Everything needed for a safe document handoff.

Read-only discovery comes first. Creation and updates remain explicit, temporary and reviewable.

Read only 01

list_templates

Returns the current catalog of stable presentation templates and the default template ID.

Read only 02

get_document_schema

Returns the published JSON Schema Draft 2020-12 contract for PTDF 1.0.

Local 03

validate_document

Validates and normalizes a complete PTDF document locally without creating a session.

Updates session 05

update_document

Replaces document content or permissions, with optional ETag protection against stale updates.

Read only 06

get_document_links

Refreshes editable and read-only links without returning document content or management secrets.

Quick setup

Connect the server to your MCP client.

Install dependencies once, register the local process, then restart your client so it can discover the six tools.

1
Install

Use Node.js 20 or newer and install the locked dependencies.

2
Register

Add the local server command to Codex or another MCP client.

3
Restart

Restart the client and confirm that all six tools appear.

Register globally in Codex
cd C:\laragon\www\pasteToPrint\integrations\mcp
npm.cmd ci --ignore-scripts

codex mcp add pastetoprint \
  --env PASTETOPRINT_API_BASE_URL=https://www.pastetoprint.com \
  -- node C:\laragon\www\pasteToPrint\integrations\mcp\src\server.js

codex mcp get pastetoprint
codex mcp list

The server uses STDIO, so standard output is reserved for MCP messages. Runtime diagnostics go to standard error. Open the complete setup guide →

Environment settings

Keep operational choices outside the prompt.

Configure the bridge through process environment variables. Do not paste credentials into a chat, tool input or document.

Variable Default Purpose
PASTETOPRINT_API_BASE_URL https://www.pastetoprint.com Base URL for Document API v2. Plain HTTP is accepted only for loopback testing.
PASTETOPRINT_API_TOKEN Not set Optional bearer token. It remains inside the MCP process.
PASTETOPRINT_DOCUMENT_TTL API tier Requested default session lifetime from 60 to 604800 seconds.
PASTETOPRINT_REQUEST_TIMEOUT_MS 15000 Maximum time for one API request, capped at 120000 milliseconds.
PASTETOPRINT_MAX_RESPONSE_BYTES 131072 Maximum accepted JSON response size, capped at one MiB.

Security model

The model gets capability, not credentials.

The local process owns the API token and temporary session management tokens. Tool outputs contain only the links and non-secret identifiers needed for the handoff.

  • Secrets stay localBearer and management tokens never appear in MCP tool inputs or outputs.
  • Redirects stay blockedThe client does not follow HTTP redirects that could forward authorization headers.
  • Structured input onlyPTDF semantic blocks are validated; arbitrary HTML and CSS are not accepted.
  • Safe empty-editor handoffManaged PTDF may fill only an empty editor with one-click Undo; existing documents still require confirmation, and output never starts automatically.
Read the authentication model

Recommended tool sequence

Discover, validate, create, then hand off.

This sequence keeps model output constrained and makes every network-side change intentional.

  1. 1
    Discover the contract

    Call the template catalog and document schema when the structure is unfamiliar.

    list_templates · get_document_schema
  2. 2
    Validate locally

    Normalize the complete PTDF document before creating any remote session.

    validate_document
  3. 3
    Create once

    Use a stable idempotency key and create the temporary editor session.

    create_document
  4. 4
    Return the right link

    Give the editor URL to a person who will review, or the view URL for read-only sharing.

    editorUrl · viewUrl

Diagnostics

Common setup issues, resolved quickly.

Start with the client registration, then check runtime, network access and API policy in that order.

01

The tools do not appear

Confirm that the server is enabled, the script path is absolute and the MCP client was restarted after configuration.

codex mcp get pastetoprint
02

The server does not start

Verify Node.js 20 or newer, install dependencies and run the integration test from the MCP directory.

npm.cmd test
03

The API is unavailable

Check the base URL, TLS access, proxy policy and whether the production endpoint returns JSON without a redirect.

PASTETOPRINT_API_BASE_URL
04

A request is rejected

Validate PTDF first, inspect the readable field error and confirm that token scopes allow the requested operation.

validate_document

Frequently asked questions

Know the boundary before you connect.

For normative behavior and exact input schemas, use the technical MCP documentation.

Open MCP specification
Does the AI model receive my API token?

No. The token stays in the environment of the local MCP process and is added only to eligible API requests.

Is an API token required?

No. Anonymous mode works without a token and uses a conservative session lifetime. A provisioned token enables the assigned API tier.

Can the MCP server print or export automatically?

No. It creates a temporary handoff. A person must open, review and confirm the document before printing or export.

Can I send HTML or CSS through the tools?

No. Creation and updates accept semantic PTDF 1.0 blocks so the document remains predictable and safely renderable.

Which clients can use the server?

Any local MCP client that supports STDIO servers and process environment variables can connect to it.

MCP Ready

Connect the model.
Keep people in control.