Superlogica icon

Superlogica

Consumir API do Superlogica Condomínios

Overview

This node integrates with the Superlogica Condomínios API to list condominium records. It is designed to fetch and filter condominium data based on various criteria such as active status, exclusion of a model condominium, and the level of detail in the response.

Common scenarios where this node is beneficial include:

  • Retrieving a paginated list of active condominiums for reporting or dashboard display.
  • Filtering out template or model condominiums that are not relevant for operational use.
  • Fetching only key columns or specific financial plan data to optimize data handling and reduce payload size.

Practical example:

  • A property management system can use this node to synchronize its database with the latest list of active condominiums from Superlogica, ensuring up-to-date information for billing or communication purposes.

Properties

Name Meaning
Somente Condomínios Ativos Return only active condominiums (true/false)
Ignorar Condomínio Modelo Ignore the old model condominium used previously (true/false)
Apenas Colunas Principais Return a filtered response with only some main fields (true/false)
Apenas Dados do Plano de Contas Return only the ID of the financial plan associated with the condominium (true/false)
Com Data de Fechamento Include the closing date of the condominium in the response (true/false)
Itens Por Página Number of items returned per request, maximum 50
Página Current page number, used together with "Itens Por Página" for pagination

Output

The output is an array of JSON objects representing condominiums matching the specified filters and pagination settings. Each item contains fields depending on the selected options:

  • If "Apenas Colunas Principais" is true, the response includes only key condominium fields.
  • If "Apenas Dados do Plano de Contas" is true, the response includes only the financial plan ID.
  • If "Com Data de Fechamento" is true, the condominium's closing date is included.
  • The output respects pagination parameters ("Itens Por Página" and "Página").

No binary data output is indicated by the source code.

Example output snippet (conceptual):

[
  {
    "id": 123,
    "nome": "Condomínio Exemplo",
    "ativo": true,
    "dataFechamento": "2024-06-30",
    "planoContasId": 456
  },
  ...
]

Dependencies

  • Requires an API key credential for authenticating with the Superlogica API.
  • The node uses the Superlogica API endpoint, defaulting to https://api.superlogica.net/v2/condor if no custom URL is provided.
  • Proper configuration of credentials with app token and access token is necessary.

Troubleshooting

  • Missing Credentials Error: If credentials are not provided or invalid, the node throws an error indicating missing credentials. Ensure that the API authentication tokens are correctly configured in n8n.
  • Pagination Limits: The "Itens Por Página" parameter has a maximum value of 50. Setting a higher value may cause errors or unexpected behavior.
  • API Rate Limits: Frequent requests might hit API rate limits imposed by Superlogica. Implement retry logic or reduce request frequency if encountering rate limit errors.
  • Filtering Issues: Incorrect boolean flags may result in empty or incomplete results. Verify the flags like "Somente Condomínios Ativos" and "Ignorar Condomínio Modelo" to match your filtering needs.

Links and References

Discussion