MCPcopy Create free account

hub / github.com/anthropics/anthropic-sdk-python / functions

Functions12,824 in github.com/anthropics/anthropic-sdk-python

Methodtest_copy_skip_auth_clears_workspace_and_credentials
(self, respx_mock: MockRouter)
tests/lib/test_google_cloud.py:1012
Methodtest_copy_token_provider_replaces_credentials
(self, respx_mock: MockRouter)
tests/lib/test_google_cloud.py:995
Functiontest_copy_with_auth_token_keeps_the_api_key
(client_cls: _AWSClientClass)
tests/lib/test_aws.py:752
Methodtest_copy_with_different_base_url_exchanges_per_client
`copy(base_url=...)` must not move the parent's token exchange: each client exchanges its assertion at its own host and only ever pres
tests/lib/test_credentials.py:3070
Methodtest_copy_with_same_base_url_shares_token_exchange
A copy targeting the same deployment (here spelled without the trailing slash the client normalises to) keeps sharing the parent's pro
tests/lib/test_credentials.py:3106
Functiontest_copy_x_stainless_helper_header_appends
()
tests/lib/test_bedrock.py:725
Methodtest_copy_x_stainless_helper_header_appends
(self, client: Anthropic)
tests/test_client.py:944
Methodtest_copy_x_stainless_helper_header_appends
(self, async_client: AsyncAnthropic)
tests/test_client.py:2399
Methodtest_copy_x_stainless_helper_header_appends
(self)
tests/lib/test_vertex.py:341
Methodtest_copy_x_stainless_helper_header_appends
(self)
tests/lib/test_vertex.py:862
Methodtest_copy_x_stainless_helper_header_appends
x-stainless-helper accumulates across copies instead of being clobbered.
tests/lib/test_azure.py:113
Methodtest_copy_x_stainless_helper_header_appends
x-stainless-helper accumulates across copies instead of being clobbered.
tests/lib/test_azure.py:182
Methodtest_copy_x_stainless_helper_header_appends
(self)
tests/lib/test_bedrock_mantle.py:403
Methodtest_corrupt_expires_at_does_not_retain_tokens
`_coerce_expires_at` raises in a secret-free frame, but the error propagates through `_call_user_oauth` whose locals hold the creds di
tests/lib/test_credentials.py:5457
Methodtest_corrupt_expires_at_external_profile_does_not_retain_token
Same as above via the no-client_id (externally rotated) path.
tests/lib/test_credentials.py:5481
Methodtest_count_tokens
(self, body: dict[str, Any], raw: bool, spans: Spans, respx_mock: MockRouter)
tests/test_open_telemetry.py:7862
Functiontest_count_tokens_accepts_a_type
(client: Anthropic, respx_mock: MockRouter)
tests/lib/test_output_format_helpers.py:28
Functiontest_count_tokens_merges_the_type_into_an_existing_output_config
(client: Anthropic, respx_mock: MockRouter)
tests/lib/test_output_format_helpers.py:45
Functiontest_count_tokens_output_config_dict_still_works
(client: Anthropic, respx_mock: MockRouter)
tests/lib/test_output_format_helpers.py:79
Functiontest_count_tokens_rejects_a_schema_dict
(client: Anthropic)
tests/lib/test_output_format_helpers.py:60
Functiontest_count_tokens_rejects_a_string
(client: Anthropic)
tests/lib/test_output_format_helpers.py:113
Methodtest_count_tokens_takes_a_tool_object
(self, client: Anthropic, respx_mock: respx.MockRouter)
tests/lib/test_stainless_helpers.py:116
Methodtest_count_tokens_takes_a_tool_object
( self, async_client: AsyncAnthropic, respx_mock: respx.MockRouter )
tests/lib/test_stainless_helpers.py:217
Methodtest_create
(self, message: dict[str, Any], content_mode: str, spans: Spans, respx_mock: MockRouter)
tests/test_open_telemetry.py:7769
Methodtest_create
(self, sync_local_filesystem_tool: BetaLocalFilesystemMemoryTool)
tests/lib/tools/memory_tools/test_filesystem.py:101
Methodtest_create
(self, async_local_filesystem_tool: BetaAsyncLocalFilesystemMemoryTool)
tests/lib/tools/memory_tools/test_filesystem.py:723
Methodtest_create_error_if_file_already_exists
( self, sync_local_filesystem_tool: BetaLocalFilesystemMemoryTool )
tests/lib/tools/memory_tools/test_filesystem.py:125
Methodtest_create_error_if_file_already_exists
( self, async_local_filesystem_tool: BetaAsyncLocalFilesystemMemoryTool )
tests/lib/tools/memory_tools/test_filesystem.py:749
Methodtest_create_has_the_id_of_what_it_created
(self, raw: bool, spans: Spans, respx_mock: MockRouter)
tests/test_open_telemetry.py:7407
Methodtest_create_nested_directories
(self, sync_local_filesystem_tool: BetaLocalFilesystemMemoryTool)
tests/lib/tools/memory_tools/test_filesystem.py:113
Methodtest_create_nested_directories
( self, async_local_filesystem_tool: BetaAsyncLocalFilesystemMemoryTool )
tests/lib/tools/memory_tools/test_filesystem.py:735
Methodtest_create_without_an_id_in_its_response
( self, body: dict[str, Any], spans: Spans, respx_mock: MockRouter )
tests/test_open_telemetry.py:7445
Methodtest_credentials_file_absent_type_is_lenient
Hand-written credentials files without `type` are accepted.
tests/lib/test_credentials.py:324
Methodtest_credentials_file_group_or_other_access_rejected
(self, tmp_path: pathlib.Path, mode: int)
tests/lib/test_credentials.py:907
Methodtest_credentials_file_owner_only_accepted
(self, tmp_path: pathlib.Path)
tests/lib/test_credentials.py:915
Methodtest_credentials_file_symlink_rejected
(self, tmp_path: pathlib.Path)
tests/lib/test_credentials.py:927
Methodtest_credentials_file_wrong_type_raises
(self, tmp_path: pathlib.Path)
tests/lib/test_credentials.py:311
Functiontest_credentials_object_attaches_bearer
(respx_mock: MockRouter)
tests/lib/test_google_cloud.py:495
Methodtest_credentials_only_still_works
(self, caplog: pytest.LogCaptureFixture)
tests/lib/test_credentials.py:5043
Methodtest_credentials_path_override
Config's `credentials_path` field redirects to a custom location.
tests/lib/test_credentials.py:1055
Methodtest_credentials_type_mismatch_does_not_retain_tokens
( self, clean_env: pytest.MonkeyPatch, tmp_path: pathlib.Path )
tests/lib/test_credentials.py:5439
Functiontest_cursor_position_renders_as_a_text_line
()
tests/lib/tools/toolsets/test_computer_pipeline.py:78
Methodtest_custom_env_var
(self, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_aws_auth.py:145
Methodtest_custom_env_var
(self, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_aws_auth.py:245
Methodtest_custom_env_var
(self, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_aws_auth.py:331
Methodtest_custom_env_var
(self, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_aws_auth.py:413
Methodtest_custom_env_var_not_set_defaults_to_sigv4
(self, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_aws_auth.py:159
Functiontest_custom_headers_env_authorization_never_conflicts
( respx_mock: MockRouter, monkeypatch: pytest.MonkeyPatch )
tests/lib/test_google_cloud.py:755
Functiontest_custom_headers_env_flows_through
(respx_mock: MockRouter, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_google_cloud.py:736
Methodtest_custom_headers_env_var_is_overridden_case_insensitively
(self, client_cls: ClientClass)
tests/test_header_case_sensitivity.py:118
Functiontest_custom_headers_from_the_environment
( client_class: ClientClass, copied: bool, monkeypatch: pytest.MonkeyPatch )
tests/lib/test_client_copy.py:305
Functiontest_custom_headers_from_the_environment_are_signed
(sync: bool, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_bedrock.py:1055
Methodtest_custom_input_schema_with_dict
(self)
tests/lib/tools/test_functions.py:132
Methodtest_custom_input_schema_with_pydantic_model
(self)
tests/lib/tools/test_functions.py:147
Methodtest_custom_name_and_description
(self)
tests/lib/tools/test_functions.py:122
Methodtest_custom_url_template
(self, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_aws_auth.py:402
Functiontest_data_json_escaped_double_new_line
(sync: bool, client: Anthropic, async_client: AsyncAnthropic)
tests/test_streaming.py:148
Functiontest_data_missing_event
(sync: bool, client: Anthropic, async_client: AsyncAnthropic)
tests/test_streaming.py:48
Functiontest_date_parsing
(value: Union[str, bytes, int, float], result: Union[date, Type[Exception]])
tests/test_utils/test_datetime_parse.py:53
Methodtest_date_serialization
(self)
tests/test_utils/test_json.py:34
Functiontest_dates_are_prepared_as_iso_strings
( send: Send, client: Anthropic | AsyncAnthropic, value: date, iso: str )
tests/test_prepare.py:374
Functiontest_datetime
()
tests/test_qs.py:27
Functiontest_datetime_parsing
(value: Union[str, bytes, int, float], result: Union[datetime, Type[Exception]])
tests/test_utils/test_datetime_parse.py:105
Methodtest_datetime_serialization
(self)
tests/test_utils/test_json.py:28
Functiontest_debug_logging_dumps_the_request_options_with_their_span_fields
( traces: bool, sync: bool, spans: Spans, respx_mock: MockRouter, caplog: pytest.LogCaptureFixture )
tests/test_open_telemetry.py:3786
Functiontest_decoder_has_what_its_subclass_sets_after_init
(sync: bool)
tests/decoders/test_jsonl.py:91
Methodtest_decorator_with_custom_parameters
Test using @function_tool() decorator with custom name and description.
tests/lib/tools/test_functions.py:406
Methodtest_decorator_with_parentheses
Test using @function_tool() decorator with parentheses.
tests/lib/tools/test_functions.py:394
Methodtest_decorator_without_parentheses
Test using @function_tool decorator without parentheses.
tests/lib/tools/test_functions.py:371
Functiontest_deep_nesting
(send: Send, client: Anthropic | AsyncAnthropic, monkeypatch: pytest.MonkeyPatch)
tests/test_prepare.py:726
Methodtest_default_client_creation
(self)
tests/test_client.py:1559
Methodtest_default_client_creation
(self)
tests/test_client.py:3048
Functiontest_default_client_proxy_arguments_beat_environment
( client_cls: type[httpx2.Client] | type[httpx2.AsyncClient], kwargs: dict[str, Any], env: dict[st
tests/test_client.py:149
Methodtest_default_credentials_explicit_env_propagates_error
When ANTHROPIC_PROFILE or ANTHROPIC_CONFIG_DIR is set explicitly, a broken config file surfaces immediately — not swallowed into a 'no auth
tests/lib/test_credentials.py:841
Methodtest_default_dir_with_configs_triggers_tier1
No env vars but configs/ has files → tier 1 fires via _has_any_config().
tests/lib/test_credentials.py:2184
Functiontest_default_disabled_members_match_the_published_toolset
()
tests/lib/tools/toolsets/test_registry.py:42
Methodtest_default_headers_case_insensitive
(self)
tests/test_client.py:623
Methodtest_default_headers_case_insensitive
(self)
tests/test_client.py:2074
Methodtest_default_headers_omit_removes_client_subclass_header_case_insensitively
( self, client_cls: ClientClass )
tests/test_header_case_sensitivity.py:147
Methodtest_default_headers_omit_removes_per_request_sdk_header
(self, client_cls: ClientClass)
tests/test_header_case_sensitivity.py:167
Methodtest_default_headers_option
(self)
tests/test_client.py:567
Methodtest_default_headers_option
(self)
tests/test_client.py:2018
Methodtest_default_headers_replace_client_subclass_header_case_insensitively
(self, client_cls: ClientClass)
tests/test_header_case_sensitivity.py:62
Methodtest_default_headers_replace_sdk_header_case_insensitively
(self, client_cls: ClientClass)
tests/test_header_case_sensitivity.py:54
Methodtest_default_query_option
(self)
tests/test_client.py:688
Methodtest_default_query_option
(self)
tests/test_client.py:2141
Methodtest_default_stream_cls
(self, respx_mock: MockRouter, client: Anthropic)
tests/test_client.py:1289
Methodtest_default_stream_cls
(self, respx_mock: MockRouter, async_client: AsyncAnthropic)
tests/test_client.py:2757
Methodtest_defaults
(self)
tests/lib/test_credentials.py:189
Functiontest_defaults_index_to_0
()
tests/lib/sessions/test_accumulate.py:89
Functiontest_defer_tool_call_changes_nothing_for_a_call_that_has_run
(setup: SetupFactory)
tests/lib/tools/test_runner_eager_tools.py:490
Functiontest_defer_tool_call_does_nothing_before_the_loop_starts_because_there_is_no_reply_yet
( setup: SetupFactory, )
tests/lib/tools/test_runner_eager_tools.py:474
Functiontest_defer_tool_call_lasts_for_one_reply
(setup: SetupFactory)
tests/lib/tools/test_runner_eager_tools.py:513
Functiontest_defer_tool_call_takes
(setup: SetupFactory, argument: str)
tests/lib/tools/test_runner_eager_tools.py:386
Functiontest_deferred_tool_calls_is_empty_once_generate_tool_call_response_has_run_the_held_calls
( setup: SetupFactory, )
tests/lib/tools/test_runner_eager_tools.py:621
Functiontest_deferred_tool_calls_lists_a_held_call_from_when_its_block_has_finished_streaming
( setup: SetupFactory, )
tests/lib/tools/test_runner_eager_tools.py:593
Functiontest_deferred_tool_calls_lists_the_held_calls_in_the_models_order_with_their_whole_input
( setup: SetupFactory, )
tests/lib/tools/test_runner_eager_tools.py:574
Functiontest_deferred_tool_calls_lists_the_held_calls_of_a_reply_that_is_cut_off
(setup: SetupFactory)
tests/lib/tools/test_runner_eager_tools.py:637
Functiontest_defers_the_calls_of_one_reply_only
(setup: SetupFactory)
tests/lib/tools/test_runner_eager_tools.py:458
Methodtest_defined_query
(self, query: str, names: tuple[str, ...], kept: str)
tests/test_open_telemetry.py:3470
← previousnext →6,101–6,200 of 12,824, ranked by callers