# installAgent

```graphql
mutation InstallAgent($input: InstallProjectAgentInput!) {
  installAgent(input: $input) {
    avatarUrl
    id
    name
    description
    provider
    version
    capabilities
    defaultInputModes
    defaultOutputModes
    tools
    skills
    suggestions
    model
    url
    kind
    canRun
    sourceType
    installedAccess
    runtimeReadiness
    sourcePath
    editMode
  }
}
```

Install agent. Requires project.agents.write.

## Arguments

| Name                     | Type                      | Required | Description                                                                                                                                |
| ------------------------ | ------------------------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------ |
| `input`                  | InstallProjectAgentInput! | Yes      |                                                                                                                                            |
| `input.projectReference` | String                    |          |                                                                                                                                            |
| `input.agentId`          | String!                   | Yes      |                                                                                                                                            |
| `input.relation`         | String                    |          | Relation of the agent access grant that installs the catalog agent. Installing creates or reuses an access grant; the agent is not copied. |

## Variables

```json
{
  "input": {
    "agentId": "string"
  }
}
```

## Responses

| Status | Description                                 |
| ------ | ------------------------------------------- |
| 200    | The ProjectAgentCard! in data.installAgent. |

## Call it

```bash
curl -X POST "https://api.veryfront.com/graphql" \
  -H "Authorization: Bearer $VERYFRONT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "query": "mutation InstallAgent($input: InstallProjectAgentInput!) {\n  installAgent(input: $input) {\n    avatarUrl\n    id\n    name\n    description\n    provider\n    version\n    capabilities\n    defaultInputModes\n    defaultOutputModes\n    tools\n    skills\n    suggestions\n    model\n    url\n    kind\n    canRun\n    sourceType\n    installedAccess\n    runtimeReadiness\n    sourcePath\n    editMode\n  }\n}",
  "variables": {
    "input": {
      "agentId": "string"
    }
  }
}'
```

## Example response

```json
{
  "data": {
    "installAgent": {
      "avatarUrl": "https://example.com",
      "id": "string",
      "name": "string",
      "description": "string",
      "provider": {},
      "version": "string",
      "capabilities": {},
      "defaultInputModes": [
        "string"
      ],
      "defaultOutputModes": [
        "string"
      ],
      "tools": [
        "string"
      ],
      "skills": [
        {}
      ],
      "suggestions": {},
      "model": "string",
      "url": "https://example.com",
      "kind": "string",
      "canRun": false,
      "sourceType": "string",
      "installedAccess": {},
      "runtimeReadiness": {},
      "sourcePath": "string",
      "editMode": "string"
    }
  }
}
```
