Clay icon

Clay

Interact with Clay data enrichment platform

Table → Find Record

AI-generated

Overview

The "Find Record" operation in the Clay node allows users to search for records within a specified Clay table by matching a field name and value. However, due to limitations of the Clay API, direct record search is not supported through the API. Instead, this operation provides guidance and alternatives for how to perform lookups or searches on Clay data.

This node is useful when you want to integrate Clay data enrichment workflows with n8n but need to handle record searching carefully because the API does not support direct queries. Practical use cases include:

  • Attempting to find if a record exists before creating or updating it.
  • Guiding users to alternative methods for searching Clay data, such as using Clay's built-in lookup features or exporting data for external filtering.
  • Automating workflows that depend on Clay data while acknowledging API constraints.

Properties

Name Meaning
Workspace Select your Clay workspace or enter workspace ID manually.
Workspace ID Manually enter your Clay workspace ID (used if manual entry selected).
Table Select your Clay table or enter table ID manually.
Table ID Manually enter your Clay table ID (used if manual entry selected).
Search Field The name of the field in the Clay table to search by (e.g., "Email").
Search Value The value to search for in the specified field (e.g., "john.doe@example.com").
Limit Maximum number of records to return (number between 1 and 100).

Output

The output JSON for the "Find Record" operation contains an informational message indicating that direct record search is not supported by the Clay API. It includes:

  • success: Always false for this operation.
  • operation: The string "findRecord".
  • message: Explanation that direct search is unsupported.
  • searchCriteria: Object containing the field, value, and limit used in the attempted search.
  • alternatives: Array of suggested alternative approaches to achieve similar results, such as:
    • Using Clay's built-in lookup functionality.
    • Exporting table data and searching externally.
    • Using Clay's Zapier integration.
    • Client-side filtering after export.
  • documentation: URL to Clay's guide on lookup data from other tables.
  • timestamp: ISO timestamp of the response generation.

Example output snippet:

{
  "success": false,
  "operation": "findRecord",
  "message": "Clay API does not support direct record search operations",
  "searchCriteria": {
    "field": "Email",
    "value": "john.doe@example.com",
    "limit": 10
  },
  "alternatives": [
    "Use Clay's built-in lookup functionality within Clay tables",
    "Export table data and search externally",
    "Use Clay's Zapier integration for search operations",
    "Implement client-side filtering after data export"
  ],
  "documentation": "https://www.clay.com/university/guide/lookup-data-from-other-tables",
  "timestamp": "2024-06-XXTXX:XX:XX.XXXZ"
}

No binary data output is produced by this operation.

Dependencies

  • Requires a valid API key credential for Clay to authenticate requests.
  • The node depends on the Clay webhook URL only for create/update operations; the "Find Record" operation does not make actual API calls but returns guidance.
  • No additional environment variables are required.
  • The node uses internal helper functions to validate inputs and construct responses.

Troubleshooting

  • Common Issue: Users might expect the node to perform actual record searches via the Clay API.

    • Explanation: The Clay API does not support direct record search endpoints.
    • Resolution: Use the suggested alternatives provided in the output, such as Clay's built-in lookup features or exporting data for external search.
  • Error Messages:

    • No specific errors are thrown for "Find Record" since it does not call the API directly.
    • If input properties like searchField or searchValue are missing, the node will throw validation errors prompting to provide these required fields.
  • Misconfiguration:

    • Selecting manual workspace or table IDs requires correct values matching those in the Clay web interface URLs.
    • Ensure the workspace and table IDs correspond to accessible resources in Clay.

Links and References

Discussion