How to Authenticate for LogMan.io API¶
All API requests to LogMan.io require authentication using an API key. This ensures secure and controlled access to your system's data and functionality.
Generating an API Key¶
To create a new API key, follow these steps:
- Log in to the LogMan.io web interface
- Navigate to Auth and Roles > API Keys
- Click the New API key button
-
Configure the following settings:
- Name: Choose a descriptive name for your API key (e.g., "Integration Service", "Monitoring Tool")
- Context: Select the tenant this key should have access to
- Resources: Select the resources this key should have access to
- Expiration: Set an expiration date for automatic key rotation and enhanced security
-
Generate the key and securely store it in a safe location
Using the API Key¶
Include your API key in the Authorization header of every request you make to the LogMan.io API. Important: Never share your API key or commit it to version control systems. Treat it as a sensitive credential like a password.
Understanding Authorization Scope¶
Each API key has a defined scope that determines what resources and data it can access:
- Tenant Context: By default, an API key is scoped to a single selected tenant, limiting access to that tenant's data and resources
- Global Context: System administrators can create API keys with Global scope for performing system-level administrative tasks across all tenants
- Resource Restrictions: Different API endpoints require different resources. Ensure your API key's scope includes the necessary resources for the endpoints you plan to use.