Docs
MCP

For developers

The protocol, endpoints, discovery documents, client registration and error format of the Docshark MCP server.

Most people never need this page: apps find everything below on their own. It is here for people building or debugging an MCP client.

Server

Endpointhttps://dashboard.doc-shark.com/mcp
TransportStreamable HTTP. POST JSON-RPC 2.0; send Accept: application/json, text/event-stream.
Protocol2025-11-25, with 2025-06-18, 2025-03-26 and 2024-11-05 also accepted, negotiated at initialize
SessionsStateless, JSON responses. No Mcp-Session-Id; every request carries its own bearer token.
Capabilitiestools (tools/list, tools/call)
Tool annotationsEvery tool has a title and either readOnlyHint: true or destructiveHint: true
Request bodyAt most 1 MB

Discovery

A request without a valid token gets 401 with:

WWW-Authenticate: Bearer resource_metadata="https://dashboard.doc-shark.com/.well-known/oauth-protected-resource/mcp", scope="docshark"
DocumentAddress
Protected resource metadata (RFC 9728)https://dashboard.doc-shark.com/.well-known/oauth-protected-resource/mcp
Authorization server metadata (RFC 8414)https://dashboard.doc-shark.com/.well-known/oauth-authorization-server

The authorization server is Docshark itself; the issuer is https://dashboard.doc-shark.com.

Endpoints

EndpointAddress
Authorizationhttps://dashboard.doc-shark.com/oauth/authorize
Tokenhttps://dashboard.doc-shark.com/oauth/token
Registration (RFC 7591)https://dashboard.doc-shark.com/oauth/register
Revocation (RFC 7009)https://dashboard.doc-shark.com/oauth/revoke

Clients

Docshark accepts two kinds of client. Both are public clients (token_endpoint_auth_method: none) and must use PKCE.

  • Client ID metadata documents. Use an https address of your metadata document as the client_id. Docshark fetches it (at most 5 KB, 3 second timeout) and reads client_name and redirect_uris. Claude and Claude Code sign in this way.
  • Dynamic registration. POST to the registration endpoint with client_name (up to 120 characters) and redirect_uris (up to 10, each up to 2,048 characters). You get a client_id starting with dsapp_.

Redirect addresses must be https, http on a loopback address (127.0.0.1, [::1], localhost) on any port, or an app's own scheme such as cursor:// or vscode://. Schemes a browser would run (javascript:, data:, file: and the like), fragments and credentials in the address are refused.

Authorization

ParameterValue
response_typecode
code_challenge_methodS256 only
scopedocshark, optionally with offline_access. A refresh token is always issued.
resourcehttps://dashboard.doc-shark.com/mcp exactly (RFC 8707)
stateUp to 1,024 characters, returned unchanged

The answer carries code, state and iss (RFC 9207). Check iss equals the issuer.

Tokens

GrantNotes
authorization_codeCode lives 60 seconds and works once. Send the same redirect_uri and the code_verifier.
refresh_tokenRotates on every use. A spent token reused within 30 seconds gets the same answer; after that, the whole sign-in ends.

Access tokens live 3,600 seconds (expires_in). A sign-in ends 90 days after consent, whatever the refreshes. Send the access token as Authorization: Bearer … on every /mcp request.

Token errors follow RFC 6749: invalid_grant, invalid_client, invalid_request, unsupported_grant_type, and invalid_target for a wrong resource.

Errors from /mcp

StatusBodyMeaning
401{"error":"invalid_token"} with WWW-AuthenticateNo token, an expired token, or an ended connection. Refresh, or sign in again.
403{"error":"mako_off"}Mako is off for the workspace.
413{"error":"payload_too_large"}The request body is over 1 MB.
429{"error":"rate_limited"} with Retry-After: 60Over 120 calls per minute on this connection.

Tool failures are not HTTP errors. They come back as a normal result with isError: true and one plain sentence in content.

Rate limits

ScopeLimit
Calls, per connection120 per minute
Changes, per connection20 per minute
Registration, per address120 per 10 minutes
Token, per address1,200 per minute
Revocation, per address300 per minute
Discovery documents, per address1,200 per minute
Calls without a token, per address1,200 per minute

Try it

npx @modelcontextprotocol/inspector

Choose Streamable HTTP, enter the server address, and press Connect. The inspector signs in through your browser and lists the tools your role opens.

On this page