Cloud API Reference (Legacy)
Cloud API Reference (Legacy)
These APIs are legacy and deprecated. Please use the current APIs instead.
Cloud SDK
The AnyscaleSDK class must be constructed in order to make calls to the SDK. This class allows you to create an authenticated client in which to use the SDK.
Param | Type | Description |
---|---|---|
auth_token | Optional String | Authentication token used to verify you have permissions to access Anyscale. If not provided, permissions default to the credentials set for your current user. Credentials can be set by following the instructions on this page: https://console.anyscale.com/credentials |
Example
from anyscale import AnyscaleSDK
sdk = AnyscaleSDK()
get_cloud
Retrieves a Cloud.
Parameters
Name | Type | Description | Notes |
---|---|---|---|
cloud_id | str | ID of the Cloud to retrieve. | Defaults to null |
Returns CloudResponse
get_default_cloud
Retrieves the default cloud for the logged in user. First prefers the default cloud set by the user's org, then the last used cloud.
Parameters This function does not have any parameters.
Returns CloudResponse
search_clouds
Searches for all accessible Clouds that satisfies the query.
Parameters
Name | Type | Description | Notes |
---|---|---|---|
clouds_query | CloudsQuery |
Returns CloudListResponse
Cloud Models
Cloud
Model used to create a Cloud.
Name | Type | Description | Notes |
---|---|---|---|
name | str | Name of this Cloud. | [default to null] |
provider | CloudProviders | Provider of this Cloud (e.g. AWS). | [default to null] |
compute_stack | ComputeStack | The compute stack associated with this cloud's primary cloud resource. | [optional] [default to null] |
region | str | Region this Cloud is operating in. This value needs to be supported by this Cloud's provider. (e.g. us-west-2) | [default to null] |
credentials | str | Credentials needed to interact with this Cloud. | [default to null] |
config | CloudConfig | Additional configurable properties of this Cloud. | [optional] [default to null] |
is_k8s | bool | Whether this cloud is managed via Kubernetes. | [optional] [default to false] |
is_aioa | bool | Whether this cloud is an AIOA cloud. | [optional] [default to false] |
availability_zones | List[str] | The availability zones that instances of this cloud are allowed to be launched in. | [optional] [default to null] |
is_bring_your_own_resource | bool | Whether the resources of this cloud are provided by the customer. | [optional] [default to null] |
is_private_cloud | bool | Whether this cloud is a private cloud. | [optional] [default to false] |
cluster_management_stack_version | ClusterManagementStackVersions | The cluster management stack version of the cloud. | [optional] [default to null] |
is_private_service_cloud | bool | Whether services created in this cloud should be private. | [optional] [default to null] |
auto_add_user | bool | Whether all users in the organization should be automatically added to this cloud. This field is only relevant for organizations with cloud isolation enabled, because all users in the organization automatically have access to all clouds if cloud isolation is not enabled. | [optional] [default to false] |
external_id | str | The trust policy external ID specified by the user for the cloud control plane role. It must start with the organization ID. | [optional] [default to null] |
id | str | Server assigned unique identifier. | [default to null] |
type | CloudTypes | [default to null] | |
creator_id | str | ID of the User who created this Cloud. | [default to null] |
created_at | datetime | Time when this Cloud was created. | [default to null] |
status | CloudStatus | The status of this cloud. | [optional] [default to null] |
state | CloudState | The state of this cloud. | [optional] [default to null] |
version | CloudVersion | The version of the cloud. | [optional] [default to null] |
is_default | bool | Whether this cloud is the default cloud. | [default to null] |
customer_aggregated_logs_config_id | str | the id of the customer aggregated logs config associated with this cloud. | [default to null] |
additional_instance_types | List[UXInstance] | the list of instance types supported in the UI and through API (SDK/CLI). | [optional] [default to null] |
is_aggregated_logs_enabled | bool | Whether the aggregated logs are enabled for this cloud. | [optional] [default to null] |
system_cluster_config_id | str | the id of the system cluster config associated with this cloud. | [optional] [default to null] |
CloudConfig
Name | Type | Description | Notes |
---|---|---|---|
max_stopped_instances | int | Maximum number of instances that can be retained for reuse after a Cluster has terminated. This may help Clusters start up faster, but stopped instances will accrue some costs. Defaults to 0, which means no instances will be retained for reuse. A value of -1 means all instances will be retained. | [optional] [default to 0] |
vpc_peering_ip_range | str | VPC IP range for this Cloud. | [optional] [default to null] |
vpc_peering_target_project_id | str | Project ID of the VPC to peer with. | [optional] [default to null] |
vpc_peering_target_vpc_id | str | ID of the VPC to peer with. | [optional] [default to null] |
CloudListResponse
A list response form the API. Contains a field "results" which has the contents of the response.
Name | Type | Description | Notes |
---|---|---|---|
results | List[Cloud] | [default to null] | |
metadata | ListResponseMetadata | [optional] [default to null] |
CloudProviders
An enumeration.
Possible Values: ['AWS', 'GCP', 'CLOUDGATEWAY', 'PCP', 'GENERIC', 'AZURE']
CloudResponse
A response from the API. Contains a field "result" which has the contents of the response.
Name | Type | Description | Notes |
---|---|---|---|
result | Cloud | [default to null] |
CloudState
An enumeration.
Possible Values: ['CREATING', 'ACTIVE', 'VERIFICATION_FAILED', 'DELETING', 'DELETED', 'CLAIMED']
CloudStatus
An enumeration.
Possible Values: ['pending', 'ready']
CloudTypes
An enumeration.
Possible Values: ['PUBLIC', 'INTERNAL']
CloudVersion
An enumeration.
Possible Values: ['v1', 'v2']
CloudsQuery
Query object used to search Clouds.
Name | Type | Description | Notes |
---|---|---|---|
name | TextQuery | Filters ComputeTemplates by name. If this field is absent, no filtering is done. | [optional] [default to null] |
paging | PageQuery | Pagination info. | [optional] [default to null] |