ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud
ibm.getEnSubscriptionEmail
Explore with Pulumi AI
Provides a read-only data source for Email subscription. You can then reference the fields of the data source in other resources within the same configuration using interpolation syntax.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as ibm from "@pulumi/ibm";
const emailSubscription = ibm.getEnSubscriptionEmail({
instanceGuid: ibm_resource_instance.en_terraform_test_resource.guid,
subscriptionId: ibm_en_subscription_email.subscriptionemail.subscription_id,
});
import pulumi
import pulumi_ibm as ibm
email_subscription = ibm.get_en_subscription_email(instance_guid=ibm_resource_instance["en_terraform_test_resource"]["guid"],
subscription_id=ibm_en_subscription_email["subscriptionemail"]["subscription_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 {
_, err := ibm.LookupEnSubscriptionEmail(ctx, &ibm.LookupEnSubscriptionEmailArgs{
InstanceGuid: ibm_resource_instance.En_terraform_test_resource.Guid,
SubscriptionId: ibm_en_subscription_email.Subscriptionemail.Subscription_id,
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Ibm = Pulumi.Ibm;
return await Deployment.RunAsync(() =>
{
var emailSubscription = Ibm.GetEnSubscriptionEmail.Invoke(new()
{
InstanceGuid = ibm_resource_instance.En_terraform_test_resource.Guid,
SubscriptionId = ibm_en_subscription_email.Subscriptionemail.Subscription_id,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.ibm.IbmFunctions;
import com.pulumi.ibm.inputs.GetEnSubscriptionEmailArgs;
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 emailSubscription = IbmFunctions.getEnSubscriptionEmail(GetEnSubscriptionEmailArgs.builder()
.instanceGuid(ibm_resource_instance.en_terraform_test_resource().guid())
.subscriptionId(ibm_en_subscription_email.subscriptionemail().subscription_id())
.build());
}
}
variables:
emailSubscription:
fn::invoke:
function: ibm:getEnSubscriptionEmail
arguments:
instanceGuid: ${ibm_resource_instance.en_terraform_test_resource.guid}
subscriptionId: ${ibm_en_subscription_email.subscriptionemail.subscription_id}
Using getEnSubscriptionEmail
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 getEnSubscriptionEmail(args: GetEnSubscriptionEmailArgs, opts?: InvokeOptions): Promise<GetEnSubscriptionEmailResult>
function getEnSubscriptionEmailOutput(args: GetEnSubscriptionEmailOutputArgs, opts?: InvokeOptions): Output<GetEnSubscriptionEmailResult>
def get_en_subscription_email(id: Optional[str] = None,
instance_guid: Optional[str] = None,
subscription_id: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetEnSubscriptionEmailResult
def get_en_subscription_email_output(id: Optional[pulumi.Input[str]] = None,
instance_guid: Optional[pulumi.Input[str]] = None,
subscription_id: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetEnSubscriptionEmailResult]
func LookupEnSubscriptionEmail(ctx *Context, args *LookupEnSubscriptionEmailArgs, opts ...InvokeOption) (*LookupEnSubscriptionEmailResult, error)
func LookupEnSubscriptionEmailOutput(ctx *Context, args *LookupEnSubscriptionEmailOutputArgs, opts ...InvokeOption) LookupEnSubscriptionEmailResultOutput
> Note: This function is named LookupEnSubscriptionEmail
in the Go SDK.
public static class GetEnSubscriptionEmail
{
public static Task<GetEnSubscriptionEmailResult> InvokeAsync(GetEnSubscriptionEmailArgs args, InvokeOptions? opts = null)
public static Output<GetEnSubscriptionEmailResult> Invoke(GetEnSubscriptionEmailInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetEnSubscriptionEmailResult> getEnSubscriptionEmail(GetEnSubscriptionEmailArgs args, InvokeOptions options)
public static Output<GetEnSubscriptionEmailResult> getEnSubscriptionEmail(GetEnSubscriptionEmailArgs args, InvokeOptions options)
fn::invoke:
function: ibm:index/getEnSubscriptionEmail:getEnSubscriptionEmail
arguments:
# arguments dictionary
The following arguments are supported:
- Instance
Guid string - Unique identifier for IBM Cloud Event Notifications instance.
- Subscription
Id string - Unique identifier for Subscription.
- Id string
- The unique identifier of the email_subscription.
- Instance
Guid string - Unique identifier for IBM Cloud Event Notifications instance.
- Subscription
Id string - Unique identifier for Subscription.
- Id string
- The unique identifier of the email_subscription.
- instance
Guid String - Unique identifier for IBM Cloud Event Notifications instance.
- subscription
Id String - Unique identifier for Subscription.
- id String
- The unique identifier of the email_subscription.
- instance
Guid string - Unique identifier for IBM Cloud Event Notifications instance.
- subscription
Id string - Unique identifier for Subscription.
- id string
- The unique identifier of the email_subscription.
- instance_
guid str - Unique identifier for IBM Cloud Event Notifications instance.
- subscription_
id str - Unique identifier for Subscription.
- id str
- The unique identifier of the email_subscription.
- instance
Guid String - Unique identifier for IBM Cloud Event Notifications instance.
- subscription
Id String - Unique identifier for Subscription.
- id String
- The unique identifier of the email_subscription.
getEnSubscriptionEmail Result
The following output properties are available:
- Attributes
List<Get
En Subscription Email Attribute> - (Required, List)
- Description string
- (String) Subscription description.
- Destination
Id string - (String) The destination ID.
- Id string
- The unique identifier of the email_subscription.
- Instance
Guid string - Name string
- (String) Subscription name.
- Subscription
Id string - Topic
Id string - (String) Topic ID.
- Updated
At string - (String) Last updated time.
- Attributes
[]Get
En Subscription Email Attribute - (Required, List)
- Description string
- (String) Subscription description.
- Destination
Id string - (String) The destination ID.
- Id string
- The unique identifier of the email_subscription.
- Instance
Guid string - Name string
- (String) Subscription name.
- Subscription
Id string - Topic
Id string - (String) Topic ID.
- Updated
At string - (String) Last updated time.
- attributes
List<Get
En Subscription Email Attribute> - (Required, List)
- description String
- (String) Subscription description.
- destination
Id String - (String) The destination ID.
- id String
- The unique identifier of the email_subscription.
- instance
Guid String - name String
- (String) Subscription name.
- subscription
Id String - topic
Id String - (String) Topic ID.
- updated
At String - (String) Last updated time.
- attributes
Get
En Subscription Email Attribute[] - (Required, List)
- description string
- (String) Subscription description.
- destination
Id string - (String) The destination ID.
- id string
- The unique identifier of the email_subscription.
- instance
Guid string - name string
- (String) Subscription name.
- subscription
Id string - topic
Id string - (String) Topic ID.
- updated
At string - (String) Last updated time.
- attributes
Sequence[Get
En Subscription Email Attribute] - (Required, List)
- description str
- (String) Subscription description.
- destination_
id str - (String) The destination ID.
- id str
- The unique identifier of the email_subscription.
- instance_
guid str - name str
- (String) Subscription name.
- subscription_
id str - topic_
id str - (String) Topic ID.
- updated_
at str - (String) Last updated time.
- attributes List<Property Map>
- (Required, List)
- description String
- (String) Subscription description.
- destination
Id String - (String) The destination ID.
- id String
- The unique identifier of the email_subscription.
- instance
Guid String - name String
- (String) Subscription name.
- subscription
Id String - topic
Id String - (String) Topic ID.
- updated
At String - (String) Last updated time.
Supporting Types
GetEnSubscriptionEmailAttribute
- Add
Notification boolPayload - (Boolean) Whether to add the notification payload to the email.
- From
Name string - Inviteds
List<Get
En Subscription Email Attribute Invited> - (List) The Email address for invitation.
- Reply
To stringMail - (String) The email address to reply to.
- Reply
To stringName - (String) The Email User Name to reply to.
- Subscribeds
List<Get
En Subscription Email Attribute Subscribed> - Unsubscribeds
List<Get
En Subscription Email Attribute Unsubscribed> - (List) The Email address which has opted for unsusbscribtion from that topic.
- Add
Notification boolPayload - (Boolean) Whether to add the notification payload to the email.
- From
Name string - Inviteds
[]Get
En Subscription Email Attribute Invited - (List) The Email address for invitation.
- Reply
To stringMail - (String) The email address to reply to.
- Reply
To stringName - (String) The Email User Name to reply to.
- Subscribeds
[]Get
En Subscription Email Attribute Subscribed - Unsubscribeds
[]Get
En Subscription Email Attribute Unsubscribed - (List) The Email address which has opted for unsusbscribtion from that topic.
- add
Notification BooleanPayload - (Boolean) Whether to add the notification payload to the email.
- from
Name String - inviteds
List<Get
En Subscription Email Attribute Invited> - (List) The Email address for invitation.
- reply
To StringMail - (String) The email address to reply to.
- reply
To StringName - (String) The Email User Name to reply to.
- subscribeds
List<Get
En Subscription Email Attribute Subscribed> - unsubscribeds
List<Get
En Subscription Email Attribute Unsubscribed> - (List) The Email address which has opted for unsusbscribtion from that topic.
- add
Notification booleanPayload - (Boolean) Whether to add the notification payload to the email.
- from
Name string - inviteds
Get
En Subscription Email Attribute Invited[] - (List) The Email address for invitation.
- reply
To stringMail - (String) The email address to reply to.
- reply
To stringName - (String) The Email User Name to reply to.
- subscribeds
Get
En Subscription Email Attribute Subscribed[] - unsubscribeds
Get
En Subscription Email Attribute Unsubscribed[] - (List) The Email address which has opted for unsusbscribtion from that topic.
- add_
notification_ boolpayload - (Boolean) Whether to add the notification payload to the email.
- from_
name str - inviteds
Sequence[Get
En Subscription Email Attribute Invited] - (List) The Email address for invitation.
- reply_
to_ strmail - (String) The email address to reply to.
- reply_
to_ strname - (String) The Email User Name to reply to.
- subscribeds
Sequence[Get
En Subscription Email Attribute Subscribed] - unsubscribeds
Sequence[Get
En Subscription Email Attribute Unsubscribed] - (List) The Email address which has opted for unsusbscribtion from that topic.
- add
Notification BooleanPayload - (Boolean) Whether to add the notification payload to the email.
- from
Name String - inviteds List<Property Map>
- (List) The Email address for invitation.
- reply
To StringMail - (String) The email address to reply to.
- reply
To StringName - (String) The Email User Name to reply to.
- subscribeds List<Property Map>
- unsubscribeds List<Property Map>
- (List) The Email address which has opted for unsusbscribtion from that topic.
GetEnSubscriptionEmailAttributeInvited
- email str
- expires_
at str - updated_
at str - (String) Last updated time.
GetEnSubscriptionEmailAttributeSubscribed
- email str
- updated_
at str - (String) Last updated time.
GetEnSubscriptionEmailAttributeUnsubscribed
- email str
- updated_
at str - (String) Last updated time.
Package Details
- Repository
- ibm ibm-cloud/terraform-provider-ibm
- License
- Notes
- This Pulumi package is based on the
ibm
Terraform Provider.