From d847fc4514008495c4abd85c69f171fc440fd30d Mon Sep 17 00:00:00 2001 From: Sweets Sweetman Date: Thu, 18 Jun 2026 15:40:21 -0500 Subject: [PATCH 1/3] feat: allow artists to connect X (Twitter); keep LinkedIn label-only (chat#1793) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add `twitter` to ALLOWED_ARTIST_CONNECTORS — artist-facing social, same class as tiktok/instagram/youtube. `linkedin` is intentionally left out (label/owner-only). TDD: isAllowedArtistConnector.test.ts asserts twitter allowed + linkedin excluded, RED before GREEN. Full lib/composio suite green (157 tests). Co-Authored-By: Claude Opus 4.8 (1M context) --- .../__tests__/isAllowedArtistConnector.test.ts | 15 ++++++++++++++- .../connectors/isAllowedArtistConnector.ts | 5 ++++- 2 files changed, 18 insertions(+), 2 deletions(-) diff --git a/lib/composio/connectors/__tests__/isAllowedArtistConnector.test.ts b/lib/composio/connectors/__tests__/isAllowedArtistConnector.test.ts index 596407d20..995b3d5fe 100644 --- a/lib/composio/connectors/__tests__/isAllowedArtistConnector.test.ts +++ b/lib/composio/connectors/__tests__/isAllowedArtistConnector.test.ts @@ -14,6 +14,14 @@ describe("isAllowedArtistConnector", () => { expect(isAllowedArtistConnector("youtube")).toBe(true); }); + it("should return true for 'twitter'", () => { + expect(isAllowedArtistConnector("twitter")).toBe(true); + }); + + it("should return false for 'linkedin' (label/owner-only)", () => { + expect(isAllowedArtistConnector("linkedin")).toBe(false); + }); + it("should return false for connectors not in ALLOWED_ARTIST_CONNECTORS", () => { expect(isAllowedArtistConnector("googlesheets")).toBe(false); expect(isAllowedArtistConnector("googledrive")).toBe(false); @@ -31,10 +39,15 @@ describe("isAllowedArtistConnector", () => { }); describe("ALLOWED_ARTIST_CONNECTORS", () => { - it("should include tiktok, instagram, and youtube", () => { + it("should include tiktok, instagram, youtube, and twitter", () => { expect(ALLOWED_ARTIST_CONNECTORS).toContain("tiktok"); expect(ALLOWED_ARTIST_CONNECTORS).toContain("instagram"); expect(ALLOWED_ARTIST_CONNECTORS).toContain("youtube"); + expect(ALLOWED_ARTIST_CONNECTORS).toContain("twitter"); + }); + + it("should not include linkedin (label/owner-only)", () => { + expect(ALLOWED_ARTIST_CONNECTORS).not.toContain("linkedin"); }); it("should be a readonly array", () => { diff --git a/lib/composio/connectors/isAllowedArtistConnector.ts b/lib/composio/connectors/isAllowedArtistConnector.ts index f3d83d82d..1ca9eaa15 100644 --- a/lib/composio/connectors/isAllowedArtistConnector.ts +++ b/lib/composio/connectors/isAllowedArtistConnector.ts @@ -1,8 +1,11 @@ /** * List of toolkit slugs that artists are allowed to connect. * Only these connectors will be shown in the artist-connectors API. + * + * `twitter` is artist-facing social, same class as the existing three. + * `linkedin` is intentionally excluded — it is label/owner-only. */ -export const ALLOWED_ARTIST_CONNECTORS = ["tiktok", "instagram", "youtube"] as const; +export const ALLOWED_ARTIST_CONNECTORS = ["tiktok", "instagram", "youtube", "twitter"] as const; export type AllowedArtistConnector = (typeof ALLOWED_ARTIST_CONNECTORS)[number]; From 802f69640a1c0ee2704be7cd1ee87258ab9ada34 Mon Sep 17 00:00:00 2001 From: Sweets Sweetman Date: Thu, 18 Jun 2026 18:05:44 -0500 Subject: [PATCH 2/3] feat: allow artists to connect LinkedIn too (chat#1793) Reversal of the earlier "LinkedIn label/owner-only" call: per owner decision 2026-06-18, LinkedIn is now an artist-facing connector like the others. Add `linkedin` to ALLOWED_ARTIST_CONNECTORS. TDD: flipped the linkedin assertions (now allowed/included), RED before GREEN. Full lib/composio suite green (159 tests). Co-Authored-By: Claude Opus 4.8 (1M context) --- .../__tests__/isAllowedArtistConnector.test.ts | 11 ++++------- lib/composio/connectors/isAllowedArtistConnector.ts | 12 +++++++++--- 2 files changed, 13 insertions(+), 10 deletions(-) diff --git a/lib/composio/connectors/__tests__/isAllowedArtistConnector.test.ts b/lib/composio/connectors/__tests__/isAllowedArtistConnector.test.ts index 995b3d5fe..af7299628 100644 --- a/lib/composio/connectors/__tests__/isAllowedArtistConnector.test.ts +++ b/lib/composio/connectors/__tests__/isAllowedArtistConnector.test.ts @@ -18,8 +18,8 @@ describe("isAllowedArtistConnector", () => { expect(isAllowedArtistConnector("twitter")).toBe(true); }); - it("should return false for 'linkedin' (label/owner-only)", () => { - expect(isAllowedArtistConnector("linkedin")).toBe(false); + it("should return true for 'linkedin'", () => { + expect(isAllowedArtistConnector("linkedin")).toBe(true); }); it("should return false for connectors not in ALLOWED_ARTIST_CONNECTORS", () => { @@ -39,15 +39,12 @@ describe("isAllowedArtistConnector", () => { }); describe("ALLOWED_ARTIST_CONNECTORS", () => { - it("should include tiktok, instagram, youtube, and twitter", () => { + it("should include tiktok, instagram, youtube, twitter, and linkedin", () => { expect(ALLOWED_ARTIST_CONNECTORS).toContain("tiktok"); expect(ALLOWED_ARTIST_CONNECTORS).toContain("instagram"); expect(ALLOWED_ARTIST_CONNECTORS).toContain("youtube"); expect(ALLOWED_ARTIST_CONNECTORS).toContain("twitter"); - }); - - it("should not include linkedin (label/owner-only)", () => { - expect(ALLOWED_ARTIST_CONNECTORS).not.toContain("linkedin"); + expect(ALLOWED_ARTIST_CONNECTORS).toContain("linkedin"); }); it("should be a readonly array", () => { diff --git a/lib/composio/connectors/isAllowedArtistConnector.ts b/lib/composio/connectors/isAllowedArtistConnector.ts index 1ca9eaa15..c10a688cd 100644 --- a/lib/composio/connectors/isAllowedArtistConnector.ts +++ b/lib/composio/connectors/isAllowedArtistConnector.ts @@ -2,10 +2,16 @@ * List of toolkit slugs that artists are allowed to connect. * Only these connectors will be shown in the artist-connectors API. * - * `twitter` is artist-facing social, same class as the existing three. - * `linkedin` is intentionally excluded — it is label/owner-only. + * `twitter` and `linkedin` are both artist-facing social, same class as the + * existing three. */ -export const ALLOWED_ARTIST_CONNECTORS = ["tiktok", "instagram", "youtube", "twitter"] as const; +export const ALLOWED_ARTIST_CONNECTORS = [ + "tiktok", + "instagram", + "youtube", + "twitter", + "linkedin", +] as const; export type AllowedArtistConnector = (typeof ALLOWED_ARTIST_CONNECTORS)[number]; From 85b26f586d18e7b758d4034e069cc1e7ecb62ae1 Mon Sep 17 00:00:00 2001 From: Sweets Sweetman Date: Thu, 18 Jun 2026 18:22:33 -0500 Subject: [PATCH 3/3] chore: remove unused ALLOWED_ARTIST_CONNECTORS from api (chat#1793) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The api copy of the artist connector allow-list had no runtime consumer — only its definition, test, and an (also-unused) barrel re-export. The connector routes are unopinionated (allow any connector for any account); the allow-list that actually drives the artist Connectors tab lives in `chat` (`lib/composio/allowedArtistConnectors.ts`). Removing the dead code. Supersedes the earlier plan to add twitter/linkedin to this api constant (decision: owner, 2026-06-18) — the artist allow-list is chat-only. Deletes isAllowedArtistConnector.ts + its test, and the barrel re-export. lib/composio suite green (149); no new tsc errors vs test (198 baseline). Co-Authored-By: Claude Opus 4.8 (1M context) --- .../isAllowedArtistConnector.test.ts | 53 ------------------- lib/composio/connectors/index.ts | 5 -- .../connectors/isAllowedArtistConnector.ts | 25 --------- 3 files changed, 83 deletions(-) delete mode 100644 lib/composio/connectors/__tests__/isAllowedArtistConnector.test.ts delete mode 100644 lib/composio/connectors/isAllowedArtistConnector.ts diff --git a/lib/composio/connectors/__tests__/isAllowedArtistConnector.test.ts b/lib/composio/connectors/__tests__/isAllowedArtistConnector.test.ts deleted file mode 100644 index af7299628..000000000 --- a/lib/composio/connectors/__tests__/isAllowedArtistConnector.test.ts +++ /dev/null @@ -1,53 +0,0 @@ -import { describe, it, expect } from "vitest"; -import { isAllowedArtistConnector, ALLOWED_ARTIST_CONNECTORS } from "../isAllowedArtistConnector"; - -describe("isAllowedArtistConnector", () => { - it("should return true for 'tiktok'", () => { - expect(isAllowedArtistConnector("tiktok")).toBe(true); - }); - - it("should return true for 'instagram'", () => { - expect(isAllowedArtistConnector("instagram")).toBe(true); - }); - - it("should return true for 'youtube'", () => { - expect(isAllowedArtistConnector("youtube")).toBe(true); - }); - - it("should return true for 'twitter'", () => { - expect(isAllowedArtistConnector("twitter")).toBe(true); - }); - - it("should return true for 'linkedin'", () => { - expect(isAllowedArtistConnector("linkedin")).toBe(true); - }); - - it("should return false for connectors not in ALLOWED_ARTIST_CONNECTORS", () => { - expect(isAllowedArtistConnector("googlesheets")).toBe(false); - expect(isAllowedArtistConnector("googledrive")).toBe(false); - expect(isAllowedArtistConnector("random")).toBe(false); - }); - - it("should return false for empty string", () => { - expect(isAllowedArtistConnector("")).toBe(false); - }); - - it("should be case-sensitive", () => { - expect(isAllowedArtistConnector("TikTok")).toBe(false); - expect(isAllowedArtistConnector("TIKTOK")).toBe(false); - }); -}); - -describe("ALLOWED_ARTIST_CONNECTORS", () => { - it("should include tiktok, instagram, youtube, twitter, and linkedin", () => { - expect(ALLOWED_ARTIST_CONNECTORS).toContain("tiktok"); - expect(ALLOWED_ARTIST_CONNECTORS).toContain("instagram"); - expect(ALLOWED_ARTIST_CONNECTORS).toContain("youtube"); - expect(ALLOWED_ARTIST_CONNECTORS).toContain("twitter"); - expect(ALLOWED_ARTIST_CONNECTORS).toContain("linkedin"); - }); - - it("should be a readonly array", () => { - expect(Array.isArray(ALLOWED_ARTIST_CONNECTORS)).toBe(true); - }); -}); diff --git a/lib/composio/connectors/index.ts b/lib/composio/connectors/index.ts index 848b357ba..be0178edb 100644 --- a/lib/composio/connectors/index.ts +++ b/lib/composio/connectors/index.ts @@ -5,9 +5,4 @@ export { type AuthorizeConnectorOptions, } from "./authorizeConnector"; export { disconnectConnector, type DisconnectConnectorOptions } from "./disconnectConnector"; -export { - ALLOWED_ARTIST_CONNECTORS, - isAllowedArtistConnector, - type AllowedArtistConnector, -} from "./isAllowedArtistConnector"; export { verifyConnectorOwnership } from "./verifyConnectorOwnership"; diff --git a/lib/composio/connectors/isAllowedArtistConnector.ts b/lib/composio/connectors/isAllowedArtistConnector.ts deleted file mode 100644 index c10a688cd..000000000 --- a/lib/composio/connectors/isAllowedArtistConnector.ts +++ /dev/null @@ -1,25 +0,0 @@ -/** - * List of toolkit slugs that artists are allowed to connect. - * Only these connectors will be shown in the artist-connectors API. - * - * `twitter` and `linkedin` are both artist-facing social, same class as the - * existing three. - */ -export const ALLOWED_ARTIST_CONNECTORS = [ - "tiktok", - "instagram", - "youtube", - "twitter", - "linkedin", -] as const; - -export type AllowedArtistConnector = (typeof ALLOWED_ARTIST_CONNECTORS)[number]; - -/** - * Check if a connector slug is an allowed artist connector. - * - * @param slug - */ -export function isAllowedArtistConnector(slug: string): slug is AllowedArtistConnector { - return (ALLOWED_ARTIST_CONNECTORS as readonly string[]).includes(slug); -}