// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumi.azure.healthcare;

import com.pulumi.azure.Utilities;
import com.pulumi.azure.healthcare.MedtechServiceFhirDestinationArgs;
import com.pulumi.azure.healthcare.inputs.MedtechServiceFhirDestinationState;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Export;
import com.pulumi.core.annotations.ResourceType;
import com.pulumi.core.internal.Codegen;
import java.lang.String;
import javax.annotation.Nullable;

/**
 * Manages a Healthcare Med Tech Service Fhir Destination.
 * ```java
 * package generated_program;
 * 
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.azure.core.ResourceGroup;
 * import com.pulumi.azure.core.ResourceGroupArgs;
 * import com.pulumi.azure.core.CoreFunctions;
 * import com.pulumi.azure.healthcare.Workspace;
 * import com.pulumi.azure.healthcare.WorkspaceArgs;
 * import com.pulumi.azure.eventhub.EventHubNamespace;
 * import com.pulumi.azure.eventhub.EventHubNamespaceArgs;
 * import com.pulumi.azure.eventhub.EventHub;
 * import com.pulumi.azure.eventhub.EventHubArgs;
 * import com.pulumi.azure.eventhub.ConsumerGroup;
 * import com.pulumi.azure.eventhub.ConsumerGroupArgs;
 * import com.pulumi.azure.healthcare.FhirService;
 * import com.pulumi.azure.healthcare.FhirServiceArgs;
 * import com.pulumi.azure.healthcare.inputs.FhirServiceAuthenticationArgs;
 * import com.pulumi.azure.healthcare.MedtechService;
 * import com.pulumi.azure.healthcare.MedtechServiceArgs;
 * import com.pulumi.azure.healthcare.MedtechServiceFhirDestination;
 * import com.pulumi.azure.healthcare.MedtechServiceFhirDestinationArgs;
 * import static com.pulumi.codegen.internal.Serialization.*;
 * 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 exampleResourceGroup = new ResourceGroup(&#34;exampleResourceGroup&#34;, ResourceGroupArgs.builder()        
 *             .location(&#34;West Europe&#34;)
 *             .build());
 * 
 *         final var current = CoreFunctions.getClientConfig();
 * 
 *         var exampleWorkspace = new Workspace(&#34;exampleWorkspace&#34;, WorkspaceArgs.builder()        
 *             .location(exampleResourceGroup.location())
 *             .resourceGroupName(exampleResourceGroup.name())
 *             .build());
 * 
 *         var exampleEventHubNamespace = new EventHubNamespace(&#34;exampleEventHubNamespace&#34;, EventHubNamespaceArgs.builder()        
 *             .location(exampleResourceGroup.location())
 *             .resourceGroupName(exampleResourceGroup.name())
 *             .sku(&#34;Standard&#34;)
 *             .build());
 * 
 *         var exampleEventHub = new EventHub(&#34;exampleEventHub&#34;, EventHubArgs.builder()        
 *             .namespaceName(exampleEventHubNamespace.name())
 *             .resourceGroupName(exampleResourceGroup.name())
 *             .partitionCount(1)
 *             .messageRetention(1)
 *             .build());
 * 
 *         var exampleConsumerGroup = new ConsumerGroup(&#34;exampleConsumerGroup&#34;, ConsumerGroupArgs.builder()        
 *             .namespaceName(exampleEventHubNamespace.name())
 *             .eventhubName(exampleEventHub.name())
 *             .resourceGroupName(exampleResourceGroup.name())
 *             .build());
 * 
 *         var exampleFhirService = new FhirService(&#34;exampleFhirService&#34;, FhirServiceArgs.builder()        
 *             .location(exampleResourceGroup.location())
 *             .resourceGroupName(exampleResourceGroup.name())
 *             .workspaceId(exampleWorkspace.id())
 *             .kind(&#34;fhir-R4&#34;)
 *             .authentication(FhirServiceAuthenticationArgs.builder()
 *                 .authority(&#34;https://login.microsoftonline.com/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx&#34;)
 *                 .audience(&#34;https://examplefhir.fhir.azurehealthcareapis.com&#34;)
 *                 .build())
 *             .build());
 * 
 *         var exampleMedtechService = new MedtechService(&#34;exampleMedtechService&#34;, MedtechServiceArgs.builder()        
 *             .workspaceId(exampleWorkspace.id())
 *             .location(exampleResourceGroup.location())
 *             .eventhubNamespaceName(exampleEventHubNamespace.name())
 *             .eventhubName(exampleEventHub.name())
 *             .eventhubConsumerGroupName(exampleConsumerGroup.name())
 *             .deviceMappingJson(serializeJson(
 *                 jsonObject(
 *                     jsonProperty(&#34;templateType&#34;, &#34;CollectionContent&#34;),
 *                     jsonProperty(&#34;template&#34;, jsonArray(
 *                     ))
 *                 )))
 *             .build());
 * 
 *         var exampleMedtechServiceFhirDestination = new MedtechServiceFhirDestination(&#34;exampleMedtechServiceFhirDestination&#34;, MedtechServiceFhirDestinationArgs.builder()        
 *             .location(&#34;east us&#34;)
 *             .medtechServiceId(exampleMedtechService.id())
 *             .destinationFhirServiceId(exampleFhirService.id())
 *             .destinationIdentityResolutionType(&#34;Create&#34;)
 *             .destinationFhirMappingJson(serializeJson(
 *                 jsonObject(
 *                     jsonProperty(&#34;templateType&#34;, &#34;CollectionFhirTemplate&#34;),
 *                     jsonProperty(&#34;template&#34;, jsonArray(jsonObject(
 *                         jsonProperty(&#34;templateType&#34;, &#34;CodeValueFhir&#34;),
 *                         jsonProperty(&#34;template&#34;, jsonObject(
 *                             jsonProperty(&#34;codes&#34;, jsonArray(jsonObject(
 *                                 jsonProperty(&#34;code&#34;, &#34;8867-4&#34;),
 *                                 jsonProperty(&#34;system&#34;, &#34;http://loinc.org&#34;),
 *                                 jsonProperty(&#34;display&#34;, &#34;Heart rate&#34;)
 *                             ))),
 *                             jsonProperty(&#34;periodInterval&#34;, 60),
 *                             jsonProperty(&#34;typeName&#34;, &#34;heartrate&#34;),
 *                             jsonProperty(&#34;value&#34;, jsonObject(
 *                                 jsonProperty(&#34;defaultPeriod&#34;, 5000),
 *                                 jsonProperty(&#34;unit&#34;, &#34;count/min&#34;),
 *                                 jsonProperty(&#34;valueName&#34;, &#34;hr&#34;),
 *                                 jsonProperty(&#34;valueType&#34;, &#34;SampledData&#34;)
 *                             ))
 *                         ))
 *                     )))
 *                 )))
 *             .build());
 * 
 *     }
 * }
 * ```
 * 
 * ## Import
 * 
 * Healthcare Med Tech Service Fhir Destination can be imported using the resource`id`, e.g.
 * 
 * ```sh
 *  $ pulumi import azure:healthcare/medtechServiceFhirDestination:MedtechServiceFhirDestination example /subscriptions/12345678-1234-9876-4563-123456789012/resourceGroups/group1/providers/Microsoft.HealthcareApis/workspaces/workspace1/iotConnectors/iotconnector1/fhirDestinations/destination1
 * ```
 * 
 */
@ResourceType(type="azure:healthcare/medtechServiceFhirDestination:MedtechServiceFhirDestination")
public class MedtechServiceFhirDestination extends com.pulumi.resources.CustomResource {
    /**
     * Specifies the destination Fhir mappings of the Med Tech Service Fhir Destination.
     * 
     */
    @Export(name="destinationFhirMappingJson", refs={String.class}, tree="[0]")
    private Output<String> destinationFhirMappingJson;

    /**
     * @return Specifies the destination Fhir mappings of the Med Tech Service Fhir Destination.
     * 
     */
    public Output<String> destinationFhirMappingJson() {
        return this.destinationFhirMappingJson;
    }
    /**
     * Specifies the destination fhir service id of the Med Tech Service Fhir Destination.
     * 
     */
    @Export(name="destinationFhirServiceId", refs={String.class}, tree="[0]")
    private Output<String> destinationFhirServiceId;

    /**
     * @return Specifies the destination fhir service id of the Med Tech Service Fhir Destination.
     * 
     */
    public Output<String> destinationFhirServiceId() {
        return this.destinationFhirServiceId;
    }
    /**
     * Specifies the destination identity resolution type where the Healthcare Med Tech Service Fhir Destination should be created. Possible values are `Create`, `Lookup`.
     * 
     */
    @Export(name="destinationIdentityResolutionType", refs={String.class}, tree="[0]")
    private Output<String> destinationIdentityResolutionType;

    /**
     * @return Specifies the destination identity resolution type where the Healthcare Med Tech Service Fhir Destination should be created. Possible values are `Create`, `Lookup`.
     * 
     */
    public Output<String> destinationIdentityResolutionType() {
        return this.destinationIdentityResolutionType;
    }
    /**
     * Specifies the Azure Region where the Healthcare Med Tech Service Fhir Destination should be created. Changing this forces a new Healthcare Med Tech Service Fhir Destination to be created.
     * 
     */
    @Export(name="location", refs={String.class}, tree="[0]")
    private Output<String> location;

    /**
     * @return Specifies the Azure Region where the Healthcare Med Tech Service Fhir Destination should be created. Changing this forces a new Healthcare Med Tech Service Fhir Destination to be created.
     * 
     */
    public Output<String> location() {
        return this.location;
    }
    /**
     * Specifies the name of the Healthcare Med Tech Service where the Healthcare Med Tech Service Fhir Destination should exist. Changing this forces a new Healthcare Med Tech Service Fhir Destination to be created.
     * 
     */
    @Export(name="medtechServiceId", refs={String.class}, tree="[0]")
    private Output<String> medtechServiceId;

    /**
     * @return Specifies the name of the Healthcare Med Tech Service where the Healthcare Med Tech Service Fhir Destination should exist. Changing this forces a new Healthcare Med Tech Service Fhir Destination to be created.
     * 
     */
    public Output<String> medtechServiceId() {
        return this.medtechServiceId;
    }
    /**
     * Specifies the name of the Healthcare Med Tech Service Fhir Destination. Changing this forces a new Healthcare Med Tech Service Fhir Destination to be created.
     * 
     */
    @Export(name="name", refs={String.class}, tree="[0]")
    private Output<String> name;

    /**
     * @return Specifies the name of the Healthcare Med Tech Service Fhir Destination. Changing this forces a new Healthcare Med Tech Service Fhir Destination to be created.
     * 
     */
    public Output<String> name() {
        return this.name;
    }

    /**
     *
     * @param name The _unique_ name of the resulting resource.
     */
    public MedtechServiceFhirDestination(String name) {
        this(name, MedtechServiceFhirDestinationArgs.Empty);
    }
    /**
     *
     * @param name The _unique_ name of the resulting resource.
     * @param args The arguments to use to populate this resource's properties.
     */
    public MedtechServiceFhirDestination(String name, MedtechServiceFhirDestinationArgs args) {
        this(name, args, null);
    }
    /**
     *
     * @param name The _unique_ name of the resulting resource.
     * @param args The arguments to use to populate this resource's properties.
     * @param options A bag of options that control this resource's behavior.
     */
    public MedtechServiceFhirDestination(String name, MedtechServiceFhirDestinationArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) {
        super("azure:healthcare/medtechServiceFhirDestination:MedtechServiceFhirDestination", name, args == null ? MedtechServiceFhirDestinationArgs.Empty : args, makeResourceOptions(options, Codegen.empty()));
    }

    private MedtechServiceFhirDestination(String name, Output<String> id, @Nullable MedtechServiceFhirDestinationState state, @Nullable com.pulumi.resources.CustomResourceOptions options) {
        super("azure:healthcare/medtechServiceFhirDestination:MedtechServiceFhirDestination", name, state, makeResourceOptions(options, id));
    }

    private static com.pulumi.resources.CustomResourceOptions makeResourceOptions(@Nullable com.pulumi.resources.CustomResourceOptions options, @Nullable Output<String> id) {
        var defaultOptions = com.pulumi.resources.CustomResourceOptions.builder()
            .version(Utilities.getVersion())
            .build();
        return com.pulumi.resources.CustomResourceOptions.merge(defaultOptions, options, id);
    }

    /**
     * Get an existing Host resource's state with the given name, ID, and optional extra
     * properties used to qualify the lookup.
     *
     * @param name The _unique_ name of the resulting resource.
     * @param id The _unique_ provider ID of the resource to lookup.
     * @param state
     * @param options Optional settings to control the behavior of the CustomResource.
     */
    public static MedtechServiceFhirDestination get(String name, Output<String> id, @Nullable MedtechServiceFhirDestinationState state, @Nullable com.pulumi.resources.CustomResourceOptions options) {
        return new MedtechServiceFhirDestination(name, id, state, options);
    }
}
