Skip to content

The ultimate harness for coding agents and beyond. All your agents. All your machines. One command center. Start with code, then follow your curiosity and build across disciplines: CAD, circuits, robots, games and music.

feat(os): Connectors show each service's own icon, bundled with the page

bubu-dudu735b7e4d4549
diff --git a/os/connectors/connections.py b/os/connectors/connections.py
index 1ee983ed3..5bef99419 100644
--- a/os/connectors/connections.py
+++ b/os/connectors/connections.py
@@ -31,6 +31,10 @@ import oauth
import renew
ASSETS = Path(__file__).parent / "web"
+# Bundled service icons: Autonomous's connector icons, Simple Icons (CC0) and
+# the services' own favicons, so the page loads nothing from the network.
+ICONS = {path.stem: path.name for path in (ASSETS / "icons").iterdir() if path.suffix in (".png", ".svg")}
+ICON_TYPES = {".png": "image/png", ".svg": "image/svg+xml"}
GATEWAY_CACHE_SECONDS = 60
@@ -119,10 +123,11 @@ def catalog(vault, offered=None):
items = []
for code, item in store.CATALOG.items():
card = vault.status(code, tokens.get(code) or {})
- card.update(description=item["description"], color=item["color"], auth=item["auth"], custom=False, reason="")
+ card.update(description=item["description"], color=item["color"], auth=item["auth"], custom=False, reason="",
+ icon="/icons/" + ICONS[code] if code in ICONS else "")
if item["auth"] == "app" and card["state"] == "not_connected":
if not signed_in:
- card["reason"] = "Sign in to Harness first (harness login)."
+ card["reason"] = "Needs harness login"
elif offered and code not in offered:
card["reason"] = "Not available yet."
items.append(card)
@@ -130,7 +135,8 @@ def catalog(vault, offered=None):
if code in store.CATALOG:
continue
card = vault.status(code, token)
- card.update(description=token.get("mcp_entry", {}).get("url", ""), color="#59634b", auth="custom", custom=True, reason="")
+ card.update(description=token.get("mcp_entry", {}).get("url", ""), color="#59634b", auth="custom", custom=True,
+ reason="", icon="")
items.append(card)
return {"connections": items, "signed_in": signed_in}
@@ -181,7 +187,7 @@ class PageHandler(BaseHTTPRequestHandler):
self.send_header("Cache-Control", "no-store")
self.send_header("X-Content-Type-Options", "nosniff")
self.send_header("Referrer-Policy", "no-referrer")
- self.send_header("Content-Security-Policy", "default-src 'none'; script-src 'self'; style-src 'self'; connect-src 'self'; frame-ancestors 'none'; base-uri 'none'; form-action 'none'")
+ self.send_header("Content-Security-Policy", "default-src 'none'; script-src 'self'; style-src 'self'; img-src 'self'; connect-src 'self'; frame-ancestors 'none'; base-uri 'none'; form-action 'none'")
self.end_headers()
self.wfile.write(raw)
@@ -221,6 +227,10 @@ class PageHandler(BaseHTTPRequestHandler):
files = {"/": ("index.html", "text/html; charset=utf-8"),
"/style.css": ("style.css", "text/css; charset=utf-8"),
"/page.js": ("page.js", "text/javascript; charset=utf-8")}
+ # Only the names listed at start-up: never a path from the request.
+ icon = self.path.removeprefix("/icons/")
+ if icon in ICONS.values():
+ files[self.path] = ("icons/" + icon, ICON_TYPES[Path(icon).suffix])
if self.path not in files:
self.reply(404, {"error": "Not found."})
return
diff --git a/os/connectors/web/icons/ahrefs.png b/os/connectors/web/icons/ahrefs.png
new file mode 100644
index 000000000..774de8b14
Binary files /dev/null and b/os/connectors/web/icons/ahrefs.png differ
diff --git a/os/connectors/web/icons/airtable.svg b/os/connectors/web/icons/airtable.svg
new file mode 100644
index 000000000..adb9cf19b
--- /dev/null
+++ b/os/connectors/web/icons/airtable.svg
@@ -0,0 +1 @@
+<svg fill="#18BFFF" role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>Airtable</title><path d="M11.992 1.966c-.434 0-.87.086-1.28.257L1.779 5.917c-.503.208-.49.908.012 1.116l8.982 3.558a3.266 3.266 0 0 0 2.454 0l8.982-3.558c.503-.196.503-.908.012-1.116l-8.957-3.694a3.255 3.255 0 0 0-1.272-.257zM23.4 8.056a.589.589 0 0 0-.222.045l-10.012 3.877a.612.612 0 0 0-.38.564v8.896a.6.6 0 0 0 .821.552L23.62 18.1a.583.583 0 0 0 .38-.551V8.653a.6.6 0 0 0-.6-.596zM.676 8.095a.644.644 0 0 0-.48.19C.086 8.396 0 8.53 0 8.69v8.355c0 .442.515.737.908.54l6.27-3.006.307-.147 2.969-1.436c.466-.22.43-.908-.061-1.092L.883 8.138a.57.57 0 0 0-.207-.044z"/></svg>
\ No newline at end of file
diff --git a/os/connectors/web/icons/amplitude.png b/os/connectors/web/icons/amplitude.png
new file mode 100644
index 000000000..973a332bb
Binary files /dev/null and b/os/connectors/web/icons/amplitude.png differ
diff --git a/os/connectors/web/icons/apollo.png b/os/connectors/web/icons/apollo.png
new file mode 100644
index 000000000..7d27de9d2
Binary files /dev/null and b/os/connectors/web/icons/apollo.png differ
diff --git a/os/connectors/web/icons/asana.png b/os/connectors/web/icons/asana.png
new file mode 100644
index 000000000..b633d0283
Binary files /dev/null and b/os/connectors/web/icons/asana.png differ
diff --git a/os/connectors/web/icons/atlassian.png b/os/connectors/web/icons/atlassian.png
new file mode 100644
index 000000000..64453108b
Binary files /dev/null and b/os/connectors/web/icons/atlassian.png differ
diff --git a/os/connectors/web/icons/attio.png b/os/connectors/web/icons/attio.png
new file mode 100644
index 000000000..6433b4a05
Binary files /dev/null and b/os/connectors/web/icons/attio.png differ
diff --git a/os/connectors/web/icons/canva.png b/os/connectors/web/icons/canva.png
new file mode 100644
index 000000000..20c51d945
Binary files /dev/null and b/os/connectors/web/icons/canva.png differ
diff --git a/os/connectors/web/icons/clickup.png b/os/connectors/web/icons/clickup.png
new file mode 100644
index 000000000..9eb7d6d4f
Binary files /dev/null and b/os/connectors/web/icons/clickup.png differ
diff --git a/os/connectors/web/icons/datadog.png b/os/connectors/web/icons/datadog.png
new file mode 100644
index 000000000..955eec21b
Binary files /dev/null and b/os/connectors/web/icons/datadog.png differ
diff --git a/os/connectors/web/icons/figma.svg b/os/connectors/web/icons/figma.svg
new file mode 100644
index 000000000..d6042ef02
--- /dev/null
+++ b/os/connectors/web/icons/figma.svg
@@ -0,0 +1 @@
+<svg id="Layer_1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 200 300" width="1667" height="2500"><style>.st0{fill:#0acf83}.st1{fill:#a259ff}.st2{fill:#f24e1e}.st3{fill:#ff7262}.st4{fill:#1abcfe}</style><title>Figma.logo</title><desc>Created using Figma</desc><path id="path0_fill" class="st0" d="M50 300c27.6 0 50-22.4 50-50v-50H50c-27.6 0-50 22.4-50 50s22.4 50 50 50z"/><path id="path1_fill" class="st1" d="M0 150c0-27.6 22.4-50 50-50h50v100H50c-27.6 0-50-22.4-50-50z"/><path id="path1_fill_1_" class="st2" d="M0 50C0 22.4 22.4 0 50 0h50v100H50C22.4 100 0 77.6 0 50z"/><path id="path2_fill" class="st3" d="M100 0h50c27.6 0 50 22.4 50 50s-22.4 50-50 50h-50V0z"/><path id="path3_fill" class="st4" d="M200 150c0 27.6-22.4 50-50 50s-50-22.4-50-50 22.4-50 50-50 50 22.4 50 50z"/></svg>
\ No newline at end of file
diff --git a/os/connectors/web/icons/github.png b/os/connectors/web/icons/github.png
new file mode 100644
index 000000000..86c3d6d45
Binary files /dev/null and b/os/connectors/web/icons/github.png differ
diff --git a/os/connectors/web/icons/gitlab.svg b/os/connectors/web/icons/gitlab.svg
new file mode 100644
index 000000000..509fa7f41
--- /dev/null
+++ b/os/connectors/web/icons/gitlab.svg
@@ -0,0 +1 @@
+<svg fill="#FC6D26" role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>GitLab</title><path d="m23.6004 9.5927-.0337-.0862L20.3.9814a.851.851 0 0 0-.3362-.405.8748.8748 0 0 0-.9997.0539.8748.8748 0 0 0-.29.4399l-2.2055 6.748H7.5375l-2.2057-6.748a.8573.8573 0 0 0-.29-.4412.8748.8748 0 0 0-.9997-.0537.8585.8585 0 0 0-.3362.4049L.4332 9.5015l-.0325.0862a6.0657 6.0657 0 0 0 2.0119 7.0105l.0113.0087.03.0213 4.976 3.7264 2.462 1.8633 1.4995 1.1321a1.0085 1.0085 0 0 0 1.2197 0l1.4995-1.1321 2.4619-1.8633 5.006-3.7489.0125-.01a6.0682 6.0682 0 0 0 2.0094-7.003z"/></svg>
\ No newline at end of file
diff --git a/os/connectors/web/icons/gmail.png b/os/connectors/web/icons/gmail.png
new file mode 100644
index 000000000..c749e90c7
Binary files /dev/null and b/os/connectors/web/icons/gmail.png differ
diff --git a/os/connectors/web/icons/google_bigquery.png b/os/connectors/web/icons/google_bigquery.png
new file mode 100644
index 000000000..d9b32674d
Binary files /dev/null and b/os/connectors/web/icons/google_bigquery.png differ
diff --git a/os/connectors/web/icons/google_calendar.png b/os/connectors/web/icons/google_calendar.png
new file mode 100644
index 000000000..a62f7f5e9
Binary files /dev/null and b/os/connectors/web/icons/google_calendar.png differ
diff --git a/os/connectors/web/icons/google_drive.png b/os/connectors/web/icons/google_drive.png
new file mode 100644
index 000000000..67115779d
Binary files /dev/null and b/os/connectors/web/icons/google_drive.png differ
diff --git a/os/connectors/web/icons/hubspot.png b/os/connectors/web/icons/hubspot.png
new file mode 100644
index 000000000..9230f04f0
Binary files /dev/null and b/os/connectors/web/icons/hubspot.png differ
diff --git a/os/connectors/web/icons/intercom.png b/os/connectors/web/icons/intercom.png
new file mode 100644
index 000000000..b50cc6593
Binary files /dev/null and b/os/connectors/web/icons/intercom.png differ
diff --git a/os/connectors/web/icons/klaviyo.png b/os/connectors/web/icons/klaviyo.png
new file mode 100644
index 000000000..8921e1df1
Binary files /dev/null and b/os/connectors/web/icons/klaviyo.png differ
diff --git a/os/connectors/web/icons/linear.png b/os/connectors/web/icons/linear.png
new file mode 100644
index 000000000..ffe851269
Binary files /dev/null and b/os/connectors/web/icons/linear.png differ
diff --git a/os/connectors/web/icons/microsoft_365.png b/os/connectors/web/icons/microsoft_365.png
new file mode 100644
index 000000000..cfd92b175
Binary files /dev/null and b/os/connectors/web/icons/microsoft_365.png differ
diff --git a/os/connectors/web/icons/mondaydotcom.png b/os/connectors/web/icons/mondaydotcom.png
new file mode 100644
index 000000000..574df55eb
Binary files /dev/null and b/os/connectors/web/icons/mondaydotcom.png differ
diff --git a/os/connectors/web/icons/notion.png b/os/connectors/web/icons/notion.png
new file mode 100644
index 000000000..a997503db
Binary files /dev/null and b/os/connectors/web/icons/notion.png differ
diff --git a/os/connectors/web/icons/pagerduty.png b/os/connectors/web/icons/pagerduty.png
new file mode 100644
index 000000000..4445c758b
Binary files /dev/null and b/os/connectors/web/icons/pagerduty.png differ
diff --git a/os/connectors/web/icons/sentry.svg b/os/connectors/web/icons/sentry.svg
new file mode 100644
index 000000000..0b470579c
--- /dev/null
+++ b/os/connectors/web/icons/sentry.svg
@@ -0,0 +1 @@
+<svg fill="#ffffff" role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>Sentry</title><path d="M13.91 2.505c-.873-1.448-2.972-1.448-3.844 0L6.904 7.92a15.478 15.478 0 0 1 8.53 12.811h-2.221A13.301 13.301 0 0 0 5.784 9.814l-2.926 5.06a7.65 7.65 0 0 1 4.435 5.848H2.194a.365.365 0 0 1-.298-.534l1.413-2.402a5.16 5.16 0 0 0-1.614-.913L.296 19.275a2.182 2.182 0 0 0 .812 2.999 2.24 2.24 0 0 0 1.086.288h6.983a9.322 9.322 0 0 0-3.845-8.318l1.11-1.922a11.47 11.47 0 0 1 4.95 10.24h5.915a17.242 17.242 0 0 0-7.885-15.28l2.244-3.845a.37.37 0 0 1 .504-.13c.255.14 9.75 16.708 9.928 16.9a.365.365 0 0 1-.327.543h-2.287c.029.612.029 1.223 0 1.831h2.297a2.206 2.206 0 0 0 1.922-3.31z"/></svg>
\ No newline at end of file
diff --git a/os/connectors/web/icons/slack.png b/os/connectors/web/icons/slack.png
new file mode 100644
index 000000000..6cdfbcdc5
Binary files /dev/null and b/os/connectors/web/icons/slack.png differ
diff --git a/os/connectors/web/icons/stripe.svg b/os/connectors/web/icons/stripe.svg
new file mode 100644
index 000000000..48272a2c5
--- /dev/null
+++ b/os/connectors/web/icons/stripe.svg
@@ -0,0 +1 @@
+<svg fill="#635BFF" role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>Stripe</title><path d="M13.976 9.15c-2.172-.806-3.356-1.426-3.356-2.409 0-.831.683-1.305 1.901-1.305 2.227 0 4.515.858 6.09 1.631l.89-5.494C18.252.975 15.697 0 12.165 0 9.667 0 7.589.654 6.104 1.872 4.56 3.147 3.757 4.992 3.757 7.218c0 4.039 2.467 5.76 6.476 7.219 2.585.92 3.445 1.574 3.445 2.583 0 .98-.84 1.545-2.354 1.545-1.875 0-4.965-.921-6.99-2.109l-.9 5.555C5.175 22.99 8.385 24 11.714 24c2.641 0 4.843-.624 6.328-1.813 1.664-1.305 2.525-3.236 2.525-5.732 0-4.128-2.524-5.851-6.594-7.305h.003z"/></svg>
\ No newline at end of file
diff --git a/os/connectors/web/icons/supabase.svg b/os/connectors/web/icons/supabase.svg
new file mode 100644
index 000000000..03f46fa27
--- /dev/null
+++ b/os/connectors/web/icons/supabase.svg
@@ -0,0 +1 @@
+<svg fill="#3FCF8E" role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>Supabase</title><path d="M11.9 1.036c-.015-.986-1.26-1.41-1.874-.637L.764 12.05C-.33 13.427.65 15.455 2.409 15.455h9.579l.113 7.51c.014.985 1.259 1.408 1.873.636l9.262-11.653c1.093-1.375.113-3.403-1.645-3.403h-9.642z"/></svg>
\ No newline at end of file
diff --git a/os/connectors/web/icons/supermetrics_marketing.png b/os/connectors/web/icons/supermetrics_marketing.png
new file mode 100644
index 000000000..3c706c68e
Binary files /dev/null and b/os/connectors/web/icons/supermetrics_marketing.png differ
diff --git a/os/connectors/web/icons/vercel.svg b/os/connectors/web/icons/vercel.svg
new file mode 100644
index 000000000..ef6a708c2
--- /dev/null
+++ b/os/connectors/web/icons/vercel.svg
@@ -0,0 +1 @@
+<svg fill="#ffffff" role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>Vercel</title><path d="M24 22.525H0l12-21.05 12 21.05z"/></svg>
\ No newline at end of file
diff --git a/os/connectors/web/page.js b/os/connectors/web/page.js
index 15f5bbf07..7171caddc 100644
--- a/os/connectors/web/page.js
+++ b/os/connectors/web/page.js
@@ -27,6 +27,12 @@ function node(tag, text, className) {
return element;
}
function mark(item) {
+ if (item.icon) {
+ const image = node("img", "", "mark logo");
+ image.src = item.icon;
+ image.alt = "";
+ return image;
+ }
const tile = node("span", (item.name || "?").trim().charAt(0).toUpperCase(), "mark");
tile.style.background = item.color || "#59634b";
return tile;
diff --git a/os/connectors/web/style.css b/os/connectors/web/style.css
index 087d844f5..31e8c0b70 100644
--- a/os/connectors/web/style.css
+++ b/os/connectors/web/style.css
@@ -25,6 +25,7 @@ button:focus-visible,input:focus-visible,textarea:focus-visible,summary:focus-vi
.card-head{display:flex;align-items:center;gap:10px}
.card-head h3{font-size:16px;margin:0;font-weight:700;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.mark{flex:none;width:26px;height:26px;border-radius:6px;display:grid;place-items:center;color:#fff;font-weight:800;font-size:14px}
+.logo{object-fit:contain;background:#2a2a2a;padding:2px}
.badge{font-size:12px;color:#9fb0ff;background:#1d2450;border-radius:6px;padding:1px 8px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:160px}
.badge.warn{color:#ffd28a;background:#4a3511}
.card-actions{margin-left:auto;display:flex;gap:6px;align-items:center}
diff --git a/os/tests/test_connections.py b/os/tests/test_connections.py
index 1452c2879..eab31bbd9 100644
--- a/os/tests/test_connections.py
+++ b/os/tests/test_connections.py
@@ -480,6 +480,16 @@ class Page(Case):
self.assertEqual(json.loads(raw)["state"], "not_connected")
self.assertIsNone(self.vault.token("linear"))
+ def test_every_service_has_a_bundled_icon_and_only_those_are_served(self):
+ self.assertEqual(set(store.CATALOG) - set(connections.ICONS), set())
+ cards = json.loads(self.request("/api/connections", headers=self.auth())[2])["connections"]
+ status, headers, raw = self.request(cards[0]["icon"])
+ self.assertEqual(status, 200)
+ self.assertIn(headers["Content-Type"], ("image/png", "image/svg+xml"))
+ self.assertTrue(raw)
+ for path in ("/icons/../connection_store.py", "/icons/x.png", "/icons/"):
+ self.assertEqual(self.request(path)[0], 404, path)
+
def test_add_custom_with_headers_and_bad_requests(self):
body = {"name": "My Tools", "url": "https://tools.example/mcp", "headers": {"Authorization": "Bearer pat-fixture"}}
status, _, raw = self.request("/api/custom", "POST", body, self.auth())