Trinks icon

Trinks

Nó N8N para interagir com a API do Trinks

Actions46

Overview

This node integrates with the Trinks API to retrieve subscription plan data from the "Clube De Assinaturas" resource, specifically using the GET /v1/clube/planos operation. It is designed to fetch paginated lists of subscription plans, optionally filtered and sorted according to user preferences.

Common scenarios for this node include:

  • Retrieving active subscription plans for display or processing in workflows.
  • Fetching subscription plans with specific names or statuses.
  • Paginating through large sets of subscription plans.
  • Sorting plans by recent subscriptions, name, or status.

Practical example:

  • A business automating its subscription management might use this node to regularly sync active subscription plans into their CRM or analytics system, filtering only active plans and sorting them by most recent subscriptions.

Properties

Name Meaning
Page The page number of results to retrieve (pagination).
Page Size Number of subscription plans to return per page.
Somente Ativos Boolean flag to filter and return only active subscription plans (true or false).
Ordenar Por Sort order of the results. Options: "Assinaturas Mais Recente" (Most Recent Subscriptions), "Nome" (Name), "Status" (Status).
Nome Filter subscription plans by name (string match).

Output

The node outputs an array of JSON objects representing subscription plans retrieved from the API. Each item corresponds to a subscription plan with all its details as returned by the Trinks API.

If the API returns binary data (not indicated here), it would be included accordingly, but this operation primarily deals with JSON data.

Dependencies

  • Requires an API key credential and an establishment ID credential for authentication with the Trinks API.
  • The base URL for requests is https://api.trinks.com.
  • The node sends HTTP requests with headers including Accept: application/json, Content-Type: application/json, and authentication headers containing the API key and establishment ID.

Troubleshooting

  • Operation Not Found Error: If the specified operation is not recognized, the node will throw an error listing available operations. Ensure the operation name matches exactly one of the supported operations.
  • Authentication Errors: Missing or invalid API key or establishment ID credentials will cause request failures. Verify that credentials are correctly configured in n8n.
  • Invalid Query Parameters: Providing invalid values for pagination or filters may result in empty responses or errors from the API. Double-check property values like page numbers and boolean flags.
  • API Rate Limits or Network Issues: Standard HTTP errors may occur due to rate limiting or connectivity problems. Implement retry logic or check network status if such errors arise.

Links and References

Discussion