# FAQ

### 1. Dictionary to JSON conversion

Q: I expect to send **JSON**, but actually do send some single quoted data, like a **Dictionary** - what can I do? Wrong example reference: \`{ "contacts": \[ {{ my\_contact\_details }} ] }\`

Wrong example result:

```
 {  
    "contacts": [ {
        'id': 'XXXXXX',
        'title': 'PJ',
        'salutation': 'Mrs',
        ...
```

A: Please add `| jsonify` to **convert a Dictionary to JSON**. So correctly it is: `{ "contacts": [ {{ my_contact_details | jsonify }} ] }`

### 2. Non public APIs

**Q**: As a SaaS company: We don't expose our APIs publicly yet, how can we work with Locoia already?\
**A**: These are some options:&#x20;

1. **Private API internally** in your environment - we can SSH, offer an agent to install on-prem to tunnel through
2. **Database access** to selected tables (e.g. also based on a replica database with some tables for additional security and reliability). It can be secured in various ways (e.g. IP white listing, SSH, user name and password, ...)
3. You can **store files on S3** and we pick them up regularly or we store them on S3 and you have e.g. a **Lambda trigger** set on new creation / edit of a file

### 3. Depth of integrations with Locoia

Q: How does Locoia differentiate in terms of **integration depth** and **quality**?\
A: Let's look at this by **breadth, length** and **depth**:

{% embed url="<https://youtu.be/q6G7AxFVknc>" %}

* **Breadth**:
  * Locoia **supports full API coverage** of endpoints (where possible), as API docs are usually fully included.
  * **Simplifying complex APIs**: Some APIs need three requests to satisfy one basic use-case from a business perspective. To simplify this, Locoia offers "**Super Actions**" that warp multiple steps into one. A good example for this is: In HubSpot one has to first create a ticket and then in a 2nd step (API call) associate the ticket to companies. Using actions, this can be done in one step in Locoia.
  * **Storing values**: In order to store values for later use, Locoia has an **internal data storage** that can be accessed via SQL. This allows to store values to be user in later workflow runs.
  * [**Multi-tenant flows**](/best-practice-guides/multi-tenant-flows.md): You can build one flow and run it for multiple of your customers. Say you are an agency and want to get specific Facebook campaign data - you can build it once and run it daily for all your customers with their specific credentials.
* **Length**:
  * **Idempotent** flow building: When a flow execution fails or Connector is down, we start the [retrying process](/automation/flow-debugger/automatic-retrying.md) automatically. This process picks up the **flow execution exactly where** it was interrupted and can access all the previous steps’ output in order to continue without interruption. E.g. if 1000 files are supposed to be uploaded sequentially and the flow fails due to network connectivity issues after 997, once the flow picks up, only the remaining 3 files are uploaded.
  * [**Multi flow trigger**](/connectors/helpers/multi-flow-trigger.md) allows to connect workflows like "functions in regular programming", including referencing the values of the parent flow or return values from the child flow.
  * Connections' **request length** can be open for 300 seconds before being cut off.
  * API **timeouts** or **network** errors:
    * Locoia has an [automatic retry mechanism](/automation/flow-debugger/automatic-retrying.md) for 429 on all REST http requests
    * One can build a flow involving error handling in order to handle 500, 502, or 404 http [errors automatically](/automation/flow-builder/custom-error-handling.md)
  * In order to support **large file imports** and complex integrations, flows can run for several hours in [Enterprise plans](https://www.locoia.com/pricing-automation/).
  * **Batching**: All flows can be build in a batched and stateful way in order to allow for restrictions of APIs - e.g. the Facebook Audience API only allows to upload 1,000 users at the same time, so if a customer wants to create a segment of 1 million users, one has to batch and upload 1,000 users 1000 times.
  * **File sizes**: Locoia supports file sizes up to 50MB standard and in some cases beyond, based on individual activation. The exact file-size depends on the [Locoia plan](https://www.locoia.com/pricing-automation/) and on the Connectors being used.
* **Depth**:
  * **99% of use-cases** possible that can be done in regular programming
  * **Full API coverage** of endpoints (where possible) and [wildcard actions](/automation/flow-builder/connectors-and-apis/wildcard-api-calls-and-actions.md) to support full flexibility
  * **Multi flow trigger** - as described above.
  * **Return values** can be determined per each flow e.g. also on webhooks as well as for multi-flows - values to be returned to the parent flow.
  * **Micro services** can be built with Locoia using the [webhook helper](/connectors/helpers/webhook-helper.md). Thus, Locoia can replace serverless services, such as e.g. AWS Lambda.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.locoia.com/best-practice-guides/faq.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
