Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/PrefectHQ/fastmcp
/ functions
Functions
15,974 in github.com/PrefectHQ/fastmcp
⨍
Functions
15,974
◇
Types & classes
2,233
↳
Endpoints
189
Method
test_template_meta_parameter
Test that meta parameter is properly handled.
tests/resources/test_resource_template_meta.py:14
Method
test_template_params_forwarded
(self)
tests/contrib/test_mcp_mixin.py:692
Method
test_template_pattern_follows_a_changed_uri_template
(self)
tests/resources/test_resource_template.py:867
Method
test_template_read_allows_nested_path
(self, skill_with_secret: Path)
tests/server/providers/test_skills_provider.py:1104
Method
test_template_read_allows_within_bounds_dotdot
( self, skill_with_secret: Path )
tests/server/providers/test_skills_provider.py:1109
Method
test_template_read_rejects_escape
( self, skill_with_secret: Path, attack: str )
tests/server/providers/test_skills_provider.py:1070
Method
test_template_tagged_by_transform_is_denied_without_scope
(self)
tests/server/auth/test_authorization.py:1611
Method
test_template_to_resource_conversion
Test that a template can be converted to a resource.
tests/server/providers/test_local_provider_resources.py:156
Method
test_template_toggle_disabled
(self)
tests/server/providers/test_local_provider_resources.py:1010
Method
test_template_toggle_enabled
(self)
tests/server/providers/test_local_provider_resources.py:995
Method
test_template_uri_params_subset_of_function_params
Test validation rule: URI parameters must be a subset of function parameters.
tests/resources/test_resource_template.py:100
Method
test_template_uri_validation
Test validation rule: URI template must have at least one parameter.
tests/resources/test_resource_template.py:85
Method
test_template_with_default_params
Test that a template can have default parameters.
tests/server/providers/test_local_provider_resources.py:138
Method
test_template_with_literal_query_is_readable
(self, via: str)
tests/resources/test_resource_template.py:1923
Method
test_template_with_non_ascii_literal_is_readable
Regression: the template was listed but every read returned Not Found.
tests/resources/test_resource_template.py:1763
Method
test_template_with_query_params
Test RFC 6570 query parameters in resource templates.
tests/server/providers/test_local_provider_resources.py:192
Method
test_template_with_varkwargs
Test that a template can have **kwargs.
tests/server/providers/test_local_provider_resources.py:127
Method
test_templated_resource_blocks_path_traversal
(self)
tests/test_upgrade_from_v3.py:349
Method
test_templated_resource_server
(self)
tests/test_upgrade_from_v3.py:96
Method
test_templated_uri_registers_template
( self, prefix, separator, expected_template, expected_name, e
tests/contrib/test_mcp_mixin.py:638
Method
test_templates_match_in_order_of_definition
If a wildcard template is defined first, it will take priority.
tests/server/providers/test_local_provider_resources.py:209
Method
test_templates_shadow_each_other_reorder
If a wildcard template is defined second, it will *not* take priority.
tests/server/providers/test_local_provider_resources.py:227
Method
test_temporary_settings
(self)
tests/utilities/test_tests.py:17
Method
test_temporary_upstream_error_is_preserved
(self, jwt_verifier)
tests/server/auth/oauth_proxy/test_tokens.py:440
Method
test_tenant_and_authority_stored_as_attributes
Test that tenant_id and base_authority are stored for OBO credential creation.
tests/server/auth/providers/test_azure_scopes.py:778
Method
test_tenant_name_with_onmicrosoft_suffix_rejected
( self, memory_storage: MemoryStore, tenant_name: str )
tests/server/auth/providers/test_azure.py:1369
Method
test_text_content_to_mcp
Test converting text ResourceContent to MCP type.
tests/resources/test_function_resources.py:253
Method
test_text_format_is_sent_as_text
A text/* format is embedded as text, not a base64 blob.
tests/utilities/test_types.py:498
Method
test_text_html_response
HTML content type is correctly extracted.
tests/server/providers/openapi/test_openapi_features.py:459
Method
test_text_plain_response
Plain text content type is correctly extracted.
tests/server/providers/openapi/test_openapi_features.py:448
Method
test_texts_refresh_when_a_tool_is_added
(self)
tests/experimental/transforms/test_jev_search.py:358
Function
test_the_apps_own_ui_still_reaches_its_backend
The point of the boundary is the audience, not the tool: a UI calling by identity is not the model, and must still work.
tests/server/transforms/test_model_visibility_boundary.py:126
Function
test_thought_only_response_on_non_tool_path_raises
When the non-tool path receives only thoughts the error message should mention 'thinking/reasoning content'.
tests/client/sampling/handlers/test_google_genai_handler.py:728
Function
test_thought_only_response_on_tool_path_raises
When the response contains ONLY thought parts the tool path should raise a ValueError whose message includes the finish_reason.
tests/client/sampling/handlers/test_google_genai_handler.py:711
Function
test_thought_parts_filtered_on_tool_path
Thought parts should be excluded; only the real text part should appear.
tests/client/sampling/handlers/test_google_genai_handler.py:691
Function
test_thought_with_function_call_keeps_function_call
When thinking parts accompany a function call, only the function call should appear in the content (thought parts filtered out).
tests/client/sampling/handlers/test_google_genai_handler.py:802
Method
test_three_level_nested_prompt_invocation
Test getting prompts from servers mounted 3 levels deep.
tests/server/mount/test_advanced.py:331
Method
test_three_level_nested_resource_invocation
Test reading resources from servers mounted 3 levels deep.
tests/server/mount/test_advanced.py:281
Method
test_three_level_nested_resource_template_invocation
Test reading resource templates from servers mounted 3 levels deep.
tests/server/mount/test_advanced.py:306
Method
test_three_level_nested_tool_invocation
Test invoking tools from servers mounted 3 levels deep.
tests/server/mount/test_advanced.py:256
Method
test_time_invalid
(self, time_format)
tests/utilities/json_schema_type/test_formats.py:154
Method
test_time_valid
(self, time_format)
tests/utilities/json_schema_type/test_formats.py:148
Method
test_timed_out_exit_is_not_held_by_another_tasks_connect
The exiting context must not wait on the session lock: another task can hold it through a reconnect that is slow or never finishes.
tests/client/client/test_client.py:1178
Method
test_timedelta_becomes_seconds
(self)
tests/utilities/test_timeout.py:26
Method
test_timedelta_is_returned_unchanged
(self)
tests/utilities/test_timeout.py:40
Method
test_timedelta_type
(self)
tests/server/providers/local_provider_tools/test_parameters.py:380
Method
test_timedelta_type_parse_int
Test that int input is coerced to timedelta (seconds).
tests/server/providers/local_provider_tools/test_parameters.py:392
Method
test_timeout
(self, sse_server: ASGIServer)
tests/client/test_sse.py:160
Method
test_timeout
(self, streamable_http_server: ASGIServer)
tests/client/test_streamable_http.py:264
Method
test_timeout
(self, fastmcp_server: FastMCP)
tests/client/client/test_timeout.py:12
Method
test_timeout_client_timeout_does_not_override_tool_call_timeout_if_lower
With SSE, the tool call timeout always takes precedence over the client. Note: on Windows, the behavior appears unpredictable.
tests/client/test_sse.py:180
Method
test_timeout_error_converted_to_tool_error
Timeout errors are converted to ToolError by FastMCP.
tests/tools/test_tool_timeout.py:221
Method
test_timeout_error_produces_useful_message
ReadTimeout should surface the actionable timeout message.
tests/server/providers/openapi/test_comprehensive.py:746
Method
test_timeout_error_raises_tool_error
Timeout error is converted to ToolError and logs warning.
tests/tools/test_tool_timeout.py:134
Method
test_timeout_errors_are_not_cached
Test that timeout errors are not cached (transient failures).
tests/server/auth/providers/test_introspection.py:822
Method
test_timeout_from_tool_from_function
Timeout works when using Tool.from_function().
tests/tools/test_tool_timeout.py:147
Method
test_timeout_not_reached_async
Async tool with timeout completes before timeout.
tests/tools/test_tool_timeout.py:46
Method
test_timeout_not_reached_sync
Sync tool with timeout completes before timeout.
tests/tools/test_tool_timeout.py:59
Method
test_timeout_returns_none
Test that timeouts return None.
tests/server/auth/providers/test_introspection.py:287
Method
test_timeout_seconds_initialization
Test timeout seconds initialization.
tests/server/auth/test_oidc_proxy.py:468
Method
test_timeout_tool_call
(self, sse_server: ASGIServer)
tests/client/test_sse.py:168
Method
test_timeout_tool_call
(self, streamable_http_server: ASGIServer)
tests/client/test_streamable_http.py:271
Method
test_timeout_tool_call
(self, fastmcp_server: FastMCP)
tests/client/client/test_timeout.py:22
Method
test_timeout_tool_call_overrides_client_timeout
( self, streamable_http_server: ASGIServer )
tests/client/test_streamable_http.py:276
Method
test_timeout_tool_call_overrides_client_timeout
( self, fastmcp_server: FastMCP )
tests/client/client/test_timeout.py:27
Method
test_timeout_tool_call_overrides_client_timeout_even_if_lower
( self, fastmcp_server: FastMCP )
tests/client/client/test_timeout.py:37
Method
test_timeout_tool_call_overrides_client_timeout_if_lower
( self, sse_server: ASGIServer )
tests/client/test_sse.py:173
Method
test_timeout_with_task_mode
Tool with timeout and task mode can be configured together.
tests/tools/test_tool_timeout.py:174
Method
test_timeout_zero_times_out_immediately
Timeout of 0 times out immediately.
tests/tools/test_tool_timeout.py:162
Method
test_timing_middleware_concurrent_operations
Test timing middleware with concurrent operations.
tests/server/middleware/test_timing.py:260
Method
test_timing_middleware_custom_logger
Test timing middleware with custom logger configuration.
tests/server/middleware/test_timing.py:282
Method
test_timing_middleware_handles_failures
Test that timing middleware measures time even for failed operations.
tests/server/middleware/test_timing.py:216
Method
test_timing_middleware_measures_tool_execution
Test that timing middleware accurately measures tool execution times.
tests/server/middleware/test_timing.py:184
Method
test_title_becomes_valid_class_name
(self)
tests/utilities/json_schema_type/test_generated_classes.py:80
Method
test_title_class_names
(self, title: str, expected: str)
tests/utilities/json_schema_type/test_generated_classes.py:114
Method
test_title_from_field_default_is_kept
(self)
tests/tools/tool/test_title.py:155
Method
test_title_on_optional_parameter_is_kept
(self)
tests/tools/tool/test_title.py:163
Method
test_title_on_optional_parameter_is_kept_with_context
(self)
tests/tools/tool/test_title.py:177
Method
test_title_pruning_preserves_parameter_named_title
Test that a parameter named 'title' is not removed during title pruning. This is a critical edge case - we want to remove title metadata but
tests/utilities/test_json_schema.py:683
Method
test_title_pruning_preserves_title_property_when_type_property_exists
Regression test for #3576: properties dict containing both 'title' and 'type' as parameter names caused the heuristic to treat 'title' as sche
tests/utilities/test_json_schema.py:715
Method
test_title_pruning_with_nested_properties
Test that nested property structures are handled correctly.
tests/utilities/test_json_schema.py:845
Method
test_titled_nullable_object_root_self_reference
(self)
tests/utilities/json_schema_type/test_advanced.py:529
Method
test_titled_root_self_reference_in_items
(self)
tests/utilities/json_schema_type/test_advanced.py:355
Method
test_titled_root_self_reference_in_property_with_extras
(self)
tests/utilities/json_schema_type/test_advanced.py:373
Method
test_titled_root_self_reference_in_union
(self)
tests/utilities/json_schema_type/test_advanced.py:337
Method
test_titled_wrapper_root_recursive_extras
(self, wrapper)
tests/utilities/json_schema_type/test_advanced.py:653
Method
test_to_audio_content
Test conversion to AudioContent.
tests/utilities/test_types.py:392
Method
test_to_audio_content_error
Test error case in to_audio_content.
tests/utilities/test_types.py:414
Method
test_to_audio_content_with_override_mime_type
Test conversion to AudioContent with override MIME type.
tests/utilities/test_types.py:425
Method
test_to_data_uri
Test conversion to data URI.
tests/utilities/test_types.py:254
Function
test_to_directory_overwrite_replaces_the_folder
(tmp_path: Path)
tests/skills/test_skill.py:229
Function
test_to_directory_refuses_a_symlink
(tmp_path: Path)
tests/skills/test_skill.py:303
Function
test_to_directory_requires_a_matching_folder_name
(tmp_path: Path)
tests/skills/test_skill.py:222
Function
test_to_directory_round_trips_through_from_directory
(tmp_path: Path)
tests/skills/test_skill.py:209
Method
test_to_image_content
Test conversion to ImageContent.
tests/utilities/test_types.py:214
Method
test_to_image_content_error
Test error case in to_image_content.
tests/utilities/test_types.py:236
Method
test_to_mcp_blob_contents
Binary content converts to BlobResourceContents with base64.
tests/resources/test_resources.py:184
Method
test_to_mcp_result
Converts to MCP ReadResourceResult with proper structure.
tests/resources/test_resources.py:247
Method
test_to_mcp_result_multiple_contents
Multiple contents all get same URI.
tests/resources/test_resources.py:261
Method
test_to_mcp_result_sets_iserror_and_preserves_content
(self)
tests/tools/tool/test_results.py:82
← previous
next →
14,501–14,600 of 15,974, ranked by callers