Skip to content

Latest commit

 

History

History
1217 lines (846 loc) · 43.7 KB

File metadata and controls

1217 lines (846 loc) · 43.7 KB

cosmotech_api.RunnerApi

All URIs are relative to http://localhost:8080

Method HTTP request Description
create_runner POST /organizations/{organization_id}/workspaces/{workspace_id}/runners Create a new Runner
create_runner_access_control POST /organizations/{organization_id}/workspaces/{workspace_id}/runners/{runner_id}/security/access Add a control access to the Runner
delete_runner DELETE /organizations/{organization_id}/workspaces/{workspace_id}/runners/{runner_id} Delete a runner
delete_runner_access_control DELETE /organizations/{organization_id}/workspaces/{workspace_id}/runners/{runner_id}/security/access/{identity_id} Remove the specified access from the given Runner
get_runner GET /organizations/{organization_id}/workspaces/{workspace_id}/runners/{runner_id} Get the details of a runner
get_runner_access_control GET /organizations/{organization_id}/workspaces/{workspace_id}/runners/{runner_id}/security/access/{identity_id} Get a control access for the Runner
get_runner_security GET /organizations/{organization_id}/workspaces/{workspace_id}/runners/{runner_id}/security Get the Runner security information
list_runner_permissions GET /organizations/{organization_id}/workspaces/{workspace_id}/runners/{runner_id}/permissions/{role} Get the Runner permission by given role
list_runner_security_users GET /organizations/{organization_id}/workspaces/{workspace_id}/runners/{runner_id}/security/users Get the Runner security users list
list_runners GET /organizations/{organization_id}/workspaces/{workspace_id}/runners List all Runners
start_run POST /organizations/{organization_id}/workspaces/{workspace_id}/runners/{runner_id}/start Start a run with runner parameters
stop_run POST /organizations/{organization_id}/workspaces/{workspace_id}/runners/{runner_id}/stop Stop the last run
update_runner PATCH /organizations/{organization_id}/workspaces/{workspace_id}/runners/{runner_id} Update a runner
update_runner_access_control PATCH /organizations/{organization_id}/workspaces/{workspace_id}/runners/{runner_id}/security/access/{identity_id} Update the specified access to User for a Runner
update_runner_default_security PATCH /organizations/{organization_id}/workspaces/{workspace_id}/runners/{runner_id}/security/default Set the Runner default security

create_runner

Runner create_runner(organization_id, workspace_id, runner_create_request)

Create a new Runner

Create a new runner for executing simulations. Use parentId to create a child runner that inherits configuration from a parent.

Example

  • OAuth Authentication (oAuth2AuthCode):
import cosmotech_api
from cosmotech_api.models.runner import Runner
from cosmotech_api.models.runner_create_request import RunnerCreateRequest
from cosmotech_api.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8080
# See configuration.py for a list of all supported configuration parameters.
configuration = cosmotech_api.Configuration(
    host = "http://localhost:8080"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

configuration.access_token = os.environ["ACCESS_TOKEN"]

# Enter a context with an instance of the API client
with cosmotech_api.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = cosmotech_api.RunnerApi(api_client)
    organization_id = 'organization_id_example' # str | the Organization identifier
    workspace_id = 'workspace_id_example' # str | the Workspace identifier
    runner_create_request = cosmotech_api.RunnerCreateRequest() # RunnerCreateRequest | the Runner to create

    try:
        # Create a new Runner
        api_response = api_instance.create_runner(organization_id, workspace_id, runner_create_request)
        print("The response of RunnerApi->create_runner:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling RunnerApi->create_runner: %s\n" % e)

Parameters

Name Type Description Notes
organization_id str the Organization identifier
workspace_id str the Workspace identifier
runner_create_request RunnerCreateRequest the Runner to create

Return type

Runner

Authorization

oAuth2AuthCode

HTTP request headers

  • Content-Type: application/json, application/yaml
  • Accept: application/json, application/yaml

HTTP response details

Status code Description Response headers
201 the runner details -
400 Bad request -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

create_runner_access_control

RunnerAccessControl create_runner_access_control(organization_id, workspace_id, runner_id, runner_access_control)

Add a control access to the Runner

Grant access to a runner for a user or group. Valid roles: viewer, editor, validator (can validate runs), admin.

Example

  • OAuth Authentication (oAuth2AuthCode):
import cosmotech_api
from cosmotech_api.models.runner_access_control import RunnerAccessControl
from cosmotech_api.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8080
# See configuration.py for a list of all supported configuration parameters.
configuration = cosmotech_api.Configuration(
    host = "http://localhost:8080"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

configuration.access_token = os.environ["ACCESS_TOKEN"]

# Enter a context with an instance of the API client
with cosmotech_api.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = cosmotech_api.RunnerApi(api_client)
    organization_id = 'organization_id_example' # str | the Organization identifier
    workspace_id = 'workspace_id_example' # str | the Workspace identifier
    runner_id = 'runner_id_example' # str | the Runner identifier
    runner_access_control = cosmotech_api.RunnerAccessControl() # RunnerAccessControl | the new Runner security access to add.

    try:
        # Add a control access to the Runner
        api_response = api_instance.create_runner_access_control(organization_id, workspace_id, runner_id, runner_access_control)
        print("The response of RunnerApi->create_runner_access_control:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling RunnerApi->create_runner_access_control: %s\n" % e)

Parameters

Name Type Description Notes
organization_id str the Organization identifier
workspace_id str the Workspace identifier
runner_id str the Runner identifier
runner_access_control RunnerAccessControl the new Runner security access to add.

Return type

RunnerAccessControl

Authorization

oAuth2AuthCode

HTTP request headers

  • Content-Type: application/json, application/yaml
  • Accept: application/json, application/yaml

HTTP response details

Status code Description Response headers
201 The Runner access -
404 the Runner specified is unknown or you don't have access to it -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

delete_runner

delete_runner(organization_id, workspace_id, runner_id)

Delete a runner

Delete a runner. Cannot delete while runs are in progress. Note: Child runners that reference this runner are not deleted automatically.

Example

  • OAuth Authentication (oAuth2AuthCode):
import cosmotech_api
from cosmotech_api.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8080
# See configuration.py for a list of all supported configuration parameters.
configuration = cosmotech_api.Configuration(
    host = "http://localhost:8080"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

configuration.access_token = os.environ["ACCESS_TOKEN"]

# Enter a context with an instance of the API client
with cosmotech_api.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = cosmotech_api.RunnerApi(api_client)
    organization_id = 'organization_id_example' # str | the Organization identifier
    workspace_id = 'workspace_id_example' # str | the Workspace identifier
    runner_id = 'runner_id_example' # str | the Runner identifier

    try:
        # Delete a runner
        api_instance.delete_runner(organization_id, workspace_id, runner_id)
    except Exception as e:
        print("Exception when calling RunnerApi->delete_runner: %s\n" % e)

Parameters

Name Type Description Notes
organization_id str the Organization identifier
workspace_id str the Workspace identifier
runner_id str the Runner identifier

Return type

void (empty response body)

Authorization

oAuth2AuthCode

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

HTTP response details

Status code Description Response headers
204 Request succeeded -
404 the Runner specified is unknown or you don't have access to it -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

delete_runner_access_control

delete_runner_access_control(organization_id, workspace_id, runner_id, identity_id)

Remove the specified access from the given Runner

Example

  • OAuth Authentication (oAuth2AuthCode):
import cosmotech_api
from cosmotech_api.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8080
# See configuration.py for a list of all supported configuration parameters.
configuration = cosmotech_api.Configuration(
    host = "http://localhost:8080"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

configuration.access_token = os.environ["ACCESS_TOKEN"]

# Enter a context with an instance of the API client
with cosmotech_api.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = cosmotech_api.RunnerApi(api_client)
    organization_id = 'organization_id_example' # str | the Organization identifier
    workspace_id = 'workspace_id_example' # str | the Workspace identifier
    runner_id = 'runner_id_example' # str | the Runner identifier
    identity_id = 'identity_id_example' # str | the User identifier

    try:
        # Remove the specified access from the given Runner
        api_instance.delete_runner_access_control(organization_id, workspace_id, runner_id, identity_id)
    except Exception as e:
        print("Exception when calling RunnerApi->delete_runner_access_control: %s\n" % e)

Parameters

Name Type Description Notes
organization_id str the Organization identifier
workspace_id str the Workspace identifier
runner_id str the Runner identifier
identity_id str the User identifier

Return type

void (empty response body)

Authorization

oAuth2AuthCode

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

HTTP response details

Status code Description Response headers
204 Request succeeded -
404 the Runner or the user specified is unknown or you don't have access to them -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_runner

Runner get_runner(organization_id, workspace_id, runner_id)

Get the details of a runner

Retrieve detailed information about a runner.

Example

  • OAuth Authentication (oAuth2AuthCode):
import cosmotech_api
from cosmotech_api.models.runner import Runner
from cosmotech_api.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8080
# See configuration.py for a list of all supported configuration parameters.
configuration = cosmotech_api.Configuration(
    host = "http://localhost:8080"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

configuration.access_token = os.environ["ACCESS_TOKEN"]

# Enter a context with an instance of the API client
with cosmotech_api.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = cosmotech_api.RunnerApi(api_client)
    organization_id = 'organization_id_example' # str | the Organization identifier
    workspace_id = 'workspace_id_example' # str | the Workspace identifier
    runner_id = 'runner_id_example' # str | the Runner identifier

    try:
        # Get the details of a runner
        api_response = api_instance.get_runner(organization_id, workspace_id, runner_id)
        print("The response of RunnerApi->get_runner:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling RunnerApi->get_runner: %s\n" % e)

Parameters

Name Type Description Notes
organization_id str the Organization identifier
workspace_id str the Workspace identifier
runner_id str the Runner identifier

Return type

Runner

Authorization

oAuth2AuthCode

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/yaml

HTTP response details

Status code Description Response headers
200 the Runner details -
404 the Runner specified is unknown or you don't have access to it -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_runner_access_control

RunnerAccessControl get_runner_access_control(organization_id, workspace_id, runner_id, identity_id)

Get a control access for the Runner

Example

  • OAuth Authentication (oAuth2AuthCode):
import cosmotech_api
from cosmotech_api.models.runner_access_control import RunnerAccessControl
from cosmotech_api.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8080
# See configuration.py for a list of all supported configuration parameters.
configuration = cosmotech_api.Configuration(
    host = "http://localhost:8080"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

configuration.access_token = os.environ["ACCESS_TOKEN"]

# Enter a context with an instance of the API client
with cosmotech_api.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = cosmotech_api.RunnerApi(api_client)
    organization_id = 'organization_id_example' # str | the Organization identifier
    workspace_id = 'workspace_id_example' # str | the Workspace identifier
    runner_id = 'runner_id_example' # str | the Runner identifier
    identity_id = 'identity_id_example' # str | the User identifier

    try:
        # Get a control access for the Runner
        api_response = api_instance.get_runner_access_control(organization_id, workspace_id, runner_id, identity_id)
        print("The response of RunnerApi->get_runner_access_control:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling RunnerApi->get_runner_access_control: %s\n" % e)

Parameters

Name Type Description Notes
organization_id str the Organization identifier
workspace_id str the Workspace identifier
runner_id str the Runner identifier
identity_id str the User identifier

Return type

RunnerAccessControl

Authorization

oAuth2AuthCode

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/yaml

HTTP response details

Status code Description Response headers
200 The Runner access -
404 the Runner or user specified is unknown or you don't have access to it -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_runner_security

RunnerSecurity get_runner_security(organization_id, workspace_id, runner_id)

Get the Runner security information

Example

  • OAuth Authentication (oAuth2AuthCode):
import cosmotech_api
from cosmotech_api.models.runner_security import RunnerSecurity
from cosmotech_api.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8080
# See configuration.py for a list of all supported configuration parameters.
configuration = cosmotech_api.Configuration(
    host = "http://localhost:8080"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

configuration.access_token = os.environ["ACCESS_TOKEN"]

# Enter a context with an instance of the API client
with cosmotech_api.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = cosmotech_api.RunnerApi(api_client)
    organization_id = 'organization_id_example' # str | the Organization identifier
    workspace_id = 'workspace_id_example' # str | the Workspace identifier
    runner_id = 'runner_id_example' # str | the Runner identifier

    try:
        # Get the Runner security information
        api_response = api_instance.get_runner_security(organization_id, workspace_id, runner_id)
        print("The response of RunnerApi->get_runner_security:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling RunnerApi->get_runner_security: %s\n" % e)

Parameters

Name Type Description Notes
organization_id str the Organization identifier
workspace_id str the Workspace identifier
runner_id str the Runner identifier

Return type

RunnerSecurity

Authorization

oAuth2AuthCode

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/yaml

HTTP response details

Status code Description Response headers
200 The Runner security -
404 the Runner specified is unknown or you don't have access to it -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

list_runner_permissions

List[str] list_runner_permissions(organization_id, workspace_id, runner_id, role)

Get the Runner permission by given role

Example

  • OAuth Authentication (oAuth2AuthCode):
import cosmotech_api
from cosmotech_api.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8080
# See configuration.py for a list of all supported configuration parameters.
configuration = cosmotech_api.Configuration(
    host = "http://localhost:8080"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

configuration.access_token = os.environ["ACCESS_TOKEN"]

# Enter a context with an instance of the API client
with cosmotech_api.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = cosmotech_api.RunnerApi(api_client)
    organization_id = 'organization_id_example' # str | the Organization identifier
    workspace_id = 'workspace_id_example' # str | the Workspace identifier
    runner_id = 'runner_id_example' # str | the Runner identifier
    role = 'role_example' # str | the Role

    try:
        # Get the Runner permission by given role
        api_response = api_instance.list_runner_permissions(organization_id, workspace_id, runner_id, role)
        print("The response of RunnerApi->list_runner_permissions:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling RunnerApi->list_runner_permissions: %s\n" % e)

Parameters

Name Type Description Notes
organization_id str the Organization identifier
workspace_id str the Workspace identifier
runner_id str the Runner identifier
role str the Role

Return type

List[str]

Authorization

oAuth2AuthCode

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/yaml

HTTP response details

Status code Description Response headers
200 The Runners security permission list -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

list_runner_security_users

List[str] list_runner_security_users(organization_id, workspace_id, runner_id)

Get the Runner security users list

Example

  • OAuth Authentication (oAuth2AuthCode):
import cosmotech_api
from cosmotech_api.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8080
# See configuration.py for a list of all supported configuration parameters.
configuration = cosmotech_api.Configuration(
    host = "http://localhost:8080"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

configuration.access_token = os.environ["ACCESS_TOKEN"]

# Enter a context with an instance of the API client
with cosmotech_api.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = cosmotech_api.RunnerApi(api_client)
    organization_id = 'organization_id_example' # str | the Organization identifier
    workspace_id = 'workspace_id_example' # str | the Workspace identifier
    runner_id = 'runner_id_example' # str | the Runner identifier

    try:
        # Get the Runner security users list
        api_response = api_instance.list_runner_security_users(organization_id, workspace_id, runner_id)
        print("The response of RunnerApi->list_runner_security_users:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling RunnerApi->list_runner_security_users: %s\n" % e)

Parameters

Name Type Description Notes
organization_id str the Organization identifier
workspace_id str the Workspace identifier
runner_id str the Runner identifier

Return type

List[str]

Authorization

oAuth2AuthCode

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/yaml

HTTP response details

Status code Description Response headers
200 The Runner security users list -
404 the Runner specified is unknown or you don't have access to it -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

list_runners

List[Runner] list_runners(organization_id, workspace_id, page=page, size=size)

List all Runners

Retrieve a paginated list of all runners in a workspace.

Example

  • OAuth Authentication (oAuth2AuthCode):
import cosmotech_api
from cosmotech_api.models.runner import Runner
from cosmotech_api.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8080
# See configuration.py for a list of all supported configuration parameters.
configuration = cosmotech_api.Configuration(
    host = "http://localhost:8080"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

configuration.access_token = os.environ["ACCESS_TOKEN"]

# Enter a context with an instance of the API client
with cosmotech_api.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = cosmotech_api.RunnerApi(api_client)
    organization_id = 'organization_id_example' # str | the Organization identifier
    workspace_id = 'workspace_id_example' # str | the Workspace identifier
    page = 56 # int | Page number to query (first page is at index 0) (optional)
    size = 56 # int | Amount of result by page (optional)

    try:
        # List all Runners
        api_response = api_instance.list_runners(organization_id, workspace_id, page=page, size=size)
        print("The response of RunnerApi->list_runners:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling RunnerApi->list_runners: %s\n" % e)

Parameters

Name Type Description Notes
organization_id str the Organization identifier
workspace_id str the Workspace identifier
page int Page number to query (first page is at index 0) [optional]
size int Amount of result by page [optional]

Return type

List[Runner]

Authorization

oAuth2AuthCode

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/yaml

HTTP response details

Status code Description Response headers
200 the list of Runners -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

start_run

CreatedRun start_run(organization_id, workspace_id, runner_id)

Start a run with runner parameters

Start a new simulation run using the runner's current configuration. Returns the run Id. The run executes asynchronously - use the run status endpoint to monitor progress

Example

  • OAuth Authentication (oAuth2AuthCode):
import cosmotech_api
from cosmotech_api.models.created_run import CreatedRun
from cosmotech_api.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8080
# See configuration.py for a list of all supported configuration parameters.
configuration = cosmotech_api.Configuration(
    host = "http://localhost:8080"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

configuration.access_token = os.environ["ACCESS_TOKEN"]

# Enter a context with an instance of the API client
with cosmotech_api.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = cosmotech_api.RunnerApi(api_client)
    organization_id = 'organization_id_example' # str | the Organization identifier
    workspace_id = 'workspace_id_example' # str | the Workspace identifier
    runner_id = 'runner_id_example' # str | the Runner identifier

    try:
        # Start a run with runner parameters
        api_response = api_instance.start_run(organization_id, workspace_id, runner_id)
        print("The response of RunnerApi->start_run:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling RunnerApi->start_run: %s\n" % e)

Parameters

Name Type Description Notes
organization_id str the Organization identifier
workspace_id str the Workspace identifier
runner_id str the Runner identifier

Return type

CreatedRun

Authorization

oAuth2AuthCode

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/yaml

HTTP response details

Status code Description Response headers
202 the newly created Run info -
404 the Runner specified is unknown or you don't have access to it -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

stop_run

stop_run(organization_id, workspace_id, runner_id)

Stop the last run

Stop the currently executing run for this runner. The stop operation is asynchronous - the run may continue briefly before stopping.

Example

  • OAuth Authentication (oAuth2AuthCode):
import cosmotech_api
from cosmotech_api.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8080
# See configuration.py for a list of all supported configuration parameters.
configuration = cosmotech_api.Configuration(
    host = "http://localhost:8080"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

configuration.access_token = os.environ["ACCESS_TOKEN"]

# Enter a context with an instance of the API client
with cosmotech_api.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = cosmotech_api.RunnerApi(api_client)
    organization_id = 'organization_id_example' # str | the Organization identifier
    workspace_id = 'workspace_id_example' # str | the Workspace identifier
    runner_id = 'runner_id_example' # str | the Runner identifier

    try:
        # Stop the last run
        api_instance.stop_run(organization_id, workspace_id, runner_id)
    except Exception as e:
        print("Exception when calling RunnerApi->stop_run: %s\n" % e)

Parameters

Name Type Description Notes
organization_id str the Organization identifier
workspace_id str the Workspace identifier
runner_id str the Runner identifier

Return type

void (empty response body)

Authorization

oAuth2AuthCode

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

HTTP response details

Status code Description Response headers
202 the last Run has been stopped -
404 the Runner specified is unknown or you don't have access to it -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

update_runner

Runner update_runner(organization_id, workspace_id, runner_id, runner_update_request)

Update a runner

Example

  • OAuth Authentication (oAuth2AuthCode):
import cosmotech_api
from cosmotech_api.models.runner import Runner
from cosmotech_api.models.runner_update_request import RunnerUpdateRequest
from cosmotech_api.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8080
# See configuration.py for a list of all supported configuration parameters.
configuration = cosmotech_api.Configuration(
    host = "http://localhost:8080"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

configuration.access_token = os.environ["ACCESS_TOKEN"]

# Enter a context with an instance of the API client
with cosmotech_api.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = cosmotech_api.RunnerApi(api_client)
    organization_id = 'organization_id_example' # str | the Organization identifier
    workspace_id = 'workspace_id_example' # str | the Workspace identifier
    runner_id = 'runner_id_example' # str | the Runner identifier
    runner_update_request = cosmotech_api.RunnerUpdateRequest() # RunnerUpdateRequest | the new Runner details. This endpoint can't be used to update security

    try:
        # Update a runner
        api_response = api_instance.update_runner(organization_id, workspace_id, runner_id, runner_update_request)
        print("The response of RunnerApi->update_runner:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling RunnerApi->update_runner: %s\n" % e)

Parameters

Name Type Description Notes
organization_id str the Organization identifier
workspace_id str the Workspace identifier
runner_id str the Runner identifier
runner_update_request RunnerUpdateRequest the new Runner details. This endpoint can't be used to update security

Return type

Runner

Authorization

oAuth2AuthCode

HTTP request headers

  • Content-Type: application/json, application/yaml
  • Accept: application/json, application/yaml

HTTP response details

Status code Description Response headers
200 the runner details -
400 Bad request -
404 the Runner specified is unknown or you don't have access to it -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

update_runner_access_control

RunnerAccessControl update_runner_access_control(organization_id, workspace_id, runner_id, identity_id, runner_role)

Update the specified access to User for a Runner

Example

  • OAuth Authentication (oAuth2AuthCode):
import cosmotech_api
from cosmotech_api.models.runner_access_control import RunnerAccessControl
from cosmotech_api.models.runner_role import RunnerRole
from cosmotech_api.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8080
# See configuration.py for a list of all supported configuration parameters.
configuration = cosmotech_api.Configuration(
    host = "http://localhost:8080"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

configuration.access_token = os.environ["ACCESS_TOKEN"]

# Enter a context with an instance of the API client
with cosmotech_api.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = cosmotech_api.RunnerApi(api_client)
    organization_id = 'organization_id_example' # str | the Organization identifier
    workspace_id = 'workspace_id_example' # str | the Workspace identifier
    runner_id = 'runner_id_example' # str | the Runner identifier
    identity_id = 'identity_id_example' # str | the User identifier
    runner_role = cosmotech_api.RunnerRole() # RunnerRole | The new Runner Access Control

    try:
        # Update the specified access to User for a Runner
        api_response = api_instance.update_runner_access_control(organization_id, workspace_id, runner_id, identity_id, runner_role)
        print("The response of RunnerApi->update_runner_access_control:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling RunnerApi->update_runner_access_control: %s\n" % e)

Parameters

Name Type Description Notes
organization_id str the Organization identifier
workspace_id str the Workspace identifier
runner_id str the Runner identifier
identity_id str the User identifier
runner_role RunnerRole The new Runner Access Control

Return type

RunnerAccessControl

Authorization

oAuth2AuthCode

HTTP request headers

  • Content-Type: application/json, application/yaml
  • Accept: application/json, application/yaml

HTTP response details

Status code Description Response headers
200 The Runner access -
404 The Organization specified is unknown or you don't have access to it -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

update_runner_default_security

RunnerSecurity update_runner_default_security(organization_id, workspace_id, runner_id, runner_role)

Set the Runner default security

Example

  • OAuth Authentication (oAuth2AuthCode):
import cosmotech_api
from cosmotech_api.models.runner_role import RunnerRole
from cosmotech_api.models.runner_security import RunnerSecurity
from cosmotech_api.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:8080
# See configuration.py for a list of all supported configuration parameters.
configuration = cosmotech_api.Configuration(
    host = "http://localhost:8080"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

configuration.access_token = os.environ["ACCESS_TOKEN"]

# Enter a context with an instance of the API client
with cosmotech_api.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = cosmotech_api.RunnerApi(api_client)
    organization_id = 'organization_id_example' # str | the Organization identifier
    workspace_id = 'workspace_id_example' # str | the Workspace identifier
    runner_id = 'runner_id_example' # str | the Runner identifier
    runner_role = cosmotech_api.RunnerRole() # RunnerRole | This change the runner default security. The default security is the role assigned to any person not on the Access Control List. If the default security is None, then nobody outside of the ACL can access the runner.

    try:
        # Set the Runner default security
        api_response = api_instance.update_runner_default_security(organization_id, workspace_id, runner_id, runner_role)
        print("The response of RunnerApi->update_runner_default_security:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling RunnerApi->update_runner_default_security: %s\n" % e)

Parameters

Name Type Description Notes
organization_id str the Organization identifier
workspace_id str the Workspace identifier
runner_id str the Runner identifier
runner_role RunnerRole This change the runner default security. The default security is the role assigned to any person not on the Access Control List. If the default security is None, then nobody outside of the ACL can access the runner.

Return type

RunnerSecurity

Authorization

oAuth2AuthCode

HTTP request headers

  • Content-Type: application/json, application/yaml
  • Accept: application/json, application/yaml

HTTP response details

Status code Description Response headers
201 The Runner default visibility -
404 the Runner specified is unknown or you don't have access to it -

[Back to top] [Back to API list] [Back to Model list] [Back to README]