Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/PrefectHQ/fastmcp
/ functions
Functions
13,374 in github.com/PrefectHQ/fastmcp
⨍
Functions
13,374
◇
Types & classes
2,002
↳
Endpoints
150
↓ 1 callers
Method
_require_connected
(self)
fastmcp_slim/fastmcp/client/group.py:169
↓ 1 callers
Method
_require_matching_task_route
Reject a task method whose `Mcp-Name` header disagrees with its body. SEP-2243 mirrors a request's name-shaped field into `Mcp-Name` so
fastmcp_tasks/fastmcp_tasks/extension.py:165
↓ 1 callers
Function
_require_property
Return a copy of *schema* with *property_name* in ``required``.
fastmcp_slim/fastmcp/utilities/json_schema.py:241
↓ 1 callers
Method
_require_route_connected
(self, route: ToolRoute)
fastmcp_slim/fastmcp/client/group.py:177
↓ 1 callers
Method
_require_tasks_capability
Reject a task method from a client that did not declare the extension. SEP-2663: a client issuing `tasks/get`/`tasks/update`/`tasks/cancel`
fastmcp_tasks/fastmcp_tasks/extension.py:145
↓ 1 callers
Method
_required_extensions
Extensions this server contributes when used as a provider. Auto-registerable registrations take precedence over provider defaults, p
fastmcp_slim/fastmcp/server/mixins/extensions.py:28
↓ 1 callers
Method
_rerank
One close-read request over the shortlist: which fits best, and whether each fits at all. Returns the names that fit, best first.
fastmcp_slim/fastmcp/experimental/transforms/jev_search.py:367
↓ 1 callers
Function
_reset_warn_once
Reinstall the shims so every property's warn-once flag starts fresh. Each bridged property closes over its own `warned` flag which persists for
tests/test_compat.py:18
↓ 1 callers
Function
_residual_union_arms
Flatten a (possibly aliased/nested) union into its non-guard arms. Every `InputRequiredResult` arm is dropped at any depth, and aliased union
fastmcp_slim/fastmcp/tools/function_parsing.py:125
↓ 1 callers
Method
_resolve_claimed_result
Finish a claimed `tools/call` result through its owning extension. A modern server may answer `tools/call` with a claimed extension shape
fastmcp_slim/fastmcp/client/client.py:1365
↓ 1 callers
Function
_resolve_docket
Resolve the active Docket from the current context or worker default.
fastmcp_tasks/fastmcp_tasks/input_loop.py:73
↓ 1 callers
Method
_resolve_factory
Resolve a server object or factory function to a server instance. Args: obj: The object that might be a server or factory functio
fastmcp_slim/fastmcp/utilities/mcp_server_config/v1/sources/filesystem.py:169
↓ 1 callers
Function
_resolve_fastmcp_dependencies
Resolve uncalled-for dependencies for a FastMCP function. Sets up the context that uncalled-for's Depends() needs: - A cache for resolved dep
fastmcp_slim/fastmcp/server/dependencies.py:816
↓ 1 callers
Function
_resolve_ref
Follow one local `$ref` (`#/$defs/Name`) into `defs`; otherwise return as-is.
fastmcp_slim/fastmcp/server/transforms/search/base.py:120
↓ 1 callers
Function
_resolve_tool
Resolve the Tool a task ran, from its compound key (tools-only surface).
fastmcp_tasks/fastmcp_tasks/handlers.py:185
↓ 1 callers
Method
_rewrite_prefab_uris
Replace placeholder Prefab URIs with per-tool hashed ones. For each tool whose ``meta.ui.resourceUri`` is the placeholder, reads the
fastmcp_slim/fastmcp/server/server.py:684
↓ 1 callers
Method
_run
Delegate to the child server's call_tool(). fn_key is already set by the parent server before calling this method. A child tool that
fastmcp_slim/fastmcp/server/providers/fastmcp_provider.py:79
↓ 1 callers
Method
_run_body
Validate arguments and execute the body, applying any timeout.
fastmcp_slim/fastmcp/tools/function_tool.py:405
↓ 1 callers
Method
_run_discover_mw
Run discovery through the typed FastMCP middleware hook.
fastmcp_slim/fastmcp/server/low_level.py:324
↓ 1 callers
Method
_run_initialize_mw
( self, fastmcp: FastMCP, ctx: ServerRequestContext, call_next: CallNext,
fastmcp_slim/fastmcp/server/low_level.py:380
↓ 1 callers
Method
_run_monty
Run code in an isolated sandbox session. Isolated so the cancellation handling in `run()` can be exercised without a live `pydantic-m
fastmcp_slim/fastmcp/experimental/transforms/code_mode.py:286
↓ 1 callers
Method
_same_origin
(self, request: Request)
fastmcp_slim/fastmcp/cli/apps_dev_security.py:88
↓ 1 callers
Function
_sample
()
scripts/benchmark_http_startup.py:116
↓ 1 callers
Method
_scope_stream_id
(self, stream_id: StreamId)
fastmcp_slim/fastmcp/server/session_scoped_event_store.py:26
↓ 1 callers
Method
_sealing_server
A one-round guard that seals a request_state on its first ask, under an explicit key so state can be replayed across instances.
tests/server/test_mrtr_guards.py:1135
↓ 1 callers
Method
_seam_span
Open the per-request SERVER span at the middleware seam. The removed SDK ``OpenTelemetryMiddleware`` produced one SERVER span per inb
fastmcp_slim/fastmcp/server/low_level.py:278
↓ 1 callers
Method
_search
(self, tools: Sequence[Tool], query: str)
fastmcp_slim/fastmcp/server/transforms/search/regex.py:42
↓ 1 callers
Method
_search
(self, tools: Sequence[Tool], query: str)
fastmcp_slim/fastmcp/server/transforms/search/bm25.py:133
↓ 1 callers
Function
_send_cancel
Send `tasks/cancel` to cooperatively cancel a task.
fastmcp_tasks/fastmcp_tasks/client.py:119
↓ 1 callers
Function
_send_images
Send post with images using the client's send_images method.
examples/atproto_mcp/src/atproto_mcp/_atproto/_posts.py:261
↓ 1 callers
Method
_send_missing_auth
Send 401 response for missing authentication (RFC 6750 §3.1 compliant). When a request lacks any authentication information, per RFC 6750 §3.
fastmcp_slim/fastmcp/server/auth/middleware.py:90
↓ 1 callers
Function
_send_update
Send `tasks/update` delivering the caller's answers to a parked task.
fastmcp_tasks/fastmcp_tasks/client.py:101
↓ 1 callers
Method
_serialize_payload
(self, context: MiddlewareContext[Any])
fastmcp_slim/fastmcp/server/middleware/logging.py:33
↓ 1 callers
Method
_serialize_query_params
Serialize query parameter values according to their OpenAPI style/explode settings. By default (style=form, explode=true), list valu
fastmcp_slim/fastmcp/utilities/openapi/director.py:319
↓ 1 callers
Function
_serialize_requests
Dump each request to the wire payload surfaced for the client to answer.
fastmcp_tasks/fastmcp_tasks/input_loop.py:63
↓ 1 callers
Function
_serving_auth
Return the auth provider and MCP path of the HTTP app serving this request. FastMCP's HTTP app factories store the provider they were built with,
fastmcp_slim/fastmcp/contrib/component_manager/component_manager.py:99
↓ 1 callers
Method
_session_runner
Background task that manages the actual session lifecycle. This task runs in the background and: 1. Establishes the transpor
fastmcp_slim/fastmcp/client/client.py:1138
↓ 1 callers
Method
_set_auth
(self, auth: httpx2.Auth | Literal["oauth"] | str | None)
fastmcp_slim/fastmcp/client/transports/http.py:102
↓ 1 callers
Method
_set_consent_state_cookie
Record that this browser received `csrf_token`, under its own name. The cookie is what makes the double-submit check meaningful: the token
fastmcp_slim/fastmcp/server/auth/oauth_proxy/consent.py:248
↓ 1 callers
Function
_set_token
Set the access token in the auth context var.
tests/server/versioning/test_visibility_version_fallback.py:31
↓ 1 callers
Function
_set_visibility_metadata
Set visibility state in tool metadata. This uses the same metadata format as the Visibility transform, so tools marked here will be filtered
fastmcp_slim/fastmcp/tools/tool_transform.py:945
↓ 1 callers
Method
_setup_handlers
Register core MCP protocol handlers with the low-level SDK server.
fastmcp_slim/fastmcp/server/mixins/mcp_operations.py:110
↓ 1 callers
Method
_setup_proxy_ping_handler
(self)
fastmcp_slim/fastmcp/server/providers/proxy.py:1496
↓ 1 callers
Method
_shared_context_lifespan
Set up the process-level ``SharedContext`` and server ContextVar. ``SharedContext`` backs app-scoped ``Shared()`` dependencies and is
fastmcp_slim/fastmcp/server/mixins/lifespan.py:55
↓ 1 callers
Function
_should_skip
(example: CodeExample)
tests/docs/test_doc_examples.py:50
↓ 1 callers
Method
_should_validate_host
(self, scope: Scope)
fastmcp_slim/fastmcp/server/http.py:281
↓ 1 callers
Method
_should_validate_origin
(self, scope: Scope, host: str)
fastmcp_slim/fastmcp/server/http.py:288
↓ 1 callers
Method
_show_consent_page
Display consent page or auto-approve/deny based on cookies.
fastmcp_slim/fastmcp/server/auth/oauth_proxy/consent.py:430
↓ 1 callers
Method
_single_pass
Rank and filter in one round trip. Chunks run concurrently; their probabilities are not comparable, so the merged order is a heuristic.
fastmcp_slim/fastmcp/experimental/transforms/jev_search.py:316
↓ 1 callers
Function
_single_pass_optimize
Optimize JSON schemas in a single traversal for better performance. This function combines three schema cleanup operations that would normal
fastmcp_slim/fastmcp/utilities/json_schema.py:615
↓ 1 callers
Function
_slugify
Convert text to a URL-friendly slug format. Only contains lowercase letters, uppercase letters, numbers, and underscores.
fastmcp_slim/fastmcp/server/providers/openapi/components.py:142
↓ 1 callers
Function
_spec_files_for_provider
Find all spec files for a given provider.
tests/utilities/json_schema_type/test_real_world_schemas.py:239
↓ 1 callers
Function
_stamp_prefab_marker
Mark a tool as needing a Prefab renderer resource. Sets ``meta["ui"]["resourceUri"]`` to a placeholder URI. The server recognizes the placeho
fastmcp_slim/fastmcp/server/providers/local_provider/decorators/tools.py:65
↓ 1 callers
Function
_start_user_server
Start the user's MCP server as a subprocess on mcp_port.
fastmcp_slim/fastmcp/cli/apps_dev.py:1713
↓ 1 callers
Function
_stdio_transport_connect_task
A standalone connection task for a stdio transport. It is not a part of the StdioTransport class to ensure that the connection task does not hold
fastmcp_slim/fastmcp/client/transports/stdio.py:237
↓ 1 callers
Method
_stop_session
Stop the session. A last exit passes the session it held, and the stop is skipped if another context now uses it; a forced stop takes whatever
fastmcp_slim/fastmcp/client/client.py:1098
↓ 1 callers
Method
_store_cache_entry
Store a document in the bounded process-local cache.
fastmcp_slim/fastmcp/server/auth/cimd.py:226
↓ 1 callers
Function
_stream_and_cleanup
(resp: httpx2.Response)
fastmcp_slim/fastmcp/cli/apps_dev.py:1589
↓ 1 callers
Function
_strip_discriminator
Recursively remove OpenAPI ``discriminator`` keys from a schema. Pydantic emits ``discriminator.mapping`` with values like ``#/$defs/ClassNam
fastmcp_slim/fastmcp/utilities/json_schema.py:212
↓ 1 callers
Function
_strip_titles
Recursively drop every "title" key, the one difference that's genuinely cosmetic. A hand-written SDK schema has no title anywhere; FastMCP derive
tests/docs/test_upgrade_guide_equivalence.py:49
↓ 1 callers
Method
_submit_consent
Handle consent approval/denial, set cookies, and redirect appropriately.
fastmcp_slim/fastmcp/server/auth/oauth_proxy/consent.py:595
↓ 1 callers
Function
_summarize
(samples: list[Sample])
scripts/benchmark_http_startup.py:133
↓ 1 callers
Function
_summary
The first paragraph of a tool's description, or its name when it has none.
fastmcp_slim/fastmcp/experimental/transforms/jev_search.py:60
↓ 1 callers
Function
_sync_result_to_wire
Serialize a synchronous ToolResult into the inlined task wire shape.
tests/tasks/server/test_task_return_types.py:33
↓ 1 callers
Function
_terminate_process
Terminate a subprocess and all its children. Sends SIGTERM to the process group first for graceful shutdown, then falls back to SIGKILL if th
fastmcp_slim/fastmcp/cli/run.py:352
↓ 1 callers
Function
_test_provider
Run json_schema_to_type on every schema for one provider.
tests/utilities/json_schema_type/test_real_world_schemas.py:262
↓ 1 callers
Function
_text_within_limit
Check the total length of every key and scalar value in *schema*. Inlining shares scalar objects rather than copying them, so a repeated long
fastmcp_slim/fastmcp/utilities/json_schema.py:162
↓ 1 callers
Method
_to_server_and_underlying_transport
Turn the transforming server into a FastMCP proxy and return its transport.
fastmcp_slim/fastmcp/mcp_config.py:123
↓ 1 callers
Function
_toast_result
()
examples/apps/media_picker/media_picker_server.py:261
↓ 1 callers
Function
_tool_skill_section
Generate a SKILL.md section for a single tool.
fastmcp_slim/fastmcp/cli/generate.py:567
↓ 1 callers
Function
_tool_table
( tools: list[dict], *, ranked: bool = False, show_params: bool = False )
examples/search/client_regex.py:47
↓ 1 callers
Function
_tool_table
( tools: list[dict], *, ranked: bool = False, show_params: bool = False )
examples/search/client_bm25.py:47
↓ 1 callers
Function
_tool_table
( tools: list[dict], *, ranked: bool = False, show_params: bool = False )
examples/code_mode/client.py:50
↓ 1 callers
Function
_tool_title
(tool: dict[str, Any])
fastmcp_slim/fastmcp/cli/apps_dev.py:1072
↓ 1 callers
Function
_tools_to_json
Serialize a list of tools to JSON-safe dicts.
fastmcp_slim/fastmcp/cli/client.py:473
↓ 1 callers
Method
_translate_scopes_from_idp
Strip ``{identifier_uri}/`` from custom API scopes Azure echoes back. Inverse of :meth:`_prefix_scopes_for_azure`. Azure echoes the prefixed
fastmcp_slim/fastmcp/server/auth/providers/azure.py:447
↓ 1 callers
Function
_ttl_ms
The task TTL in milliseconds, from Docket's execution TTL (server-set).
fastmcp_tasks/fastmcp_tasks/handlers.py:111
↓ 1 callers
Function
_unclamp_logger
Remove all clamped log filters from the logger.
fastmcp_slim/fastmcp/utilities/logging.py:250
↓ 1 callers
Method
_unflatten_arguments
Maps flat arguments back to their OpenAPI locations using the parameter map. The parameter map is the only source of argument locati
fastmcp_slim/fastmcp/utilities/openapi/director.py:228
↓ 1 callers
Function
_union_enum_values
Enum values of a union, only when every non-null branch is enumerated. A union such as `Literal["a"] | int` has no closed set of valid values, so
fastmcp_slim/fastmcp/server/transforms/search/base.py:226
↓ 1 callers
Function
_union_type
(branches: list[Any])
fastmcp_slim/fastmcp/server/transforms/search/base.py:83
↓ 1 callers
Function
_unread
Allow the response body to be read on the client side.
tests/utilities/httpx2_mock.py:79
↓ 1 callers
Method
_unscope_stream_id
(self, stream_id: StreamId)
fastmcp_slim/fastmcp/server/session_scoped_event_store.py:29
↓ 1 callers
Function
_unwrap_result
Extract the logical return value from a ToolResult.
tests/experimental/transforms/test_code_mode_discovery.py:17
↓ 1 callers
Function
_unwrap_tool_result
Convert a ToolResult for use in the sandbox. - Output schema present → structured_content dict (matches the schema) - Otherwise → concatenate
fastmcp_slim/fastmcp/experimental/transforms/code_mode.py:114
↓ 1 callers
Function
_update_all_lists
Actions to update all three status lists from a tool result.
examples/apps/approvals/approvals_server.py:208
↓ 1 callers
Function
_url_match
Full URL match with query-parameter order insensitivity. A ``re.Pattern`` matches against the string form of the received URL, mirroring ``py
tests/utilities/httpx2_mock.py:40
↓ 1 callers
Method
_uses_alternate_verification
Patch returned token scopes from the upstream token response. Hugging Face OAuth access tokens are opaque. The userinfo endpoint vali
fastmcp_slim/fastmcp/server/auth/providers/huggingface.py:277
↓ 1 callers
Method
_uses_alternate_verification
Whether this provider verifies a different token than the access token. When True, ``load_access_token`` patches the validated result with
fastmcp_slim/fastmcp/server/auth/oauth_proxy/proxy.py:2051
↓ 1 callers
Function
_uses_default_multipart_encoding
Explicit defaults serialize like omitted encoding; overrides stay unchanged.
fastmcp_slim/fastmcp/utilities/openapi/director.py:31
↓ 1 callers
Method
_valid_host
(self, headers: Headers)
fastmcp_slim/fastmcp/cli/apps_dev_security.py:58
↓ 1 callers
Function
_validate
()
fastmcp_slim/fastmcp/cli/cimd.py:170
↓ 1 callers
Method
_validate_issuer
Check a token's `iss` claim against the configured issuer(s). Subclasses override this to implement provider-specific rules, such as
fastmcp_slim/fastmcp/server/auth/providers/jwt.py:468
↓ 1 callers
Method
_validate_task_extension_registered
Fail loudly if a task-enabled tool has no tasks extension registered. `task=True` on a tool is only an intent declaration; the engine that ru
fastmcp_slim/fastmcp/server/mixins/lifespan.py:120
↓ 1 callers
Function
_validation_error_summary
Keep counts and built-in codes, never input-derived validation details.
fastmcp_slim/fastmcp/server/server.py:137
↓ 1 callers
Function
_verified_links
( links: list[MediaLink], )
examples/apps/media_picker/media_picker_server.py:243
↓ 1 callers
Method
_verify_consent_binding_cookie
Verify the consent binding for a specific transaction.
fastmcp_slim/fastmcp/server/auth/oauth_proxy/consent.py:409
↓ 1 callers
Function
_verify_youtube
( client: httpx2.AsyncClient, link: MediaLink, video_id: str )
examples/apps/media_picker/media_picker_server.py:105
↓ 1 callers
Function
_version_key
(version: str)
scripts/rank_issues.py:723
↓ 1 callers
Function
_wait_for_port
Poll until a TCP connection to `host:port` is accepted, or raise on timeout.
fastmcp_slim/fastmcp/utilities/tests.py:154
← previous
next →
1,901–2,000 of 13,374, ranked by callers