Focus Chat API icon

Focus Chat API

Node de integração Focus Chat

Overview

This node integrates with the Focus Chat API, enabling users to interact with various messaging-related resources such as action cards, message templates, and quick replies. It is useful for automating retrieval and synchronization of messaging components within a chat or customer support system.

Common scenarios include:

  • Fetching specific action cards or message templates by their IDs.
  • Listing available quick replies either for the company linked to the channel or for a specified user.
  • Synchronizing message templates for WhatsApp Cloud channels.

Practical examples:

  • Automatically retrieving a quick reply template to send in response to a customer query.
  • Syncing updated WhatsApp Cloud message templates to keep the system current.
  • Listing all system-wide action cards to display options in a chatbot interface.

Properties

Name Meaning
Access Token The access token for authenticating with the Focus Chat API channel.
Ação The action to perform; options include:
- Busca Um Cartão De Ação Pelo Seu ID (Fetch an action card by its ID)
- Busca Um Template Pelo Seu ID (Somente WhatsApp Cloud) (Fetch a message template by ID)
- Busca Uma Resposta Rápida Pelo Seu ID (Fetch a quick reply by ID)
- Lista As Respostas Rápidas Da Empresa Vinculada Ao Canal (List quick replies linked to company)
- Lista As Respostas Rápidas Do Usuário Especificado (List quick replies for a specified user)
- Lista Os Cartões De Ação Do Sistema (List system action cards)
- Lista Os Templates De Mensagem Do Canal De Tipo WhatsAppCloud (List WhatsApp Cloud message templates)
- Solicita Sincronização Dos Templates De Mensagem Do Canal De Tipo WhatsAppCloud (Request sync of WhatsApp Cloud message templates)

Output

The node outputs JSON data corresponding to the requested resource or list. The structure depends on the selected action but generally includes details about action cards, templates, or quick replies retrieved from the Focus Chat API.

If binary data were involved (not indicated here), it would typically represent media or files related to messages, but this node focuses on JSON responses.

Dependencies

  • Requires an active internet connection to reach https://api.focuschat.com.br.
  • Needs a valid access token for authentication with the Focus Chat API.
  • No additional environment variables or external services are explicitly required beyond the access token.

Troubleshooting

  • Invalid or missing access token: The node requires a valid access token. Ensure the token is correctly provided and has not expired.
  • API endpoint errors: Network issues or incorrect API URLs can cause failures. Verify connectivity and that the base URL is accessible.
  • Unsupported actions: Selecting an action incompatible with the channel type (e.g., requesting WhatsApp Cloud templates on a non-WhatsApp channel) may result in errors.
  • Empty or malformed responses: Check if the requested resource exists and the IDs used are correct.

Links and References

  • Focus Chat API Documentation (assumed official API docs)
  • n8n documentation on creating custom nodes and using HTTP request nodes for API integration

Discussion