We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/j-shelfwood/obsidian-local-rest-api-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server
name: Sync API Spec
on:
repository_dispatch:
types: [api_spec_updated]
schedule:
- cron: '*/5 * * * *'
workflow_dispatch:
jobs:
sync:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Checkout
uses: actions/checkout@v4
with:
persist-credentials: true
- name: Set up Node (Bun)
uses: oven-sh/setup-bun@v1
with:
bun-version: '1.2.17'
- name: Fetch OpenAPI spec from source repo
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
repo=${{ github.event.client_payload.spec_repo || 'j-shelfwood/obsidian-local-rest-api' }}
path=${{ github.event.client_payload.spec_path || 'openapi.json' }}
curl -sSL \
-H "Accept: application/vnd.github.raw+json" \
https://api.github.com/repos/${repo}/contents/${path} > openapi.json
jq . openapi.json > /dev/null
- name: Update working tree with new spec
run: |
mkdir -p src
mv openapi.json src/openapi.json
- name: Install deps
run: bun install --frozen-lockfile || bun install
- name: Build
run: bun run build
- name: Test
run: bun test
- name: Commit and push to main
env:
GIT_AUTHOR_NAME: github-actions[bot]
GIT_AUTHOR_EMAIL: 41898282+github-actions[bot]@users.noreply.github.com
GIT_COMMITTER_NAME: github-actions[bot]
GIT_COMMITTER_EMAIL: 41898282+github-actions[bot]@users.noreply.github.com
run: |
if git diff --quiet --exit-code src/openapi.json; then
echo "No changes to spec; skipping commit."
exit 0
fi
git add src/openapi.json
git commit -m "chore: sync API spec (scheduled or dispatch)"
git push origin HEAD:main