1. Registry
  2. Packages
  3. Spectrocloud Provider
  4. API Docs
  5. getRateConfig
Viewing docs for spectrocloud 0.30.5
published on Wednesday, Nov 4, 2026 by spectrocloud
spectrocloud
Viewing docs for spectrocloud 0.30.5
published on Wednesday, Nov 4, 2026 by spectrocloud

    Provides the tenant-level cloud rate config, the unit prices Palette uses to estimate cluster cloud cost and usage cost.

    The rate config is a tenant-level singleton, so this data source takes no arguments and always returns the rate config of the tenant the provider is authenticated against.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as spectrocloud from "@pulumi/spectrocloud";
    
    // Retrieve the tenant cloud rate config
    const current = spectrocloud.getRateConfig({});
    export const vsphereCpuUnitPricePerHour = current.then(current => current.vspheres?.[0]?.cpuUnitPricePerHour);
    
    import pulumi
    import pulumi_spectrocloud as spectrocloud
    
    # Retrieve the tenant cloud rate config
    current = spectrocloud.get_rate_config()
    pulumi.export("vsphereCpuUnitPricePerHour", current.vspheres[0].cpu_unit_price_per_hour)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/spectrocloud/spectrocloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		// Retrieve the tenant cloud rate config
    		current, err := spectrocloud.LookupRateConfig(ctx, &spectrocloud.LookupRateConfigArgs{}, nil)
    		if err != nil {
    			return err
    		}
    		ctx.Export("vsphereCpuUnitPricePerHour", current.Vspheres[0].CpuUnitPricePerHour)
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Spectrocloud = Pulumi.Spectrocloud;
    
    return await Deployment.RunAsync(() => 
    {
        // Retrieve the tenant cloud rate config
        var current = Spectrocloud.GetRateConfig.Invoke();
    
        return new Dictionary<string, object?>
        {
            ["vsphereCpuUnitPricePerHour"] = current.Apply(getRateConfigResult => getRateConfigResult.Vspheres[0]?.CpuUnitPricePerHour),
        };
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.spectrocloud.SpectrocloudFunctions;
    import com.pulumi.spectrocloud.inputs.GetRateConfigArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            // Retrieve the tenant cloud rate config
            final var current = SpectrocloudFunctions.getRateConfig(GetRateConfigArgs.builder()
                .build());
    
            ctx.export("vsphereCpuUnitPricePerHour", current.vspheres()[0].cpuUnitPricePerHour());
        }
    }
    
    variables:
      # Retrieve the tenant cloud rate config
      current:
        fn::invoke:
          function: spectrocloud:getRateConfig
          arguments: {}
    outputs:
      # Output the vSphere CPU rate Palette uses for cost estimates
      vsphereCpuUnitPricePerHour: ${current.vspheres[0].cpuUnitPricePerHour}
    
    Example coming soon!
    

    Using getRateConfig

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getRateConfig(args: GetRateConfigArgs, opts?: InvokeOptions): Promise<GetRateConfigResult>
    function getRateConfigOutput(args: GetRateConfigOutputArgs, opts?: InvokeOutputOptions): Output<GetRateConfigResult>
    def get_rate_config(id: Optional[str] = None,
                        opts: Optional[InvokeOptions] = None) -> GetRateConfigResult
    def get_rate_config_output(id: pulumi.Input[Optional[str]] = None,
                        opts: Optional[InvokeOutputOptions] = None) -> Output[GetRateConfigResult]
    func LookupRateConfig(ctx *Context, args *LookupRateConfigArgs, opts ...InvokeOption) (*LookupRateConfigResult, error)
    func LookupRateConfigOutput(ctx *Context, args *LookupRateConfigOutputArgs, opts ...InvokeOption) LookupRateConfigResultOutput

    > Note: This function is named LookupRateConfig in the Go SDK.

    public static class GetRateConfig 
    {
        public static Task<GetRateConfigResult> InvokeAsync(GetRateConfigArgs args, InvokeOptions? opts = null)
        public static Output<GetRateConfigResult> Invoke(GetRateConfigInvokeArgs args, InvokeOptions? opts = null)
        public static Output<GetRateConfigResult> Invoke(GetRateConfigInvokeArgs args, InvokeOutputOptions opts)
    }
    public static CompletableFuture<GetRateConfigResult> getRateConfig(GetRateConfigArgs args, InvokeOptions options)
    public static Output<GetRateConfigResult> getRateConfig(GetRateConfigArgs args, InvokeOptions options)
    public static Output<GetRateConfigResult> getRateConfig(GetRateConfigArgs args, InvokeOutputOptions options)
    
    fn::invoke:
      function: spectrocloud:index/getRateConfig:getRateConfig
      arguments:
        # arguments dictionary
    data "spectrocloud_get_rate_config" "name" {
        # arguments
    }

    The following arguments are supported:

    Id string
    The ID of this resource.
    Id string
    The ID of this resource.
    id string
    The ID of this resource.
    id String
    The ID of this resource.
    id string
    The ID of this resource.
    id str
    The ID of this resource.
    id String
    The ID of this resource.

    getRateConfig Result

    The following output properties are available:

    ApacheCloudstacks List<GetRateConfigApacheCloudstack>
    Unit prices used to estimate the cost of Apache CloudStack resources.
    Aws List<GetRateConfigAw>
    Rate proportions used to estimate the cost of AWS instances.
    Azures List<GetRateConfigAzure>
    Rate proportions used to estimate the cost of Azure instances.
    Customs List<GetRateConfigCustom>
    Unit prices applied to the custom cloud types registered in the tenant. One block per custom cloud.
    Gcps List<GetRateConfigGcp>
    Rate proportions used to estimate the cost of GCP instances.
    Generics List<GetRateConfigGeneric>
    Unit prices used to estimate the cost of generic cloud resources.
    Id string
    The ID of this resource.
    Maas List<GetRateConfigMaa>
    Unit prices used to estimate the cost of MAAS resources.
    Vspheres List<GetRateConfigVsphere>
    Unit prices used to estimate the cost of VMware vSphere resources.
    ApacheCloudstacks []GetRateConfigApacheCloudstack
    Unit prices used to estimate the cost of Apache CloudStack resources.
    Aws []GetRateConfigAw
    Rate proportions used to estimate the cost of AWS instances.
    Azures []GetRateConfigAzure
    Rate proportions used to estimate the cost of Azure instances.
    Customs []GetRateConfigCustom
    Unit prices applied to the custom cloud types registered in the tenant. One block per custom cloud.
    Gcps []GetRateConfigGcp
    Rate proportions used to estimate the cost of GCP instances.
    Generics []GetRateConfigGeneric
    Unit prices used to estimate the cost of generic cloud resources.
    Id string
    The ID of this resource.
    Maas []GetRateConfigMaa
    Unit prices used to estimate the cost of MAAS resources.
    Vspheres []GetRateConfigVsphere
    Unit prices used to estimate the cost of VMware vSphere resources.
    apache_cloudstacks list(object)
    Unit prices used to estimate the cost of Apache CloudStack resources.
    aws list(object)
    Rate proportions used to estimate the cost of AWS instances.
    azures list(object)
    Rate proportions used to estimate the cost of Azure instances.
    customs list(object)
    Unit prices applied to the custom cloud types registered in the tenant. One block per custom cloud.
    gcps list(object)
    Rate proportions used to estimate the cost of GCP instances.
    generics list(object)
    Unit prices used to estimate the cost of generic cloud resources.
    id string
    The ID of this resource.
    maas list(object)
    Unit prices used to estimate the cost of MAAS resources.
    vspheres list(object)
    Unit prices used to estimate the cost of VMware vSphere resources.
    apacheCloudstacks List<GetRateConfigApacheCloudstack>
    Unit prices used to estimate the cost of Apache CloudStack resources.
    aws List<GetRateConfigAw>
    Rate proportions used to estimate the cost of AWS instances.
    azures List<GetRateConfigAzure>
    Rate proportions used to estimate the cost of Azure instances.
    customs List<GetRateConfigCustom>
    Unit prices applied to the custom cloud types registered in the tenant. One block per custom cloud.
    gcps List<GetRateConfigGcp>
    Rate proportions used to estimate the cost of GCP instances.
    generics List<GetRateConfigGeneric>
    Unit prices used to estimate the cost of generic cloud resources.
    id String
    The ID of this resource.
    maas List<GetRateConfigMaa>
    Unit prices used to estimate the cost of MAAS resources.
    vspheres List<GetRateConfigVsphere>
    Unit prices used to estimate the cost of VMware vSphere resources.
    apacheCloudstacks GetRateConfigApacheCloudstack[]
    Unit prices used to estimate the cost of Apache CloudStack resources.
    aws GetRateConfigAw[]
    Rate proportions used to estimate the cost of AWS instances.
    azures GetRateConfigAzure[]
    Rate proportions used to estimate the cost of Azure instances.
    customs GetRateConfigCustom[]
    Unit prices applied to the custom cloud types registered in the tenant. One block per custom cloud.
    gcps GetRateConfigGcp[]
    Rate proportions used to estimate the cost of GCP instances.
    generics GetRateConfigGeneric[]
    Unit prices used to estimate the cost of generic cloud resources.
    id string
    The ID of this resource.
    maas GetRateConfigMaa[]
    Unit prices used to estimate the cost of MAAS resources.
    vspheres GetRateConfigVsphere[]
    Unit prices used to estimate the cost of VMware vSphere resources.
    apache_cloudstacks Sequence[GetRateConfigApacheCloudstack]
    Unit prices used to estimate the cost of Apache CloudStack resources.
    aws Sequence[GetRateConfigAw]
    Rate proportions used to estimate the cost of AWS instances.
    azures Sequence[GetRateConfigAzure]
    Rate proportions used to estimate the cost of Azure instances.
    customs Sequence[GetRateConfigCustom]
    Unit prices applied to the custom cloud types registered in the tenant. One block per custom cloud.
    gcps Sequence[GetRateConfigGcp]
    Rate proportions used to estimate the cost of GCP instances.
    generics Sequence[GetRateConfigGeneric]
    Unit prices used to estimate the cost of generic cloud resources.
    id str
    The ID of this resource.
    maas Sequence[GetRateConfigMaa]
    Unit prices used to estimate the cost of MAAS resources.
    vspheres Sequence[GetRateConfigVsphere]
    Unit prices used to estimate the cost of VMware vSphere resources.
    apacheCloudstacks List<Property Map>
    Unit prices used to estimate the cost of Apache CloudStack resources.
    aws List<Property Map>
    Rate proportions used to estimate the cost of AWS instances.
    azures List<Property Map>
    Rate proportions used to estimate the cost of Azure instances.
    customs List<Property Map>
    Unit prices applied to the custom cloud types registered in the tenant. One block per custom cloud.
    gcps List<Property Map>
    Rate proportions used to estimate the cost of GCP instances.
    generics List<Property Map>
    Unit prices used to estimate the cost of generic cloud resources.
    id String
    The ID of this resource.
    maas List<Property Map>
    Unit prices used to estimate the cost of MAAS resources.
    vspheres List<Property Map>
    Unit prices used to estimate the cost of VMware vSphere resources.

    Supporting Types

    GetRateConfigApacheCloudstack

    GetRateConfigAw

    GetRateConfigAwComputeOptimized

    GetRateConfigAwMemoryOptimized

    GetRateConfigAzure

    GetRateConfigAzureComputeOptimized

    GetRateConfigAzureMemoryOptimized

    GetRateConfigCustom

    GetRateConfigCustomRateConfig

    GetRateConfigGcp

    GetRateConfigGcpComputeOptimized

    GetRateConfigGcpMemoryOptimized

    GetRateConfigGeneric

    GetRateConfigMaa

    GetRateConfigVsphere

    Package Details

    Repository
    spectrocloud spectrocloud/terraform-provider-spectrocloud
    License
    Notes
    This Pulumi package is based on the spectrocloud Terraform Provider.
    spectrocloud
    Viewing docs for spectrocloud 0.30.5
    published on Wednesday, Nov 4, 2026 by spectrocloud

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial