# 🛠technical-support
Ryan Smith
Ryan Smith·12 replies

Hi guys when using api call nodes im seeing object.object as the response, is there a way i can get the data and include only relevant parts from it in response?

Sahil | YourGPT
Sahil | YourGPT18/03/2025 10:20

hello @Sumishī
When you print the response, it is an object received from the API. However, in chat, only text can be rendered. If you need to store the details separately, you can use a code block to assign different parts of the response to multiple variables and then use those variables as needed.

Ryan Smith
Ryan Smith18/03/2025 10:22

So what I need to do is receive the data in the api call block but be able to send to the user some parts from it

Ryan Smith
Ryan Smith18/03/2025 10:23

As not all of it is relevant data

Sahil | YourGPT
Sahil | YourGPT18/03/2025 10:27

Receive the API call data in FLOW.last_response.

In a code node, you can map the data into variables.

FLOW.name = FLOW.last_response.user.name

Alternatively, you can use the AI response node to pass the stored data into a prompt and instruct the AI to generate human-readable text from it.

Ryan Smith
Ryan Smith18/03/2025 10:35

I tried this but it isn't able to give any usable information when passing it to AI response node.

When I try using a code node and execute the api that way it still is unreadable after storing in to the variable FLOW.problem_solution

Ryan Smith
Ryan Smith18/03/2025 10:35

And I can see in the logs the api call is successful and the data is there

Sahil | YourGPT
Sahil | YourGPT18/03/2025 10:37

Where are you storing the api response in which variable ?

Ryan Smith
Ryan Smith18/03/2025 10:40

I was trying to store the api response into the variable i created FLOW.problem_solution

Sahil | YourGPT
Sahil | YourGPT18/03/2025 10:42

After the AI success path, can you insert a code block containing this code and log the variable into next text node?

FLOW.problem_solution = JSON.stringify(FLOW.problem_solution)

Ryan Smith
Ryan Smith18/03/2025 10:46

Will give it a try

Ryan Smith
Ryan Smith18/03/2025 10:52

Looks good thankyou, so for future when I add more api i should implement a code block following

Sahil | YourGPT
Sahil | YourGPT18/03/2025 11:36

For now, yes. Some parsing still needs to be done. We’re currently reviewing it and working on improvements.