MCPcopy Create free account
hub / github.com/CommonstackAI/UncommonRoute / _current_connection_payload

Function _current_connection_payload

uncommon_route/proxy.py:2864–2884  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2862 return _providers
2863
2864 def _current_connection_payload() -> dict[str, Any]:
2865 effective = resolve_primary_connection(
2866 cli_upstream=_cli_upstream_override,
2867 store=_connections_store,
2868 )
2869 return {
2870 "source": effective.source,
2871 "upstream_source": effective.upstream_source,
2872 "api_key_source": effective.api_key_source,
2873 "editable": effective.editable,
2874 "upstream": upstream,
2875 "has_api_key": bool(_primary_api_key),
2876 "api_key_preview": mask_api_key(_primary_api_key),
2877 "provider": _mapper.provider,
2878 "is_gateway": _mapper.is_gateway,
2879 "discovered": _mapper.discovered,
2880 "upstream_model_count": _mapper.upstream_model_count,
2881 "pool_size": _mapper.pool_size,
2882 "unresolved": _mapper.unresolved_models(),
2883 "pricing_source": "dynamic" if _mapper.discovered else "static",
2884 }
2885
2886 async def _reload_primary_connection(
2887 *,

Callers 3

handle_healthFunction · 0.85
handle_connectionsFunction · 0.85

Calls 3

mask_api_keyFunction · 0.90
unresolved_modelsMethod · 0.80

Tested by

no test coverage detected