diff --git a/libs/client/src/function.ts b/libs/client/src/function.ts
index b3846f0..82d2b99 100644
--- a/libs/client/src/function.ts
+++ b/libs/client/src/function.ts
@@ -7,7 +7,7 @@ import {
QueueStatus,
RequestLog,
} from './types';
-import { ensureAppIdFormat, isUUIDv4, isValidUrl, parseAppId } from './utils';
+import { ensureAppIdFormat, isValidUrl, parseAppId } from './utils';
/**
* The function input and other configuration when running
@@ -79,7 +79,6 @@ export function buildUrl(
Object.keys(params).length > 0
? `?${new URLSearchParams(params).toString()}`
: '';
- const parts = id.split('/');
// if a fal url is passed, just use it
if (isValidUrl(id)) {
@@ -87,12 +86,6 @@ export function buildUrl(
return `${url}${path}${queryParams}`;
}
- // TODO remove this after some time, fal.run should be preferred
- if (parts.length === 2 && isUUIDv4(parts[1])) {
- const host = 'gateway.alpha.fal.ai';
- return `https://${host}/trigger/${id}/${path}${queryParams}`;
- }
-
const appId = ensureAppIdFormat(id);
const subdomain = options.subdomain ? `${options.subdomain}.` : '';
const url = `https://${subdomain}fal.run/${appId}/${path}`;
diff --git a/libs/client/src/streaming.ts b/libs/client/src/streaming.ts
index 769107a..bcca90b 100644
--- a/libs/client/src/streaming.ts
+++ b/libs/client/src/streaming.ts
@@ -131,7 +131,6 @@ export class FalStream {
const token = await getTemporaryAuthToken(endpointId);
const { fetch = global.fetch } = getConfig();
const parsedUrl = new URL(this.url);
- console.log(this.url);
parsedUrl.searchParams.set('fal_jwt_token', token);
const response = await fetch(parsedUrl.toString(), {
method: method.toUpperCase(),
diff --git a/libs/client/src/utils.spec.ts b/libs/client/src/utils.spec.ts
index dcd6d58..f31b0bd 100644
--- a/libs/client/src/utils.spec.ts
+++ b/libs/client/src/utils.spec.ts
@@ -1,17 +1,6 @@
-import uuid from 'uuid-random';
-import { ensureAppIdFormat, isUUIDv4, parseAppId } from './utils';
+import { ensureAppIdFormat, parseAppId } from './utils';
describe('The utils test suite', () => {
- it('should match a valid v4 uuid', () => {
- const id = uuid();
- expect(isUUIDv4(id)).toBe(true);
- });
-
- it('should not match invalid v4 id', () => {
- const id = 'e726b886-e2c2-11ed-b5ea-0242ac120002';
- expect(isUUIDv4(id)).toBe(false);
- });
-
it('shoud match match a legacy appOwner-appId format', () => {
const id = '12345-abcde-fgh';
expect(ensureAppIdFormat(id)).toBe('12345/abcde-fgh');
diff --git a/libs/client/src/utils.ts b/libs/client/src/utils.ts
index dd9117d..e307ba3 100644
--- a/libs/client/src/utils.ts
+++ b/libs/client/src/utils.ts
@@ -1,12 +1,3 @@
-export function isUUIDv4(id: string): boolean {
- return (
- typeof id === 'string' &&
- id.length === 36 &&
- id[14] === '4' &&
- ['8', '9', 'a', 'b'].includes(id[19])
- );
-}
-
export function ensureAppIdFormat(id: string): string {
const parts = id.split('/');
if (parts.length > 1) {