sew-proto 0.11.6

Sew wire contracts: ids, addresses, errors, HTTP and gateway bodies, permissions, policies, audit.
Documentation
{
  "$defs": {
    "LinkPreviewKind": {
      "description": "What a link preview shows.",
      "oneOf": [
        {
          "const": "page",
          "description": "An HTML page (title, description, optional image).",
          "type": "string"
        },
        {
          "const": "image",
          "description": "The link is an image.",
          "type": "string"
        }
      ]
    },
    "PreviewImage": {
      "description": "A preview's image, stored and served by Sew.",
      "properties": {
        "height": {
          "description": "Height in pixels (≤ 800).",
          "format": "uint32",
          "minimum": 0,
          "type": "integer"
        },
        "url": {
          "description": "Signed URL (1 h).",
          "type": "string"
        },
        "width": {
          "description": "Width in pixels (≤ 800).",
          "format": "uint32",
          "minimum": 0,
          "type": "integer"
        }
      },
      "required": [
        "url",
        "width",
        "height"
      ],
      "type": "object"
    }
  },
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "description": "One link preview of a message. Text fields are plain text: never render them as HTML or\nmarkdown.",
  "properties": {
    "description": {
      "description": "The page description (≤ 512 characters).",
      "type": [
        "string",
        "null"
      ]
    },
    "host": {
      "description": "Its host.",
      "type": "string"
    },
    "image": {
      "anyOf": [
        {
          "$ref": "#/$defs/PreviewImage"
        },
        {
          "type": "null"
        }
      ],
      "description": "The preview image."
    },
    "kind": {
      "$ref": "#/$defs/LinkPreviewKind",
      "description": "Page or image."
    },
    "redirected_host": {
      "description": "The final host when a redirect changed it; clients should show it.",
      "type": [
        "string",
        "null"
      ]
    },
    "site_name": {
      "description": "The site name (≤ 100 characters).",
      "type": [
        "string",
        "null"
      ]
    },
    "title": {
      "description": "The page title (≤ 256 characters).",
      "type": [
        "string",
        "null"
      ]
    },
    "url": {
      "description": "The URL as the author typed it.",
      "type": "string"
    }
  },
  "required": [
    "url",
    "host",
    "kind"
  ],
  "title": "LinkPreview",
  "type": "object"
}