Skip to content

Commit 2110528

Browse files
document restrictions for sorting in the search dci jobs tool
1 parent c05ad0f commit 2110528

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

mcp_server/tools/job_tools.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,12 @@ async def search_dci_jobs(
141141
description="search criteria (e.g., ((components.type='ocp') and (components.version='4.19.0')) and ((components.type='storage') and (components.name='my-storage'))"
142142
),
143143
],
144-
sort: Annotated[str, Field(description="Sort criteria")] = "-created_at",
144+
sort: Annotated[
145+
str,
146+
Field(
147+
description="Sort criteria. Use a minus prefix for descending order (e.g., '-created_at'). Only date and numeric fields are sortable: 'created_at', 'updated_at', 'duration'. Text fields like 'name' or 'status' are NOT sortable and will return empty results. Default is '-created_at'."
148+
),
149+
] = "-created_at",
145150
limit: Annotated[
146151
int,
147152
Field(

0 commit comments

Comments
 (0)