mirror of https://github.com/dapr/docs.git
34 lines
936 B
Markdown
34 lines
936 B
Markdown
# Azure CosmosDB Binding Spec
|
|
|
|
```yaml
|
|
apiVersion: dapr.io/v1alpha1
|
|
kind: Component
|
|
metadata:
|
|
name: <NAME>
|
|
namespace: <NAMESPACE>
|
|
spec:
|
|
type: bindings.azure.cosmosdb
|
|
metadata:
|
|
- name: url
|
|
value: https://******.documents.azure.com:443/
|
|
- name: masterKey
|
|
value: *****
|
|
- name: database
|
|
value: db
|
|
- name: collection
|
|
value: collection
|
|
- name: partitionKey
|
|
value: message
|
|
```
|
|
|
|
- `url` is the CosmosDB url.
|
|
- `masterKey` is the CosmosDB account master key.
|
|
- `database` is the name of the CosmosDB database.
|
|
- `collection` is name of the collection inside the database.
|
|
- `partitionKey` is the name of the partitionKey to extract from the payload.
|
|
|
|
> **Note:** In production never place passwords or secrets within Dapr components. For information on securely storing and retrieving secrets refer to [Setup Secret Store](../../../howto/setup-secret-store)
|
|
|
|
## Output Binding Supported Operations
|
|
|
|
* create |