DigitaloceanFunctions

Functions

Link copied to clipboard

Get information on your DigitalOcean account.

Link copied to clipboard
suspend fun getApp(argument: GetAppPlainArgs): GetAppResult

Get information on a DigitalOcean App.

suspend fun getApp(argument: suspend GetAppPlainArgsBuilder.() -> Unit): GetAppResult
suspend fun getApp(appId: String, dedicatedIps: List<GetAppDedicatedIp>? = null): GetAppResult
Link copied to clipboard

Get information on a certificate. This data source provides the name, type, state, domains, expiry date, and the sha1 fingerprint as configured on your DigitalOcean account. This is useful if the certificate in question is not managed by this provider or you need to utilize any of the certificates data. An error is triggered if the provided certificate name does not exist.

Link copied to clipboard

Get information on a container registry. This data source provides the name as configured on your DigitalOcean account. This is useful if the container registry name in question is not managed by this provider or you need validate if the container registry exists in the account. An error is triggered if the provided container registry name does not exist.

Link copied to clipboard

Provides the CA certificate for a DigitalOcean database.

suspend fun getDatabaseCa(clusterId: String): GetDatabaseCaResult
Link copied to clipboard

Provides information on a DigitalOcean database cluster resource.

suspend fun getDatabaseCluster(name: String, tags: List<String>? = null): GetDatabaseClusterResult
Link copied to clipboard

Provides information on a DigitalOcean PostgreSQL database connection pool.

Link copied to clipboard

Provides information on a DigitalOcean database replica.

suspend fun getDatabaseReplica(clusterId: String, name: String, tags: List<String>? = null): GetDatabaseReplicaResult
Link copied to clipboard

Provides information on a DigitalOcean database user resource.

suspend fun getDatabaseUser(clusterId: String, name: String): GetDatabaseUserResult
Link copied to clipboard

Get information on a domain. This data source provides the name, TTL, and zone file as configured on your DigitalOcean account. This is useful if the domain name in question is not managed by this provider or you need to utilize TTL or zone file data. An error is triggered if the provided domain name is not managed with your DigitalOcean account.

suspend fun getDomain(name: String): GetDomainResult
suspend fun getDomain(argument: suspend GetDomainPlainArgsBuilder.() -> Unit): GetDomainResult
Link copied to clipboard

Get information on domains for use in other resources, with the ability to filter and sort the results. If no filters are specified, all domains will be returned. This data source is useful if the domains in question are not managed by this provider or you need to utilize any of the domains' data. Note: You can use the digitalocean.Domain data source to obtain metadata about a single domain if you already know the name.

suspend fun getDomains(argument: suspend GetDomainsPlainArgsBuilder.() -> Unit): GetDomainsResult
suspend fun getDomains(filters: List<GetDomainsFilter>? = null, sorts: List<GetDomainsSort>? = null): GetDomainsResult
Link copied to clipboard

Get information on a Droplet for use in other resources. This data source provides all of the Droplet's properties as configured on your DigitalOcean account. This is useful if the Droplet in question is not managed by this provider or you need to utilize any of the Droplet's data. Note: This data source returns a single Droplet. When specifying a tag, an error is triggered if more than one Droplet is found.

suspend fun getDroplet(argument: suspend GetDropletPlainArgsBuilder.() -> Unit): GetDropletResult
suspend fun getDroplet(gpu: Boolean? = null, id: Int? = null, name: String? = null, tag: String? = null): GetDropletResult
Link copied to clipboard

Get the Droplet Autoscale pool by name:

suspend fun getDropletAutoscale(id: String? = null, name: String? = null): GetDropletAutoscaleResult
Link copied to clipboard

Get information on Droplets for use in other resources, with the ability to filter and sort the results. If no filters are specified, all Droplets will be returned. This data source is useful if the Droplets in question are not managed by the provider or you need to utilize any of the Droplets' data. By default, only non-GPU Droplets are returned. To list only GPU Droplets, set the gpus attribute to true. Note: You can use the digitalocean.Droplet data source to obtain metadata about a single Droplet if you already know the id, unique name, or unique tag to retrieve.

suspend fun getDroplets(argument: suspend GetDropletsPlainArgsBuilder.() -> Unit): GetDropletsResult
suspend fun getDroplets(filters: List<GetDropletsFilter>? = null, gpus: Boolean? = null, sorts: List<GetDropletsSort>? = null): GetDropletsResult
Link copied to clipboard

Droplet snapshots are saved instances of a Droplet. Use this data source to retrieve the ID of a DigitalOcean Droplet snapshot for use in other resources.

suspend fun getDropletSnapshot(mostRecent: Boolean? = null, name: String? = null, nameRegex: String? = null, region: String? = null): GetDropletSnapshotResult
Link copied to clipboard

Get information on a DigitalOcean Firewall.

suspend fun getFirewall(argument: suspend GetFirewallPlainArgsBuilder.() -> Unit): GetFirewallResult
suspend fun getFirewall(dropletIds: List<Int>? = null, firewallId: String, inboundRules: List<GetFirewallInboundRule>? = null, outboundRules: List<GetFirewallOutboundRule>? = null, tags: List<String>? = null): GetFirewallResult
Link copied to clipboard

Get the floating IP:

suspend fun getFloatingIp(ipAddress: String): GetFloatingIpResult
Link copied to clipboard
suspend fun getImage(argument: GetImagePlainArgs): GetImageResult

Get information on an image for use in other resources (e.g. creating a Droplet based on snapshot). This data source provides all of the image properties as configured on your DigitalOcean account. This is useful if the image in question is not managed by the provider or you need to utilize any of the image's data. An error is triggered if zero or more than one result is returned by the query.

suspend fun getImage(argument: suspend GetImagePlainArgsBuilder.() -> Unit): GetImageResult
suspend fun getImage(id: Int? = null, name: String? = null, slug: String? = null, source: String? = null): GetImageResult
Link copied to clipboard

Get information on images for use in other resources (e.g. creating a Droplet based on a snapshot), with the ability to filter and sort the results. If no filters are specified, all images will be returned. This data source is useful if the image in question is not managed by the provider or you need to utilize any of the image's data. Note: You can use the digitalocean.getImage data source to obtain metadata about a single image if you already know the slug, unique name, or id to retrieve.

suspend fun getImages(argument: suspend GetImagesPlainArgsBuilder.() -> Unit): GetImagesResult
suspend fun getImages(filters: List<GetImagesFilter>? = null, sorts: List<GetImagesSort>? = null): GetImagesResult
Link copied to clipboard

Retrieves information about a DigitalOcean Kubernetes cluster for use in other resources. This data source provides all of the cluster's properties as configured on your DigitalOcean account. This is useful if the cluster in question is not managed by the provider.

suspend fun getKubernetesCluster(clusterAutoscalerConfigurations: List<GetKubernetesClusterClusterAutoscalerConfiguration>? = null, kubeconfigExpireSeconds: Int? = null, name: String, routingAgent: GetKubernetesClusterRoutingAgent? = null, tags: List<String>? = null): GetKubernetesClusterResult
Link copied to clipboard

Provides access to the available DigitalOcean Kubernetes Service versions.

suspend fun getKubernetesVersions(versionPrefix: String? = null): GetKubernetesVersionsResult
Link copied to clipboard

Get information on a load balancer for use in other resources. This data source provides all of the load balancers properties as configured on your DigitalOcean account. This is useful if the load balancer in question is not managed by the provider or you need to utilize any of the load balancers data. An error is triggered if the provided load balancer name does not exist.

suspend fun getLoadBalancer(id: String? = null, name: String? = null): GetLoadBalancerResult
Link copied to clipboard

Get information on a single DigitalOcean project. If neither the id nor name attributes are provided, then this data source returns the default project.

suspend fun getProject(argument: suspend GetProjectPlainArgsBuilder.() -> Unit): GetProjectResult
suspend fun getProject(id: String? = null, name: String? = null): GetProjectResult
Link copied to clipboard

Retrieve information about all DigitalOcean projects associated with an account, with the ability to filter and sort the results. If no filters are specified, all projects will be returned. Note: You can use the digitalocean.Project data source to obtain metadata about a single project if you already know the id to retrieve or the unique name of the project.

suspend fun getProjects(argument: suspend GetProjectsPlainArgsBuilder.() -> Unit): GetProjectsResult
suspend fun getProjects(filters: List<GetProjectsFilter>? = null, sorts: List<GetProjectsSort>? = null): GetProjectsResult
Link copied to clipboard

Get information on a DNS record. This data source provides the name, TTL, and zone file as configured on your DigitalOcean account. This is useful if the record in question is not managed by the provider. An error is triggered if the provided domain name or record are not managed with your DigitalOcean account.

suspend fun getRecord(argument: suspend GetRecordPlainArgsBuilder.() -> Unit): GetRecordResult
suspend fun getRecord(domain: String, name: String): GetRecordResult
Link copied to clipboard

Retrieve information about all DNS records within a domain, with the ability to filter and sort the results. If no filters are specified, all records will be returned.

suspend fun getRecords(argument: suspend GetRecordsPlainArgsBuilder.() -> Unit): GetRecordsResult
suspend fun getRecords(domain: String, filters: List<GetRecordsFilter>? = null, sorts: List<GetRecordsSort>? = null): GetRecordsResult
Link copied to clipboard

Get information on a single DigitalOcean region. This is useful to find out what Droplet sizes and features are supported within a region.

suspend fun getRegion(slug: String): GetRegionResult
suspend fun getRegion(argument: suspend GetRegionPlainArgsBuilder.() -> Unit): GetRegionResult
Link copied to clipboard

Retrieve information about all supported DigitalOcean regions, with the ability to filter and sort the results. If no filters are specified, all regions will be returned. Note: You can use the digitalocean.getRegion data source to obtain metadata about a single region if you already know the slug to retrieve.

suspend fun getRegions(argument: suspend GetRegionsPlainArgsBuilder.() -> Unit): GetRegionsResult
suspend fun getRegions(filters: List<GetRegionsFilter>? = null, sorts: List<GetRegionsSort>? = null): GetRegionsResult
Link copied to clipboard

Get the reserved IP:

suspend fun getReservedIp(ipAddress: String): GetReservedIpResult
Link copied to clipboard
Link copied to clipboard
suspend fun getSizes(argument: GetSizesPlainArgs): GetSizesResult

Retrieves information about the Droplet sizes that DigitalOcean supports, with the ability to filter and sort the results. If no filters are specified, all sizes will be returned.

suspend fun getSizes(argument: suspend GetSizesPlainArgsBuilder.() -> Unit): GetSizesResult
suspend fun getSizes(filters: List<GetSizesFilter>? = null, sorts: List<GetSizesSort>? = null): GetSizesResult
Link copied to clipboard

Get information on a Spaces bucket for use in other resources. This is useful if the Spaces bucket in question is not managed by the provider or you need to utilize any of the bucket's data.

suspend fun getSpacesBucket(name: String, region: String): GetSpacesBucketResult
Link copied to clipboard

The Spaces object data source allows access to the metadata and optionally (see below) content of an object stored inside a Spaces bucket.

suspend fun getSpacesBucketObject(bucket: String, key: String, range: String? = null, region: String, versionId: String? = null): GetSpacesBucketObjectResult
Link copied to clipboard
suspend fun getSpacesBucketObjects(bucket: String, delimiter: String? = null, encodingType: String? = null, maxKeys: Int? = null, prefix: String? = null, region: String): GetSpacesBucketObjectsResult
Link copied to clipboard

Get information on Spaces buckets for use in other resources, with the ability to filter and sort the results. If no filters are specified, all Spaces buckets will be returned. Note: You can use the digitalocean.SpacesBucket data source to obtain metadata about a single bucket if you already know its name and region.

Link copied to clipboard

Get the key by access key ID:

suspend fun getSpacesKey(accessKey: String): GetSpacesKeyResult
Link copied to clipboard

Get information on a ssh key. This data source provides the name, public key, and fingerprint as configured on your DigitalOcean account. This is useful if the ssh key in question is not managed by the provider or you need to utilize any of the keys data. An error is triggered if the provided ssh key name does not exist.

suspend fun getSshKey(name: String): GetSshKeyResult
suspend fun getSshKey(argument: suspend GetSshKeyPlainArgsBuilder.() -> Unit): GetSshKeyResult
Link copied to clipboard

Get information on SSH Keys for use in other resources. This data source is useful if the SSH Keys in question are not managed by the provider or you need to utilize any of the SSH Keys' data. Note: You can use the digitalocean.SshKey data source to obtain metadata about a single SSH Key if you already know the unique name to retrieve.

suspend fun getSshKeys(argument: suspend GetSshKeysPlainArgsBuilder.() -> Unit): GetSshKeysResult
suspend fun getSshKeys(filters: List<GetSshKeysFilter>? = null, sorts: List<GetSshKeysSort>? = null): GetSshKeysResult
Link copied to clipboard
suspend fun getTag(argument: GetTagPlainArgs): GetTagResult

Get information on a tag. This data source provides the name as configured on your DigitalOcean account. This is useful if the tag name in question is not managed by the provider or you need validate if the tag exists in the account. An error is triggered if the provided tag name does not exist.

suspend fun getTag(name: String): GetTagResult
suspend fun getTag(argument: suspend GetTagPlainArgsBuilder.() -> Unit): GetTagResult
Link copied to clipboard
suspend fun getTags(argument: GetTagsPlainArgs): GetTagsResult

Returns a list of tags in your DigitalOcean account, with the ability to filter and sort the results. If no filters are specified, all tags will be returned.

suspend fun getTags(argument: suspend GetTagsPlainArgsBuilder.() -> Unit): GetTagsResult
suspend fun getTags(filters: List<GetTagsFilter>? = null, sorts: List<GetTagsSort>? = null): GetTagsResult
Link copied to clipboard

Get information on a volume for use in other resources. This data source provides all of the volumes properties as configured on your DigitalOcean account. This is useful if the volume in question is not managed by the provider or you need to utilize any of the volumes data. An error is triggered if the provided volume name does not exist.

suspend fun getVolume(argument: suspend GetVolumePlainArgsBuilder.() -> Unit): GetVolumeResult
suspend fun getVolume(description: String? = null, name: String, region: String? = null): GetVolumeResult
Link copied to clipboard

Volume snapshots are saved instances of a block storage volume. Use this data source to retrieve the ID of a DigitalOcean volume snapshot for use in other resources.

suspend fun getVolumeSnapshot(mostRecent: Boolean? = null, name: String? = null, nameRegex: String? = null, region: String? = null): GetVolumeSnapshotResult
Link copied to clipboard
suspend fun getVpc(argument: GetVpcPlainArgs): GetVpcResult

Retrieve information about a VPC for use in other resources. This data source provides all of the VPC's properties as configured on your DigitalOcean account. This is useful if the VPC in question is not managed by the provider or you need to utilize any of the VPC's data. VPCs may be looked up by id or name. Specifying a region will return that that region's default VPC.

suspend fun getVpc(argument: suspend GetVpcPlainArgsBuilder.() -> Unit): GetVpcResult
suspend fun getVpc(id: String? = null, name: String? = null, region: String? = null): GetVpcResult
Link copied to clipboard
suspend fun getVpcPeering(id: String? = null, name: String? = null, vpcIds: List<String>? = null): GetVpcPeeringResult