Dapr MCP server tool reference

Every tool the Dapr MCP server exposes, its inputs, its safety properties, and the component type that enables it

The Dapr MCP server exposes 17 tools. Three are always registered. The rest are registered only while the sidecar has at least one component of the matching type, so an agent never sees tools it can’t use.

The schema the server sends when a client connects is the authoritative definition of each tool. This page is a readable summary of it.

Call get_components first

Component-specific tools take a component name as input, such as storeName or pubsubName. An agent should call get_components first to learn the names that exist, rather than guess. The server’s instructions to the model say the same thing, and tell it to pass metadata fields as JSON objects ({}), never as strings ("{}").

Safety properties

Each tool carries the MCP annotations readOnlyHint, destructiveHint, and idempotentHint, which MCP clients can use to decide whether to ask a person before a call. The tables below show them as:

  • Read-only: reads data and changes nothing.
  • Idempotent: calling it again with the same inputs has no further effect, so it is safe to retry.
  • Destructive: may delete or overwrite data, or trigger an action that can’t be undone. Consider asking a person to confirm the first call.
  • Side effect: changes state or triggers an action somewhere.

Every tool except get_components also sets openWorldHint, because it reaches systems outside the server.

Tools at a glance

ToolRegistered when the sidecar hasSafety
get_componentsAlwaysRead-only, idempotent
invoke_serviceAlwaysDestructive, side effect, not idempotent
invoke_actor_methodAlwaysDestructive, side effect, not idempotent
save_stateA state.* componentSide effect, idempotent
get_stateA state.* componentRead-only, idempotent
delete_stateA state.* componentDestructive, idempotent
execute_transactionA state.* componentDestructive, side effect, not idempotent
publish_eventA pubsub.* componentSide effect, not idempotent
publish_event_with_metadataA pubsub.* componentSide effect, not idempotent
invoke_output_bindingA bindings.* componentDestructive, side effect, not idempotent
get_secretA secretstores.* componentRead-only, idempotent
get_bulk_secretsA secretstores.* componentRead-only, idempotent
converse_with_llmA conversation.* componentRead-only, idempotent
encrypt_dataA crypto.* componentDestructive, side effect, not idempotent
decrypt_dataA crypto.* componentRead-only, idempotent
acquire_lockA lock.* componentSide effect, idempotent
release_lockA lock.* componentSide effect, not idempotent

Tools follow the components loaded in the sidecar. When component hot reloading adds the first component of a type, the server registers that type’s tools the next time a client lists tools or calls get_components, and notifies connected clients that the tool list changed. When the last one is removed, its tools are removed too. Clients that read the tool list only once need to reconnect to see the change.

A tool that fails, because an input is missing or the sidecar returns an error, returns a result marked as an error with a message the model can read, rather than failing the MCP request.

Metadata

get_components

Lists the components loaded in the sidecar, with each one’s name, type, version, and capabilities. Only component types the server has tools for are listed. The list is read live from the sidecar on every call.

Inputs: none.

Service invocation

invoke_service

Calls a method on another Dapr app through service invocation and returns the response body.

InputRequiredDescription
appIDYesApp ID of the target app.
methodYesMethod or path to call, for example orders/status.
dataNoRequest body, usually JSON.
httpVerbNoGET, HEAD, POST, PUT, PATCH, DELETE, or OPTIONS. Default POST.
contentTypeNoContent type of data. Default application/json if data is valid JSON, text/plain otherwise.
metadataNoHeaders to send to the target app. Keys starting with dapr-, grpc-, or : are rejected.

Actors

invoke_actor_method

Calls a method on a virtual actor and returns its response.

InputRequiredDescription
actorTypeYesRegistered actor type.
actorIDYesID of the actor instance.
methodYesActor method to call.
dataNoPayload to pass to the method.

State management

save_state

Saves one key-value pair to a state store.

InputRequiredDescription
storeNameYesState store component name.
keyYesKey to save under.
valueYesValue to save, as a string. JSON is stored as given.

get_state

Reads the value of one key. Reports found: false when the key doesn’t exist.

InputRequiredDescription
storeNameYesState store component name.
keyYesKey to read.

delete_state

Deletes one key.

InputRequiredDescription
storeNameYesState store component name.
keyYesKey to delete.

execute_transaction

Runs several saves and deletes as one atomic transaction. The state store must support transactions.

InputRequiredDescription
storeNameYesState store component name.
itemsYesNon-empty list of operations. Each has a key (required), a value to save, and isDelete: true to delete the key instead.

Publish and subscribe

publish_event

Publishes a message to a topic on a pub/sub component.

InputRequiredDescription
pubsubNameYesPub/sub component name.
topicYesTopic to publish to.
messageYesMessage payload, usually JSON.
contentTypeNoContent type of message. Default application/json if message is valid JSON, text/plain otherwise.

publish_event_with_metadata

Same as publish_event, with publish metadata such as ttlInSeconds.

InputRequiredDescription
pubsubNameYesPub/sub component name.
topicYesTopic to publish to.
messageYesMessage payload, usually JSON.
contentTypeNoContent type of message.
metadataNoPublish metadata, for example {"ttlInSeconds": "60"}.

Bindings

invoke_output_binding

Invokes an operation on an output binding, such as an HTTP endpoint, a queue, or object storage, and returns the response.

InputRequiredDescription
bindingNameYesBinding component name.
operationYesOperation supported by the binding, for example create, get, or delete.
dataNoPayload, usually JSON.
metadataNoMetadata the binding needs for this operation, for example key for a storage binding.

Secrets

Secret values are returned to the model in the tool result. Expose only secret stores the agent should read, and narrow them with secret scopes.

get_secret

Reads one secret from a secret store.

InputRequiredDescription
storeNameYesSecret store component name.
secretNameYesName of the secret.
metadataNoStore-specific options, for example version_id.

get_bulk_secrets

Reads every secret the app can access in a secret store. The tool description tells the model to use it only when the user explicitly asks for all secrets.

InputRequiredDescription
storeNameYesSecret store component name.
metadataNoStore-specific options.

Conversation

converse_with_llm

Sends a prompt to another LLM through a conversation component and returns the reply, along with a context_id to continue the conversation.

InputRequiredDescription
nameYesConversation component name.
promptYesPrompt to send.
contextIdNocontext_id from an earlier call, to continue that conversation. A new one is generated when omitted.
temperatureNoSampling temperature from 0.0 to 1.0. Default 0.7.

Cryptography

encrypt_data

Encrypts text with a key held by a cryptography component and returns the cipher text, base64-encoded.

InputRequiredDescription
componentNameYesCryptography component name.
plainTextYesText to encrypt.
keyNameNoKey name, or name/version. Default rsa-private-key.pem.
keyWrapAlgorithmNoKey wrap algorithm, for example RSA, RSA-OAEP-256, or A256KW. Default RSA.

decrypt_data

Decrypts cipher text produced by encrypt_data and returns the plain text.

InputRequiredDescription
componentNameYesCryptography component name.
cipherTextYesBase64-encoded cipher text.
keyNameNoKey name, or name/version. When omitted, the key named in the cipher text header is used.

Distributed lock

Always pair acquire_lock with release_lock, and set an expiry so a lock isn’t held forever if the agent stops.

acquire_lock

Tries to acquire a distributed lock on a resource. If another owner holds it, the call succeeds with lock_acquired: false.

InputRequiredDescription
storeNameYesLock store component name.
resourceIDYesName of the resource to lock.
lockOwnerYesUnique ID of the caller, used again to release the lock.
expiryInSecondsYesLock lifetime in seconds, greater than zero. The lock expires automatically after this time.

release_lock

Releases a lock. Fails if the lock doesn’t exist or belongs to a different owner.

InputRequiredDescription
storeNameYesLock store component name.
resourceIDYesName of the locked resource.
lockOwnerYesThe owner ID used to acquire the lock.