Supercharge your AI agents with data from the web and beyond. Building the library for superintelligence. 🔥
TypeScript aiai-agentsai-crawlerai-scrapingai-searchcrawlerdata-extractionhtml-to-markdownllmmarkdownscraperscrapingweb-crawlerweb-dataweb-data-extractionweb-scraperweb-scrapingweb-searchwebscraping
Caleb: solve for typechecking on idempotencyKey on my machine
Caleb Peffer5a91d8425f40
diff --git a/apps/api/src/services/idempotency/validate.ts b/apps/api/src/services/idempotency/validate.tsindex ad6f2c450..1ca348bbc 100644--- a/apps/api/src/services/idempotency/validate.ts+++ b/apps/api/src/services/idempotency/validate.ts@@ -10,10 +10,12 @@ export async function validateIdempotencyKey(// // not returning for missing idempotency key for nowreturn true;}- if (!isUuid(idempotencyKey)) {- console.error("Invalid idempotency key provided in the request headers.");- return false;- }+ // Ensure idempotencyKey is treated as a string+ const key = Array.isArray(idempotencyKey) ? idempotencyKey[0] : idempotencyKey;+ if (!isUuid(key)) {+ console.error("Invalid idempotency key provided in the request headers.");+ return false;+ }const { data, error } = await supabase_service.from("idempotency_keys")