{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "main": {
      "description": "A deterministic WASM program anyone can re-run under the Cairns check profile.",
      "key": "tid",
      "record": {
        "properties": {
          "accepts": {
            "description": "Hashes of the payload schemas the check accepts. Absent when the input isn't a payload, as for the transform interpreter, whose input is a script and a source.",
            "items": {
              "ref": "org.cairnsproto.draft.defs#hash",
              "type": "ref"
            },
            "maxLength": 64,
            "minLength": 1,
            "type": "array"
          },
          "createdAt": {
            "format": "datetime",
            "type": "string"
          },
          "gasLimit": {
            "minimum": 1,
            "type": "integer"
          },
          "license": {
            "description": "SPDX expression or URL for the module and its source.",
            "maxLength": 512,
            "type": "string"
          },
          "module": {
            "accept": [
              "application/wasm"
            ],
            "maxSize": 5000000,
            "type": "blob"
          },
          "output": {
            "description": "Hash of the output schema. Absent when another record names it, as each transform names the schema of its interpreter run's output.",
            "ref": "org.cairnsproto.draft.defs#hash",
            "type": "ref"
          },
          "profile": {
            "ref": "#profile",
            "type": "ref"
          },
          "proves": {
            "description": "The exact claim a passing result supports.",
            "maxLength": 3000,
            "type": "string"
          },
          "source": {
            "ref": "#sourceRef",
            "type": "ref"
          }
        },
        "required": [
          "module",
          "profile",
          "gasLimit",
          "proves",
          "license",
          "createdAt"
        ],
        "type": "object"
      },
      "type": "record"
    },
    "profile": {
      "properties": {
        "instrumenter": {
          "description": "Tool and exact version that checked the module against the profile. Runners apply the profile's own metering pass.",
          "maxLength": 256,
          "type": "string"
        },
        "version": {
          "maxLength": 64,
          "type": "string"
        }
      },
      "required": [
        "version",
        "instrumenter"
      ],
      "type": "object"
    },
    "sourceRef": {
      "description": "The git commit the module was built from.",
      "properties": {
        "commit": {
          "maxLength": 64,
          "minLength": 40,
          "type": "string"
        },
        "repo": {
          "format": "uri",
          "type": "string"
        }
      },
      "required": [
        "repo",
        "commit"
      ],
      "type": "object"
    }
  },
  "id": "org.cairnsproto.draft.check",
  "lexicon": 1
}
