Lambda
App · 20 actions
Manage Lambda Cloud GPU instances, SSH keys and shared file systems.
Actions
| Action | What it does |
|---|---|
| Add SSH key | Add an SSH key to your Lambda Cloud account. |
| Create file system | Creates a new filesystem. |
| Delete file system | Deletes the filesystem with the specified ID. |
| Delete SSH key | Deletes the specified SSH key. |
| Get current identity | Retrieves the details of the current identity. |
| Get instance | Retrieves the details of a specific instance, including whether or not the instance is running. |
| Get workspace | Retrieves the details of a specific workspace. |
| Launch instance | Launches a Lambda On-Demand Cloud instance. |
| List audit events | Retrieves a list of audit events that have occurred in your account. |
| List file systems | Retrieves a list of your filesystems. |
| List firewall rulesets | Retrieves a list of your firewall rulesets. |
| List images | Retrieves a list of available images by region. |
| List instance types | Retrieves a list of the instance types currently offered on Lambda's public cloud, as well as details about each type. |
| List instances | Retrieves a list of your running instances. |
| List regions | Retrieves a list of available regions. |
| List SSH keys | Retrieves a list of your SSH keys. |
| List workspaces | Lists the workspaces the requester is a member of, by default (when view=membership), or all workspaces in the account (when view=all). |
| Restart instances | Restarts one or more instances. |
| Terminate instances | Terminates one or more instances. |
| Update instance | Updates the details of the specified instance. |
Add SSH key
Add an SSH key to your Lambda Cloud account. You can upload an existing public key, or you can generate a new key pair.
Inputs
- Name
nametextRequired - The name of the SSH key.
- Public key
public_keytextRequired - The public key to store. Omit this to generate a new key pair.
- Workspace
workspace_idtext - The unique identifier (ID) of the workspace that will own this SSH key. Defaults to the account's default workspace.
Outputs
dataobject- Result.
Example output
{
"data": {
"data": {
"id": "example",
"name": "example",
"public_key": "example",
"workspace_id": "example"
}
}
}Create file system
Creates a new filesystem.
Inputs
- Name
nametextRequired - The name of the filesystem.
- Region
regiontextRequired - The region in which you want to create the filesystem.
- Workspace
workspace_idtext - The workspace in which to create the filesystem. If not specified, the filesystem will be created within the default workspace.
Outputs
dataobject- Result.
Example output
{
"data": {
"data": {
"bytes_used": 1,
"created": "example",
"created_by": {
"email": "example",
"id": "example",
"status": "example"
},
"id": "example",
"is_in_use": false,
"mount_point": "example",
"name": "example",
"region": {
"description": "example",
"name": "example"
},
"workspace_id": "example"
}
}
}Delete file system
Deletes the filesystem with the specified ID. The filesystem must not be mounted to any running instances at the time of deletion.
Inputs
- File system
file_system_idtextRequired - The unique identifier (ID) of the filesystem to delete
Outputs
dataobject- Result.
Example output
{
"data": {
"data": {
"deleted_ids": []
}
}
}Delete SSH key
Deletes the specified SSH key.
Inputs
- SSH key
ssh_key_idtextRequired - The unique identifier (ID) of the SSH key to delete
Outputs
dataobject- Result.
Example output
{
"data": {
"data": {}
}
}Get current identity
Retrieves the details of the current identity.
Inputs
None.
Outputs
dataobject- Result.
Example output
{
"data": {
"data": {
"account_id": "example",
"created_at": "example",
"display_name": "example",
"email": "example",
"first_name": "example",
"id": "example",
"identity_type": "example",
"is_managed": false,
"is_verified": false,
"last_name": "example",
"status": "example"
}
}
}Get instance
Retrieves the details of a specific instance, including whether or not the instance is running.
Inputs
- Instance
instance_idtextRequired - The unique identifier (ID) of the instance
Outputs
dataobject- Result.
Example output
{
"data": {
"data": {
"actions": {
"cold_reboot": {
"available": false,
"reason_description": "example"
},
"migrate": {
"available": false,
"reason_description": "example"
},
"power_cycle": {
"available": false,
"reason_description": "example"
},
"rebuild": {
"available": false,
"reason_description": "example"
},
"restart": {
"available": false,
"reason_description": "example"
},
"terminate": {
"available": false,
"reason_description": "example"
}
},
"file_system_mounts": [],
"file_system_names": [],
"firewall_rulesets": [],
"first_healthy": "example",
"hostname": "example",
"id": "example",
"image": {
"family": "example",
"id": "example"
},
"instance_type": {
"architecture": "example",
"description": "example",
"gpu_description": "example",
"name": "example",
"price_cents_per_hour": 1,
"specs": {
"gpus": 1,
"memory_gib": 1,
"storage_gib": 1,
"vcpus": 1
}
},
"ip": "example",
"name": "example",
"private_ip": "example",
"region": {
"description": "example",
"name": "example"
},
"ssh_key_names": [],
"status": "example",
"tags": [],
"workspace_id": "example"
}
}
}Get workspace
Retrieves the details of a specific workspace.
Inputs
- Workspace
workspace_idtextRequired - The unique identifier (ID) of the workspace
Outputs
dataobject- Result.
Example output
{
"data": {
"data": {
"account_id": "example",
"created": "example",
"id": "example",
"is_default": false,
"name": "example"
}
}
}Launch instance
Launches a Lambda On-Demand Cloud instance.
Inputs
- Region name
region_nametextRequired - The region into which you want to launch the instance.
- Instance type name
instance_type_nametextRequired - The type of instance you want to launch. To retrieve a list of available instance types, see List available instance types.
- SSH key names
ssh_key_nameslistRequired - The names of the SSH keys you want to use to provide access to the instance. Currently, exactly one SSH key must be specified.
- File system names
file_system_nameslist - The names of the filesystems you want to mount to the instance. When specified alongside file_system_mounts, any filesystems referred to in both lists will use the mount path specified in file_system_mounts, rather than the default.
- File system mounts
file_system_mountslist - The filesystem mounts to mount to the instance. When specified alongside file_system_names, any filesystems referred to in both lists will use the mount path specified in file_system_mounts, rather than the default.
- Hostname
hostnametext - The hostname to assign to the instance. If not specified, a default, IP-address-based hostname is assigned. This hostname is driven into /etc/hostname on the instance.
- Name
nametext - The name you want to assign to your instance. Must be 64 characters or fewer.
- Image
imageobject - The machine image you want to use. Defaults to the latest Lambda Stack image.
- User data
user_datatext - An instance configuration string specified in a valid cloud-init user-data format. You can use this field to configure your instance on launch. The user data string must be plain text and cannot exceed 1MB in size.
- Tags
tagslist - Key/value pairs representing the instance's tags.
- Firewall rulesets
firewall_rulesetslist - The firewall rulesets to associate with the instance. The firewall rulesets must exist in the same region as the instance.
- Workspace
workspace_idtext - The workspace ID to associate with the instance. When specified, the instance will be created within the specified workspace.
Outputs
dataobject- Result.
Example output
{
"data": {
"data": {
"instance_ids": []
}
}
}List audit events
Retrieves a list of audit events that have occurred in your account. To view the full catalog of possible audit events, visit Access and security > Audit logs in the Lambda Cloud documentation.
Inputs
- Start
startdate and time - An ISO 8601 timestamp defining the start of the time range to query, inclusive. If omitted, the response starts at the earliest available event.
- End
enddate and time - An ISO 8601 timestamp defining the end of the time range to query, inclusive. If omitted, the response ends at the most recent event.
- Page token
page_tokentext - The token returned by the previous API response to retrieve the next page of results.
- Resource type
resource_typetext - The resource type to filter by. By default, all available resource types are retrieved.
Outputs
dataobject- Result.
Example output
{
"data": {
"data": [],
"page_token": "example"
}
}List file systems
Retrieves a list of your filesystems.
Inputs
- Workspace
workspace_idtext - The unique identifier (ID) of the workspace to filter by
Outputs
dataobject- Result.
Example output
{
"data": {
"data": []
}
}List firewall rulesets
Retrieves a list of your firewall rulesets.
Inputs
- Workspace
workspace_idtext - The unique identifier (ID) of the workspace to filter by
Outputs
dataobject- Result.
Example output
{
"data": {
"data": []
}
}List images
Retrieves a list of available images by region.
Inputs
- Workspace
workspace_idtext - The unique identifier (ID) of the workspace to filter by
Outputs
dataobject- Result.
Example output
{
"data": {
"data": []
}
}List instance types
Retrieves a list of the instance types currently offered on Lambda's public cloud, as well as details about each type. Details include resource specifications, pricing, and regional availability.
Inputs
- Workspace
workspace_idtext - The unique identifier (ID) of the workspace to filter by
Outputs
dataobject- Result.
Example output
{
"data": {
"data": {}
}
}List instances
Retrieves a list of your running instances.
Inputs
- Page size
page_sizenumber - Maximum number of results per page. Can be between 1 and 100. The default is 50.
- Page token
page_tokentext - A page token for cursor-based pagination.
- Cluster ID
cluster_idtext - If provided, the resulting list will only include instances that are part of a cluster with this unique identifier (ID).
- Workspace
workspace_idtext - The unique identifier (ID) of the workspace to filter by
Outputs
dataobject- Result.
Example output
{
"data": {
"data": [],
"page_token": "example"
}
}List regions
Retrieves a list of available regions.
Inputs
None.
Outputs
dataobject- Result.
Example output
{
"data": {
"data": []
}
}List SSH keys
Retrieves a list of your SSH keys.
Inputs
- Workspace
workspace_idtext - The unique identifier (ID) of the workspace to filter by
Outputs
dataobject- Result.
Example output
{
"data": {
"data": []
}
}List workspaces
Lists the workspaces the requester is a member of, by default (when view=membership), or all workspaces in the account (when view=all). The view=all option requires the iam:workspace:read permission on the account.
Inputs
- View
viewtext - View.One of:
membership,all. Default:membership.
Outputs
dataobject- Result.
Example output
{
"data": {
"data": []
}
}Restart instances
Restarts one or more instances.
Inputs
- Instance IDS
instance_idslistRequired - The unique identifiers (IDs) of the instances to restart.
Outputs
dataobject- Result.
Example output
{
"data": {
"data": {
"restarted_instances": []
}
}
}Terminate instances
Terminates one or more instances.
Inputs
- Instance IDS
instance_idslistRequired - The unique identifiers (IDs) of the instances to terminate.
Outputs
dataobject- Result.
Example output
{
"data": {
"data": {
"terminated_instances": []
}
}
}Update instance
Updates the details of the specified instance.
Inputs
- Instance
instance_idtextRequired - The unique identifier (ID) of the instance
- Name
nametext - The new, user-provided name for the instance.
- Tags
tagslist - The new tags for the instance. If provided, this replaces the existing tags (an empty list clears them). If not provided, the tags will not be updated.
Outputs
dataobject- Result.
Example output
{
"data": {
"data": {
"actions": {
"cold_reboot": {
"available": false,
"reason_description": "example"
},
"migrate": {
"available": false,
"reason_description": "example"
},
"power_cycle": {
"available": false,
"reason_description": "example"
},
"rebuild": {
"available": false,
"reason_description": "example"
},
"restart": {
"available": false,
"reason_description": "example"
},
"terminate": {
"available": false,
"reason_description": "example"
}
},
"file_system_mounts": [],
"file_system_names": [],
"firewall_rulesets": [],
"first_healthy": "example",
"hostname": "example",
"id": "example",
"image": {
"family": "example",
"id": "example"
},
"instance_type": {
"architecture": "example",
"description": "example",
"gpu_description": "example",
"name": "example",
"price_cents_per_hour": 1,
"specs": {
"gpus": 1,
"memory_gib": 1,
"storage_gib": 1,
"vcpus": 1
}
},
"ip": "example",
"jupyter_token": "example",
"jupyter_url": "example",
"name": "example",
"private_ip": "example",
"region": {
"description": "example",
"name": "example"
},
"ssh_key_names": [],
"status": "example",
"tags": [],
"workspace_id": "example"
}
}
}