Brasil API icon

Brasil API

Consulta endpoints públicos da BrasilAPI

Overview

This node integrates with BrasilAPI, a public API providing various Brazilian data endpoints. Specifically, the "Feriados por Ano" (Holidays by Year) operation fetches the list of official holidays for a given year in Brazil.

Use cases include:

  • Automating workflows that depend on Brazilian public holidays, such as scheduling, payroll processing, or business day calculations.
  • Integrating holiday data into calendars or notification systems.
  • Validating dates against holidays to avoid scheduling conflicts.

Example: Retrieve all Brazilian public holidays for the year 2025 to adjust delivery schedules accordingly.

Properties

Name Meaning
Ano The year for which to retrieve the list of holidays. Must be a number (e.g., 2025).

Output

The node outputs an array of JSON objects representing the holidays for the specified year. Each object typically contains details about a holiday, such as its date and name.

Example output structure (simplified):

[
  {
    "date": "2025-01-01",
    "name": "Confraternização Universal"
  },
  {
    "date": "2025-04-21",
    "name": "Tiradentes"
  }
  // ... more holidays
]

No binary data is produced by this operation.

Dependencies

  • Requires internet access to call the BrasilAPI public endpoints.
  • No authentication or API keys are needed since BrasilAPI is publicly accessible.
  • The node uses HTTP GET requests with a timeout of 10 seconds per request.

Troubleshooting

  • Timeouts or slow responses: The node sets a 10-second timeout; if the API is slow or unreachable, the node will error out. Check network connectivity or try again later.
  • Unsupported operation error: If the operation parameter is set incorrectly, the node throws an error indicating the operation is unsupported.
  • Invalid year input: Providing a non-numeric or invalid year may cause unexpected results or errors from the API.
  • API changes or downtime: Since the node depends on an external public API, any changes or downtime on BrasilAPI can affect functionality.

Links and References

Discussion