MCPcopy Index your code
hub / github.com/github/github-mcp-server / WithCursorPagination

Function WithCursorPagination

pkg/github/params.go:369–383  ·  view source on GitHub ↗

WithCursorPagination adds only cursor-based pagination parameters to a tool (no page parameter).

(schema *jsonschema.Schema)

Source from the content-addressed store, hash-verified

367
368// WithCursorPagination adds only cursor-based pagination parameters to a tool (no page parameter).
369func WithCursorPagination(schema *jsonschema.Schema) *jsonschema.Schema {
370 schema.Properties["perPage"] = &jsonschema.Schema{
371 Type: "number",
372 Description: "Results per page for pagination (min 1, max 100)",
373 Minimum: jsonschema.Ptr(1.0),
374 Maximum: jsonschema.Ptr(100.0),
375 }
376
377 schema.Properties["after"] = &jsonschema.Schema{
378 Type: "string",
379 Description: "Cursor for pagination. Use the cursor from the previous response.",
380 }
381
382 return schema
383}
384
385type PaginationParams struct {
386 Page int

Callers 6

GetFileBlameFunction · 0.85
ListIssuesFunction · 0.85
ListDiscussionsFunction · 0.85
GetDiscussionCommentsFunction · 0.85
ListDependabotAlertsFunction · 0.85
IssueDependencyReadFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected