Portainer icon

Portainer

Work with Portainer API data to manage Docker

Secret → Inspect

AI-generated

Overview

This node operation inspects a Docker Swarm secret within a specified environment in Portainer. It retrieves detailed information about the secret identified by its Secret ID, allowing users to view its properties and metadata.

Use Case Examples

  1. Inspect a Docker Swarm secret to retrieve its detailed configuration and metadata for auditing or management purposes.
  2. Use this operation to verify the existence and details of a secret before using it in a Docker Swarm service.

Properties

Name Meaning
Environment ID The ID of the environment/endpoint in Portainer where the secret resides.
Secret ID The ID of the Docker Swarm secret to inspect.
Request Options Additional request options such as batching, SSL certificate validation, proxy settings, and timeout configuration to customize the API request behavior.

Output

JSON

  • id - The unique identifier of the secret.
  • version - Version information of the secret object.
  • createdAt - Timestamp when the secret was created.
  • updatedAt - Timestamp when the secret was last updated.
  • spec
    • name - The name of the secret.
    • labels - Labels associated with the secret for categorization or metadata.

Dependencies

  • An API key credential for authenticating with the Portainer API.

Troubleshooting

  • Ensure the Environment ID and Secret ID are correct and correspond to existing resources in Portainer.
  • Check API key credentials and permissions to access secrets in the specified environment.
  • If SSL issues occur, consider enabling the option to ignore SSL certificate validation, especially in development or self-signed certificate scenarios.
  • Verify network connectivity and proxy settings if used to ensure the request reaches the Portainer API endpoint.

Links

Discussion