MCPcopy Create free account
hub / github.com/Tron521/codex-console-temp / proxy_url

Method proxy_url

src/database/models.py:399–412  ·  view source on GitHub ↗

获取完整的代理 URL

(self)

Source from the content-addressed store, hash-verified

397
398 @property
399 def proxy_url(self) -> str:
400 """获取完整的代理 URL"""
401 if self.type == "http":
402 scheme = "http"
403 elif self.type == "socks5":
404 scheme = "socks5"
405 else:
406 scheme = self.type
407
408 auth = ""
409 if self.username and self.password:
410 auth = f"{self.username}:{self.password}@"
411
412 return f"{scheme}://{auth}{self.host}:{self.port}"

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected