ibm 1.77.1 published on Monday, Apr 14, 2025 by ibm-cloud
ibm.getKmsKmipAdapter
Explore with Pulumi AI
Example Usage
Sample example to retrieve a KMIP adapter as a data source.
import * as pulumi from "@pulumi/pulumi";
import * as ibm from "@pulumi/ibm";
const kmsInstance = new ibm.ResourceInstance("kmsInstance", {
    service: "kms",
    plan: "tiered-pricing",
    location: "us-south",
});
const myadapter = new ibm.KmsKmipAdapter("myadapter", {
    instanceId: kmsInstance.guid,
    profile: "native_1.0",
    profileData: {
        crk_id: ibm_kms_key.key.key_id,
    },
    description: "adding a description",
});
const myadapterByname = ibm.getKmsKmipAdapterOutput({
    instanceId: kmsInstance.guid,
    name: myadapter.name,
});
const myadapterByid = ibm.getKmsKmipAdapterOutput({
    instanceId: kmsInstance.guid,
    adapterId: myadapter.adapterId,
});
import pulumi
import pulumi_ibm as ibm
kms_instance = ibm.ResourceInstance("kmsInstance",
    service="kms",
    plan="tiered-pricing",
    location="us-south")
myadapter = ibm.KmsKmipAdapter("myadapter",
    instance_id=kms_instance.guid,
    profile="native_1.0",
    profile_data={
        "crk_id": ibm_kms_key["key"]["key_id"],
    },
    description="adding a description")
myadapter_byname = ibm.get_kms_kmip_adapter_output(instance_id=kms_instance.guid,
    name=myadapter.name)
myadapter_byid = ibm.get_kms_kmip_adapter_output(instance_id=kms_instance.guid,
    adapter_id=myadapter.adapter_id)
package main
import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/ibm/ibm"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		kmsInstance, err := ibm.NewResourceInstance(ctx, "kmsInstance", &ibm.ResourceInstanceArgs{
			Service:  pulumi.String("kms"),
			Plan:     pulumi.String("tiered-pricing"),
			Location: pulumi.String("us-south"),
		})
		if err != nil {
			return err
		}
		myadapter, err := ibm.NewKmsKmipAdapter(ctx, "myadapter", &ibm.KmsKmipAdapterArgs{
			InstanceId: kmsInstance.Guid,
			Profile:    pulumi.String("native_1.0"),
			ProfileData: pulumi.StringMap{
				"crk_id": pulumi.Any(ibm_kms_key.Key.Key_id),
			},
			Description: pulumi.String("adding a description"),
		})
		if err != nil {
			return err
		}
		_ = ibm.LookupKmsKmipAdapterOutput(ctx, ibm.GetKmsKmipAdapterOutputArgs{
			InstanceId: kmsInstance.Guid,
			Name:       myadapter.Name,
		}, nil)
		_ = ibm.LookupKmsKmipAdapterOutput(ctx, ibm.GetKmsKmipAdapterOutputArgs{
			InstanceId: kmsInstance.Guid,
			AdapterId:  myadapter.AdapterId,
		}, nil)
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Ibm = Pulumi.Ibm;
return await Deployment.RunAsync(() => 
{
    var kmsInstance = new Ibm.ResourceInstance("kmsInstance", new()
    {
        Service = "kms",
        Plan = "tiered-pricing",
        Location = "us-south",
    });
    var myadapter = new Ibm.KmsKmipAdapter("myadapter", new()
    {
        InstanceId = kmsInstance.Guid,
        Profile = "native_1.0",
        ProfileData = 
        {
            { "crk_id", ibm_kms_key.Key.Key_id },
        },
        Description = "adding a description",
    });
    var myadapterByname = Ibm.GetKmsKmipAdapter.Invoke(new()
    {
        InstanceId = kmsInstance.Guid,
        Name = myadapter.Name,
    });
    var myadapterByid = Ibm.GetKmsKmipAdapter.Invoke(new()
    {
        InstanceId = kmsInstance.Guid,
        AdapterId = myadapter.AdapterId,
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.ibm.ResourceInstance;
import com.pulumi.ibm.ResourceInstanceArgs;
import com.pulumi.ibm.KmsKmipAdapter;
import com.pulumi.ibm.KmsKmipAdapterArgs;
import com.pulumi.ibm.IbmFunctions;
import com.pulumi.ibm.inputs.GetKmsKmipAdapterArgs;
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) {
        var kmsInstance = new ResourceInstance("kmsInstance", ResourceInstanceArgs.builder()
            .service("kms")
            .plan("tiered-pricing")
            .location("us-south")
            .build());
        var myadapter = new KmsKmipAdapter("myadapter", KmsKmipAdapterArgs.builder()
            .instanceId(kmsInstance.guid())
            .profile("native_1.0")
            .profileData(Map.of("crk_id", ibm_kms_key.key().key_id()))
            .description("adding a description")
            .build());
        final var myadapterByname = IbmFunctions.getKmsKmipAdapter(GetKmsKmipAdapterArgs.builder()
            .instanceId(kmsInstance.guid())
            .name(myadapter.name())
            .build());
        final var myadapterByid = IbmFunctions.getKmsKmipAdapter(GetKmsKmipAdapterArgs.builder()
            .instanceId(kmsInstance.guid())
            .adapterId(myadapter.adapterId())
            .build());
    }
}
resources:
  kmsInstance:
    type: ibm:ResourceInstance
    properties:
      service: kms
      plan: tiered-pricing
      location: us-south
  myadapter:
    type: ibm:KmsKmipAdapter
    properties:
      instanceId: ${kmsInstance.guid}
      profile: native_1.0
      profileData:
        crk_id: ${ibm_kms_key.key.key_id}
      description: adding a description
variables:
  myadapterByname:
    fn::invoke:
      function: ibm:getKmsKmipAdapter
      arguments:
        instanceId: ${kmsInstance.guid}
        name: ${myadapter.name}
  myadapterByid:
    fn::invoke:
      function: ibm:getKmsKmipAdapter
      arguments:
        instanceId: ${kmsInstance.guid}
        adapterId: ${myadapter.adapterId}
Using getKmsKmipAdapter
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 getKmsKmipAdapter(args: GetKmsKmipAdapterArgs, opts?: InvokeOptions): Promise<GetKmsKmipAdapterResult>
function getKmsKmipAdapterOutput(args: GetKmsKmipAdapterOutputArgs, opts?: InvokeOptions): Output<GetKmsKmipAdapterResult>def get_kms_kmip_adapter(adapter_id: Optional[str] = None,
                         endpoint_type: Optional[str] = None,
                         id: Optional[str] = None,
                         instance_id: Optional[str] = None,
                         name: Optional[str] = None,
                         opts: Optional[InvokeOptions] = None) -> GetKmsKmipAdapterResult
def get_kms_kmip_adapter_output(adapter_id: Optional[pulumi.Input[str]] = None,
                         endpoint_type: Optional[pulumi.Input[str]] = None,
                         id: Optional[pulumi.Input[str]] = None,
                         instance_id: Optional[pulumi.Input[str]] = None,
                         name: Optional[pulumi.Input[str]] = None,
                         opts: Optional[InvokeOptions] = None) -> Output[GetKmsKmipAdapterResult]func LookupKmsKmipAdapter(ctx *Context, args *LookupKmsKmipAdapterArgs, opts ...InvokeOption) (*LookupKmsKmipAdapterResult, error)
func LookupKmsKmipAdapterOutput(ctx *Context, args *LookupKmsKmipAdapterOutputArgs, opts ...InvokeOption) LookupKmsKmipAdapterResultOutput> Note: This function is named LookupKmsKmipAdapter in the Go SDK.
public static class GetKmsKmipAdapter 
{
    public static Task<GetKmsKmipAdapterResult> InvokeAsync(GetKmsKmipAdapterArgs args, InvokeOptions? opts = null)
    public static Output<GetKmsKmipAdapterResult> Invoke(GetKmsKmipAdapterInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetKmsKmipAdapterResult> getKmsKmipAdapter(GetKmsKmipAdapterArgs args, InvokeOptions options)
public static Output<GetKmsKmipAdapterResult> getKmsKmipAdapter(GetKmsKmipAdapterArgs args, InvokeOptions options)
fn::invoke:
  function: ibm:index/getKmsKmipAdapter:getKmsKmipAdapter
  arguments:
    # arguments dictionaryThe following arguments are supported:
- Instance
Id string - The key protect instance GUID.
 - Adapter
Id string - The UUID of the KMIP adapter to be fetched. Mutually exclusive argument with 
name. One has to be given. - Endpoint
Type string - The type of the public endpoint, or private endpoint to be used for creating keys.
 - Id string
 - Name string
 - The name of the KMIP adapter to be fetched. Mutually exclusive argument with 
adapter_id. One has to be given. 
- Instance
Id string - The key protect instance GUID.
 - Adapter
Id string - The UUID of the KMIP adapter to be fetched. Mutually exclusive argument with 
name. One has to be given. - Endpoint
Type string - The type of the public endpoint, or private endpoint to be used for creating keys.
 - Id string
 - Name string
 - The name of the KMIP adapter to be fetched. Mutually exclusive argument with 
adapter_id. One has to be given. 
- instance
Id String - The key protect instance GUID.
 - adapter
Id String - The UUID of the KMIP adapter to be fetched. Mutually exclusive argument with 
name. One has to be given. - endpoint
Type String - The type of the public endpoint, or private endpoint to be used for creating keys.
 - id String
 - name String
 - The name of the KMIP adapter to be fetched. Mutually exclusive argument with 
adapter_id. One has to be given. 
- instance
Id string - The key protect instance GUID.
 - adapter
Id string - The UUID of the KMIP adapter to be fetched. Mutually exclusive argument with 
name. One has to be given. - endpoint
Type string - The type of the public endpoint, or private endpoint to be used for creating keys.
 - id string
 - name string
 - The name of the KMIP adapter to be fetched. Mutually exclusive argument with 
adapter_id. One has to be given. 
- instance_
id str - The key protect instance GUID.
 - adapter_
id str - The UUID of the KMIP adapter to be fetched. Mutually exclusive argument with 
name. One has to be given. - endpoint_
type str - The type of the public endpoint, or private endpoint to be used for creating keys.
 - id str
 - name str
 - The name of the KMIP adapter to be fetched. Mutually exclusive argument with 
adapter_id. One has to be given. 
- instance
Id String - The key protect instance GUID.
 - adapter
Id String - The UUID of the KMIP adapter to be fetched. Mutually exclusive argument with 
name. One has to be given. - endpoint
Type String - The type of the public endpoint, or private endpoint to be used for creating keys.
 - id String
 - name String
 - The name of the KMIP adapter to be fetched. Mutually exclusive argument with 
adapter_id. One has to be given. 
getKmsKmipAdapter Result
The following output properties are available:
- Adapter
Id string - Created
At string - (String) The date the resource was created, in RFC 3339 format
 - Created
By string - (String) The IBM-ID of the identity that created the resource
 - Description string
 - (String) The description of the KMIP adapter.
 - Endpoint
Type string - Id string
 - Instance
Id string - Name string
 - Profile string
 - (String) The profile of the KMIP adapter.
 - Profile
Data Dictionary<string, string> - (Map) The profile data of the KMIP adapter.
 - Updated
At string - (String) The date the resource was updated, in RFC 3339 format
 - Updated
By string - (String) The IBM-ID of the identity that updated the resource
 
- Adapter
Id string - Created
At string - (String) The date the resource was created, in RFC 3339 format
 - Created
By string - (String) The IBM-ID of the identity that created the resource
 - Description string
 - (String) The description of the KMIP adapter.
 - Endpoint
Type string - Id string
 - Instance
Id string - Name string
 - Profile string
 - (String) The profile of the KMIP adapter.
 - Profile
Data map[string]string - (Map) The profile data of the KMIP adapter.
 - Updated
At string - (String) The date the resource was updated, in RFC 3339 format
 - Updated
By string - (String) The IBM-ID of the identity that updated the resource
 
- adapter
Id String - created
At String - (String) The date the resource was created, in RFC 3339 format
 - created
By String - (String) The IBM-ID of the identity that created the resource
 - description String
 - (String) The description of the KMIP adapter.
 - endpoint
Type String - id String
 - instance
Id String - name String
 - profile String
 - (String) The profile of the KMIP adapter.
 - profile
Data Map<String,String> - (Map) The profile data of the KMIP adapter.
 - updated
At String - (String) The date the resource was updated, in RFC 3339 format
 - updated
By String - (String) The IBM-ID of the identity that updated the resource
 
- adapter
Id string - created
At string - (String) The date the resource was created, in RFC 3339 format
 - created
By string - (String) The IBM-ID of the identity that created the resource
 - description string
 - (String) The description of the KMIP adapter.
 - endpoint
Type string - id string
 - instance
Id string - name string
 - profile string
 - (String) The profile of the KMIP adapter.
 - profile
Data {[key: string]: string} - (Map) The profile data of the KMIP adapter.
 - updated
At string - (String) The date the resource was updated, in RFC 3339 format
 - updated
By string - (String) The IBM-ID of the identity that updated the resource
 
- adapter_
id str - created_
at str - (String) The date the resource was created, in RFC 3339 format
 - created_
by str - (String) The IBM-ID of the identity that created the resource
 - description str
 - (String) The description of the KMIP adapter.
 - endpoint_
type str - id str
 - instance_
id str - name str
 - profile str
 - (String) The profile of the KMIP adapter.
 - profile_
data Mapping[str, str] - (Map) The profile data of the KMIP adapter.
 - updated_
at str - (String) The date the resource was updated, in RFC 3339 format
 - updated_
by str - (String) The IBM-ID of the identity that updated the resource
 
- adapter
Id String - created
At String - (String) The date the resource was created, in RFC 3339 format
 - created
By String - (String) The IBM-ID of the identity that created the resource
 - description String
 - (String) The description of the KMIP adapter.
 - endpoint
Type String - id String
 - instance
Id String - name String
 - profile String
 - (String) The profile of the KMIP adapter.
 - profile
Data Map<String> - (Map) The profile data of the KMIP adapter.
 - updated
At String - (String) The date the resource was updated, in RFC 3339 format
 - updated
By String - (String) The IBM-ID of the identity that updated the resource
 
Package Details
- Repository
 - ibm ibm-cloud/terraform-provider-ibm
 - License
 - Notes
 - This Pulumi package is based on the 
ibmTerraform Provider.