Skip to content
HALOWERK

Text Tools

jsonfeed handoff headline byte budget

Feed headline packing fits the longest ordered prefix of ID and title pairs into a UTF-8 JSON byte budget. Use it when an agent needs keeping a headline handoff within a payload limit.

POST https://text.halowerk.com/v1/jsonfeed-handoff-headline-byte-budget

Inputs

Fields of the published input schema
FieldTypeRequiredDescription
itemsarrayYes
bytesintegerYes
Show full input schema
{
  "type": "object",
  "properties": {
    "items": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "maxLength": 400,
            "minLength": 1
          }
        },
        "required": [
          "id"
        ]
      },
      "maxItems": 100,
      "minItems": 1
    },
    "bytes": {
      "type": "integer",
      "minimum": 2,
      "maximum": 100000
    }
  },
  "required": [
    "items",
    "bytes"
  ],
  "additionalProperties": false
}

Open original schema

Published input example

{
  "items": [
    {
      "id": "us6000udhb",
      "title": "M 4.4 - 5 km NNW of Itháki, Greece"
    },
    {
      "id": "us6000udfu",
      "title": "M 3.4 - 92 km SW of Adak, Alaska"
    }
  ],
  "bytes": 120
}

Result & documentation

Show published result schema
{
  "type": "object",
  "required": [
    "measured_at",
    "source",
    "data",
    "limitations"
  ],
  "properties": {
    "measured_at": {
      "type": "string"
    },
    "source": {
      "type": "object",
      "required": [
        "reference",
        "retrieved_at"
      ],
      "properties": {
        "reference": {
          "type": "string"
        },
        "retrieved_at": {
          "type": "string"
        }
      }
    },
    "data": {
      "type": "object",
      "properties": {
        "included": {
          "type": "integer"
        },
        "used_bytes": {
          "type": "integer"
        },
        "first_excluded": {
          "type": "string"
        }
      },
      "required": [
        "included",
        "used_bytes",
        "first_excluded"
      ]
    },
    "limitations": {
      "type": "string"
    }
  }
}

Machine-readable documentation of this hub

Source of this page: the published HALOWERK catalog. Updated: 2026-12-05 UTC.

More endpoints in this hub

All endpoints in this hub →