ChannelArgs

data class ChannelArgs(val channelName: Output<String>? = null, val channelType: Output<Either<String, ChannelType>>? = null, val expirationTimeIfNotActivatedUtc: Output<String>? = null, val messageForActivation: Output<String>? = null, val partnerNamespaceName: Output<String>? = null, val partnerTopicInfo: Output<PartnerTopicInfoArgs>? = null, val provisioningState: Output<Either<String, ChannelProvisioningState>>? = null, val readinessState: Output<Either<String, ReadinessState>>? = null, val resourceGroupName: Output<String>? = null) : ConvertibleToJava<ChannelArgs>

Channel info. Uses Azure REST API version 2025-02-15. In version 2.x of the Azure Native provider, it used API version 2022-06-15. Other available API versions: 2022-06-15, 2023-06-01-preview, 2023-12-15-preview, 2024-06-01-preview, 2024-12-15-preview. These can be accessed by generating a local SDK package using the CLI command pulumi package add azure-native eventgrid [ApiVersion]. See the ../../../version-guide/#accessing-any-api-version-via-local-packages for details.

Example Usage

Channels_CreateOrUpdate

using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var channel = new AzureNative.EventGrid.Channel("channel", new()
{
ChannelName = "exampleChannelName1",
ChannelType = AzureNative.EventGrid.ChannelType.PartnerTopic,
ExpirationTimeIfNotActivatedUtc = "2021-10-21T22:50:25.410433Z",
MessageForActivation = "Example message to approver",
PartnerNamespaceName = "examplePartnerNamespaceName1",
PartnerTopicInfo = new AzureNative.EventGrid.Inputs.PartnerTopicInfoArgs
{
AzureSubscriptionId = "5b4b650e-28b9-4790-b3ab-ddbd88d727c4",
Name = "examplePartnerTopic1",
ResourceGroupName = "examplerg2",
Source = "ContosoCorp.Accounts.User1",
},
ResourceGroupName = "examplerg",
});
});
package main
import (
eventgrid "github.com/pulumi/pulumi-azure-native-sdk/eventgrid/v2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := eventgrid.NewChannel(ctx, "channel", &eventgrid.ChannelArgs{
ChannelName: pulumi.String("exampleChannelName1"),
ChannelType: pulumi.String(eventgrid.ChannelTypePartnerTopic),
ExpirationTimeIfNotActivatedUtc: pulumi.String("2021-10-21T22:50:25.410433Z"),
MessageForActivation: pulumi.String("Example message to approver"),
PartnerNamespaceName: pulumi.String("examplePartnerNamespaceName1"),
PartnerTopicInfo: &eventgrid.PartnerTopicInfoArgs{
AzureSubscriptionId: pulumi.String("5b4b650e-28b9-4790-b3ab-ddbd88d727c4"),
Name: pulumi.String("examplePartnerTopic1"),
ResourceGroupName: pulumi.String("examplerg2"),
Source: pulumi.String("ContosoCorp.Accounts.User1"),
},
ResourceGroupName: pulumi.String("examplerg"),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.eventgrid.Channel;
import com.pulumi.azurenative.eventgrid.ChannelArgs;
import com.pulumi.azurenative.eventgrid.inputs.PartnerTopicInfoArgs;
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 channel = new Channel("channel", ChannelArgs.builder()
.channelName("exampleChannelName1")
.channelType("PartnerTopic")
.expirationTimeIfNotActivatedUtc("2021-10-21T22:50:25.410433Z")
.messageForActivation("Example message to approver")
.partnerNamespaceName("examplePartnerNamespaceName1")
.partnerTopicInfo(PartnerTopicInfoArgs.builder()
.azureSubscriptionId("5b4b650e-28b9-4790-b3ab-ddbd88d727c4")
.name("examplePartnerTopic1")
.resourceGroupName("examplerg2")
.source("ContosoCorp.Accounts.User1")
.build())
.resourceGroupName("examplerg")
.build());
}
}

Import

An existing resource can be imported using its type token, name, and identifier, e.g.

$ pulumi import azure-native:eventgrid:Channel exampleChannelName1 /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/partnerNamespaces/{partnerNamespaceName}/channels/{channelName}

Constructors

Link copied to clipboard
constructor(channelName: Output<String>? = null, channelType: Output<Either<String, ChannelType>>? = null, expirationTimeIfNotActivatedUtc: Output<String>? = null, messageForActivation: Output<String>? = null, partnerNamespaceName: Output<String>? = null, partnerTopicInfo: Output<PartnerTopicInfoArgs>? = null, provisioningState: Output<Either<String, ChannelProvisioningState>>? = null, readinessState: Output<Either<String, ReadinessState>>? = null, resourceGroupName: Output<String>? = null)

Properties

Link copied to clipboard
val channelName: Output<String>? = null

Name of the channel.

Link copied to clipboard
val channelType: Output<Either<String, ChannelType>>? = null

The type of the event channel which represents the direction flow of events.

Link copied to clipboard

Expiration time of the channel. If this timer expires while the corresponding partner topic is never activated, the channel and corresponding partner topic are deleted.

Link copied to clipboard
val messageForActivation: Output<String>? = null

Context or helpful message that can be used during the approval process by the subscriber.

Link copied to clipboard
val partnerNamespaceName: Output<String>? = null

Name of the partner namespace.

Link copied to clipboard

This property should be populated when channelType is PartnerTopic and represents information about the partner topic resource corresponding to the channel.

Link copied to clipboard
val provisioningState: Output<Either<String, ChannelProvisioningState>>? = null

Provisioning state of the channel.

Link copied to clipboard
val readinessState: Output<Either<String, ReadinessState>>? = null

The readiness state of the corresponding partner topic.

Link copied to clipboard
val resourceGroupName: Output<String>? = null

The name of the resource group within the partners subscription.

Functions

Link copied to clipboard
open override fun toJava(): ChannelArgs