# pub.chive.admin.getTrendingVelocity

> 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.admin.getTrendingVelocity)
- [Documentation](https://lexicon.garden/lexicon/did:plc:7natp5xae72bddaqlkef2t4e/pub.chive.admin.getTrendingVelocity/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:7natp5xae72bddaqlkef2t4e/pub.chive.admin.getTrendingVelocity/examples)

## Definitions

### `pub.chive.admin.getTrendingVelocity`

**Type**: `query`

Get trending eprints ranked by engagement velocity

#### Parameters

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `limit` | `integer` | No | Maximum number of results |
| `window` | `string` | No | Time window for velocity calculation |

#### Output

**Encoding**: `application/json`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `items` | `array` | Yes | Trending eprints with velocity data |

#### Errors

- **AuthenticationRequired**
- **AdminRequired**

### `pub.chive.admin.getTrendingVelocity#velocityEntry`

**Type**: `object`

Eprint trending velocity entry

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `uri` | `string` (at-uri) | Yes | Eprint AT URI |
| `title` | `string` | Yes | Eprint title |
| `views` | `integer` | No | Total views in window |
| `velocity` | `integer` | Yes | Engagement velocity in milliunits (divide by 1000 for ratio of current to baseline) |
| `authorDid` | `string` (did) | No | Author DID |
| `downloads` | `integer` | No | Total downloads in window |
| `acceleration` | `integer` | No | Velocity change between windows in milliunits (divide by 1000) |
| `dailyAvgCurrent` | `integer` | No | Current window daily average views in milliunits (divide by 1000) |
| `dailyAvgBaseline` | `integer` | No | Baseline window daily average views in milliunits (divide by 1000) |

## Raw Schema

```json
{
  "id": "pub.chive.admin.getTrendingVelocity",
  "defs": {
    "main": {
      "type": "query",
      "errors": [
        {
          "name": "AuthenticationRequired"
        },
        {
          "name": "AdminRequired"
        }
      ],
      "output": {
        "schema": {
          "type": "object",
          "required": [
            "items"
          ],
          "properties": {
            "items": {
              "type": "array",
              "items": {
                "ref": "#velocityEntry",
                "type": "ref"
              },
              "description": "Trending eprints with velocity data"
            }
          }
        },
        "encoding": "application/json"
      },
      "parameters": {
        "type": "params",
        "properties": {
          "limit": {
            "type": "integer",
            "default": 20,
            "maximum": 100,
            "minimum": 1,
            "description": "Maximum number of results"
          },
          "window": {
            "type": "string",
            "default": "24h",
            "description": "Time window for velocity calculation",
            "knownValues": [
              "24h",
              "7d",
              "30d"
            ]
          }
        }
      },
      "description": "Get trending eprints ranked by engagement velocity"
    },
    "velocityEntry": {
      "type": "object",
      "required": [
        "uri",
        "title",
        "velocity"
      ],
      "properties": {
        "uri": {
          "type": "string",
          "format": "at-uri",
          "description": "Eprint AT URI"
        },
        "title": {
          "type": "string",
          "description": "Eprint title"
        },
        "views": {
          "type": "integer",
          "description": "Total views in window"
        },
        "velocity": {
          "type": "integer",
          "description": "Engagement velocity in milliunits (divide by 1000 for ratio of current to baseline)"
        },
        "authorDid": {
          "type": "string",
          "format": "did",
          "description": "Author DID"
        },
        "downloads": {
          "type": "integer",
          "description": "Total downloads in window"
        },
        "acceleration": {
          "type": "integer",
          "description": "Velocity change between windows in milliunits (divide by 1000)"
        },
        "dailyAvgCurrent": {
          "type": "integer",
          "description": "Current window daily average views in milliunits (divide by 1000)"
        },
        "dailyAvgBaseline": {
          "type": "integer",
          "description": "Baseline window daily average views in milliunits (divide by 1000)"
        }
      },
      "description": "Eprint trending velocity entry"
    }
  },
  "$type": "com.atproto.lexicon.schema",
  "lexicon": 1,
  "revision": 1
}
```
