Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/PrefectHQ/fastmcp
/ functions
Functions
17,519 in github.com/PrefectHQ/fastmcp
⨍
Functions
17,519
◇
Types & classes
2,390
↳
Endpoints
196
↓ 7 callers
Function
_prune_param
Return a new schema with *param* removed from `properties`, `required`, and (if no longer referenced) `$defs`.
fastmcp_slim/fastmcp/utilities/json_schema.py:672
↓ 7 callers
Method
_put
(self, key: str, value: BaseModel | Mapping[str, Any], ttl: float)
fastmcp_events/fastmcp_events/webhook_delivery.py:248
↓ 7 callers
Function
_schema_type_label
Return a human-readable type label for a property schema.
fastmcp_slim/fastmcp/cli/generate.py:719
↓ 7 callers
Method
_time_operation
Helper method to time any operation.
fastmcp_slim/fastmcp/server/middleware/timing.py:91
↓ 7 callers
Method
aclose
(self)
fastmcp_slim/fastmcp/cli/deploy/horizon_client.py:188
↓ 7 callers
Method
authorize
Start OAuth transaction and route through consent interstitial. Flow: 1. Validate client's resource matches server's resource URL (se
fastmcp_slim/fastmcp/server/auth/oauth_proxy/proxy.py:1226
↓ 7 callers
Function
build_cache_hints
Build the per-method `CacheHint` map for the SDK low-level server. `cache_ttl` is in seconds and is converted to the wire's milliseconds. When
fastmcp_slim/fastmcp/server/caching.py:26
↓ 7 callers
Function
build_id_server
Server whose cart tools take an explicit `session_id: SessionId`.
tests/server/test_session_provider.py:90
↓ 7 callers
Function
cancel_task
Call the `tasks/cancel` handler within the given auth scope.
tests/tasks/task_helpers.py:163
↓ 7 callers
Function
client
(server: FastMCP)
tests/events/test_redis_log.py:47
↓ 7 callers
Function
client_supports_extension
Check whether the connected client supports a given MCP extension. Inspects the ``extensions`` capability the client declared, read from ``se
fastmcp_slim/fastmcp/server/low_level.py:117
↓ 7 callers
Method
close
(self)
examples/smart_home/src/smart_home/fire_tv/client.py:91
↓ 7 callers
Function
combine_lifespans
Combine multiple lifespans into a single lifespan. Useful when mounting FastMCP into FastAPI and you need to run both your app's lifespan and
fastmcp_slim/fastmcp/utilities/lifespan.py:12
↓ 7 callers
Function
combined
(app: AppT)
fastmcp_slim/fastmcp/utilities/lifespan.py:47
↓ 7 callers
Method
connect
()
tests/client/test_stdio.py:580
↓ 7 callers
Function
create_jwt
Create a test JWT token.
tests/utilities/test_auth.py:15
↓ 7 callers
Function
create_oauth_callback_server
Create an OAuth callback server. Args: port: The port to run the server on callback_path: The path to listen for OAuth redir
fastmcp_slim/fastmcp/client/oauth_callback.py:114
↓ 7 callers
Function
create_openapi_server
Helper to create a FastMCP server with OpenAPIProvider.
tests/server/providers/openapi/test_openapi_features.py:26
↓ 7 callers
Method
create_server
(self, include_tags=None, exclude_tags=None)
tests/server/providers/test_local_provider_resources.py:688
↓ 7 callers
Method
create_server
(self, include_tags=None, exclude_tags=None)
tests/server/providers/test_local_provider_resources.py:897
↓ 7 callers
Method
create_server
(self, include_tags=None, exclude_tags=None)
tests/server/providers/test_local_provider_prompts.py:423
↓ 7 callers
Method
create_server
(self, include_tags=None, exclude_tags=None)
tests/server/providers/local_provider_tools/test_tags.py:42
↓ 7 callers
Function
delegate_span
Create an INTERNAL span for provider delegation. Used by FastMCPProvider when delegating to mounted servers. Automatically records any except
fastmcp_slim/fastmcp/server/telemetry.py:445
↓ 7 callers
Method
end
Invalidate the session — delete its one key and all of its state. After this the id no longer resolves through `get_session`. This is
fastmcp_slim/fastmcp/server/sessions.py:294
↓ 7 callers
Function
extract_trace_context
Extract trace context from an MCP request meta dict. If already in a valid trace (e.g., from HTTP propagation), the existing trace context is
fastmcp_slim/fastmcp/telemetry.py:306
↓ 7 callers
Method
finish
(self)
tests/downstream/_harness.py:225
↓ 7 callers
Function
form
(token: str, include_client_id: bool = False)
tests/server/auth/test_private_key_jwt_auth.py:71
↓ 7 callers
Function
generate_cursor_deeplink
Generate a Cursor deeplink for installing the MCP server. Args: server_name: Name of the server server_config: Server configurati
fastmcp_slim/fastmcp/cli/install/cursor.py:22
↓ 7 callers
Method
get_calls
Get all recorded calls for a specific method or hook. Args: method: The method to filter by (e.g. "tools/list")
tests/server/middleware/test_middleware.py:48
↓ 7 callers
Function
get_fastmcp_meta
Extract FastMCP metadata from a function, handling bound methods and wrappers.
fastmcp_slim/fastmcp/decorators.py:29
↓ 7 callers
Method
get_prompt
Get prompt by transformed name with all transforms applied. Note: This method does NOT filter disabled components. The Server (FastMC
fastmcp_slim/fastmcp/server/providers/base.py:438
↓ 7 callers
Method
get_resource
(uri: str, version=None)
tests/server/providers/test_transforming_provider.py:300
↓ 7 callers
Function
get_skill_manifest
Get the manifest for a specific skill. Args: client: Connected FastMCP client skill_name: Name of the skill Returns:
fastmcp_slim/fastmcp/utilities/skills.py:110
↓ 7 callers
Method
get_token_expiry
(self)
fastmcp_slim/fastmcp/client/auth/oauth.py:169
↓ 7 callers
Function
install_goose
Install FastMCP server in Goose via deeplink. Args: file: Path to the server file. server_object: Optional server object name (fo
fastmcp_slim/fastmcp/cli/install/goose.py:85
↓ 7 callers
Function
intercept_streams
Route every `events/stream` request through `handle`.
tests/events/test_push_lifecycle.py:64
↓ 7 callers
Function
is_docket_available
Check if a compatible pydocket (>= 0.19.0) is installed and importable. Three things have to be true for fastmcp's task features to work: 1
fastmcp_slim/fastmcp/server/dependencies.py:310
↓ 7 callers
Method
list_resource_templates
List resource templates with all transforms applied. Components may be marked as disabled but are NOT filtered here.
fastmcp_slim/fastmcp/server/providers/base.py:385
↓ 7 callers
Function
make_server
( log: list[dict[str, Any]], subscribed: anyio.Event | None = None )
tests/events/test_cli.py:36
↓ 7 callers
Function
make_server
(url: str, **extension_kwargs)
tests/events/test_redis_log.py:39
↓ 7 callers
Function
nested_union_schema
Each level is a union of three references to the level below.
tests/utilities/test_json_schema_expansion.py:14
↓ 7 callers
Function
node
(tag, text, className)
status-site/app.js:43
↓ 7 callers
Function
non_rotating_upstream
Upstream that keeps the same refresh token, like Cognito.
tests/server/auth/oauth_proxy/test_single_use.py:82
↓ 7 callers
Method
on_message
(self, context: MiddlewareContext, call_next: CallNext)
tests/server/middleware/test_message_visibility.py:32
↓ 7 callers
Function
paginate_request
One page of `items` for a list request, or all of them when `page_size` is None. An invalid cursor raises an `MCPError` with `INVALID_PARAMS`, so
fastmcp_slim/fastmcp/utilities/pagination.py:93
↓ 7 callers
Function
parse_env_var
Parse environment variable string in format KEY=VALUE.
fastmcp_slim/fastmcp/cli/install/shared.py:166
↓ 7 callers
Function
post
( event: str, payload: dict, secret="s3cret", delivery="d-1", path="/g
tests/test_floor_receiver.py:79
↓ 7 callers
Function
pr
(**overrides)
tests/test_public_triage.py:41
↓ 7 callers
Function
public_result_meta
Strip FastMCP's internal bookkeeping out of component meta. Component `meta` carries private entries under the `fastmcp` namespace (e.g. `_in
fastmcp_slim/fastmcp/utilities/components.py:39
↓ 7 callers
Function
record
(operation: str, ctx: Context)
tests/server/providers/proxy/test_proxy_request_meta.py:49
↓ 7 callers
Method
replay_events_after
Replay events that occurred after the specified event ID. Args: last_event_id: The ID of the last event the client received
fastmcp_slim/fastmcp/server/event_store.py:170
↓ 7 callers
Method
resource
Decorator to register a function as a resource. The function will be called when the resource is read to generate its content. The fu
fastmcp_slim/fastmcp/server/server.py:2353
↓ 7 callers
Function
result_value
The `"result"` field of a direct `Tool.run()` call's structured content. `structured_content` is `dict | None` on `ToolResult` (a bare function t
tests/server/test_session_provider.py:39
↓ 7 callers
Function
run
(command: list[str], **kwargs: object)
tests/cli/deploy/test_credentials.py:242
↓ 7 callers
Method
run
( self, code: str, *, inputs: dict[str, Any] | None = None, external_f
tests/experimental/transforms/test_code_mode.py:72
↓ 7 callers
Function
run_asgi_lifespan
Run an ASGI application's lifespan, driving the protocol as a real server does. The application's lifespan runs inside a dedicated task for the w
fastmcp_slim/fastmcp/utilities/asgi_transport.py:224
↓ 7 callers
Function
secret_of
(key: bytes)
tests/pbt/test_webhook_signing.py:42
↓ 7 callers
Method
set_message
Update the progress status message.
fastmcp_slim/fastmcp/server/dependencies.py:1366
↓ 7 callers
Function
sign
The `v1,` signature of one delivery.
fastmcp_events/fastmcp_events/webhooks.py:55
↓ 7 callers
Function
skills_client
(server: FastMCP)
tests/skills/test_directory_provider.py:25
↓ 7 callers
Function
sync_skills
Download all available skills from a server. Args: client: Connected FastMCP client target_dir: Directory where skill folders wil
fastmcp_slim/fastmcp/utilities/skills.py:264
↓ 7 callers
Function
tick_server
A server with a `tick` event type, for a test to give a reader.
tests/events/test_extension.py:89
↓ 7 callers
Function
to_mcp_error
Translate a FastMCP exception into a wire-format ``MCPError``. Central mapping from FastMCP's public exception types to the JSON-RPC error co
fastmcp_slim/fastmcp/exceptions.py:117
↓ 7 callers
Method
to_mcp_resource_contents
Convert to MCP resource contents type. Args: uri: The URI of the resource (required by MCP types) Returns: T
fastmcp_slim/fastmcp/resources/base.py:91
↓ 7 callers
Method
to_mcp_result
( self, )
fastmcp_slim/fastmcp/tools/base.py:231
↓ 7 callers
Method
to_transport
(self)
tests/test_mcp_config.py:105
↓ 7 callers
Function
unsubscribe_webhook
Send one `events/unsubscribe` request: stop a webhook subscription now. Not needed for correctness: a subscription that is not refreshed lapses
fastmcp_events/fastmcp_events/subscription.py:686
↓ 7 callers
Method
verify_token
Verify a Hugging Face OAuth token using the userinfo endpoint.
fastmcp_slim/fastmcp/server/auth/providers/huggingface.py:75
↓ 6 callers
Method
__init__
Initialize a Stdio transport. Args: command: The command to run (e.g., "python", "node", "uvx") args: The ar
fastmcp_slim/fastmcp/client/transports/stdio.py:33
↓ 6 callers
Method
__init__
( self, reload: bool = False, supporting_files: Literal["template", "resources"] = "te
fastmcp_slim/fastmcp/server/providers/skills/vendor_providers.py:54
↓ 6 callers
Method
_cached_fetch
Serve a cacheable request through the response cache. Mirrors the SDK Client's list caching while also supporting cacheable extension
fastmcp_slim/fastmcp/client/client.py:1412
↓ 6 callers
Function
_call_over_http
(mcp: FastMCP | None = None, **http_app_kwargs: Any)
tests/server/telemetry/test_span_links.py:72
↓ 6 callers
Function
_claude_code_config
Build a minimal ~/.claude.json structure.
tests/cli/test_discovery.py:282
↓ 6 callers
Method
_collection_cookie_route
(self, explode: bool | None)
tests/utilities/openapi/test_director.py:1595
↓ 6 callers
Function
_decode
(value: Any)
fastmcp_tasks/fastmcp_tasks/input_store.py:127
↓ 6 callers
Function
_events_extension
(client: Client)
fastmcp_events/fastmcp_events/subscription.py:428
↓ 6 callers
Method
_exists
Whether a session record exists for this `(principal, session_id)`. True only once `create_session` has written the creation marker. A raw
fastmcp_slim/fastmcp/server/sessions.py:237
↓ 6 callers
Function
_find_session_manager
(app: StarletteWithLifespan)
tests/server/http/test_session_idle_timeout.py:37
↓ 6 callers
Method
_forward_authorization_server_metadata
Return the upstream authorization server metadata, cached per provider. The first URL in ``metadata_urls`` that answers 2xx with a JSON body
fastmcp_slim/fastmcp/server/auth/auth.py:669
↓ 6 callers
Function
_get_auth_context
Get auth context for the current request. Returns a tuple of (skip_auth, token) where: - skip_auth=True means auth checks should be skipped (
fastmcp_slim/fastmcp/server/server.py:333
↓ 6 callers
Function
_get_auth_partition_key
Return a stable, hashed identifier for the current access token. Cache entries are partitioned by access token so that responses filtered by
fastmcp_slim/fastmcp/server/middleware/caching.py:682
↓ 6 callers
Method
_get_client
Gets a client instance by calling the sync or async factory.
fastmcp_slim/fastmcp/server/providers/proxy.py:420
↓ 6 callers
Method
_get_visibility_rules
Load visibility rule dicts from session state.
fastmcp_slim/fastmcp/server/context.py:1233
↓ 6 callers
Function
_hash_schema
Generate a deterministic hash for schema caching.
fastmcp_slim/fastmcp/utilities/json_schema_type.py:538
↓ 6 callers
Function
_issue_refresh_token
A refresh token on `user`'s grant, with its own jti like a real exchange. `names_grant=False` mints one without the `grant` claim, as tokens issu
tests/server/auth/oauth_proxy/test_revocation.py:345
↓ 6 callers
Method
_load_raw
Read the session's full stored dict, or `None` when the key is unset.
fastmcp_slim/fastmcp/server/sessions.py:215
↓ 6 callers
Function
_loop_thread_id
()
tests/tools/test_tool_run_in_thread.py:22
↓ 6 callers
Function
_make_add_server
()
tests/test_mcp_config.py:675
↓ 6 callers
Function
_make_call_tool_cache_key
Make a cache key for a tool call using protocol era, name, version, and arguments.
fastmcp_slim/fastmcp/server/middleware/caching.py:715
↓ 6 callers
Function
_make_upstream_token_set
Create an UpstreamTokenSet with optional id_token.
tests/server/auth/test_oidc_proxy_token.py:47
↓ 6 callers
Method
_maybe_cull_expired_state
Reap expired entries from the default on-disk store, at most hourly. Called on the OAuth write paths, so a long-running server keeps its
fastmcp_slim/fastmcp/server/auth/oauth_proxy/proxy.py:814
↓ 6 callers
Function
_normalize_server_entry
Normalize editor-specific server config fields to MCPConfig format. Handles two known differences: - Claude Code uses ``type`` where MCPConfi
fastmcp_slim/fastmcp/cli/discovery.py:68
↓ 6 callers
Method
_prepare_scopes_for_token_exchange
Prepare scopes for Azure authorization code exchange. Azure requires scopes during token exchange (AADSTS28003 error if missing). Azu
fastmcp_slim/fastmcp/server/auth/providers/azure.py:533
↓ 6 callers
Function
_proxy_upstream_error
Report an unreachable backend the same way however the failure arrived. Depending on where the dead connection is noticed, the proxy sees either
fastmcp_slim/fastmcp/server/providers/proxy.py:163
↓ 6 callers
Function
_query_scalar_to_str
Convert a scalar to its query-string representation. Booleans are lowercased to match JSON/OpenAPI conventions (true/false) rather than Pytho
fastmcp_slim/fastmcp/utilities/openapi/director.py:32
↓ 6 callers
Method
_resolve_ref
Resolves a reference to its target definition.
fastmcp_slim/fastmcp/utilities/openapi/parser.py:161
↓ 6 callers
Method
_respond
(self, schema: dict[str, Any], response: Any)
tests/client/test_elicitation.py:947
↓ 6 callers
Function
_sanitize_name
Convert string to valid Python identifier.
fastmcp_slim/fastmcp/utilities/json_schema_type.py:1256
↓ 6 callers
Function
_sanitize_untrusted_text
Escape rich markup and encode control chars for terminal-safe output.
fastmcp_slim/fastmcp/cli/client.py:574
↓ 6 callers
Function
_scan_goose
Scan Goose config for MCP server extensions. Goose uses YAML (``~/.config/goose/config.yaml``) with a different schema — MCP servers are defi
fastmcp_slim/fastmcp/cli/discovery.py:290
← previous
next →
601–700 of 17,519, ranked by callers