Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
53 changes: 53 additions & 0 deletions .github/workflows/deploy-mcp.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: Deploy MCP Worker

on:
push:
branches:
- main
paths:
- "worker/src/mcp.ts"
- "worker/src/env.ts"
- "worker/mcp-entry.ts"
- "worker/wrangler-mcp.toml"
- "worker/package.json"
- "worker/package-lock.json"
workflow_dispatch:

permissions:
contents: read

concurrency:
group: deploy-mcp-production
cancel-in-progress: false

jobs:
deploy:
name: Deploy PS-Wiki MCP Worker
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 22
cache: npm
cache-dependency-path: worker/package-lock.json

- name: Install and verify
working-directory: worker
run: |
npm ci
npm run check
npx wrangler deploy --config wrangler-mcp.toml --dry-run

- name: Deploy
uses: cloudflare/wrangler-action@v4
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
command: deploy --config wrangler-mcp.toml
workingDirectory: worker
wranglerVersion: "4"
17 changes: 16 additions & 1 deletion .github/workflows/deploy-worker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ on:
branches:
- main
paths:
- "worker/src/**"
- "worker/src/index.ts"
- "worker/src/env.ts"
- "worker/wrangler.toml"
- "worker/package.json"
- "worker/package-lock.json"
Expand All @@ -27,6 +28,20 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 22
cache: npm
cache-dependency-path: worker/package-lock.json

- name: Install and verify
working-directory: worker
run: |
npm ci
npm run check
npx wrangler deploy --dry-run

- name: Deploy
uses: cloudflare/wrangler-action@v4
with:
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ Built with [MkDocs Material](https://squidfunk.github.io/mkdocs-material/), the
## REST API

The PS-Wiki REST API provides read-only access to term data in JSON format.
It is deployed via [Cloudflare Workers](./worker) and documented using the OpenAPI 3.1.0 specification at <https://api.ning.guru/openapi.json>
It is deployed via [Cloudflare Workers](./worker) and documented using the OpenAPI 3.1.0 specification at <https://api.ps-wiki.ning.guru/openapi.json>

### Developer Notes

Expand Down
2 changes: 1 addition & 1 deletion database/openapi/pswiki.v1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ info:
name: CC BY-NC 4.0
url: https://creativecommons.org/licenses/by-nc/4.0/
servers:
- url: https://api.ning.guru
- url: https://api.ps-wiki.ning.guru
description: Production server
- url: http://localhost:8787
description: Local development server
Expand Down
4 changes: 2 additions & 2 deletions database/pyscripts/test_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -381,8 +381,8 @@ def main(argv=None) -> int:
parser = argparse.ArgumentParser(description="PS-Wiki API Contract Test Suite")
parser.add_argument(
"--base-url",
default="https://api.ning.guru",
help="Base URL (default: https://api.ning.guru). Examples: http://localhost:8787 or https://api.ning.guru",
default="https://api.ps-wiki.ning.guru",
help="Base URL (default: https://api.ps-wiki.ning.guru). Examples: http://localhost:8787 or https://api.ps-wiki.ning.guru",
)
parser.add_argument("--query", help="Optional free-text query for /v1/terms")
parser.add_argument("--tag", help="Optional tag filter for /v1/terms")
Expand Down
4 changes: 4 additions & 0 deletions docs/changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ This page records major changes in this wiki.

## 2026

### 09-14

- Added the public, read-only remote MCP service at `https://mcp.ps-wiki.ning.guru/mcp`, backed by the REST API at `https://api.ps-wiki.ning.guru`; documented local stdio and remote MCP usage, deployment, verification, and attribution

### 09-13

- Prepared the REST API contract for the upcoming `1.1.0` release while retaining the `/v1` routes; added canonical term URLs and structured PS-Wiki attribution and license metadata to API responses
Expand Down
Loading
Loading