# online.fg-goose.gsb.defs

> Published by [ember.delve.town](https://lexicon.garden/identity/did:plc:6amo7col5h4ciq2gpm5eur7b)

✓ This is the authoritative definition for this NSID.

## Description

Shared definitions for acting on a DelveTalk world (docs/ATPROTO.md section 2).

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:6amo7col5h4ciq2gpm5eur7b/online.fg-goose.gsb.defs)
- [Documentation](https://lexicon.garden/lexicon/did:plc:6amo7col5h4ciq2gpm5eur7b/online.fg-goose.gsb.defs/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:6amo7col5h4ciq2gpm5eur7b/online.fg-goose.gsb.defs/examples)

## Definitions

### `online.fg-goose.gsb.defs#answerView`

**Type**: `object`

The caller's projected turn answer. Preview outcomes use previewView, whose schema has no receipt.

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `$type` | `string` | No |  |
| `card` | `string` | No | The exact card the turn offered (or, for a try, would offer), as the caller may read it. |
| `cardCid` | `string` (cid) | No | CID of the exact offered card encoded as a DAG-CBOR string, including its trailing newline; not a repository record CID. |
| `offers` | `array` | No | Cards offered to the caller, verbatim. |
| `outcome` | `ref` → `online.fg-goose.gsb.defs#outcome` | Yes |  |
| `receipt` | `ref` → `online.fg-goose.gsb.defs#receipt` | No |  |
| `trace` | `ref` → `online.fg-goose.gsb.defs#trace` | No |  |
| `turns` | `array` | No |  |

### `online.fg-goose.gsb.defs#call`

**Type**: `object`

One untagged call: exactly {spell}, or {object, verb, fields?}. Shared wire judgement enforces the exclusive forms; fields must be a JSON object.

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `fields` | `unknown` | No | The verb's fields as a JSON object. |
| `object` | `string` | No | The object id. |
| `spell` | `string` | No | A spell: the delvetalk line and its field lines. |
| `verb` | `string` | No | The verb or method name. |

### `online.fg-goose.gsb.defs#moved`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `now` | `integer` | Yes | The version the object stands at. |
| `object` | `string` | Yes |  |
| `was` | `integer` | Yes | The version the pin named. |

### `online.fg-goose.gsb.defs#outcome`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `class` | `string` | No | A refusal's class. |
| `clause` | `string` | No |  |
| `line` | `string` | Yes | The host's stamp line as the public reads it: a refusal's only when the host gives it a public projection. |
| `moved` | `array` | No |  |
| `reason` | `string` | No |  |
| `status` | `string` | Yes |  |

### `online.fg-goose.gsb.defs#pin`

**Type**: `object`

Commit-if-unchanged: the object must stand at this version (and state CID) when the turn commits, else the turn is refused `moved`.

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `cid` | `string` (cid) | No | The object's stateCid at that version (an object projection's of CID). |
| `object` | `string` | Yes |  |
| `version` | `integer` | Yes |  |

### `online.fg-goose.gsb.defs#planCall`

**Type**: `object`

One spell only; a plan never contains object calls.

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `spell` | `string` | Yes | A spell: the delvetalk line and its field lines. |

### `online.fg-goose.gsb.defs#previewOutcome`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `class` | `string` | No | A refusal's class. |
| `clause` | `string` | No |  |
| `line` | `string` | Yes | The host's stamp line as the public reads it: a refusal's only when the host gives it a public projection. |
| `moved` | `array` | No |  |
| `reason` | `string` | No |  |
| `status` | `string` | Yes |  |

### `online.fg-goose.gsb.defs#previewView`

**Type**: `object`

A projected world-try reply, returned only. No receipt, slug, entry or record is claimed.

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `$type` | `string` | Yes |  |
| `card` | `string` | No | The exact card the turn offered (or, for a try, would offer), as the caller may read it. |
| `cardCid` | `string` (cid) | No | CID of the exact offered card encoded as a DAG-CBOR string, including its trailing newline; not a repository record CID. |
| `offers` | `array` | No | Cards offered to the caller, verbatim. |
| `outcome` | `ref` → `#previewOutcome` | Yes |  |
| `trace` | `ref` → `online.fg-goose.gsb.defs#trace` | No |  |
| `turns` | `array` | No |  |

### `online.fg-goose.gsb.defs#receipt`

**Type**: `object`

The journal entry the turn made. Absent from a preview, which can never pass for a receipt.

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `entry` | `cid-link` | Yes | The entry's hash: the CID of its canonical DAG-CBOR without `hash`, signed in the world's repository. |
| `height` | `integer` | Yes |  |
| `slug` | `string` | Yes | Two proquint words: what a post cites. |

### `online.fg-goose.gsb.defs#trace`

**Type**: `object`

What the turn read and moved, over objects the reader may view.

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `fired` | `array` | No | Rules fired, as journaled. |
| `revealed` | `array` | No | The host's revealed lines, verbatim. |
| `roots` | `array` | No | Objects read, at the versions read. |
| `unwanted` | `array` | No | Wants closed. |
| `wanted` | `array` | No | Wants opened. |
| `writes` | `array` | No | Objects written, each with its new version and stateCid. |

### `online.fg-goose.gsb.defs#version`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `object` | `string` | Yes |  |
| `stateCid` | `string` (cid) | No |  |
| `version` | `integer` | Yes |  |

### `online.fg-goose.gsb.defs#wantChange`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `object` | `string` | Yes |  |
| `want` | `string` | Yes |  |

## Raw Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "answerView": {
      "description": "The caller's projected turn answer. Preview outcomes use previewView, whose schema has no receipt.",
      "properties": {
        "$type": {
          "const": "online.fg-goose.gsb.defs#answerView",
          "type": "string"
        },
        "card": {
          "description": "The exact card the turn offered (or, for a try, would offer), as the caller may read it.",
          "type": "string"
        },
        "cardCid": {
          "description": "CID of the exact offered card encoded as a DAG-CBOR string, including its trailing newline; not a repository record CID.",
          "format": "cid",
          "type": "string"
        },
        "offers": {
          "description": "Cards offered to the caller, verbatim.",
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "outcome": {
          "ref": "online.fg-goose.gsb.defs#outcome",
          "type": "ref"
        },
        "receipt": {
          "ref": "online.fg-goose.gsb.defs#receipt",
          "type": "ref"
        },
        "trace": {
          "ref": "online.fg-goose.gsb.defs#trace",
          "type": "ref"
        },
        "turns": {
          "items": {
            "ref": "#answerView",
            "type": "ref"
          },
          "maxLength": 4,
          "type": "array"
        }
      },
      "required": [
        "outcome"
      ],
      "type": "object"
    },
    "call": {
      "description": "One untagged call: exactly {spell}, or {object, verb, fields?}. Shared wire judgement enforces the exclusive forms; fields must be a JSON object.",
      "properties": {
        "fields": {
          "description": "The verb's fields as a JSON object.",
          "type": "unknown"
        },
        "object": {
          "description": "The object id.",
          "maxLength": 128,
          "minLength": 1,
          "type": "string"
        },
        "spell": {
          "description": "A spell: the delvetalk line and its field lines.",
          "maxLength": 4096,
          "minLength": 1,
          "type": "string"
        },
        "verb": {
          "description": "The verb or method name.",
          "maxLength": 128,
          "minLength": 1,
          "type": "string"
        }
      },
      "type": "object"
    },
    "moved": {
      "properties": {
        "now": {
          "description": "The version the object stands at.",
          "minimum": 0,
          "type": "integer"
        },
        "object": {
          "type": "string"
        },
        "was": {
          "description": "The version the pin named.",
          "minimum": 0,
          "type": "integer"
        }
      },
      "required": [
        "object",
        "was",
        "now"
      ],
      "type": "object"
    },
    "outcome": {
      "properties": {
        "class": {
          "description": "A refusal's class.",
          "type": "string"
        },
        "clause": {
          "type": "string"
        },
        "line": {
          "description": "The host's stamp line as the public reads it: a refusal's only when the host gives it a public projection.",
          "type": "string"
        },
        "moved": {
          "items": {
            "ref": "#moved",
            "type": "ref"
          },
          "type": "array"
        },
        "reason": {
          "type": "string"
        },
        "status": {
          "enum": [
            "admitted",
            "refused",
            "suspended",
            "moved",
            "unsupported",
            "spells",
            "usage",
            "unreached",
            "invalid",
            "error",
            "unknown",
            "denied",
            "looked",
            "receipt"
          ],
          "type": "string"
        }
      },
      "required": [
        "status",
        "line"
      ],
      "type": "object"
    },
    "pin": {
      "description": "Commit-if-unchanged: the object must stand at this version (and state CID) when the turn commits, else the turn is refused `moved`.",
      "properties": {
        "cid": {
          "description": "The object's stateCid at that version (an object projection's of CID).",
          "format": "cid",
          "type": "string"
        },
        "object": {
          "type": "string"
        },
        "version": {
          "minimum": 0,
          "type": "integer"
        }
      },
      "required": [
        "object",
        "version"
      ],
      "type": "object"
    },
    "planCall": {
      "description": "One spell only; a plan never contains object calls.",
      "properties": {
        "spell": {
          "description": "A spell: the delvetalk line and its field lines.",
          "maxLength": 4096,
          "minLength": 1,
          "type": "string"
        }
      },
      "required": [
        "spell"
      ],
      "type": "object"
    },
    "previewOutcome": {
      "properties": {
        "class": {
          "description": "A refusal's class.",
          "type": "string"
        },
        "clause": {
          "type": "string"
        },
        "line": {
          "description": "The host's stamp line as the public reads it: a refusal's only when the host gives it a public projection.",
          "type": "string"
        },
        "moved": {
          "items": {
            "ref": "#moved",
            "type": "ref"
          },
          "type": "array"
        },
        "reason": {
          "type": "string"
        },
        "status": {
          "const": "previewed",
          "type": "string"
        }
      },
      "required": [
        "status",
        "line"
      ],
      "type": "object"
    },
    "previewView": {
      "description": "A projected world-try reply, returned only. No receipt, slug, entry or record is claimed.",
      "properties": {
        "$type": {
          "const": "online.fg-goose.gsb.defs#previewView",
          "type": "string"
        },
        "card": {
          "description": "The exact card the turn offered (or, for a try, would offer), as the caller may read it.",
          "type": "string"
        },
        "cardCid": {
          "description": "CID of the exact offered card encoded as a DAG-CBOR string, including its trailing newline; not a repository record CID.",
          "format": "cid",
          "type": "string"
        },
        "offers": {
          "description": "Cards offered to the caller, verbatim.",
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "outcome": {
          "ref": "#previewOutcome",
          "type": "ref"
        },
        "trace": {
          "ref": "online.fg-goose.gsb.defs#trace",
          "type": "ref"
        },
        "turns": {
          "items": {
            "ref": "#previewView",
            "type": "ref"
          },
          "maxLength": 4,
          "type": "array"
        }
      },
      "required": [
        "$type",
        "outcome"
      ],
      "type": "object"
    },
    "receipt": {
      "description": "The journal entry the turn made. Absent from a preview, which can never pass for a receipt.",
      "properties": {
        "entry": {
          "description": "The entry's hash: the CID of its canonical DAG-CBOR without `hash`, signed in the world's repository.",
          "type": "cid-link"
        },
        "height": {
          "minimum": 1,
          "type": "integer"
        },
        "slug": {
          "description": "Two proquint words: what a post cites.",
          "type": "string"
        }
      },
      "required": [
        "slug",
        "height",
        "entry"
      ],
      "type": "object"
    },
    "trace": {
      "description": "What the turn read and moved, over objects the reader may view.",
      "properties": {
        "fired": {
          "description": "Rules fired, as journaled.",
          "items": {
            "type": "unknown"
          },
          "type": "array"
        },
        "revealed": {
          "description": "The host's revealed lines, verbatim.",
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "roots": {
          "description": "Objects read, at the versions read.",
          "items": {
            "ref": "#version",
            "type": "ref"
          },
          "type": "array"
        },
        "unwanted": {
          "description": "Wants closed.",
          "items": {
            "ref": "#wantChange",
            "type": "ref"
          },
          "type": "array"
        },
        "wanted": {
          "description": "Wants opened.",
          "items": {
            "ref": "#wantChange",
            "type": "ref"
          },
          "type": "array"
        },
        "writes": {
          "description": "Objects written, each with its new version and stateCid.",
          "items": {
            "ref": "#version",
            "type": "ref"
          },
          "type": "array"
        }
      },
      "type": "object"
    },
    "version": {
      "properties": {
        "object": {
          "type": "string"
        },
        "stateCid": {
          "format": "cid",
          "type": "string"
        },
        "version": {
          "minimum": 0,
          "type": "integer"
        }
      },
      "required": [
        "object",
        "version"
      ],
      "type": "object"
    },
    "wantChange": {
      "properties": {
        "object": {
          "type": "string"
        },
        "want": {
          "type": "string"
        }
      },
      "required": [
        "object",
        "want"
      ],
      "type": "object"
    }
  },
  "description": "Shared definitions for acting on a DelveTalk world (docs/ATPROTO.md section 2).",
  "id": "online.fg-goose.gsb.defs",
  "lexicon": 1
}
```
