Apply
Smarter API command-line interface ‘apply’ view /api/v1/cli/apply/
- exception smarter.apps.api.v1.cli.views.apply.APIV1CLIViewManifestMalFormedError(message='')
Bases:
APIV1CLIViewErrorCustom error for when a manifest is malformed.
- exception smarter.apps.api.v1.cli.views.apply.APIV1CLIViewManifestNotFoundError(message='')
Bases:
APIV1CLIViewErrorCustom error for when a manifest is not found.
- class smarter.apps.api.v1.cli.views.apply.ApiV1CliApplyApiView(*args, **kwargs)
Bases:
CliBaseApiViewThis is the API endpoint for the ‘apply’ command in the Smarter command-line interface (CLI).
The ‘apply’ command is a Smarter Brokered and Journaled operation that is used with all Smarter resources. It expects a YAML manifest in smarter.sh/v1 format.
The client making the HTTP request to this endpoint is expected to be the Smarter CLI, which is written in Golang and available on Windows, macOS, and Linux.
The response from this endpoint is a JSON object.
This class is a child of the Django Rest Framework View.
- property formatted_class_name: str
Returns the class name in a formatted string along with the name of this mixin.
- post(request, *args, **kwargs)
Handles POST requests to apply a Smarter manifest.
- smarter.apps.api.v1.cli.views.apply.should_log(level)
Check if logging should be done based on the waffle switch.