Skip to content
FIVEGUARDIAN5DOCUMENTATION
/
Español Open the panel
Administration

API

How to automate FiveGuardian5 administration tasks through the API, securely.

What the API is

FiveGuardian5 provides a REST API that lets you perform programmatically the same tasks done in the panel: query devices, manage users and groups, create policies and so on. It is useful to integrate FiveGuardian5 with other systems in the organization or to automate repetitive tasks, such as onboarding or offboarding staff.

The API is accessed through the same domain as the panel, https://twh.fiveguardian5.com, always over HTTPS and with a valid credential.

Access credentials

Every API request must carry an access token. There are two options:

  • A user's personal token: acts with that user's permissions. Useful for testing or one-off tasks.
  • Service user: a technical account created under Team › Service Users, with its own role and tokens. This is the recommended option for permanent automations, because it does not depend on a person who might leave the organization.

When creating a token, choose an expiration date. The token value is shown only once; store it immediately in a secrets manager.

An API token gives access to the network configuration with its owner's permissions. Never include it in source code, shared documents, emails or chat messages. If you suspect it was exposed, delete it immediately and create a new one.

Permissions

Tokens inherit their user's role. Give each service user the minimum role the automation needs. For example, an integration that only reads the device inventory does not need permission to modify policies. Review role scope under Settings › Permissions.

Good practices

  • Use a different service user for each integration, with a name that states its purpose.
  • Set expirations and rotate tokens periodically.
  • Test automations in read-only mode first.
  • Actions performed through the API are recorded in Audit Events under the user or service user that performed them.
  • Before automating changes that affect many users (policies, DNS, routes), check with the FiveGuardian5 support team.

For the reference of available methods, request the API documentation through Support.