Servidor MCP

dpyc-oracle

io.github.lonniev/dpyc-oracle
Infraestructura MCP y de agentes Público y accesible MCP 2025-11-25

Qué hace este MCP

Acts as a community registry and onboarding concierge for DPYC members, authorities, operators, services, governance, relays, campaigns, and network status.

about
Extended narration about DPYC, the Social Contract, and the Oracle. Fetches README.md and GOVERNANCE.md from the dpyc-community repo and assembles a comprehensive context answer.
Esquema de entrada
{'type': 'object', 'properties': {}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'required': ['result'], 'properties': {'result': {'type': 'string'}}, 'x-fastmcp-wrap-result': True}
cast_ban_vote
Cast a Lightning-funded vote in an active ban election. Not yet implemented — will verify npub membership, validate the election is active, and record the vote with a Lightning payment proof.
Esquema de entrada
{'type': 'object', 'required': ['election_id', 'vote', 'npub'], 'properties': {'npub': {'type': 'string'}, 'vote': {'type': 'string'}, 'election_id': {'type': 'string'}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
check_ban_status
Check whether an npub is banned from the DPYC Social Contract. Looks up the member in the community registry and checks whether their status is "banned". Unknown npubs are not considered banned (they simply aren't members). Free, unauthenticated. Used by operators during the cold path (credit purchases) to enforce community bans.
Esquema de entrada
{'type': 'object', 'required': ['npub'], 'properties': {'npub': {'type': 'string'}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
confirm_citizenship
Complete the citizen registration by submitting a signed Nostr event. This is part of the **citizen** registration flow (Operator-owned). The Operator calls this on behalf of a patron after the patron has signed the cryptographic challenge from request_citizenship. Verifies: 1. The challenge exists and hasn't expired 2. The Schnorr signature is valid 3. The event's pubkey matches the claimed npub 4. The event content contains the issued nonce 5. The npub is not already registered On success, commits directly to dpyc-community/members/citizens/{npub}.json to register the new Citizen immediately.
Esquema de entrada
{'type': 'object', 'required': ['npub', 'challenge_id', 'signed_event_json'], 'properties': {'npub': {'type': 'string'}, 'challenge_id': {'type': 'string'}, 'signed_event_json': {'type': 'string'}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
deregister_operator
Remove an Operator from the DPYC community registry. Called when an Authority disowns an Operator. An Operator cannot exist without a sponsoring Authority, so deregistration removes the member file entirely, returning the Operator to initial state.
Esquema de entrada
{'type': 'object', 'required': ['operator_npub', 'authority_npub'], 'properties': {'operator_npub': {'type': 'string', 'description': 'Nostr npub of the Operator to remove.'}, 'authority_npub': {'type': 'string', 'description': 'npub of the Authority requesting deregistration\n(must be a registered authority or prime_authority).'}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
economic_model
Explain the DPYC Social Contract economic model — qualitatively. Describes how value flows through the network: ad valorem certification fees, the cascade up the Certification Chain to the First Curator, and where the live numbers actually live. The Oracle quotes **no** rates, counts, or revenue figures — those belong to the Authorities' pricing models and the live registry, not to a docent. Free, unauthenticated.
Esquema de entrada
{'type': 'object', 'properties': {}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
get_campaign
Retrieve a published pricing campaign.
Esquema de entrada
{'type': 'object', 'required': ['author_npub', 'operator_npub', 'slug'], 'properties': {'slug': {'type': 'string', 'description': 'The campaign slug (directory name).'}, 'format': {'type': 'string', 'default': 'json', 'description': '"json" for importable data, "markdown" for readable summary.'}, 'author_npub': {'type': 'string', 'description': "The campaign author's npub."}, 'operator_npub': {'type': 'string', 'description': "The target operator's npub."}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
get_relays
Return the DPYC Nostr relay set, best first. The single source of truth is ``dpyc-community/relays.json``. An Operator seeds its relay set from here at cold start (its only fixed dependency is this Oracle endpoint), then reads its own bootstrap config from Nostr using just its nsec — no direct GitHub access. That file is a curated *guess*: it says which relays are worth using, not which are up this minute. Relays that an operator reported and the Oracle then proved unreachable are moved to the back of the list; everything else keeps its declared order, and nothing is ever dropped. This call never probes anything — it is on every operator's cold-start path, so it stays a lookup. Ranking improves only when someone hits a dead relay and says so via ``report_relay_failure``. Report failures only; successes need no announcement. Free.
Esquema de entrada
{'type': 'object', 'properties': {}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
get_rulebook
Fetch the DPYC Social Contract governance document. Returns the raw markdown of GOVERNANCE.md from the dpyc-community repo.
Esquema de entrada
{'type': 'object', 'properties': {}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'required': ['result'], 'properties': {'result': {'type': 'string'}}, 'x-fastmcp-wrap-result': True}
get_tax_rate
Explain how Tollbooth certification taxation works. Taxation is ad valorem and **per-Authority** — there is no single network-wide number, and the Oracle deliberately quotes none. The actual fee is the Authority's own accounting, set in its pricing model and reported at transaction time. This tool is a docent: it explains the model and points to the live source. For the exact figure, query the relevant Authority's ``check_price`` for ``certify_credits``.
Esquema de entrada
{'type': 'object', 'properties': {}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
how_to_add_authority
End-to-end guide for spinning up a new Tollbooth Authority. Returns the eight-step procedure covering identity, region selection, GitHub workspace, dpyc-community registry entry, Neon + BTCPay + Horizon deployment, BTCPay credential delivery via Secure Courier, the self-registration challenge-response with the parent Authority, and pre-funding the cert-fee balance. Fetched live from docs/how-to-add-authority.md in the dpyc-community repo.
Esquema de entrada
{'type': 'object', 'properties': {}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'required': ['result'], 'properties': {'result': {'type': 'string'}}, 'x-fastmcp-wrap-result': True}
how_to_join
Tier-specific onboarding guide for joining the DPYC Social Contract. Covers all five tiers: Citizen, Advocate, Operator, Authority, and First Curator. Includes Nostr keygen instructions and practical next steps.
Esquema de entrada
{'type': 'object', 'properties': {}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'required': ['result'], 'properties': {'result': {'type': 'string'}}, 'x-fastmcp-wrap-result': True}
initiate_ban_election
Initiate a community ban election against a member. Not yet implemented — will create a GitHub Issue with a 72-hour discussion period and Lightning-funded economic voting.
Esquema de entrada
{'type': 'object', 'required': ['target_npub', 'reason'], 'properties': {'reason': {'type': 'string'}, 'target_npub': {'type': 'string'}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
list_campaigns
List published pricing campaigns from the DPYC community. Optionally filter by operator or author npub.
Esquema de entrada
{'type': 'object', 'properties': {'author_npub': {'type': 'string', 'default': '', 'description': 'Filter to campaigns by this author (optional).'}, 'operator_npub': {'type': 'string', 'default': '', 'description': 'Filter to campaigns for this operator (optional).'}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
list_services
Enumerate the live DPYC service network with self-described summaries. Reads the member roster from the dpyc-community registry, then (when ``probe=True``) performs a lightweight MCP handshake against each member's public service endpoint to fetch that service's *own* self-description and tool inventory. Nothing about the services is hardcoded here — descriptions are authored by each service, and prices come from each Operator/Authority pricing model (call the service's ``check_price``). Resilient by design: per-service timeout, partial results, brief caching, and a registry-only fallback when an endpoint is asleep or unreachable. A sleeping service never breaks the listing. Free, unauthenticated.
Esquema de entrada
{'type': 'object', 'properties': {'kind': {'type': 'string', 'default': 'all', 'description': 'Role filter â\x80\x94 "all", "operator", "authority", or "advocate".'}, 'probe': {'type': 'boolean', 'default': True, 'description': 'Handshake each endpoint for a live self-description. Set\nFalse for a fast registry-only listing (no network fan-out).'}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
lookup_member
Look up a member by their Nostr npub. Can look up any role's npub — citizen, operator, or authority. Returns the full member record if found, or a not-found message.
Esquema de entrada
{'type': 'object', 'required': ['npub'], 'properties': {'npub': {'type': 'string'}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'required': ['result'], 'properties': {'result': {'anyOf': [{'type': 'object', 'additionalProperties': True}, {'type': 'string'}]}}, 'x-fastmcp-wrap-result': True}
network_advisory
Get current network deployment advisory. Returns human-readable guidance on what changed recently, urgent upgrades, and actions operators should take. Fetched live from ADVISORY.md in the dpyc-community repo.
Esquema de entrada
{'type': 'object', 'properties': {}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'required': ['result'], 'properties': {'result': {'type': 'string'}}, 'x-fastmcp-wrap-result': True}
network_versions
Get current recommended versions of all Tollbooth components. Returns component versions, minimum compatibility, active protocols, and a short advisory summary. Data is fetched live from network-status.json in the dpyc-community repo.
Esquema de entrada
{'type': 'object', 'properties': {}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
publish_campaign
Publish a pricing campaign to the DPYC community. Commits both a machine-importable JSON file and a human-readable Markdown summary to the dpyc-community campaigns directory.
Esquema de entrada
{'type': 'object', 'required': ['author_npub', 'operator_npub', 'campaign_json'], 'properties': {'author_npub': {'type': 'string', 'description': 'The npub of the person who designed the campaign.'}, 'campaign_json': {'type': 'string', 'description': 'The full campaign export as a JSON string.'}, 'campaign_name': {'type': 'string', 'default': '', 'description': 'Optional display name. Derived from JSON if omitted.'}, 'operator_npub': {'type': 'string', 'description': 'The npub of the operator the campaign is for.'}, 'campaign_markdown': {'type': 'string', 'default': '', 'description': 'Optional pre-rendered Markdown. If omitted, the\nOracle generates a basic summary from the JSON.'}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
register_advocate
Register a new Advocate in the DPYC community registry. Advocates are community utility services that provide shared infrastructure (e.g., OAuth2 callback collectors) but aren't monetized Operators or certification Authorities. This is an Oracle-mediated registration — no Nostr DM challenge-response needed. The Oracle operator (Prime Authority) trusts the commit via GitHub token.
Esquema de entrada
{'type': 'object', 'required': ['npub', 'display_name', 'service_name', 'service_url', 'service_description'], 'properties': {'npub': {'type': 'string', 'description': 'Nostr npub of the Advocate service.'}, 'service_url': {'type': 'string', 'description': 'Public URL of the service.'}, 'display_name': {'type': 'string', 'description': 'Human-readable name for the service.'}, 'service_name': {'type': 'string', 'description': 'Machine-readable service identifier\n(e.g., "tollbooth-oauth2-collector").'}, 'service_description': {'type': 'string', 'description': 'Short description of what the service does.'}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
register_authority
Register a new Authority in the DPYC community registry. Called by an Authority service at the end of the onboarding protocol (after the candidate proves npub ownership and the Prime Authority approves). Commits a new ``members/authorities/{npub}.json`` file to dpyc-community on GitHub. The full Authority onboarding protocol is a 3-step Nostr DM challenge-response flow: 1. ``register_authority_npub(npub)`` — Authority sends DM challenge 2. ``confirm_authority_claim(npub)`` — verifies candidate DM, escalates to Prime 3. ``check_authority_approval(npub)`` — Prime approves, this tool is called
Esquema de entrada
{'type': 'object', 'required': ['authority_npub', 'display_name', 'service_url', 'upstream_authority_npub'], 'properties': {'service_url': {'type': 'string', 'description': 'Public MCP endpoint URL of the Authority service.'}, 'display_name': {'type': 'string', 'description': 'Human-readable name for the Authority.'}, 'authority_npub': {'type': 'string', 'description': 'Nostr npub of the new Authority curator.'}, 'upstream_authority_npub': {'type': 'string', 'description': 'npub of the sponsoring Authority (must\nalready exist as a prime_authority or authority in the registry).'}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
register_operator
Register a new Operator in the DPYC community registry. Called by an Authority service after the operator requests registration. The Authority validates the operator's identity and sponsors the registration by calling this tool via MCP-to-MCP.
Esquema de entrada
{'type': 'object', 'required': ['operator_npub', 'display_name', 'service_url', 'authority_npub'], 'properties': {'service_url': {'type': 'string', 'description': 'Public MCP endpoint URL of the Operator service.'}, 'display_name': {'type': 'string', 'description': 'Human-readable name for the Operator service.'}, 'operator_npub': {'type': 'string', 'description': 'Nostr npub of the new Operator.'}, 'authority_npub': {'type': 'string', 'description': 'npub of the sponsoring Authority (must already\nexist as an authority or prime_authority in the registry).'}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
renounce_membership
Citizen self-removal from the DPYC Social Contract via automated PR. Not yet implemented — will create a GitHub PR to remove the member from the registry.
Esquema de entrada
{'type': 'object', 'required': ['npub'], 'properties': {'npub': {'type': 'string'}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
report_relay_failure
Report that a relay in the DPYC set was unreachable, and re-rank it. A report does not set a relay's rank. It asks the Oracle to measure that relay *now*, and the Oracle's own probe decides. A false or mistaken report therefore costs one probe and changes nothing — no caller can demote a healthy relay by asserting that it is down. Report only failures. Successes are far too frequent to be worth carrying, and a relay that works needs no announcement.
Esquema de entrada
{'type': 'object', 'required': ['relay', 'reporter_npub', 'signed_event'], 'properties': {'mode': {'type': 'string', 'default': 'unknown', 'description': 'What was being attempted â\x80\x94 ``"send"``, ``"read"``, or\n``"unknown"``. Recorded for the human reading the logs.'}, 'relay': {'type': 'string', 'description': 'The relay that failed. Must already be in the DPYC set â\x80\x94\nthis tool re-measures the curated set, it is not a probe-anything\nprimitive that can be aimed at arbitrary hosts.'}, 'signed_event': {'type': 'string', 'description': "A Nostr event signed by ``reporter_npub`` whose content\ncontains the relay URL, created within the last few minutes.\nStateless by design: no challenge is issued first, because a\nchallenge store would not survive this service's recycles â\x80\x94 and\na relay report is most needed exactly when relays are broken."}, 'reporter_npub': {'type': 'string', 'description': "The reporting operator's npub."}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
request_citizenship
Begin the citizen registration process (Operator-owned flow). This is the **citizen** registration path. Called by the Operator on behalf of a patron — invokes the Oracle directly. No Authority npub is required or consulted. The patron's npub is registered as a Citizen in the DPYC community. The npub provided here becomes the user's **patron identity** — the keypair they will use for credit purchases and service access across all Tollbooth-monetized services. Not to be confused with **operator** registration, which goes through the Authority via a Nostr DM delegation request. Issues a cryptographic challenge that the applicant must sign with their Nostr private key (nsec) to prove they own the claimed npub. The nsec never leaves the applicant's device. Returns a challenge_id, nonce, and signing instructions. The applicant signs a Nostr event containing the nonce and submits it via confirm_citizenship within 10 minutes.
Esquema de entrada
{'type': 'object', 'required': ['npub', 'display_name'], 'properties': {'npub': {'type': 'string'}, 'display_name': {'type': 'string'}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
resolve_authority_for
Resolve the certifying Authority for an operator npub. Returns the Authority's ``{npub, url, name}`` (from the operator's ``upstream_authority_npub``). Use this after bootstrap to learn — and verify — which Authority signed your config, without reading GitHub.
Esquema de entrada
{'type': 'object', 'required': ['npub'], 'properties': {'npub': {'type': 'string'}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
resolve_service
Resolve a DPYC service by ``name`` or ``npub``. Returns ``{npub, url, name, role, purchase_mode}`` where ``purchase_mode`` is the registry-topology fact ``"certified"`` or ``"direct"`` (not a price). Supply exactly one of ``name`` or ``npub``.
Esquema de entrada
{'type': 'object', 'properties': {'name': {'type': 'string', 'default': ''}, 'npub': {'type': 'string', 'default': ''}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
service_status
Diagnostic: report this service's software versions and runtime info. Free, unauthenticated. Use to verify deployment versions across the DPYC ecosystem.
Esquema de entrada
{'type': 'object', 'properties': {}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
update_operator
Update an existing Operator's registry entry. Used when an Operator moves to a new MCP endpoint, changes its display name, or needs to correct a registration. Must be called by the sponsoring Authority (or any Authority).
Esquema de entrada
{'type': 'object', 'required': ['operator_npub'], 'properties': {'service_url': {'type': 'string', 'default': '', 'description': 'New MCP endpoint URL (leave empty to keep current).'}, 'display_name': {'type': 'string', 'default': '', 'description': 'New display name (leave empty to keep current).'}, 'operator_npub': {'type': 'string', 'description': 'Nostr npub of the Operator to update.'}, 'authority_npub': {'type': 'string', 'default': '', 'description': 'npub of the requesting Authority (must be a\nregistered authority or prime_authority).'}}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'additionalProperties': True}
who_is_first_curator
Identify the First Curator (Prime Authority) of the Certification Chain. Returns the curator's npub, display name, and member record.
Esquema de entrada
{'type': 'object', 'properties': {}, 'additionalProperties': False}
Esquema de salida
{'type': 'object', 'required': ['result'], 'properties': {'result': {'anyOf': [{'type': 'object', 'additionalProperties': True}, {'type': 'string'}]}}, 'x-fastmcp-wrap-result': True}
Añadido
get_campaign
17 de September de 2026 a las 12:43
Añadido
list_campaigns
17 de September de 2026 a las 12:43
Añadido
publish_campaign
17 de September de 2026 a las 12:43
Añadido
cast_ban_vote
17 de September de 2026 a las 12:43
Añadido
initiate_ban_election
17 de September de 2026 a las 12:43
Añadido
renounce_membership
17 de September de 2026 a las 12:43
Añadido
check_ban_status
17 de September de 2026 a las 12:43
Añadido
register_advocate
17 de September de 2026 a las 12:43
Añadido
deregister_operator
17 de September de 2026 a las 12:43
Añadido
update_operator
17 de September de 2026 a las 12:43
Añadido
register_operator
17 de September de 2026 a las 12:43
Añadido
register_authority
17 de September de 2026 a las 12:43
Añadido
confirm_citizenship
17 de September de 2026 a las 12:43
Añadido
request_citizenship
17 de September de 2026 a las 12:43
Añadido
resolve_service
17 de September de 2026 a las 12:43
Añadido
resolve_authority_for
17 de September de 2026 a las 12:43
Añadido
report_relay_failure
17 de September de 2026 a las 12:43
Añadido
get_relays
17 de September de 2026 a las 12:43
Añadido
list_services
17 de September de 2026 a las 12:43
Añadido
service_status
17 de September de 2026 a las 12:43
Añadido
how_to_add_authority
17 de September de 2026 a las 12:43
Añadido
network_advisory
17 de September de 2026 a las 12:43
Añadido
network_versions
17 de September de 2026 a las 12:43
Añadido
who_is_first_curator
17 de September de 2026 a las 12:43
Añadido
how_to_join
17 de September de 2026 a las 12:43
Añadido
get_rulebook
17 de September de 2026 a las 12:43
Añadido
economic_model
17 de September de 2026 a las 12:43
Añadido
get_tax_rate
17 de September de 2026 a las 12:43
Añadido
lookup_member
17 de September de 2026 a las 12:43
Añadido
about
17 de September de 2026 a las 12:43