Use the answer in your flow

Values from the API's answer used in your next messages and conditions, or saved on the person for later.

By Anant Gupta, founder4 min readOwner, Administrator or ManagerUpdated

Copies the whole guide as plain text, with every location and link, to paste into an assistant.Open in the app
On this page
  1. Before you start
  2. 1Name the response and send a test request
  3. 2Pick the field you need from Fields it sent back
  4. 3Save a value on the contact, if it should outlive this conversation
  5. 4Use it in a message or a condition
  6. If something is off
  7. Common questions
  8. Related guides

Before you start

  • A real call, with sample values.
  • 30 tests a minute.
  • 20 saved values.
Steps

Name the response and send a test request.

ResponseResponse nameSample valuesSend test request

The Response section: Response name, the sample value, Send test request.
The Response section on a phone.

You will see The answer, and which way it takes.

Pick the field you need from Fields it sent back.

Fields it sent backa rowcopy

Fields it sent back: each value of the answer, with copy and Save to contact on its row.
The same on a phone.

You will see Every field, ready to use.

Save a value on the contact, if it should outlive this conversation.

Save to contactTheir email / Their phone / Their name / A saved field

Save to contact, open on a field: Their email, Their phone, Their name, A saved field.
The same on a phone.

You will see Saved on the person.

Use it in a message or a condition.

A later messageInsert a variableFrom API calls

The message after Success, with {{city}} in its text: the variable button open on From API calls.
The same on a phone.

You will see The value in the message.

If something is off

Not found in the last test
Test again.
A message shows the variable empty
Use it after the step, on the Success way.
Test the request to see the fields it sends back
Run a test first.
Too many tests in a minute
30 tests a minute.

Common questions

Can I save an API value on the contact?

Yes. Save to contact on any field of the answer: as their email, phone or name, or as a saved field that later runs and conditions read too.

Can a condition check the API's answer?

Yes. Every field of a named response is a variable a Condition can check, and with Counts as success set to Any answer, the status code too.

Does the test request really call the API?

Yes. It makes the real call from our server with your sample values and shows the answer, its headers and exactly what was sent, with secrets masked.

For agents: plain text of this guide · all guides

For agents

Guide: Use the answer in your flow

This page: https://commentwatchdog.com/help/http-requests/use-the-answer-in-your-flow

Topic: HTTP requests

Time: about 4 minutes

Who can do it: Owner, Administrator or Manager

Author: https://anantgupta.xyz (Anant Gupta, founder of CommentWatchDog)

Start in the app: https://app.commentwatchdog.com/en/inbox

Result when done: Values from the API's answer used in your next messages and conditions, or saved on the person for later.

Context: Name the response once and every field it sends back can go into later messages, requests and conditions by that name, like {{order.items[0].name}} or {{order.$status}}. Test the request for real with sample values and the step lists the fields it sent back with their values, ready to insert. A value worth keeping beyond this conversation can be saved on the contact: as their email, phone or name, or as a saved field that later runs and conditions read too.

Before you start

1. The test makes the real call from our server, with sample values in place of the variables.

2. Up to 30 test requests a minute per person.

3. The answer is read up to 512 KB; up to 20 values saved on the contact per step.

Steps

Step 1 of 4: Name the response and send a test request.

Where: In the step's Response section, under Headers: Response name (for example ship), then Sample values for its variables (for example 97205 for zip), then Send test request. Once a test has run, the button reads Test again.

Link: https://app.commentwatchdog.com/en/inbox (Open the app)

Screenshot: https://commentwatchdog.com/media/shots/dm-node-http-more.en.webp (The Response section: Response name, the sample value, Send test request.)

Screenshot: https://commentwatchdog.com/media/shots/dm-node-http-more-phone.en.webp (The Response section on a phone.)

You should see: Under the button: the status (200), the time it took and which way it would take, Takes the Success way or Takes the Failed way. Response, Headers and What was sent, under the fields, open the raw answer and exactly what was sent.

Step 2 of 4: Pick the field you need from Fields it sent back.

Where: Under the result, Fields it sent back lists every value in the answer by where it sits, with the value under it: Status code 200, country United States, places[0].place name Portland. The copy button on a row copies its variable, for example {{ship.places[0].place name}}. Later steps also find them under the variable button, in From API calls.

Screenshot: https://commentwatchdog.com/media/shots/dm-http-test.en.webp (Fields it sent back: each value of the answer, with copy and Save to contact on its row.)

Screenshot: https://commentwatchdog.com/media/shots/dm-http-test-phone.en.webp (The same on a phone.)

You should see: Under the list: Insert any of these later with the variable button. Copy one to paste it yourself. The fields stay listed (from the last test) after you close the step.

Step 3 of 4: Save a value on the contact, if it should outlive this conversation.

Where: Save to contact, on a field's row, opens four choices: Their email, Their phone, Their name, or A saved field. The row's button then reads the choice, and the value is listed under Saved to the contact, below the fields, where you can change where it goes or remove it.

Screenshot: https://commentwatchdog.com/media/shots/dm-http-save.en.webp (Save to contact, open on a field: Their email, Their phone, Their name, A saved field.)

Screenshot: https://commentwatchdog.com/media/shots/dm-http-save-phone.en.webp (The same on a phone.)

You should see: Under Saved to the contact: the field's place in the answer (places[0].place name), where it goes, and Last test: with the value it read (Portland).

Step 4 of 4: Use it in a message or a condition.

Where: In a later message, press the {x} variable button beside Insert, under the text. Its list opens on From API calls: the response’s status code (ship.$status, with 200 from the last test) and the value you kept as a variable (city). Insert one, for example: Good news! Beans reach {{city}} in 3 to 5 business days. In a Condition, check the value or the status code.

Screenshot: https://commentwatchdog.com/media/shots/dm-http-use.en.webp (The message after Success, with {{city}} in its text: the variable button open on From API calls.)

Screenshot: https://commentwatchdog.com/media/shots/dm-http-use-phone.en.webp (The same on a phone.)

You should see: The message shows the variable in double braces, here {{city}}, in the panel and on the step; in a test run it reads the real value.

If something is off

Problem: Not found in the last test

Fix: The path you saved is not in the latest answer. Test again with sample values that return it.

Problem: A message shows the variable empty

Fix: The value is used before its HTTP step can have run, or the request took the Failed way. The builder warns when a response is used before its step.

Problem: Test the request to see the fields it sends back

Fix: No test has run yet. Fill the sample values and press Send test request.

Problem: Too many tests in a minute

Fix: Up to 30 tests a minute per person. Wait a moment and test again.

Common questions

Question: Can I save an API value on the contact?

Answer: Yes. Save to contact on any field of the answer: as their email, phone or name, or as a saved field that later runs and conditions read too.

Question: Can a condition check the API's answer?

Answer: Yes. Every field of a named response is a variable a Condition can check, and with Counts as success set to Any answer, the status code too.

Question: Does the test request really call the API?

Answer: Yes. It makes the real call from our server with your sample values and shows the answer, its headers and exactly what was sent, with secrets masked.

Related guides

Send an HTTP request from a flow: https://commentwatchdog.com/help/http-requests/send-an-http-request-from-a-flow

Custom fields: https://commentwatchdog.com/help/people/custom-fields

Build the request with AI: https://commentwatchdog.com/help/http-requests/build-the-request-with-ai

Plain text of this guide: https://commentwatchdog.com/help/http-requests/use-the-answer-in-your-flow.md

All guides for assistants: https://commentwatchdog.com/help/llms.txt

Put a watchdog on your pages tonight

Meta API approved Start your free trial

Free for 7 days, no credit card required