Skip to main content
Glama
Jambozx

OnlineCyberTools MCP (280+ filterable tools)

text_sort_lines

Read-onlyIdempotent

Sort any text block alphabetically, numerically, by length, date, randomly, or reversed. Optionally remove duplicates and empty lines.

Instructions

Sort Lines. Sort the lines of a text block by a chosen order and type, with optional duplicate and empty-line removal. sortType picks the key: 'alphabetical' (locale-aware), 'numeric' (parses leading number), 'length' (byte length), 'date' (parsed timestamp), 'random' (shuffle), or 'reverse' (invert input order). Use this to order lines; use text_duplicate_line_remover when you only need dedupe with original order preserved, and text_randomizer for richer shuffling by word/character/sentence. Pure local compute: read-only, non-destructive, idempotent (except sortType=random), offline, and rate-limited (60 requests/min for anonymous callers). Returns the sorted text plus before/after line statistics and the effective options.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
textYesNewline-separated text to sort; each line is one element.
sortTypeNoSort key. random shuffles; reverse inverts input order and ignores sortOrder.alphabetical
sortOrderNoDirection for alphabetical/numeric/length/date; ignored by random and reverse.asc
caseSensitiveNoWhen true, alphabetical sort and dedupe are case-sensitive; when false they fold case.
removeEmptyNoDrop blank or whitespace-only lines before sorting.
removeDuplicatesNoRemove duplicate lines (keeping first occurrence) before sorting.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
successNoAlways true on success.
resultNoThe sorted lines joined by newlines.
statsNoLine metrics before and after processing.
optionsNoThe effective settings applied.
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint, destructiveHint, idempotentHint. Description adds crucial behavioral context: 'Pure local compute: read-only, non-destructive, idempotent (except sortType=random), offline, and rate-limited (60 requests/min)' and describes output format with statistics and options.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Every sentence contributes: purpose, usage guidance, behavioral notes, output summary, rate limiting. Front-loaded with primary function, no redundancy, appropriate length for complexity.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With output schema present, description appropriately omits return value details but still mentions output content. Covers all aspects: purpose, when to use, behavioral nuances, parameter semantics, and constraints (rate limit, offline). Fully adequate for the tool's complexity.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema has 100% coverage but description adds significant value by explaining each sortType option (e.g., 'alphabetical (locale-aware)', 'numeric (parses leading number)') and noting that caseSensitive affects both sorting and deduplication, enriching parameter understanding beyond enum labels.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Clearly states 'Sort lines of a text block' with specific verb and resource. Lists sort type options and differentiates from sibling tools text_duplicate_line_remover and text_randomizer, establishing its unique purpose.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly says 'Use this to order lines' and provides alternative tools for deduplication (text_duplicate_line_remover) and richer shuffling (text_randomizer), giving clear guidance on when to use this tool versus alternatives.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Jambozx/onlinecybertools-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server