Public
Like
clay-proxy
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: v73View latest version
Simple API / SDK to enrich data with Clay.
import { clay } from "https://esm.town/v/charmaine/clay-proxy/sdk.ts";
// Enrich GitHub user
const githubUser = await clay({
github_username: "charmaine",
repo: "val-town/vt",
source: "github_stargazer"
});
// Enrich by email
const emailUser = await clay({
email: "charmainekmlee@gmail.com",
source: "user_signup"
});
console.log(githubUser.linkedin); // LinkedIn URL
console.log(emailUser.tech_stack); // Tech stack
console.log(emailUser.funding); // Funding info
If you need to get an email from a GitHub username first:
import { emailsFromGitHubUsername } from "https://esm.town/v/stevekrouse/github-user-email/index.ts";
const emails = await emailsFromGitHubUsername("charmaine");
const email = emails[0]; // "charmainekmlee@gmail.com"
// Then enrich with Clay
const result = await clay({
email,
github_username: "charmaine",
source: "github_stargazer"
});
email- Email addressgithub_username- GitHub usernamesource- Data sourcerepo- Repository name
linkedin- LinkedIn URLlinkedin_data- LinkedIn profile datatech_stack- Technology stackfunding- Funding information
curl -X POST https://clayapidemo.val.run/enrich \ -H "Content-Type: application/json" \ -d '{"email": "user@example.com"}'