Shodai Agreements
This server manages the full lifecycle of on-chain agreements — from authoring and validation through deployment, input submission, and history inspection.
Read & Query
List agreements: Browse summaries with pagination, filtering by chain ID, lifecycle state, date ranges, and sorting.
Get agreement: Retrieve a full record including authored JSON, participants, observers, owner, and deployment address.
Get agreement document: Fetch the rendered prose document (content type, display name, chain, docUri, record references).
Get agreement state: Check the current lifecycle state of a deployed agreement; useful for polling after input submission.
Get input history: Inspect past inputs with filtering by status (
PENDING,MINED,FAILED) or input ID, with pagination.
Validation & Preflight
Validate agreement structure: Check authored agreement JSON for structural correctness — returns participant variable keys, input IDs, state IDs, and warnings without touching deployment.
Preflight deployment: Verify the agreement JSON, target chain, deployment values, participant wallet mappings, and observer context are ready before signing anything.
Signing Preparation
Prepare deployment typed data: Build the exact EIP-712 payload to authorize deployment; sign externally, then call deploy.
Prepare input typed data: Build the exact EIP-712 payload to authorize submitting an input; sign externally, then call submit.
Write & Execution
Deploy agreement: Deploy an authored agreement on-chain using a pre-signed EIP-712 permit.
Submit input: Submit a signed input to a deployed agreement to advance its on-chain lifecycle state.
Shodai Agreements SDK + MCP
Shodai turns agreement definitions into machine-readable, verifiable coordination workflows for humans, products, and AI agents. Agreements carry readable terms plus participants, valid inputs, states, transitions, and history.
This repository supports builders using the TypeScript SDK, agents or tools using MCP, and the canonical Shodai Reference App built on top of the SDK.
Start Here
Need | Start |
Understand Shodai | |
Get access | |
Build | Choose SDK vs MCP · MCP quickstart · TypeScript SDK quickstart · End-to-end workflow |
Hosted MCP: https://shodai.network/mcp is the Shodai Agreements execution MCP endpoint. OAuth-capable clients connect through browser sign-in and consent for testnet access. The endpoint uses Streamable HTTP, requires an environment tool argument, supports environment-scoped API keys as a fallback, and has no hosted private-key custody.
Packages and apps: @shodai-network/agreements-api-client · @shodai-network/agreements-mcp-server · agreements-api-playground · shodai-reference-app · oauth-connect-cli (shodai-oauth)
Related MCP server: dpay-mcp
Why Builders Use Shodai Agreements
Shared agreement state that humans, applications, and agents can inspect.
Deterministic next actions from authored states, inputs, issuers, and transitions.
Validation and deployment preflight before signatures.
EIP-712 signed authorization for deployment and participant inputs.
State and input history for receipts and monitoring.
Less repeated contract orchestration, indexing, and participant workflow plumbing.
Choose Your Path
Path | Use it when | First success |
MCP / agent tools | An agent or MCP-capable client will work with agreements through hosted Streamable HTTP or local stdio. | Authenticate, read or list where permitted, validate an example, preflight deployment, and prepare deploy typed data. |
TypeScript SDK | You are building a TypeScript application or service. | Authenticate, read or list agreements, validate an example, preflight deployment, and prove local EIP-712 signing readiness. |
Both paths converge on the same agreement lifecycle. After one quickstart works, run the end-to-end workflow.
Hosted MCP Endpoint
Configure Shodai as a remote Streamable HTTP MCP server:
URL:
https://shodai.network/mcp
Required API-calling tool argument:
environment: "testnet"Start the connection in an OAuth-capable client, then complete Shodai browser sign-in and consent. The hosted endpoint advertises the testnet authorization server, so use environment: "testnet" for this OAuth connection.
Clients without OAuth support can send Authorization: Bearer cns_pk_.... API keys only work in the environment where they were created; a production key can use environment: "production". Hosted MCP never receives private keys; write tools use externally signed EIP-712 permits or typed-data preparation.
An ordinary browser GET to /mcp may return 405 because the endpoint expects MCP protocol requests. MCP surfaces on docs.shodai.network are for docs and search only; https://shodai.network/mcp is the Agreements execution endpoint.
MCP quickstart: docs.shodai.network/sdks/quickstart-with-mcp
MCP package docs:
packages/agreements-mcp-server/README.mdExecution server card: shodai.network/.well-known/mcp/server-card.json
MCP catalog: shodai.network/.well-known/mcp/catalog.json
What This Repository Contains
Package or app | Location | Purpose |
| Typed REST client for the Agreements API with | |
| Local MCP server package aligned with the hosted Agreements execution MCP surface. | |
| Reference Vite app for browser API experimentation and SDK workflow examples. | |
| Full-stack React/Nest/Mongo reference implementation for developer platform auth, Agreements API usage, agreement lifecycle UX, signing, persistence, and webhook reconciliation. | |
| CLI that connects a public OAuth app to a user via authorization_code + PKCE, stores a refreshable session, and calls the Agreements API as that user. |
Install the TypeScript SDK
Most TypeScript consumers should install the published npm package rather than this monorepo:
npm install @shodai-network/agreements-api-clientAdd viem if you want the built-in permit-signing helpers for deploy and input submission:
npm install @shodai-network/agreements-api-client viemCreate a client with a named Shodai environment:
const client = new ApiClient({
environment: 'testnet',
apiKey: process.env.AGREEMENTS_API_KEY,
});SDK usage and API lifecycle docs live in packages/agreements-api-client/README.md. For constructor options, methods, signing helpers, diagnostics, and exports, see the TypeScript client reference.
Run MCP Locally
Use the published MCP package for local stdio clients:
{
"mcpServers": {
"shodai-agreements": {
"command": "npx",
"args": ["-y", "@shodai-network/agreements-mcp-server"],
"env": {
"AGREEMENTS_API_KEY": "YOUR_API_KEY",
"AGREEMENTS_API_ENVIRONMENT": "testnet"
}
}
}
}Local stdio mode uses AGREEMENTS_API_ENVIRONMENT; hosted MCP uses the environment tool argument. See packages/agreements-mcp-server/README.md for self-hosting, environment variables, tools, resources, prompts, and Inspector usage.
Agreement Lifecycle
Phase | TypeScript SDK | MCP |
Author agreement JSON | Use complete agreement JSON artifacts and examples. | Read example resources or use the authoring prompt. |
Validate structure |
|
|
Preflight deployment |
|
|
Prepare or sign deployment permit | SDK signing helpers with |
|
Deploy |
|
|
Read state |
|
|
Prepare or sign input permit | SDK input-signing helpers |
|
Submit input |
|
|
Inspect history |
|
|
For a guided run through validation, deployment, signed input submission, state reads, and input history, use the end-to-end workflow.
Agreements API Environments
The SDK prefers a named environment instead of a raw host:
const client = new ApiClient({
environment: 'testnet',
apiKey: process.env.AGREEMENTS_API_KEY,
});Built-in mappings:
testnet->https://test-api.shodai.networkproduction->https://api.shodai.network
API keys are environment-scoped. Use a testnet key with testnet and a production key with production.
The client still supports baseUrl as an advanced override for local proxies, internal gateways, or non-standard deployments. It continues to add /v0/* automatically.
Local Development
# from the repository root
pnpm install
pnpm build
pnpm devThe default dev command starts the Shodai Reference App. Its backend defaults to http://localhost:4199 and its frontend defaults to http://localhost:5184/agreements/.
Stop the reference app dev stack with:
pnpm dev:stopSee apps/shodai-reference-app/README.md for the required local environment files.
Run the API playground explicitly with:
pnpm dev:playgroundThe playground defaults to http://localhost:5176. If that port is already in use, start the playground on another port:
pnpm --filter agreements-api-playground exec vite --host 127.0.0.1 --port 4176For local browser development, the playground is environment-first and defaults to testnet. Use the in-app environment selector to switch between hosted testnet and production API targets.
Optional package-specific validation commands:
pnpm --filter @shodai-network/agreements-api-client run lint
pnpm --filter @shodai-network/agreements-mcp-server testSee apps/agreements-api-playground/README.md for the full environment configuration.
Boundaries
Hosted MCP does not hold private keys. Hosted MCP browser OAuth and direct API delegated OAuth are supported connection paths; x402 payments are not a current setup path. Shodai agreements do not claim legal finality or fully autonomous enforcement. Shodai does not move value without authorized signed inputs.
Open Source Project Notes
API client consumer docs:
packages/agreements-api-client/README.mdAPI client maintainer notes:
packages/agreements-api-client/DEVELOPMENT.mdMCP server docs:
packages/agreements-mcp-server/README.mdPlayground docs:
apps/agreements-api-playground/README.mdRoot license: Apache-2.0
MCP package license: MIT
Available Tools
11 toolsdeploy_agreementDeploy agreementADestructiveInspect
Deploys authored agreement JSON using an EIP-712 permit; the API submits the on-chain transaction and returns the deployed agreement record. Provide a pre-signed permit (signer, deadline, signature), or call prepare_deployment_typed_data first to obtain the payload to sign. Always run preflight_deployment before deploying. Requires the agreements.write scope.
| Name | Required | Description | Default |
|---|---|---|---|
| docUri | No | Optional document URI recorded on-chain with the agreement. | |
| signer | No | Wallet address (0x...) that signed the permit. | |
| chainId | No | Target EVM chain ID (e.g. 59141 for Linea Sepolia). | |
| deadline | No | Permit deadline in unix seconds. Must match the signed payload. | |
| agreement | Yes | Complete authored agreement JSON document with metadata, variables, content, and execution sections. | |
| observers | No | Observer email addresses. | |
| documentId | No | Optional hosted document ID paired with docUri for GET /v0/agreements/documents/{documentId}. | |
| initValues | No | Deployment-time values for variables referenced by execution.initialize.data. | |
| signatureR | No | Permit signature r component (0x... 32 bytes). | |
| signatureS | No | Permit signature s component (0x... 32 bytes). | |
| signatureV | No | Permit signature v component (27 or 28). | |
| displayName | Yes | Human-readable name for the deployed agreement record. | |
| participants | No | Wallet mappings for participant variables. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already indicate destructive and non-readOnly behavior. The description adds value by explaining the permit flow, the need for preflight, and that the API submits an on-chain transaction and returns a record. This context enriches understanding beyond annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three sentences, each earning its place: the first explains the core action, the second outlines the permit workflow, and the third gives a prerequisite and scope. No fluff, front-loaded with the most critical information.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given 13 parameters, nested objects, and no output schema, the description adequately explains what the tool does, what it returns, and the essential workflow steps. It covers prerequisites (preflight) and auth scope, making it complete for its complexity.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% with detailed descriptions, so baseline is 3. The narrative description adds high-level context about permit components (signer, deadline, signatures) and references prepare_deployment_typed_data, but does not significantly elaborate beyond the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the verb 'deploys', the resource 'authored agreement JSON', the mechanism 'EIP-712 permit', and the outcome 'returns the deployed agreement record'. It also distinguishes from sibling tools by mentioning alternatives like prepare_deployment_typed_data.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description explicitly states to 'Always run preflight_deployment before deploying' and 'Requires the agreements.write scope'. It also provides context on when to use prepare_deployment_typed_data first. It lacks explicit 'when not to use', but the guidance is clear and actionable.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_agreementGet agreementARead-onlyIdempotentInspect
Returns a single agreement record, including the full authored agreement JSON and hosted record context (participants, observers, owner, deployment address).
| Name | Required | Description | Default |
|---|---|---|---|
| agreementId | Yes | Agreement record ID, as returned by list_agreements (not the on-chain address). |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already indicate read-only, idempotent, non-destructive behavior. The description adds the specific return contents (authored JSON, hosted record context), which is useful but does not contradict annotations. It adds moderate value beyond structured fields.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single sentence with no extraneous words, front-loading the key information about what the tool returns.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple retrieval tool with one parameter, good annotations, and no output schema, the description adequately covers what is returned and the context needed. Sibling tools are addressed by implication.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% with a clear parameter description. The tool description does not add additional meaning beyond the schema, so baseline 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb 'Returns' and identifies the resource as 'a single agreement record' with key contents listed. It clearly distinguishes from siblings like get_agreement_document or get_agreement_state by specifying the full record.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies use when a single agreement record is needed by ID, but does not explicitly state when not to use it or mention alternatives. It provides clear context without exclusions.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_agreement_documentGet agreement documentARead-onlyIdempotentInspect
Returns the rendered hosted prose document for an agreement by documentId, including content type, display name, chain, docUri, and agreement record references. Use documentId from list_agreements/get_agreement or from prepare_deployment_typed_data.
| Name | Required | Description | Default |
|---|---|---|---|
| documentId | Yes | Hosted agreement document ID, as returned by list_agreements/get_agreement or prepare_deployment_typed_data. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
The description adds behavioral context beyond the annotations by listing the returned fields (content type, display name, chain, etc.). Annotations already declare readOnlyHint, idempotentHint, and no destructiveness, so the description complements them well without contradiction.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two concise sentences cover purpose and usage guidance with zero fluff. All information is front-loaded and necessary.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a single-parameter tool with no output schema, the description adequately explains what is returned (list of fields). It could be more complete with response structure details, but the listed fields provide sufficient understanding.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema description for documentId already states the same sourcing guidance as the tool description. With 100% schema coverage, the description does not add significant new meaning beyond what the parameter description provides.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action ('Returns the rendered hosted prose document') and resource ('agreement by documentId'). It lists the specific content fields included, distinguishing it from sibling tools like get_agreement (which likely returns metadata) and list_agreements.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description explicitly tells the agent where to obtain the documentId ('Use documentId from list_agreements/get_agreement or from prepare_deployment_typed_data'), providing clear sourcing guidance. While it doesn't state when not to use it, the context is sufficient for this read-only lookup.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_agreement_stateGet agreement stateARead-onlyIdempotentInspect
Returns the current state of an agreement. For deployed agreements, interpret the state against the states defined in the authored agreement lifecycle (execution.states). Use this to poll for transitions after submitting an input.
| Name | Required | Description | Default |
|---|---|---|---|
| agreementId | Yes | Agreement record ID, as returned by list_agreements (not the on-chain address). |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint, idempotentHint, and destructiveHint. Description adds valuable context about interpreting state relative to the lifecycle, which goes beyond annotation signals.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences, front-loaded with purpose, no unnecessary words. Every sentence adds value.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
No output schema is provided, which might be a gap, but the description sufficiently explains the return value's semantics and usage pattern. For a simple state-retrieval tool, it is mostly complete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% with a well-described single parameter. The tool description does not add additional parameter meaning beyond the schema, so baseline score of 3 applies.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Clearly states verb ('Returns') and resource ('state of an agreement'), distinguishes from siblings like get_agreement by focusing on state and adding context about lifecycle interpretation.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly advises polling scenario ('Use this to poll for transitions after submitting an input'), providing clear context. Does not mention when not to use or list alternatives, but guidance is specific and helpful.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_input_historyGet input historyARead-onlyIdempotentInspect
Returns recorded input submissions for an agreement, with pagination and filtering. Use this to inspect which events have been submitted and whether each is PENDING, MINED, or FAILED.
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Page size (max 100). | |
| cursor | No | Opaque pagination cursor from a previous response (pageInfo.nextCursor). | |
| status | No | Filter by submission status. | |
| inputId | No | Filter by input ID as defined in the agreement JSON (execution.inputs). | |
| agreementId | Yes | Agreement record ID, as returned by list_agreements (not the on-chain address). |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Adds context about returned statuses (PENDING, MINED, FAILED) beyond the annotations, which already declare readOnlyHint and idempotentHint. No contradictions.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two concise sentences: first states functionality, second states use case. No unnecessary words.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Lacks output schema and does not describe the response structure (e.g., pagination format). Adequate for basic usage but could be more complete given 5 parameters and no output schema.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema has 100% coverage with descriptions, but the tool description adds value by summarizing that pagination and filtering by status are available, reinforcing the parameters' purposes.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states it returns recorded input submissions with pagination and filtering, distinguishing it from sibling tools like submit_input and get_agreement_state.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly says to inspect events and their statuses, but does not mention when not to use it or provide alternative tool names for different use cases.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_agreementsList agreementsARead-onlyIdempotentInspect
Lists agreement summaries visible to the current API key. Supports pagination (cursor + limit), filtering by chain and state, and sorting. Returns summaries only; use get_agreement for the full record.
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Page size (max 100). | |
| state | No | Filter by current lifecycle state ID. | |
| cursor | No | Opaque pagination cursor from a previous response (pageInfo.nextCursor). | |
| sortBy | No | Sort field (single field only). | |
| chainId | No | Filter by EVM chain ID (e.g. 59141 for Linea Sepolia). | |
| createdAfter | No | ISO 8601 timestamp; only agreements created at or after this time. | |
| updatedAfter | No | ISO 8601 timestamp; only agreements updated at or after this time. | |
| createdBefore | No | ISO 8601 timestamp; only agreements created at or before this time. | |
| sortDirection | No | Sort direction; defaults to desc. | |
| updatedBefore | No | ISO 8601 timestamp; only agreements updated at or before this time. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true and idempotentHint=true, so safety profile is known. Description adds that results are paginated, filterable, and sortable, and that only summaries are returned. No contradictions.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences, no wasted words. Front-loaded with the primary action and immediately clarifies what the tool returns. Every sentence adds essential information.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
With 10 parameters and no output schema, the description covers the main capabilities (pagination, filtering, sorting, scope). Could be improved by noting that results are paginated via cursor, but it already mentions cursor and limit. Pointing to get_agreement for full details is helpful. Good overall.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so baseline is 3. Description adds value by grouping parameters into pagination, filtering, and sorting, and by mentioning that cursor and limit are for pagination, chain and state for filtering. This helps the agent understand how to combine parameters.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States 'Lists agreement summaries visible to the current API key' with a specific verb and resource. Explicitly distinguishes from sibling 'get_agreement' by noting that this returns summaries only, while the sibling returns the full record.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Clearly indicates when to use (for listing summaries) and explicitly references 'get_agreement' for full records. Does not provide explicit 'when not to use' scenarios but the context is clear enough.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
preflight_deploymentPreflight deployment requestARead-onlyIdempotentInspect
Checks whether authored agreement JSON plus target chain, deployment values, participant wallet mappings, and observer context are ready for deployment. This does not deploy the agreement and does not require a signature. Always run this before signing a deploy permit. Requires the agreements.write scope.
| Name | Required | Description | Default |
|---|---|---|---|
| chainId | No | Target EVM chain ID for deployment. | |
| agreement | Yes | Complete authored agreement JSON document with metadata, variables, content, and execution sections. See the simple/complex example resources for the authoritative shape. | |
| observers | No | Observer email addresses for the deployed agreement. | |
| initValues | No | Deployment-time values for variables referenced by execution.initialize.data. | |
| participants | No | Wallet mappings for participant variables. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true, destructiveHint=false, idempotentHint=true, and openWorldHint=true. The description confirms the read-only nature ('does not deploy, does not require signature') and adds the required scope ('agreements.write'), but does not provide additional behavioral details beyond what annotations already communicate.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three concise sentences: first states purpose and inputs, second clarifies non-deployment and non-signing, third gives usage guideline and scope. Every sentence adds value, no redundant text, and key information is front-loaded.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The tool has 5 parameters, nested objects, no output schema, and moderate complexity. The description lacks any mention of what the tool returns (e.g., validation result, boolean, error messages), leaving an agent uncertain about the response format. This is a significant gap.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, with each parameter having a description. The description summarizes the five parameter groups ('agreement JSON plus target chain, deployment values, participant wallet mappings, and observer context'), but does not add new semantic meaning beyond what the schema provides. Baseline of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool checks readiness for deployment, explicitly clarifies it does not deploy or require a signature, and distinguishes itself from the sibling deploy_agreement. The verb 'checks' plus resource 'agreement plus inputs' is specific.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides explicit when-to-use guidance: 'Always run this before signing a deploy permit.' It also contrasts with deploy_agreement by stating it does not deploy. However, it does not mention when not to use it or how it differs from validate_agreement, a potential sibling alternative.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
prepare_deployment_typed_dataPrepare deployment permit typed dataARead-onlyIdempotentInspect
Builds the exact EIP-712 payload that must be signed to authorize deployment of the given agreement JSON. Sign the returned typedData with the deploying wallet (eth_signTypedData_v4 / viem signTypedData), then call deploy_agreement with signer, deadline, and the signature components. No transaction is sent and nothing is stored. Reads the signer nonce from the target chain.
| Name | Required | Description | Default |
|---|---|---|---|
| docUri | No | Document URI (must match the later deploy_agreement call). | |
| chainId | Yes | Target EVM chain ID (e.g. 59141 for Linea Sepolia). | |
| deadline | No | Permit deadline in unix seconds; defaults to one hour from now. | |
| agreement | Yes | Complete authored agreement JSON document with metadata, variables, content, and execution sections. | |
| observers | No | Observer email addresses. | |
| documentId | No | Hosted document ID. If omitted with docUri, no hosted document ID is stored; if both are omitted, the server generates both values. | |
| initValues | No | Deployment-time init values (must match the later deploy_agreement call). | |
| participants | No | Wallet mappings for participant variables. | |
| signerAddress | Yes | Wallet address (0x...) that will sign and own the deployment. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
The description clearly states that 'no transaction is sent and nothing is stored,' which aligns with the annotations (readOnlyHint, idempotentHint). It also reveals that it 'reads the signer nonce from the target chain,' providing additional behavioral context beyond the annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is extremely concise with three sentences that convey purpose, usage instructions, and side-effect absence. Every sentence is informative and necessary, with no wasted words.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given that there is no output schema, the description implicitly explains the return value by saying 'Sign the returned typedData.' It also covers critical details like reading the nonce. However, it could be slightly more explicit about the structure of the returned typedData object. Despite this, it is sufficiently complete for a data preparation tool with good annotations.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema has 100% description coverage, so the schema already explains each parameter. The description adds value by tying parameters to the workflow (e.g., mentioning that 'deadline defaults to one hour from now' and that 'agreement' is the JSON to be deployed). However, the description does not introduce new parameter semantics beyond the schema, but it provides context that aids in understanding parameter relationships.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool 'builds the exact EIP-712 payload' for deployment authorization, using a specific verb and resource. It distinguishes itself from sibling tools like prepare_input_typed_data by focusing on deployment, and it explains the exact workflow (signing then calling deploy_agreement).
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description explicitly states when to use this tool (to prepare the payload for signing before calling deploy_agreement) and provides step-by-step instructions for the next actions (signing and calling deploy_agreement with specific components). It also implies not to use this tool if you want to directly deploy without preparing typed data.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
prepare_input_typed_dataPrepare input permit typed dataARead-onlyIdempotentInspect
Builds the exact EIP-712 payload that must be signed to authorize submitting an input to a deployed agreement. Sign the returned typedData with a wallet allowed by the input definition, then call submit_input with signer, deadline, and the signature components. No transaction is sent and nothing is stored. Reads the agreement record and signer nonce.
| Name | Required | Description | Default |
|---|---|---|---|
| values | Yes | Values matching the input schema (must match the later submit_input call). | |
| inputId | Yes | Input ID defined by the agreement JSON (execution.inputs). | |
| deadline | No | Permit deadline in unix seconds; defaults to one hour from now. | |
| agreementId | Yes | Agreement record ID of a deployed agreement. | |
| signerAddress | Yes | Wallet address (0x...) that will sign the input permit. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint and destructiveHint. The description adds that it reads the agreement record and signer nonce, and confirms no storage. This aligns with annotations and provides extra context. However, it omits authorization requirements (signer must be allowed by input definition), which could be useful for the agent.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is three sentences, each serving a distinct purpose: stating the primary action, explaining the next steps, and noting side effects. It is front-loaded with the key purpose and contains no redundant information.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description provides workflow context but lacks details on the return structure (typedData fields) and preconditions (e.g., agreement must be deployed, inputId must exist). Since there is no output schema, describing the return shape would improve completeness. The tool's complexity and 5 parameters warrant more guidance on prerequisites.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so baseline is 3. The description adds value beyond the schema by noting the deadline defaults to one hour from now and contextualizing inputId and values relative to the agreement. This enhances understanding of how to use the parameters.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool builds an EIP-712 payload for signing, linking it to submit_input. It distinguishes itself from siblings like submit_input (actual submission) and prepare_deployment_typed_data (deployment context) by specifying no transaction is sent. The verb 'builds' and resource 'EIP-712 payload' are specific.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description explicitly outlines the intended workflow: prepare payload, sign, then call submit_input. It clarifies that no transaction is sent and nothing is stored, guiding safe usage. However, it does not explicitly state when not to use this tool or compare with alternatives like get_agreement, though the purpose implies it's only for preparing input permits.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
submit_inputSubmit input with permitADestructiveInspect
Submits a signed input to a deployed agreement, advancing its on-chain lifecycle. The input ID and values must match an input defined by the agreement JSON, and the signer must be allowed by that input. Provide a pre-signed permit (signer, deadline, signature), or call prepare_input_typed_data first. Requires the agreements.write scope.
| Name | Required | Description | Default |
|---|---|---|---|
| signer | No | Wallet address (0x...) that signed the permit. | |
| values | Yes | Values matching the input schema defined by the agreement JSON. | |
| inputId | Yes | Input ID defined by the agreement JSON (execution.inputs). | |
| deadline | No | Permit deadline in unix seconds. Must match the signed payload. | |
| signatureR | No | Permit signature r component (0x... 32 bytes). | |
| signatureS | No | Permit signature s component (0x... 32 bytes). | |
| signatureV | No | Permit signature v component (27 or 28). | |
| agreementId | Yes | Agreement record ID of a deployed agreement. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations declare destructiveHint=true and readOnlyHint=false, and the description adds context about advancing on-chain lifecycle and requiring permissions. However, it does not detail potential side effects beyond advancing lifecycle.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two concise sentences plus a scope note, front-loaded with main action. No wasted words.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
No output schema is provided, and the description does not explain return values or error handling. Given the complexity (8 parameters, nested objects), more detail on post-submission behavior would be beneficial.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema covers 100% of parameters. Description adds context by linking parameters to agreement JSON and explaining the permit structure beyond schema descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the verb 'submit' and the resource 'signed input to a deployed agreement', and mentions advancing on-chain lifecycle. It distinguishes from sibling tools like prepare_input_typed_data by indicating it as a prerequisite.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly states conditions for use (input ID and values must match agreement JSON, signer must be allowed), provides alternative action (call prepare_input_typed_data), and specifies required scope (agreements.write).
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
validate_agreementValidate agreement structureARead-onlyIdempotentInspect
Checks only the authored agreement JSON document and returns participant variable keys, input IDs, state IDs, and warnings. This does not validate deployment values, participant wallet addresses, signer, or permit data — use preflight_deployment for that. Iterate on the agreement JSON until this returns no blocking warnings. Requires the agreements.write scope.
| Name | Required | Description | Default |
|---|---|---|---|
| agreement | Yes | Complete authored agreement JSON document with metadata, variables, content, and execution sections. See the simple/complex example resources for the authoritative shape. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already indicate readOnlyHint=true, idempotentHint=true, destructiveHint=false, so the description is not burdened with basic safety. It adds behavioral context by explicitly listing what it does NOT validate and what it returns (warnings, keys, IDs), which goes beyond the annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is relatively short and front-loaded with the main action. Every sentence serves a purpose, but some small improvements could be made (e.g., merging 'This does not validate...' and 'Iterate on...' more tightly). Overall efficient.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool has one parameter, no output schema, rich annotations, and many siblings, the description covers its purpose, scope, return values, usage flow, and alternatives comprehensively. It is sufficient for correct invocation.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% with a single parameter (agreement) already described in schema. The description adds value by explaining that the parameter is the authored agreement JSON and that the tool returns specific validation results, but does not detail the parameter's structure beyond what schema provides.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool validates only the authored agreement JSON structure, distinct from deployment validation, and lists return fields (participant variable keys, input IDs, state IDs, warnings). It uses specific verb+resource and differentiates from sibling tool preflight_deployment.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description explicitly says when to use (iterate on agreement JSON until no blocking warnings) and when not to use (for deployment values, wallets, signer, permit data) with a clear alternative (preflight_deployment). It also mentions required scope (agreements.write).
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
TDQS
Each tool targets a distinct action or resource. There is no ambiguity between deploy, get, list, preflight, prepare, submit, validate operations. Even similar-sounding tools like get_agreement and get_agreement_document are clearly differentiated by their descriptions and return types.
All tool names consistently use snake_case with a verb_noun pattern. The verbs are descriptive (deploy, get, list, preflight, prepare, submit, validate) and the nouns accurately reflect the resource or context. Naming is predictable and systematic.
With 11 tools covering the full lifecycle of agreement management—from validation and preflight to deployment, state queries, and input submission—the count is well-scoped. Each tool serves a clear purpose without redundancy or bloat.
The tool set covers the core workflows: validation, deployment preparation/signing, deploying, reading agreements/documents/state, listing, submitting inputs, and inspecting history. Missing are update/amend or delete/terminate operations, but these may be outside the domain's scope given the immutable nature of deployed agreements.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
MCP server for Boson Protocol — on-chain agentic commerce for physical & digital goods.
Hosted MCP server for AI-driven data ops. Create apps, manage schemas, and CRUD structured data.
Hosted MCP server for live Bittensor chain reads and self-custodial on-chain writes.
MCP server for Modern Treasury — payment orders, transactions, counterparties and ledgers.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceMCP server for temporal state queries and cryptographic audit trails. Query historical entity state at any point in time, generate Merkle proofs of past state, and anchor contract snapshots for immutable provenance.MIT
- AlicenseAqualityBmaintenanceAn MCP server for creating, settling, disputing, and refunding escrows on EVM chains.814Apache 2.0
- AlicenseNot gradedqualityCmaintenanceProvides a sovereign, MIT-licensed MCP server for professional-service workflows, running entirely on your infrastructure with Ed25519 cryptographic signing for every action.MIT
- AlicenseNot gradedqualityAmaintenanceAn MCP server that exposes nine local-first contract-ops CLIs as tools for contract extraction, linting, comparison, conversion, template vaults, and signed-contract vaults, with signing operations strictly human-gated.160MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/CNSLabs/agreements-api-sdk'
If you have feedback or need assistance with the MCP directory API, please join our Discord server