Detect a Company's Technology Stack with the Clay CLI
Detect a Company's Technology Stack with the Clay CLI
Find out which software a company runs — CRM, analytics, hosting — using the clay CLI to run Clay's Website Technology Stack function (BuiltWith-backed).
What you will build
A CLI workflow that runs the tech-stack routine and matches target technologies against the real, comma-separated result string.
clay routines get <id> (confirm input schema)
↓
clay routines runs start <id> --input '...' (submit domain)
↓
clay routines runs get <run-id> --wait 60 (poll until complete)
↓
split on ", " and exact-match target technologies
AI Prompt
Using the clay CLI, detect a company's technology stack using Clay's "Website Technology Stack" managed function. Requirements: - Find the real routine id via `clay routines list`. - Confirm the input schema with `clay routines get <id>` -- required key is "Company Domain". - The result key is "Website Tech Stack" -- a single COMMA-SEPARATED STRING of technology names, NOT a JSON list. Split on ", " and match target technologies as exact tokens (case-insensitive); do not substring-match the raw blob, since related entries exist (e.g. "Hubspot Ads", "Hubspot Forms" alongside the bare "Hubspot" token). - Run the verification step below before finishing.
Prerequisites
- The
clayCLI on PATH, authenticated jq
1. Find and confirm the routine
clay routines list
Resolve the real routine id dynamically by matching on its display name rather than hardcoding it:
ROUTINE_ID=$(clay routines list | jq -r '.data[] | select(.name=="Website Technology Stack") | .id') clay routines get "$ROUTINE_ID"
2. Run it
clay routines runs start "$ROUTINE_ID" \
--input '{"items":[{"id":"ts-1","inputs":{"Company Domain":"clay.com"}}]}'
clay routines runs get <run-id> --wait 60
3. Match technologies locally
RAW=$(clay routines runs get <run-id> --wait 60 | jq -r '.data[0].result["Website Tech Stack"]') echo "$RAW" | tr ',' '\n' | sed 's/^ *//' | grep -ixE "Hubspot|Salesforce|Segment"
4. Verify the result
This example was tested live against clay.com.
clay routines runs start "$ROUTINE_ID" \
--input '{"items":[{"id":"ts-1","inputs":{"Company Domain":"clay.com"}}]}'
{ "routineRunId": "run_0tjznd3TKeM5xDJFQry", "mode": "inline", "status": "in_progress" }
clay routines runs get run_0tjznd3TKeM5xDJFQry --wait 60
Real confirmed result (abbreviated): a comma-separated string containing Hubspot, HubSpot Analytics, Hubspot Ads, Hubspot Forms, My Salesforce, and Segment — matching exactly the technologies found during earlier REST testing of the same domain.
How it works
Website Technology Stack returns BuiltWith-sourced technology detections as one comma-separated string per domain, potentially hundreds of tokens long. Splitting and doing exact (case-insensitive) token matching, rather than substring-matching the raw blob, avoids counting a technology's own sub-products (ad tools, form builders) as false positives for the base product name.
Common issues
Searching for "Forms" incorrectly matches "Hubspot Forms"
Cause: substring-matching the raw comma-separated string directly instead of splitting into tokens first.
Fix: split on ", ", then do exact (case-insensitive) equality against each token — never a raw substring search against the whole blob.
Result field looks like it should be a JSON array
Cause: the field's plural-sounding name ("Tech Stack") might suggest a list, but the real live response returns a plain string.
Fix: always split the raw string yourself; never assume it's already structured.
Next steps
- Find companies using competitor tech via query-mode — see the Clay technographic-prospecting CLI example
- Score qualified companies — see the Clay firmographic lead-scoring CLI example
- Source the domain list first — see the Clay TAM-by-industry CLI example
Verification
verification:
status: verified
tested_at: "2026-08-18"
cli_version: "0.7.0"
auth_method: "clay login --device"
command: "clay routines runs start function:t_0tjqmaaKYnuvGNmpagE --input '{\"items\":[{\"id\":\"ts-1\",\"inputs\":{\"Company Domain\":\"clay.com\"}}]}' && clay routines runs get run_0tjznd3TKeM5xDJFQry --wait 60"
expected_result: "status=complete, Website Tech Stack contains Hubspot, Salesforce (as 'My Salesforce'), and Segment"