# net.wireservice.redirect

> Published by [wireservice.net](https://lexicon.garden/identity/did:plc:lktj64hp7lc3fzuf6iyy7lwj)

✓ This is the authoritative definition for this NSID.

## Description

The record key is the hex SHA-256 of the path (normalized: leading slash, no trailing slash).

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:lktj64hp7lc3fzuf6iyy7lwj/net.wireservice.redirect)
- [Documentation](https://lexicon.garden/lexicon/did:plc:lktj64hp7lc3fzuf6iyy7lwj/net.wireservice.redirect/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:lktj64hp7lc3fzuf6iyy7lwj/net.wireservice.redirect/examples)

## Definitions

### `net.wireservice.redirect`

**Type**: `record`

An old path on the publication's site that now belongs to a document: from an imported archive, or a document whose path changed. Any app can answer the old URL with a getRecord, without an index.

**Key**: `any`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `createdAt` | `string` (datetime) | Yes |  |
| `path` | `string` | Yes | The old path, with a leading slash and no trailing slash. |
| `target` | `string` (at-uri) | Yes | The site.standard.document the path now belongs to. Redirect to that document's current path. |

## Raw Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "main": {
      "description": "An old path on the publication's site that now belongs to a document: from an imported archive, or a document whose path changed. Any app can answer the old URL with a getRecord, without an index.",
      "key": "any",
      "record": {
        "properties": {
          "createdAt": {
            "format": "datetime",
            "type": "string"
          },
          "path": {
            "description": "The old path, with a leading slash and no trailing slash.",
            "maxLength": 2048,
            "type": "string"
          },
          "target": {
            "description": "The site.standard.document the path now belongs to. Redirect to that document's current path.",
            "format": "at-uri",
            "type": "string"
          }
        },
        "required": [
          "path",
          "target",
          "createdAt"
        ],
        "type": "object"
      },
      "type": "record"
    }
  },
  "description": "The record key is the hex SHA-256 of the path (normalized: leading slash, no trailing slash).",
  "id": "net.wireservice.redirect",
  "lexicon": 1
}
```
