cloudfoundry 0.54.0 published on Monday, Apr 14, 2025 by cloudfoundry-community
cloudfoundry.getServiceKey
Explore with Pulumi AI
cloudfoundry 0.54.0 published on Monday, Apr 14, 2025 by cloudfoundry-community
Gets information on a Cloud Foundry service key.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as cloudfoundry from "@pulumi/cloudfoundry";
const my_key = cloudfoundry.getServiceKey({
name: "my-service-key",
serviceInstance: "service-instance-id",
});
import pulumi
import pulumi_cloudfoundry as cloudfoundry
my_key = cloudfoundry.get_service_key(name="my-service-key",
service_instance="service-instance-id")
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/cloudfoundry/cloudfoundry"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := cloudfoundry.LookupServiceKey(ctx, &cloudfoundry.LookupServiceKeyArgs{
Name: "my-service-key",
ServiceInstance: "service-instance-id",
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Cloudfoundry = Pulumi.Cloudfoundry;
return await Deployment.RunAsync(() =>
{
var my_key = Cloudfoundry.GetServiceKey.Invoke(new()
{
Name = "my-service-key",
ServiceInstance = "service-instance-id",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.cloudfoundry.CloudfoundryFunctions;
import com.pulumi.cloudfoundry.inputs.GetServiceKeyArgs;
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) {
final var my-key = CloudfoundryFunctions.getServiceKey(GetServiceKeyArgs.builder()
.name("my-service-key")
.serviceInstance("service-instance-id")
.build());
}
}
variables:
my-key:
fn::invoke:
function: cloudfoundry:getServiceKey
arguments:
name: my-service-key
serviceInstance: service-instance-id
Using getServiceKey
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 getServiceKey(args: GetServiceKeyArgs, opts?: InvokeOptions): Promise<GetServiceKeyResult>
function getServiceKeyOutput(args: GetServiceKeyOutputArgs, opts?: InvokeOptions): Output<GetServiceKeyResult>
def get_service_key(id: Optional[str] = None,
name: Optional[str] = None,
service_instance: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetServiceKeyResult
def get_service_key_output(id: Optional[pulumi.Input[str]] = None,
name: Optional[pulumi.Input[str]] = None,
service_instance: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetServiceKeyResult]
func LookupServiceKey(ctx *Context, args *LookupServiceKeyArgs, opts ...InvokeOption) (*LookupServiceKeyResult, error)
func LookupServiceKeyOutput(ctx *Context, args *LookupServiceKeyOutputArgs, opts ...InvokeOption) LookupServiceKeyResultOutput
> Note: This function is named LookupServiceKey
in the Go SDK.
public static class GetServiceKey
{
public static Task<GetServiceKeyResult> InvokeAsync(GetServiceKeyArgs args, InvokeOptions? opts = null)
public static Output<GetServiceKeyResult> Invoke(GetServiceKeyInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetServiceKeyResult> getServiceKey(GetServiceKeyArgs args, InvokeOptions options)
public static Output<GetServiceKeyResult> getServiceKey(GetServiceKeyArgs args, InvokeOptions options)
fn::invoke:
function: cloudfoundry:index/getServiceKey:getServiceKey
arguments:
# arguments dictionary
The following arguments are supported:
- Name string
- The name of the service key.
- Service
Instance string - The service instance guid for this service key.
- Id string
- The GUID of the service key.
- Name string
- The name of the service key.
- Service
Instance string - The service instance guid for this service key.
- Id string
- The GUID of the service key.
- name String
- The name of the service key.
- service
Instance String - The service instance guid for this service key.
- id String
- The GUID of the service key.
- name string
- The name of the service key.
- service
Instance string - The service instance guid for this service key.
- id string
- The GUID of the service key.
- name str
- The name of the service key.
- service_
instance str - The service instance guid for this service key.
- id str
- The GUID of the service key.
- name String
- The name of the service key.
- service
Instance String - The service instance guid for this service key.
- id String
- The GUID of the service key.
getServiceKey Result
The following output properties are available:
- Credentials Dictionary<string, string>
- Map of credentials found inside service key.
- Id string
- The GUID of the service key.
- Name string
- Service
Instance string
- Credentials map[string]string
- Map of credentials found inside service key.
- Id string
- The GUID of the service key.
- Name string
- Service
Instance string
- credentials Map<String,String>
- Map of credentials found inside service key.
- id String
- The GUID of the service key.
- name String
- service
Instance String
- credentials {[key: string]: string}
- Map of credentials found inside service key.
- id string
- The GUID of the service key.
- name string
- service
Instance string
- credentials Mapping[str, str]
- Map of credentials found inside service key.
- id str
- The GUID of the service key.
- name str
- service_
instance str
- credentials Map<String>
- Map of credentials found inside service key.
- id String
- The GUID of the service key.
- name String
- service
Instance String
Package Details
- Repository
- cloudfoundry cloudfoundry-community/terraform-provider-cloudfoundry
- License
- Notes
- This Pulumi package is based on the
cloudfoundry
Terraform Provider.
cloudfoundry 0.54.0 published on Monday, Apr 14, 2025 by cloudfoundry-community