[{"data":1,"prerenderedAt":566},["ShallowReactive",2],{"docs-\u002Fdocs\u002Fmcp\u002Fnetwork-access":3},{"id":4,"title":5,"body":6,"description":555,"extension":556,"icon":557,"meta":558,"navigation":559,"path":560,"seo":561,"sitemap":562,"stem":563,"updated":564,"__hash__":565},"docs\u002Fdocs\u002F3.mcp\u002F8.network-access.md","Network access",{"type":7,"value":8,"toc":545},"minimark",[9,13,31,36,98,105,122,135,139,144,155,252,270,274,288,394,410,414,420,437,446,450,458,461,480,484,487,509,515,518,538,541],[10,11,5],"h1",{"id":12},"network-access",[14,15,16,17,21,22,26,27,30],"p",{},"Most agent environments let outbound traffic through, or already allow your MCP client's own connection. The one step that sandboxes commonly block is the ",[18,19,20],"strong",{},"upload PUT",": after ",[23,24,25],"code",{},"deploy_create_upload",", the agent sends the file's bytes from its own shell, with ",[23,28,29],{},"curl"," or a script. Those requests go to your site's partition API host, so that host has to be reachable from the agent's shell.",[32,33,35],"h2",{"id":34},"what-needs-to-be-reachable","What needs to be reachable",[37,38,39,55],"table",{},[40,41,42],"thead",{},[43,44,45,49,52],"tr",{},[46,47,48],"th",{},"From",[46,50,51],{},"To",[46,53,54],{},"When",[56,57,58,83],"tbody",{},[43,59,60,71,76],{},[61,62,63,64,66,67,70],"td",{},"The agent's shell, where ",[23,65,29],{}," or ",[23,68,69],{},"fetch"," runs",[61,72,73],{},[23,74,75],{},"us.api.hostsmith.net",[61,77,78,79,82],{},"Uploads to sites in the ",[23,80,81],{},"us"," partition",[43,84,85,88,93],{},[61,86,87],{},"The agent's shell",[61,89,90],{},[23,91,92],{},"eu.api.hostsmith.net",[61,94,78,95,82],{},[23,96,97],{},"eu",[14,99,100,101,104],{},"Both use HTTPS on port 443. Small deploys with ",[23,102,103],{},"deploy_files"," send the content through the MCP server and need neither.",[106,107,109],"callout",{"type":108},"info",[14,110,111,121],{},[18,112,113,114,66,117,120],{},"You don't need to allow ",[23,115,116],{},"mcp.hostsmith.net",[23,118,119],{},"hostsmith.net"," for the agent's shell."," The MCP connection and the sign-in run in your client app (Claude, Claude Code, Cursor and others), not in the agent's shell, so terminal sandbox rules don't apply to them. If you added the MCP server and signed in, those already work.",[106,123,124],{"type":108},[14,125,126,127,130,131,134],{},"The REST API can also return direct S3 URLs, when a caller asks for ",[23,128,129],{},"mode: \"presigned\""," when starting an upload. Those need egress to the bucket's S3 host (",[23,132,133],{},"*.s3.\u003Cregion>.amazonaws.com",") instead. The MCP server always uses the default, the partition API host.",[32,136,138],{"id":137},"allowing-the-hosts-in-your-sandbox","Allowing the hosts in your sandbox",[140,141,143],"h3",{"id":142},"cursor","Cursor",[14,145,146,147,150,151,154],{},"Add the hosts to the network policy in ",[23,148,149],{},"~\u002F.cursor\u002Fsandbox.json"," (all workspaces) or ",[23,152,153],{},"\u003Cworkspace>\u002F.cursor\u002Fsandbox.json"," (one workspace):",[156,157,162],"pre",{"className":158,"code":159,"language":160,"meta":161,"style":161},"language-json shiki shiki-themes hostsmith-docs-tokyo-night","{\n  \"networkPolicy\": {\n    \"allow\": [\n      \"us.api.hostsmith.net\",\n      \"eu.api.hostsmith.net\"\n    ]\n  }\n}\n","json","",[23,163,164,173,193,210,224,234,240,246],{"__ignoreMap":161},[165,166,169],"span",{"class":167,"line":168},"line",1,[165,170,172],{"class":171},"sgJMe","{\n",[165,174,176,180,184,187,190],{"class":167,"line":175},2,[165,177,179],{"class":178},"sAklC","  \"",[165,181,183],{"class":182},"s3R4Z","networkPolicy",[165,185,186],{"class":178},"\"",[165,188,189],{"class":178},":",[165,191,192],{"class":171}," {\n",[165,194,196,199,203,205,207],{"class":167,"line":195},3,[165,197,198],{"class":178},"    \"",[165,200,202],{"class":201},"sySf4","allow",[165,204,186],{"class":178},[165,206,189],{"class":178},[165,208,209],{"class":171}," [\n",[165,211,213,216,219,221],{"class":167,"line":212},4,[165,214,215],{"class":178},"      \"",[165,217,75],{"class":218},"sPY7s",[165,220,186],{"class":178},[165,222,223],{"class":178},",\n",[165,225,227,229,231],{"class":167,"line":226},5,[165,228,215],{"class":178},[165,230,92],{"class":218},[165,232,233],{"class":178},"\"\n",[165,235,237],{"class":167,"line":236},6,[165,238,239],{"class":171},"    ]\n",[165,241,243],{"class":167,"line":242},7,[165,244,245],{"class":171},"  }\n",[165,247,249],{"class":167,"line":248},8,[165,250,251],{"class":171},"}\n",[14,253,254,255,258,259,261,262,269],{},"A host listed in ",[23,256,257],{},"networkPolicy.deny"," stays blocked even if it's also in ",[23,260,202],{},". If your team admin manages the network allowlist, it replaces your local one: ask them to add the hosts. See Cursor's ",[263,264,268],"a",{"href":265,"rel":266},"https:\u002F\u002Fcursor.com\u002Fdocs\u002Freference\u002Fsandbox",[267],"nofollow","sandbox.json reference",".",[140,271,273],{"id":272},"claude-code","Claude Code",[14,275,276,277,280,281,284,285,189],{},"Add the hosts to ",[23,278,279],{},"sandbox.network.allowedDomains"," in ",[23,282,283],{},"~\u002F.claude\u002Fsettings.json",", or in the project's ",[23,286,287],{},".claude\u002Fsettings.json",[156,289,291],{"className":158,"code":290,"language":160,"meta":161,"style":161},"{\n  \"sandbox\": {\n    \"enabled\": true,\n    \"network\": {\n      \"allowedDomains\": [\n        \"us.api.hostsmith.net\",\n        \"eu.api.hostsmith.net\"\n      ]\n    }\n  }\n}\n",[23,292,293,297,310,327,340,354,365,373,378,384,389],{"__ignoreMap":161},[165,294,295],{"class":167,"line":168},[165,296,172],{"class":171},[165,298,299,301,304,306,308],{"class":167,"line":175},[165,300,179],{"class":178},[165,302,303],{"class":182},"sandbox",[165,305,186],{"class":178},[165,307,189],{"class":178},[165,309,192],{"class":171},[165,311,312,314,317,319,321,325],{"class":167,"line":195},[165,313,198],{"class":178},[165,315,316],{"class":201},"enabled",[165,318,186],{"class":178},[165,320,189],{"class":178},[165,322,324],{"class":323},"sOJ5S"," true",[165,326,223],{"class":178},[165,328,329,331,334,336,338],{"class":167,"line":212},[165,330,198],{"class":178},[165,332,333],{"class":201},"network",[165,335,186],{"class":178},[165,337,189],{"class":178},[165,339,192],{"class":171},[165,341,342,344,348,350,352],{"class":167,"line":226},[165,343,215],{"class":178},[165,345,347],{"class":346},"su0L4","allowedDomains",[165,349,186],{"class":178},[165,351,189],{"class":178},[165,353,209],{"class":171},[165,355,356,359,361,363],{"class":167,"line":236},[165,357,358],{"class":178},"        \"",[165,360,75],{"class":218},[165,362,186],{"class":178},[165,364,223],{"class":178},[165,366,367,369,371],{"class":167,"line":242},[165,368,358],{"class":178},[165,370,92],{"class":218},[165,372,233],{"class":178},[165,374,375],{"class":167,"line":248},[165,376,377],{"class":171},"      ]\n",[165,379,381],{"class":167,"line":380},9,[165,382,383],{"class":171},"    }\n",[165,385,387],{"class":167,"line":386},10,[165,388,245],{"class":171},[165,390,392],{"class":167,"line":391},11,[165,393,251],{"class":171},[14,395,396,397,400,401,404,405,269],{},"If ",[23,398,399],{},"deniedDomains"," lists one of these hosts, remove it first: deny wins over allow. Without the entry, Claude Code asks you the first time a command reaches a new host, and ",[18,402,403],{},"Yes, and don't ask again"," saves the host for you. See Claude Code's ",[263,406,409],{"href":407,"rel":408},"https:\u002F\u002Fcode.claude.com\u002Fdocs\u002Fen\u002Fsandboxing",[267],"sandboxing docs",[140,411,413],{"id":412},"codex-cli","Codex CLI",[14,415,416,417,189],{},"The workspace-write sandbox turns network access off by default. Turn it on in ",[23,418,419],{},"~\u002F.codex\u002Fconfig.toml",[156,421,425],{"className":422,"code":423,"language":424,"meta":161,"style":161},"language-toml shiki shiki-themes hostsmith-docs-tokyo-night","[sandbox_workspace_write]\nnetwork_access = true\n","toml",[23,426,427,432],{"__ignoreMap":161},[165,428,429],{"class":167,"line":168},[165,430,431],{},"[sandbox_workspace_write]\n",[165,433,434],{"class":167,"line":175},[165,435,436],{},"network_access = true\n",[14,438,439,440,445],{},"This opens outbound network for every command in workspace-write mode, not just these hosts. Codex's network proxy, which limits traffic to listed domains, is experimental; see Codex's ",[263,441,444],{"href":442,"rel":443},"https:\u002F\u002Fdevelopers.openai.com\u002Fcodex\u002Fconfig-reference",[267],"configuration reference"," if you want to try it. The risk of the broad setting is bounded by the upload URLs themselves: each carries a token that lets one PUT to one object, for one hour.",[140,447,449],{"id":448},"other-sandboxes-and-corporate-firewalls","Other sandboxes and corporate firewalls",[14,451,452,453,455,456,269],{},"Allow outbound HTTPS (TCP 443) to ",[23,454,75],{}," and ",[23,457,92],{},[14,459,460],{},"If an HTTP proxy sits in the path, make sure that:",[462,463,464,471,474],"ul",{},[465,466,467,470],"li",{},[23,468,469],{},"CONNECT"," is allowed for both hosts;",[465,472,473],{},"if the proxy inspects TLS, it trusts the certificate chain: Hostsmith's certificates are issued by Amazon (Amazon Trust Services);",[465,475,476,479],{},[23,477,478],{},"NO_PROXY"," lists these hosts only if your network expects direct traffic to them.",[32,481,483],{"id":482},"when-egress-is-blocked","When egress is blocked",[14,485,486],{},"A large deploy that fails with one of these usually means the agent's shell can't reach the partition API host:",[462,488,489,494,500,506],{},[465,490,491],{},[23,492,493],{},"curl: (6) Could not resolve host: us.api.hostsmith.net",[465,495,496,499],{},[23,497,498],{},"connection refused"," from a host your browser reaches",[465,501,502,505],{},[23,503,504],{},"407 Proxy Authentication Required"," from a corporate proxy",[465,507,508],{},"a PUT that hangs or times out",[14,510,511,512,514],{},"Retrying doesn't help: a blocked host stays blocked. The ",[23,513,25],{}," tool tells your agent to stop, show you the setting for your sandbox from this page, and wait for you to change it. If you can't change it, the agent can give you the upload URLs to run the PUT yourself. The URLs stay valid for an hour, so the agent can retry the same ones once you've allowed the host.",[14,516,517],{},"To test the path yourself, run this from the same shell your agent uses:",[156,519,523],{"className":520,"code":521,"language":522,"meta":161,"style":161},"language-bash shiki shiki-themes hostsmith-docs-tokyo-night","curl -sS https:\u002F\u002Fus.api.hostsmith.net\u002Fv1\u002Fpartitions\n","bash",[23,524,525],{"__ignoreMap":161},[165,526,527,531,535],{"class":167,"line":168},[165,528,530],{"class":529},"sE3pS","curl ",[165,532,534],{"class":533},"sT800","-sS",[165,536,537],{"class":218}," https:\u002F\u002Fus.api.hostsmith.net\u002Fv1\u002Fpartitions\n",[14,539,540],{},"If it prints the partitions as JSON, the host is reachable. If it fails, the agent's uploads fail the same way.",[542,543,544],"style",{},"html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html pre.shiki code .sgJMe, html code.shiki .sgJMe{--shiki-default:#9ABDF5}html pre.shiki code .sAklC, html code.shiki .sAklC{--shiki-default:#89DDFF}html pre.shiki code .s3R4Z, html code.shiki .s3R4Z{--shiki-default:#7AA2F7}html pre.shiki code .sySf4, html code.shiki .sySf4{--shiki-default:#0DB9D7}html pre.shiki code .sPY7s, html code.shiki .sPY7s{--shiki-default:#9ECE6A}html pre.shiki code .sOJ5S, html code.shiki .sOJ5S{--shiki-default:#FF9E64}html pre.shiki code .su0L4, html code.shiki .su0L4{--shiki-default:#7DCFFF}html pre.shiki code .sE3pS, html code.shiki .sE3pS{--shiki-default:#C0CAF5}html pre.shiki code .sT800, html code.shiki .sT800{--shiki-default:#E0AF68}",{"title":161,"searchDepth":175,"depth":175,"links":546},[547,548,554],{"id":34,"depth":175,"text":35},{"id":137,"depth":175,"text":138,"children":549},[550,551,552,553],{"id":142,"depth":195,"text":143},{"id":272,"depth":195,"text":273},{"id":412,"depth":195,"text":413},{"id":448,"depth":195,"text":449},{"id":482,"depth":175,"text":483},"The hosts your agent's shell contacts when it deploys large files, and how to allow them in sandboxed environments.","md","solar:shield-network-bold",{},null,"\u002Fdocs\u002Fmcp\u002Fnetwork-access",{"title":5,"description":555},{"loc":560},"docs\u002F3.mcp\u002F8.network-access","2026-11-15","leciBtIxXGeF4R51chchBZMotfCfSMY5KEeIZDCOpHk",1796141180651]