Data Transformation & Quality · x402 V2

Text Chunk Structure

Use this service when you need this capability: creates deterministic source-ordered chunks from text or Markdown using headings, paragraphs, lists, and code blocks.

Price and endpoint

LivePOSTBase USDC

0.01 USDC per call

x402 V2 exact payment on Base mainnet (eip155:8453) using USDC. The HTTP 402 challenge confirms the exact requirements before an authorized payment.

POST https://signalharness.ai/api/agent/services/text_chunk_structure/invoke

Purpose

Creates deterministic source-ordered chunks from text or Markdown using headings, paragraphs, lists, and code blocks.

This service applies bounded processing to the supplied input. Review its schema, result fields, and limits for the exact supported capability.

Inputs

Request fields and validation limits
FieldTypeRequiredLimits
textstringRequiredMinimum length 1; Maximum length 65536
maxChunkCharsintegerOptionalMinimum 256; Maximum 16000

Example request body

{
  "text": "# Example\n\nBody."
}
View complete input schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "additionalProperties": false,
  "minProperties": 1,
  "maxProperties": 2,
  "required": [
    "text"
  ],
  "properties": {
    "text": {
      "type": "string",
      "minLength": 1,
      "maxLength": 65536
    },
    "maxChunkChars": {
      "type": "integer",
      "minimum": 256,
      "maximum": 16000
    }
  }
}

Realistic output shape

Illustrative output from the canonical adapter fixture and schema. It is not a completed paid execution or a current live observation.

{
  "chunkCount": 0,
  "chunks": [
    {
      "id": "example000",
      "headingHierarchy": [
        "example"
      ],
      "text": "Example caller-supplied content.",
      "start": 0,
      "end": 0,
      "estimatedTokens": 1,
      "hash": "0000000000000000000000000000000000000000000000000000000000000000",
      "ordinal": 0
    }
  ],
  "sourceHash": "0000000000000000000000000000000000000000000000000000000000000000"
}
View complete output schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "additionalProperties": false,
  "minProperties": 3,
  "maxProperties": 3,
  "required": [
    "chunkCount",
    "chunks",
    "sourceHash"
  ],
  "properties": {
    "chunkCount": {
      "type": "integer",
      "minimum": 0,
      "maximum": 512
    },
    "chunks": {
      "type": "array",
      "minItems": 0,
      "maxItems": 256,
      "items": {
        "type": "object",
        "additionalProperties": false,
        "minProperties": 8,
        "maxProperties": 8,
        "required": [
          "id",
          "headingHierarchy",
          "text",
          "start",
          "end",
          "estimatedTokens",
          "hash",
          "ordinal"
        ],
        "properties": {
          "id": {
            "type": "string",
            "minLength": 10,
            "maxLength": 16
          },
          "headingHierarchy": {
            "type": "array",
            "minItems": 0,
            "maxItems": 6,
            "items": {
              "type": "string",
              "minLength": 1,
              "maxLength": 8192
            }
          },
          "text": {
            "type": "string",
            "minLength": 1,
            "maxLength": 16000
          },
          "start": {
            "type": "integer",
            "minimum": 0,
            "maximum": 1048576
          },
          "end": {
            "type": "integer",
            "minimum": 0,
            "maximum": 1048576
          },
          "estimatedTokens": {
            "type": "integer",
            "minimum": 1,
            "maximum": 100000
          },
          "hash": {
            "type": "string",
            "pattern": "^[0-9a-f]{64}$",
            "minLength": 64,
            "maxLength": 64
          },
          "ordinal": {
            "type": "integer",
            "minimum": 0,
            "maximum": 511
          }
        }
      }
    },
    "sourceHash": {
      "type": "string",
      "pattern": "^[0-9a-f]{64}$",
      "minLength": 64,
      "maxLength": 64
    }
  }
}

Execution limits

  • MaxInputBytes: 524288
  • MaxOutputBytes: 1048576
  • MaxConcurrentExecutions: 4
  • MaxArtifacts: 0
  • MaxArtifactBytes: 0
  • RateLimitPerMinute: 60
  • MaxChunks: 256
  • MaxNesting: 64

Timeout: 5000 ms. Full schemas are in OpenAPI.

Copyable unpaid request

This schema-valid request returns the canonical HTTP 402 challenge without executing the service. A payment-capable client validates the challenge, signs only with prior authority and budget, and retries the identical body.

curl -i -X POST https://signalharness.ai/api/agent/services/text_chunk_structure/invoke \
  -H "Content-Type: application/json" \
  --data '{"text":"# Example\n\nBody."}'

Continue with the paid-call walkthrough →