Clay Icon

Integrating Clay with n8n: Understanding HTTP Responses and Data Format | Clay

·
·

Hi Clay Team! I am currently integrating my Clay setup with n8n, an automation tool, using webhook triggers. In our workflow, Clay initiates the process by sending a HTTP request to an n8n webhook. My n8n workflow processes this request and at the end generates an output, which I wish to send back to Clay. To send the output back, I'm using the Respond to Webhook node in n8n which sends a HTTP response to the service that originally triggered the webhook. I am currently unclear about how Clay handles these HTTP responses. Here are my specific questions:

  • Can Clay handle HTTP responses from the webhooks it triggers?

  • If yes, how should we format the response data for Clay to correctly interpret it?

  • Is there a specific API endpoint in Clay we should send the response data to, or will it automatically be received by the original caller of the webhook?

  • What should be the structure of the response data? Specifically, should it be JSON-formatted or plain text?

  • Does Clay require any specific HTTP headers in the response?

  • Any guidance or additional documentation you can provide about how Clay handles incoming HTTP responses would be much appreciated.

Thank you in advance for your help. https://app.clay.com/workspaces/59172/tables/t_eBg3jrJWAQtc/views/gv_E4AZOBn9XeKs

  • Avatar of Clay Team
    Clay Team
    APP
    ·
    ·

    Hey Flory, thanks for reaching out! It looks like your HTTP request is set up properly and if you click inside the cell it seems like it got this response from it

    ba14add5-09f2-4100-b74c-82733bb87e30.png(24 kB)
  • Avatar of Clay Team
    Clay Team
    APP
    ·
    ·

    If the response or data you're looking for is different after it initially reaches n8n, you can maybe then create another HTTP call to GET the final output from n8n given that final endpoint.We also have the option to receive data to a specific Webhook cURL, you can generate it by creating a webhook column either by going to New Table (or Import within an existing table) -> Import from a Webhook

  • Avatar of Clay Team
    Clay Team
    APP
    ·
    ·

    Here's our documentation and a few videos if it helps! HTTP API integration. Quick video on how HTTP API works: https://www.loom.com/share/114ff06973bd4ed7985b32fa031be867Here's a video showing a few automations you can set up in Clay (webhook example in the first few minutes of this video): https://youtu.be/yw5paDolwTQ?feature=shared

  • Avatar of Flory M.
    Flory M.
    ·
    ·

    Thanks Arturo O.!