# dev.cocore.devicePair.start

> Published by [cocore.dev](https://lexicon.garden/identity/did:plc:5quuhkmwe2q4k3azfsgg7kdz)

✓ This is the authoritative definition for this NSID.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:5quuhkmwe2q4k3azfsgg7kdz/dev.cocore.devicePair.start)
- [Documentation](https://lexicon.garden/lexicon/did:plc:5quuhkmwe2q4k3azfsgg7kdz/dev.cocore.devicePair.start/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:5quuhkmwe2q4k3azfsgg7kdz/dev.cocore.devicePair.start/examples)

## Definitions

### `dev.cocore.devicePair.start`

**Type**: `procedure`

Begin a device-pairing flow (OAuth 2.0 device-authorization style). Returns a `deviceId` plus a short human-typable `userCode` and the `verificationUri` where a signed-in user approves the pairing. The caller then polls `dev.cocore.devicePair.poll` until approval.

#### Output

**Encoding**: `application/json`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `deviceId` | `string` | Yes |  |
| `userCode` | `string` | Yes | Short code the user types at the verification URI. |
| `expiresInSecs` | `integer` | Yes | Seconds until this pairing attempt expires. |
| `verificationUri` | `string` (uri) | Yes |  |
| `pollIntervalSecs` | `integer` | Yes | Minimum seconds between poll calls. |

## Raw Schema

```json
{
  "id": "dev.cocore.devicePair.start",
  "defs": {
    "main": {
      "type": "procedure",
      "output": {
        "schema": {
          "type": "object",
          "required": [
            "deviceId",
            "userCode",
            "verificationUri",
            "pollIntervalSecs",
            "expiresInSecs"
          ],
          "properties": {
            "deviceId": {
              "type": "string"
            },
            "userCode": {
              "type": "string",
              "description": "Short code the user types at the verification URI."
            },
            "expiresInSecs": {
              "type": "integer",
              "description": "Seconds until this pairing attempt expires."
            },
            "verificationUri": {
              "type": "string",
              "format": "uri"
            },
            "pollIntervalSecs": {
              "type": "integer",
              "description": "Minimum seconds between poll calls."
            }
          }
        },
        "encoding": "application/json"
      },
      "description": "Begin a device-pairing flow (OAuth 2.0 device-authorization style). Returns a `deviceId` plus a short human-typable `userCode` and the `verificationUri` where a signed-in user approves the pairing. The caller then polls `dev.cocore.devicePair.poll` until approval."
    }
  },
  "$type": "com.atproto.lexicon.schema",
  "lexicon": 1
}
```
