# dev.knotless.cancel

> Kept in the account of the repository's owner, keyed `<repo key>.<tid>`. A runner acts on the requests in the owner's account, newer than the last it acted on, and on no one else's: it cancels its runs of the ref or the pull going or waiting for their turn when it reads the request, even those of a workflow whose runs finish, and files their checks as cancelled. A merge queue's batches are not a ref's runs. Naming neither a ref nor a pull asks for nothing. With a workflow, only that workflow's runs are cancelled.

- Kind: record
- Record key: any
- Authority: knotless.dev
- Lexicon: 1
- Published by [lexicons.knotless.dev](https://lexicon.garden/identity/did:plc:yqsg7znbbhfmj3a2nrpnaerk), the NSID's authority

## Links

- [Documentation](https://lexicon.garden/lexicon/did:plc:yqsg7znbbhfmj3a2nrpnaerk/dev.knotless.cancel)
- [Schema JSON](https://lexicon.garden/lexicon/did:plc:yqsg7znbbhfmj3a2nrpnaerk/dev.knotless.cancel/schema.json)
- [Analytics](https://lexicon.garden/lexicon/did:plc:yqsg7znbbhfmj3a2nrpnaerk/dev.knotless.cancel/analytics)

## Record (`dev.knotless.cancel`)

Type: record · key any

### Properties

- `createdAt` (string · datetime, required)
- `pull` (string · at-uri): The dev.knotless.pull record whose runs to cancel.
- `ref` (string): The full ref name whose runs to cancel, such as refs/heads/main.
  - Constraints: maxLength: 1024
- `repo` (ref, required): The repository, which is the owner's.
  - Reference: `dev.knotless.defs#repoRef`
- `workflow` (string): The name of the one workflow whose runs to cancel.
  - Constraints: maxLength: 64

## Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "main": {
      "description": "Kept in the account of the repository's owner, keyed `<repo key>.<tid>`. A runner acts on the requests in the owner's account, newer than the last it acted on, and on no one else's: it cancels its runs of the ref or the pull going or waiting for their turn when it reads the request, even those of a workflow whose runs finish, and files their checks as cancelled. A merge queue's batches are not a ref's runs. Naming neither a ref nor a pull asks for nothing. With a workflow, only that workflow's runs are cancelled.",
      "key": "any",
      "record": {
        "properties": {
          "createdAt": {
            "format": "datetime",
            "type": "string"
          },
          "pull": {
            "description": "The dev.knotless.pull record whose runs to cancel.",
            "format": "at-uri",
            "type": "string"
          },
          "ref": {
            "description": "The full ref name whose runs to cancel, such as refs/heads/main.",
            "maxLength": 1024,
            "type": "string"
          },
          "repo": {
            "description": "The repository, which is the owner's.",
            "ref": "dev.knotless.defs#repoRef",
            "type": "ref"
          },
          "workflow": {
            "description": "The name of the one workflow whose runs to cancel.",
            "maxLength": 64,
            "type": "string"
          }
        },
        "required": [
          "repo",
          "createdAt"
        ],
        "type": "object"
      },
      "type": "record"
    }
  },
  "description": "A repository owner's request that its runners cancel the runs of a ref or a pull still going.",
  "id": "dev.knotless.cancel",
  "lexicon": 1
}
```
