Portainer icon

Portainer

Interact with Portainer via API

Actions190

Custom Templates → Custom Template Inspect

AI-generated

Overview

This node interacts with the Portainer API to inspect a specific custom template by its identifier. It is useful in scenarios where users need to retrieve detailed information about a particular custom template managed within Portainer, such as for auditing, validation, or further automation workflows that depend on template data.

For example, a user might use this node to fetch the configuration details of a deployment template before triggering an update or to verify template settings as part of a compliance check.

Properties

Name Meaning
Id Template identifier (number). This is the unique ID of the custom template you want to inspect.

Output

The node outputs JSON data representing the detailed information of the specified custom template. The structure typically includes all properties and metadata associated with the template as returned by the Portainer API. This may include fields like template name, description, deployment parameters, and other configuration details.

If the node supports binary data output, it would relate to any file or artifact associated with the template, but based on the provided code snippet, only JSON output is expected.

Dependencies

  • Requires an active connection to a Portainer instance via its API.
  • Needs an API authentication token or key configured in the node credentials to authorize requests.
  • The base URL for the Portainer API must be set in the node credentials.

Troubleshooting

  • Common issues:

    • Invalid or missing template ID will result in errors or empty responses.
    • Incorrect or expired API credentials will cause authentication failures.
    • Network connectivity problems to the Portainer server can prevent successful API calls.
  • Error messages:

    • Authentication errors typically indicate invalid API keys or tokens; verify and update credentials.
    • "Template not found" errors suggest the provided template ID does not exist; double-check the ID.
    • Timeout or network errors require checking the Portainer server availability and network settings.

Links and References

Discussion