verae-mcp-timestamping-server/docs/operator-guide.md
George Lambert c547804835 feat: add signup, login, session, and create_user
signup calls POST /auth/signup and leaves the stored JWT in place.
login writes the VeraeTime token to the auth properties file and
does not return it. A stored username and password refresh that
token when expires_at is missing or within five minutes.
create_user still requires an admin session.
2026-09-23 11:15:11 -04:00

59 lines
1.4 KiB
Markdown

# Operator guide
## Install
```sh
cd /Users/marchon/research/modelcontextprotocol/verae-mcp-timestamping-server
uv sync --group dev
```
## Run stdio
```sh
uv run verae-mcp-timestamping-server
```
## Run Streamable HTTP
```sh
VERAE_MCP_TRANSPORT=streamable-http uv run verae-mcp-timestamping-server
```
The listener is `http://127.0.0.1:8000/mcp`.
For the sample page on another origin:
```sh
VERAE_MCP_CORS=1 VERAE_MCP_TRANSPORT=streamable-http uv run verae-mcp-timestamping-server
```
A page served from the public internet still cannot call `127.0.0.1` from current browsers. Open `site/index.html` on the same machine, or put TLS and an access control in front of a non-loopback bind you choose yourself.
## Global token
`signup` creates a role `user` account with no bearer token. Call `login` with that username and password to store the JWT in `~/.verae/auth.properties` (mode 600). The server uses it for `scope=global` without a restart. `session` checks that JWT. `create_user` adds an account when the stored role is `admin`.
```sh
# or skip the tool and export a token yourself:
export VERAE_GLOBAL_TOKEN=...
```
## Tests
```sh
uv run pytest
```
Stamp traces (live VeraeTime) are a separate script. They write `debug-trace/<YYYY-MM-DDTHHMMSSZ>-<slug>/`:
```sh
uv run python scripts/transaction_log_test.py
```
## Build these documents
```sh
bash scripts/build-docs.sh
```
HTML lands in `docs/html/`. PDF lands in `docs/pdf/`.