Classes Endpoint

GET /v1/classes

Response Format

The response is a JSON array of class objects.
Each class object contains the following keys:

name: the name of the class (a string).

environment: the name of the environment that this class exists in.
Note that the same class can exist in different environments and can have different parameters in each environment.

parameters: an object describing the parameters and default parameter values for the class.
The keys of this object are the parameter names (strings). Each value is the default value for the associated parameter (which can be any legal JSON value). If the value is null, then the parameter is required.

(Note that all other operations on classes require using the environment-specific endpoints below.)

Class List Caching

This and all other endpoints on this page return the classes currently known to the node classifier, which retrieves them periodically from the Puppet master. To force an update, use the update_classes endpoint. To determine when classes were last retrieved from the Puppet master, use the last_class_update endpoint.

GET /v1/environments/<environment>/classes

Retrieve a list of all classes known to the node classifier within the given environment.