MCPcopy Create free account
hub / github.com/anthropics/anthropic-sdk-python / write

Method write

tests/lib/test_credentials.py:396–405  ·  view source on GitHub ↗
(profile: str, *, with_base_url: Optional[str])

Source from the content-addressed store, hash-verified

394 bound = "https://bound.example"
395
396 def write(profile: str, *, with_base_url: Optional[str]) -> None:
397 cfg: Dict[str, Any] = {
398 "type": "workload_identity",
399 "identity_token": {"source": "file", "path": str(jwt_path)},
400 "federation_rule_id": "fdrl_x",
401 "organization_id": "org",
402 }
403 if with_base_url is not None:
404 cfg["base_url"] = with_base_url
405 _write_profile(tmp_path, profile, config=cfg)
406
407 # config omits base_url, no bind → DEFAULT_BASE_URL
408 write("p0", with_base_url=None)

Callers 14

write_to_fileMethod · 0.45
write_to_fileMethod · 0.45
stream_to_fileMethod · 0.45
stream_to_fileMethod · 0.45
_atomic_write_fileFunction · 0.45
createMethod · 0.45
write_replace_and_syncFunction · 0.45
create_exclusiveMethod · 0.45
_replace_via_tempFunction · 0.45
format_code_blocksFunction · 0.45
format_fileFunction · 0.45

Calls 1

_write_profileFunction · 0.85

Tested by

no test coverage detected