diff --git a/daprdocs/content/en/developing-ai/dapr-agents/dapr-agents-operations.md b/daprdocs/content/en/developing-ai/dapr-agents/dapr-agents-operations.md new file mode 100644 index 00000000000..ae0ed98d86e --- /dev/null +++ b/daprdocs/content/en/developing-ai/dapr-agents/dapr-agents-operations.md @@ -0,0 +1,42 @@ +--- +type: docs +title: "Operations" +linkTitle: "Operations" +weight: 80 +description: "Get started with secure and reliable operations of Dapr Agents" +aliases: + - /developing-ai/dapr-agents/dapr-agents-operations +--- + +## Operations + +### Agent Registry + +#### Agent Metadata Schema + +Dapr Agents utilizes an agent registry (often referenced as `agent-registry` statestore) to communicate agent capabilities. The agent registry contains agent metadata, including the agent's name, description, version and more. + +In order to facilitate easier handling of version changes to the agent metadata, Dapr Agents supplies versioned JSON schemas. Within the agents repository you'll find 3 types of JSON schema files: + +- [index.json](https://raw.githubusercontent.com/dapr/dapr-agents/main/schemas/agent-metadata/index.json) +- [latest.json](https://raw.githubusercontent.com/dapr/dapr-agents/main/schemas/agent-metadata/latest.json) +- `v{version}.json` + +The `index.json` can be used as a lookup table and looks like: + +``` +{ + "current_version": "X.Y.Z", + "schema_url": "https://raw.githubusercontent.com/dapr/dapr-agents/main/schemas/agent-metadata/vX.Y.Z.json", + "available_versions": [ + "vX.Y.Z", + "vA.B.C" + ] +} +``` + +When the agent starts up it will insert its own metadata into the supplied agent registry. The agent metadata object contains the key `schema_version` which can be used as a reference to fetch the valid schema for that agent version: + +```sh +curl -s -v "https://raw.githubusercontent.com/dapr/dapr-agents/main/schemas/agent-metadata/v$(jq -r '.schema_version' agent-metadata.json).json" +```