VoidZero
Val Town is a collaborative website to build and scale JavaScript apps.
Deploy APIs, crons, & store data – all from the browser, and deployed in milliseconds.
Viewing readonly version of main branch: v28View latest version
Turn Clay into an API. Send data, get enriched results back.
Clay doesn't offer an API, but this val acts as one by sending data to Clay via webhook and receiving enriched results back via HTTP.
This example shows you how to input an email and see where the person works and the funding stage of their company.
- Copy the Clay template
- Remix this val
- Update CLAY_WEBHOOK_URL in
Environment variables
(get it from your Clay table'sWebhook
column) - Update the HTTP API endpoint in the
HTTP API
column in Clay to point to your val's/enriched
endpoint
Run test.ts
to test with sample data:
const testData = {
email: "steveykrouse@gmail.com"
};
Input:
{"email": "steveykrouse@gmail.com"}
Output:
{ email: "steveykrouse@gmail.com", person: "Steve Krouse", Company: "Val Town", funding: "SEED", totalFunding: "$7 million" }
Now you can enrich any data programmatically inside and outside of Clay!