mirror of https://github.com/dapr/docs.git
949 B
949 B
| type | title | linkTitle | description |
|---|---|---|---|
| docs | invoke CLI command reference | invoke | Detailed information on the invoke CLI command |
Description
Invoke a method on a given Dapr application.
Supported platforms
- [Self-Hosted]({{< ref self-hosted >}})
Usage
dapr invoke [flags]
Flags
| Name | Environment Variable | Default | Description |
|---|---|---|---|
--app-id, -a |
The application id to invoke | ||
--help, -h |
Print this help message | ||
--method, -m |
The method to invoke | ||
--data, -d |
The JSON serialized data string (optional) | ||
--verb, -v |
POST |
The HTTP verb to use |
Examples
Invoke a sample method on target app with POST Verb
dapr invoke --app-id target --method sample --data '{"key":"value"}'
Invoke a sample method on target app with GET Verb
dapr invoke --app-id target --method sample --verb GET