Skip to main content
All CollectionsHow-tosCertification Examples
Example Approach: Story Troubleshooting
Example Approach: Story Troubleshooting

Walk through common troubleshooting steps in Tines stories using a simple scenario.

Yanni Hajioannou avatar
Written by Yanni Hajioannou
Updated over 2 months ago

Overview

While working in Tines, you may encounter situations that require troubleshooting. This article outlines a scenario that uses common methods to help resolve issues and ensure your stories function correctly.

Tines references

Before getting started, we recommend familiarizing yourself with the surrounding functionality this article covers:

In this video, we walk through a story that experiences different errors. We'll also look at this video's topics at a high-level throughout this article.

Make it happen

Page behavior

In pages, the Page behavior setting defines what happens after your Button is clicked. It can navigate to the next page, redirect to a URL, or display a success message. By default, it’s set to Show success message. So, for example, if you want it to lead to another page, be sure to update this setting accordingly.

HTTP request error

When making a request to a service, it's crucial to verify that the request is successful before proceeding with your story. After configuring your actions, always run them to ensure you're receiving the expected data. You can always view more details in the Logs tab on the top-right corner of the properties panel in a given action.

In the example provided, we get a 404 response status code. The Logs of the action tell us that it cannot POST. This means that we are more than likely using the incorrect method in our API call:

Failed with 404 status code

Response body:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Error</title>
</head>
<body>
<pre>Cannot POST /api/v2/pokemon/120</pre>
</body>
</html>

We change the Method option in our HTTP request action from POST to GET. This returns a successful response. If you still get an error, it's always good to refer back to the documentation of the API you are reaching out to.

Re-emit last event

Instead of using the Run option on your actions, we recommend navigating to the last successfully executed action, clicking the three-dot menu in the bottom bar, and selecting Re-emit last event. This allows you to quickly verify whether the updated or modified action works as expected.

Incomplete path error

After re-emitting the last event from the top, we see that the final page action has the following error in the Logs tab:

Incomplete path for value: `get_random_image.body.sprites.front_default.`

This means that there was an extra period (".") at the end of the JSON path; we can also see this in the error itself. We'll fix this in the next section.

Edit page

Since this is a page we are working with, we'll click the Edit option.

This will open the page configuration and allow us to access its Elements. In this example, we're using an Image.

We click on where it says Couldn't load image. Here, we're able to see in the editor Path that error of incomplete path for value from before.

Once that extra period (".") is removed, the results are going to show what would be in that JSON path (since we fixed the previous HTTP action).

Review the results

After working through these issues, we run the story one last time to make sure it works as intended. We'll navigate to the first page action as an end-user → click Submit → See image results!

Did this answer your question?