All URIs are relative to /api/v1
| Method | HTTP request | Description |
|---|---|---|
| create_device | POST /devices | |
| decommission_device | PUT /devices/{name}/decommission | |
| delete_device | DELETE /devices/{name} | |
| get_device | GET /devices/{name} | |
| get_device_application_console | GET /ws/v1/devices/{name}/applications/{appname}/console | |
| get_device_console | GET /ws/v1/devices/{name}/console | |
| get_device_last_seen | GET /devices/{name}/lastseen | |
| get_device_status | GET /devices/{name}/status | |
| get_rendered_device | GET /devices/{name}/rendered | |
| list_devices | GET /devices | |
| patch_device | PATCH /devices/{name} | |
| patch_device_status | PATCH /devices/{name}/status | |
| replace_device | PUT /devices/{name} | |
| replace_device_status | PUT /devices/{name}/status | |
| restart_device_application | POST /devices/{name}/applications/{appname}/actions/restart | |
| start_device_application | POST /devices/{name}/applications/{appname}/actions/start | |
| stop_device_application | POST /devices/{name}/applications/{appname}/actions/stop |
Device create_device(device)
Create a Device resource.
import flightctl
from flightctl.models.device import Device
from flightctl.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = flightctl.Configuration(
host = "/api/v1"
)
# Enter a context with an instance of the API client
with flightctl.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = flightctl.DeviceApi(api_client)
device = flightctl.Device() # Device |
try:
api_response = api_instance.create_device(device)
print("The response of DeviceApi->create_device:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DeviceApi->create_device: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| device | Device |
No authorization required
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 201 | Created | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 409 | Conflict | - |
| 429 | Too Many Requests | - |
| 503 | Service Unavailable | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Device decommission_device(name, device_decommission)
schedule the device to decommission
import flightctl
from flightctl.models.device import Device
from flightctl.models.device_decommission import DeviceDecommission
from flightctl.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = flightctl.Configuration(
host = "/api/v1"
)
# Enter a context with an instance of the API client
with flightctl.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = flightctl.DeviceApi(api_client)
name = 'name_example' # str | The name of the Device resource to decommission.
device_decommission = flightctl.DeviceDecommission() # DeviceDecommission |
try:
api_response = api_instance.decommission_device(name, device_decommission)
print("The response of DeviceApi->decommission_device:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DeviceApi->decommission_device: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | The name of the Device resource to decommission. | |
| device_decommission | DeviceDecommission |
No authorization required
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 404 | Not Found | - |
| 409 | Conflict | - |
| 429 | Too Many Requests | - |
| 503 | Service Unavailable | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Status delete_device(name)
Delete a Device resource.
import flightctl
from flightctl.models.status import Status
from flightctl.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = flightctl.Configuration(
host = "/api/v1"
)
# Enter a context with an instance of the API client
with flightctl.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = flightctl.DeviceApi(api_client)
name = 'name_example' # str | The name of the Device resource to delete.
try:
api_response = api_instance.delete_device(name)
print("The response of DeviceApi->delete_device:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DeviceApi->delete_device: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | The name of the Device resource to delete. |
No authorization required
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 404 | Not Found | - |
| 429 | Too Many Requests | - |
| 503 | Service Unavailable | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Device get_device(name)
Get a Device resource.
import flightctl
from flightctl.models.device import Device
from flightctl.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = flightctl.Configuration(
host = "/api/v1"
)
# Enter a context with an instance of the API client
with flightctl.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = flightctl.DeviceApi(api_client)
name = 'name_example' # str | The name of the Device resource to get.
try:
api_response = api_instance.get_device(name)
print("The response of DeviceApi->get_device:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DeviceApi->get_device: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | The name of the Device resource to get. |
No authorization required
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 404 | Not Found | - |
| 429 | Too Many Requests | - |
| 503 | Service Unavailable | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
get_device_application_console(name, appname, console_type, force=force)
Open a WebSocket console session to an application running on the Device.
import flightctl
from flightctl.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = flightctl.Configuration(
host = "/api/v1"
)
# Enter a context with an instance of the API client
with flightctl.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = flightctl.DeviceApi(api_client)
name = 'name_example' # str | The name of the Device resource.
appname = 'appname_example' # str | The name of the application to connect to.
console_type = 'console_type_example' # str | The type of console session to open. \"serial\" opens a text terminal; \"vnc\" opens a VNC proxy tunnel.
force = False # bool | If true, take over an already-active console session of the same type for this application instead of failing with a 409 Conflict. The replaced session is disconnected and told why. (optional) (default to False)
try:
api_instance.get_device_application_console(name, appname, console_type, force=force)
except Exception as e:
print("Exception when calling DeviceApi->get_device_application_console: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | The name of the Device resource. | |
| appname | str | The name of the application to connect to. | |
| console_type | str | The type of console session to open. "serial" opens a text terminal; "vnc" opens a VNC proxy tunnel. | |
| force | bool | If true, take over an already-active console session of the same type for this application instead of failing with a 409 Conflict. The replaced session is disconnected and told why. | [optional] [default to False] |
void (empty response body)
No authorization required
- Content-Type: Not defined
- Accept: Not defined
| Status code | Description | Response headers |
|---|---|---|
| 101 | Switching Protocols | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 404 | Not Found | - |
| 409 | Conflict | - |
| 429 | Too Many Requests | - |
| 500 | Internal Server Error | - |
| 504 | Gateway Timeout | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
get_device_console(name)
Open a WebSocket console session to the Device.
import flightctl
from flightctl.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = flightctl.Configuration(
host = "/api/v1"
)
# Enter a context with an instance of the API client
with flightctl.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = flightctl.DeviceApi(api_client)
name = 'name_example' # str | The name of the Device resource.
try:
api_instance.get_device_console(name)
except Exception as e:
print("Exception when calling DeviceApi->get_device_console: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | The name of the Device resource. |
void (empty response body)
No authorization required
- Content-Type: Not defined
- Accept: Not defined
| Status code | Description | Response headers |
|---|---|---|
| 101 | Switching Protocols | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 404 | Not Found | - |
| 429 | Too Many Requests | - |
| 500 | Internal Server Error | - |
| 504 | Gateway Timeout | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
DeviceLastSeen get_device_last_seen(name)
Get the last seen timestamp of the Device resource.
import flightctl
from flightctl.models.device_last_seen import DeviceLastSeen
from flightctl.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = flightctl.Configuration(
host = "/api/v1"
)
# Enter a context with an instance of the API client
with flightctl.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = flightctl.DeviceApi(api_client)
name = 'name_example' # str | The name of the Device resource to get the last seen timestamp for.
try:
api_response = api_instance.get_device_last_seen(name)
print("The response of DeviceApi->get_device_last_seen:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DeviceApi->get_device_last_seen: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | The name of the Device resource to get the last seen timestamp for. |
No authorization required
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | - |
| 204 | No Content | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 404 | Not Found | - |
| 429 | Too Many Requests | - |
| 503 | Service Unavailable | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Device get_device_status(name)
Get the status of a Device resource.
import flightctl
from flightctl.models.device import Device
from flightctl.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = flightctl.Configuration(
host = "/api/v1"
)
# Enter a context with an instance of the API client
with flightctl.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = flightctl.DeviceApi(api_client)
name = 'name_example' # str | The name of the Device resource to get.
try:
api_response = api_instance.get_device_status(name)
print("The response of DeviceApi->get_device_status:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DeviceApi->get_device_status: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | The name of the Device resource to get. |
No authorization required
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 404 | Not Found | - |
| 429 | Too Many Requests | - |
| 503 | Service Unavailable | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Device get_rendered_device(name, known_rendered_version=known_rendered_version)
Get the rendered device.
import flightctl
from flightctl.models.device import Device
from flightctl.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = flightctl.Configuration(
host = "/api/v1"
)
# Enter a context with an instance of the API client
with flightctl.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = flightctl.DeviceApi(api_client)
name = 'name_example' # str | The name of the Device resource to get the rendered device specification for.
known_rendered_version = 'known_rendered_version_example' # str | The last known renderedVersion. (optional)
try:
api_response = api_instance.get_rendered_device(name, known_rendered_version=known_rendered_version)
print("The response of DeviceApi->get_rendered_device:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DeviceApi->get_rendered_device: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | The name of the Device resource to get the rendered device specification for. | |
| known_rendered_version | str | The last known renderedVersion. | [optional] |
No authorization required
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | - |
| 204 | No Content | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 404 | Not Found | - |
| 409 | Conflict | - |
| 429 | Too Many Requests | - |
| 503 | Service Unavailable | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
DeviceList list_devices(var_continue=var_continue, label_selector=label_selector, field_selector=field_selector, limit=limit, summary_only=summary_only, cve_id=cve_id)
List Device resources.
import flightctl
from flightctl.models.device_list import DeviceList
from flightctl.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = flightctl.Configuration(
host = "/api/v1"
)
# Enter a context with an instance of the API client
with flightctl.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = flightctl.DeviceApi(api_client)
var_continue = 'var_continue_example' # str | An optional parameter to query more results from the server. The value of the paramter must match the value of the 'continue' field in the previous list response. (optional)
label_selector = 'label_selector_example' # str | A selector to restrict the list of returned objects by their labels. Defaults to everything. (optional)
field_selector = 'field_selector_example' # str | A selector to restrict the list of returned objects by their fields, supporting operators like '=', '==', and '!=' (e.g., \"key1=value1,key2!=value2\"). (optional)
limit = 56 # int | The maximum number of results returned in the list response. The server will set the 'continue' field in the list response if more results exist. The continue value may then be specified as parameter in a subsequent query. (optional)
summary_only = True # bool | A boolean flag to include only a summary of the devices. When set to true, the response will contain only the summary information. Only the 'owner' and 'labelSelector' parameters are supported when 'summaryOnly' is true. (optional)
cve_id = 'cve_id_example' # str | Filter devices by CVE ID. Only returns devices whose OS image digest has the specified vulnerability. Must be a MITRE-style identifier (CVE-YYYY-sequence, e.g. CVE-2024-12345). (optional)
try:
api_response = api_instance.list_devices(var_continue=var_continue, label_selector=label_selector, field_selector=field_selector, limit=limit, summary_only=summary_only, cve_id=cve_id)
print("The response of DeviceApi->list_devices:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DeviceApi->list_devices: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| var_continue | str | An optional parameter to query more results from the server. The value of the paramter must match the value of the 'continue' field in the previous list response. | [optional] |
| label_selector | str | A selector to restrict the list of returned objects by their labels. Defaults to everything. | [optional] |
| field_selector | str | A selector to restrict the list of returned objects by their fields, supporting operators like '=', '==', and '!=' (e.g., "key1=value1,key2!=value2"). | [optional] |
| limit | int | The maximum number of results returned in the list response. The server will set the 'continue' field in the list response if more results exist. The continue value may then be specified as parameter in a subsequent query. | [optional] |
| summary_only | bool | A boolean flag to include only a summary of the devices. When set to true, the response will contain only the summary information. Only the 'owner' and 'labelSelector' parameters are supported when 'summaryOnly' is true. | [optional] |
| cve_id | str | Filter devices by CVE ID. Only returns devices whose OS image digest has the specified vulnerability. Must be a MITRE-style identifier (CVE-YYYY-sequence, e.g. CVE-2024-12345). | [optional] |
No authorization required
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 429 | Too Many Requests | - |
| 503 | Service Unavailable | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Device patch_device(name, patch_request_inner)
Patch a Device resource.
import flightctl
from flightctl.models.device import Device
from flightctl.models.patch_request_inner import PatchRequestInner
from flightctl.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = flightctl.Configuration(
host = "/api/v1"
)
# Enter a context with an instance of the API client
with flightctl.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = flightctl.DeviceApi(api_client)
name = 'name_example' # str | The name of the Device resource to patch.
patch_request_inner = [flightctl.PatchRequestInner()] # List[PatchRequestInner] |
try:
api_response = api_instance.patch_device(name, patch_request_inner)
print("The response of DeviceApi->patch_device:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DeviceApi->patch_device: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | The name of the Device resource to patch. | |
| patch_request_inner | List[PatchRequestInner] |
No authorization required
- Content-Type: application/json-patch+json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 404 | Not Found | - |
| 409 | Conflict | - |
| 429 | Too Many Requests | - |
| 503 | Service Unavailable | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Device patch_device_status(name, patch_request_inner)
Patch the status of a Device resource.
import flightctl
from flightctl.models.device import Device
from flightctl.models.patch_request_inner import PatchRequestInner
from flightctl.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = flightctl.Configuration(
host = "/api/v1"
)
# Enter a context with an instance of the API client
with flightctl.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = flightctl.DeviceApi(api_client)
name = 'name_example' # str | The name of the Device resource to patch.
patch_request_inner = [flightctl.PatchRequestInner()] # List[PatchRequestInner] |
try:
api_response = api_instance.patch_device_status(name, patch_request_inner)
print("The response of DeviceApi->patch_device_status:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DeviceApi->patch_device_status: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | The name of the Device resource to patch. | |
| patch_request_inner | List[PatchRequestInner] |
No authorization required
- Content-Type: application/json-patch+json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 404 | Not Found | - |
| 429 | Too Many Requests | - |
| 503 | Service Unavailable | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Device replace_device(name, device)
Update a Device resource.
import flightctl
from flightctl.models.device import Device
from flightctl.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = flightctl.Configuration(
host = "/api/v1"
)
# Enter a context with an instance of the API client
with flightctl.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = flightctl.DeviceApi(api_client)
name = 'name_example' # str | The name of the Device resource to update.
device = flightctl.Device() # Device |
try:
api_response = api_instance.replace_device(name, device)
print("The response of DeviceApi->replace_device:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DeviceApi->replace_device: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | The name of the Device resource to update. | |
| device | Device |
No authorization required
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | - |
| 201 | Created | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 404 | Not Found | - |
| 409 | Conflict | - |
| 429 | Too Many Requests | - |
| 503 | Service Unavailable | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Device replace_device_status(name, device)
Update the status of a Device resource.
import flightctl
from flightctl.models.device import Device
from flightctl.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = flightctl.Configuration(
host = "/api/v1"
)
# Enter a context with an instance of the API client
with flightctl.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = flightctl.DeviceApi(api_client)
name = 'name_example' # str | The name of the Device resource to update.
device = flightctl.Device() # Device |
try:
api_response = api_instance.replace_device_status(name, device)
print("The response of DeviceApi->replace_device_status:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DeviceApi->replace_device_status: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | The name of the Device resource to update. | |
| device | Device |
No authorization required
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 404 | Not Found | - |
| 409 | Conflict | - |
| 429 | Too Many Requests | - |
| 503 | Service Unavailable | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Device restart_device_application(name, appname)
Restart an application on this device. Sets a device-level restartGeneration override (independent of the application's declarative spec, fleet template or standalone device); the control plane computes the next generation, and the agent restarts the application using the type-appropriate restart operation when it observes the change. The override is applied on top of the rendered application spec at render time and survives fleet template rollouts, since it is never stored as part of the device's spec. Only meaningful while the application's desired state is "running".
import flightctl
from flightctl.models.device import Device
from flightctl.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = flightctl.Configuration(
host = "/api/v1"
)
# Enter a context with an instance of the API client
with flightctl.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = flightctl.DeviceApi(api_client)
name = 'name_example' # str | The name of the Device resource.
appname = 'appname_example' # str | The name of the application, as defined in the device's rendered application spec.
try:
api_response = api_instance.restart_device_application(name, appname)
print("The response of DeviceApi->restart_device_application:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DeviceApi->restart_device_application: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | The name of the Device resource. | |
| appname | str | The name of the application, as defined in the device's rendered application spec. |
No authorization required
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 404 | Not Found | - |
| 409 | Conflict | - |
| 429 | Too Many Requests | - |
| 503 | Service Unavailable | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Device start_device_application(name, appname)
Start an application on this device. Sets a device-level lifecycle override (independent of the application's declarative spec, fleet template or standalone device) that is applied on top of the rendered application spec at render time and survives fleet template rollouts, since it is never stored as part of the device's spec. If the application is also owned by a fleet with its own stop/start default for this application, whichever of the two actions was issued most recently takes effect.
import flightctl
from flightctl.models.device import Device
from flightctl.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = flightctl.Configuration(
host = "/api/v1"
)
# Enter a context with an instance of the API client
with flightctl.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = flightctl.DeviceApi(api_client)
name = 'name_example' # str | The name of the Device resource.
appname = 'appname_example' # str | The name of the application, as defined in the device's rendered application spec.
try:
api_response = api_instance.start_device_application(name, appname)
print("The response of DeviceApi->start_device_application:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DeviceApi->start_device_application: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | The name of the Device resource. | |
| appname | str | The name of the application, as defined in the device's rendered application spec. |
No authorization required
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 404 | Not Found | - |
| 409 | Conflict | - |
| 429 | Too Many Requests | - |
| 503 | Service Unavailable | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Device stop_device_application(name, appname)
Stop an application on this device. Sets a device-level lifecycle override (independent of the application's declarative spec, fleet template or standalone device) that is applied on top of the rendered application spec at render time and survives fleet template rollouts, since it is never stored as part of the device's spec.
import flightctl
from flightctl.models.device import Device
from flightctl.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = flightctl.Configuration(
host = "/api/v1"
)
# Enter a context with an instance of the API client
with flightctl.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = flightctl.DeviceApi(api_client)
name = 'name_example' # str | The name of the Device resource.
appname = 'appname_example' # str | The name of the application, as defined in the device's rendered application spec.
try:
api_response = api_instance.stop_device_application(name, appname)
print("The response of DeviceApi->stop_device_application:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DeviceApi->stop_device_application: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | The name of the Device resource. | |
| appname | str | The name of the application, as defined in the device's rendered application spec. |
No authorization required
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 404 | Not Found | - |
| 409 | Conflict | - |
| 429 | Too Many Requests | - |
| 503 | Service Unavailable | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]