# pub.chive.metrics.recordSearchDownload

> Published by [chive.pub](https://lexicon.garden/identity/did:plc:7natp5xae72bddaqlkef2t4e)

✓ This is the authoritative definition for this NSID.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:7natp5xae72bddaqlkef2t4e/pub.chive.metrics.recordSearchDownload)
- [Documentation](https://lexicon.garden/lexicon/did:plc:7natp5xae72bddaqlkef2t4e/pub.chive.metrics.recordSearchDownload/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:7natp5xae72bddaqlkef2t4e/pub.chive.metrics.recordSearchDownload/examples)

## Definitions

### `pub.chive.metrics.recordSearchDownload`

**Type**: `procedure`

Record a download event from a search result (strong positive relevance signal)

#### Input

**Encoding**: `application/json`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `uri` | `string` (at-uri) | Yes | AT-URI of the downloaded eprint |
| `impressionId` | `string` | Yes | UUID of the search impression |

#### Output

**Encoding**: `application/json`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `success` | `boolean` | Yes | Whether the download was recorded |

#### Errors

- **InvalidRequest**

## Raw Schema

```json
{
  "id": "pub.chive.metrics.recordSearchDownload",
  "defs": {
    "main": {
      "type": "procedure",
      "input": {
        "schema": {
          "type": "object",
          "required": [
            "impressionId",
            "uri"
          ],
          "properties": {
            "uri": {
              "type": "string",
              "format": "at-uri",
              "description": "AT-URI of the downloaded eprint"
            },
            "impressionId": {
              "type": "string",
              "description": "UUID of the search impression"
            }
          }
        },
        "encoding": "application/json"
      },
      "errors": [
        {
          "name": "InvalidRequest"
        }
      ],
      "output": {
        "schema": {
          "type": "object",
          "required": [
            "success"
          ],
          "properties": {
            "success": {
              "type": "boolean",
              "description": "Whether the download was recorded"
            }
          }
        },
        "encoding": "application/json"
      },
      "description": "Record a download event from a search result (strong positive relevance signal)"
    }
  },
  "$type": "com.atproto.lexicon.schema",
  "lexicon": 1,
  "revision": 1
}
```
