@posthog/agent 2.3.285 → 2.3.293

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/agent.js CHANGED
@@ -245,7 +245,7 @@ import { v7 as uuidv7 } from "uuid";
245
245
  // package.json
246
246
  var package_default = {
247
247
  name: "@posthog/agent",
248
- version: "2.3.285",
248
+ version: "2.3.293",
249
249
  repository: "https://github.com/PostHog/code",
250
250
  description: "TypeScript agent framework wrapping Claude Agent SDK with Git-based task execution for PostHog",
251
251
  exports: {
@@ -4979,17 +4979,20 @@ function createCodexConnection(config) {
4979
4979
  }
4980
4980
 
4981
4981
  // src/utils/gateway.ts
4982
- function getLlmGatewayUrl(posthogHost, product = "posthog_code") {
4982
+ function getGatewayBaseUrl(posthogHost) {
4983
4983
  const url = new URL(posthogHost);
4984
4984
  const hostname = url.hostname;
4985
4985
  if (hostname === "localhost" || hostname === "127.0.0.1") {
4986
- return `${url.protocol}//localhost:3308/${product}`;
4986
+ return `${url.protocol}//localhost:3308`;
4987
4987
  }
4988
4988
  if (hostname === "host.docker.internal") {
4989
- return `${url.protocol}//host.docker.internal:3308/${product}`;
4989
+ return `${url.protocol}//host.docker.internal:3308`;
4990
4990
  }
4991
4991
  const region = hostname.match(/^(us|eu)\.posthog\.com$/)?.[1] ?? "us";
4992
- return `https://gateway.${region}.posthog.com/${product}`;
4992
+ return `https://gateway.${region}.posthog.com`;
4993
+ }
4994
+ function getLlmGatewayUrl(posthogHost, product = "posthog_code") {
4995
+ return `${getGatewayBaseUrl(posthogHost)}/${product}`;
4993
4996
  }
4994
4997
 
4995
4998
  // src/posthog-api.ts