# State who answers for the agent

`PUT /agent-owners/{agent}` · Praecise Shield · Agents as customers

praecise_account needs the admin key; the other kinds need the manage secret (the admin key is also taken). The agent must have proven its name.

## Parameters

- `agent` (path, required), string

## Request body

`application/json`

```json
{
  "type": "object",
  "properties": {
    "owner": {
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "kind": {
              "const": "organisation"
            },
            "name": {
              "type": "string",
              "description": "Legal name."
            },
            "contact": {
              "type": "string",
              "description": "Contact email address."
            }
          },
          "required": [
            "kind",
            "name",
            "contact"
          ]
        },
        {
          "type": "object",
          "properties": {
            "kind": {
              "const": "network_identity"
            },
            "address": {
              "type": "string",
              "description": "0x… address (checked) or another form (kept as claimed, not verified)."
            },
            "proof": {
              "type": "string",
              "description": "0x… signature over: praecise-shield agent <host> owner <address> <token>"
            }
          },
          "required": [
            "kind",
            "address"
          ]
        },
        {
          "type": "object",
          "properties": {
            "kind": {
              "const": "praecise_account"
            },
            "id": {
              "type": "string",
              "description": ""
            }
          },
          "required": [
            "kind",
            "id"
          ]
        }
      ]
    }
  },
  "required": [
    "owner"
  ]
}
```

## Responses

- `200`
- `400`: The proof did not match.
- `409`: The agent has not proven its name.

## Example

```sh
curl -X PUT 'https://shield.praecise.com/agent-owners/{agent}' \
  -H 'Authorization: Bearer $KEY' \
  -H 'Content-Type: application/json' \
  -d '{
  "owner": {
    "kind": "organisation",
    "name": "string",
    "contact": "string"
  }
}'
```
