Text indentation detect

text-indentation-detect · version 1.0.0 · Text · free, no key needed

Detect whether a text uses tabs or spaces for indentation by counting lines.

Use when you need to: text indentation detect · detect indentation · check if text uses tabs or spaces.

Supported

Not supported

Behavior

Input

Output

Limits

Example

Request input:

{
  "text": "function foo() {\n\treturn 1;\n}"
}

Response:

{
  "result": {
    "tab_indented_lines": 1,
    "space_indented_lines": 0,
    "mixed_indented_lines": 0,
    "predominant": "tabs"
  }
}

How to call it

MCP

Connect https://computefirst.net/mcp (setup), then call execute with:

{
  "id": "text-indentation-detect",
  "version": "1.0.0",
  "input": {
    "text": "function foo() {\n\treturn 1;\n}"
  }
}

HTTP (no key)

curl -X POST https://computefirst.net/v1/tools/text-indentation-detect/versions/1.0.0/execute \
  -H "Content-Type: application/json" \
  -d '{"text":"function foo() {\n\treturn 1;\n}"}'

The machine-readable contract is at /v1/tools/text-indentation-detect/versions/1.0.0.

CLI

node cli.mjs run text-indentation-detect 1.0.0 --input input.json --base-url https://computefirst.net

Get the client at /clients/cli/.