External API

Hi,

In the API tester why the data shows like this, with lots of backslashes?


When setting the API endpoint in the global then the data that it fetches is stored in data? Like I could access the keys, data.status or how? I tried but nothing, see the fields from the screenshot referenced above.

Thanks

Hey Abd,

The backslashes are used to escape special characters within the JSON string. In JSON, characters like double quotes (") have special meaning (they delimit strings). To include a literal double quote within a string, it must be escaped with a backslash (").

How do I do that? Could you explain? Also about the data, what should I target to access the keys?

I’m sending you credentials to have a look at the issue what I’m having with it.

Hello @abdurrehman,

We cannot access the given site. Please check the screenshot below.

Thanks.

I know why is that because you’d access to other site and currently logged in with that user that’s why not able to login, please log out from the user you’re logged in with another site and these credentials should work fine as when I shared then checked them as well.

Hey @abdurrehman,

You should have this Looper Provider API settings:

With the help of the {{dc:looper:debug_consumer}}, you can get this:

You can use it to access the data:

<p>Status: {{dc:looper:field key="status"}}</p>
<p>Username: {{dc:looper:field key="data.username"}}</p>

Hope this helps.