1. Registry
  2. Packages
  3. Alibaba Cloud Provider
  4. API Docs
  5. sslcertificatesservice
  6. Contacts
Viewing docs for Alibaba Cloud v3.108.0
published on Thursday, Sep 17, 2026 by Pulumi
alicloud logo alicloud logo
Viewing docs for Alibaba Cloud v3.108.0
published on Thursday, Sep 17, 2026 by Pulumi
    Deprecated: alicloud.sslcertificatesservice/contacts.Contacts has been deprecated in favor of alicloud.sslcertificatesservice/getcontacts.getContacts

    This data source provides Ssl Certificates Service Contact available to the user.What is Contact

    NOTE: Available since v1.285.0.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as alicloud from "@pulumi/alicloud";
    
    const config = new pulumi.Config();
    const name = config.get("name") || "terraform-example";
    const defaultContact = new alicloud.sslcertificatesservice.Contact("default", {
        name: name,
        mobile: "13312345678",
        email: "test@example.com",
    });
    const _default = alicloud.sslcertificatesservice.getContactsOutput({
        ids: [defaultContact.id],
        name: name,
    });
    export const alicloudSslCertificatesServiceContactExampleId = _default.apply(_default => _default.contacts?.[0]?.id);
    
    import pulumi
    import pulumi_alicloud as alicloud
    
    config = pulumi.Config()
    name = config.get("name")
    if name is None:
        name = "terraform-example"
    default_contact = alicloud.sslcertificatesservice.Contact("default",
        name=name,
        mobile="13312345678",
        email="test@example.com")
    default = alicloud.sslcertificatesservice.get_contacts_output(ids=[default_contact.id],
        name=name)
    pulumi.export("alicloudSslCertificatesServiceContactExampleId", default.contacts[0].id)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/sslcertificatesservice"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		cfg := config.New(ctx, "")
    		name := "terraform-example"
    		if param := cfg.Get("name"); param != "" {
    			name = param
    		}
    		defaultContact, err := sslcertificatesservice.NewContact(ctx, "default", &sslcertificatesservice.ContactArgs{
    			Name:   pulumi.String(name),
    			Mobile: pulumi.String("13312345678"),
    			Email:  pulumi.String("test@example.com"),
    		})
    		if err != nil {
    			return err
    		}
    		_default := sslcertificatesservice.GetContactsOutput(ctx, sslcertificatesservice.GetContactsOutputArgs{
    			Ids: pulumi.StringArray{
    				defaultContact.ID().ToIDOutput().ToStringOutput(),
    			},
    			Name: pulumi.String(name),
    		}, nil)
    		ctx.Export("alicloudSslCertificatesServiceContactExampleId", _default.ApplyT(func(_default sslcertificatesservice.GetContactsResult) (*int, error) {
    			return _default.Contacts[0].Id, nil
    		}).(pulumi.IntPtrOutput))
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using AliCloud = Pulumi.AliCloud;
    
    return await Deployment.RunAsync(() => 
    {
        var config = new Config();
        var name = config.Get("name") ?? "terraform-example";
        var defaultContact = new AliCloud.SslCertificatesService.Contact("default", new()
        {
            Name = name,
            Mobile = "13312345678",
            Email = "test@example.com",
        });
    
        var @default = AliCloud.SslCertificatesService.GetContacts.Invoke(new()
        {
            Ids = new[]
            {
                defaultContact.Id,
            },
            Name = name,
        });
    
        return new Dictionary<string, object?>
        {
            ["alicloudSslCertificatesServiceContactExampleId"] = @default.Apply(@default => @default.Apply(getContactsResult => getContactsResult.Contacts[0]?.Id)),
        };
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.alicloud.sslcertificatesservice.Contact;
    import com.pulumi.alicloud.sslcertificatesservice.ContactArgs;
    import com.pulumi.alicloud.sslcertificatesservice.SslcertificatesserviceFunctions;
    import com.pulumi.alicloud.sslcertificatesservice.inputs.GetContactsArgs;
    import java.util.ArrayList;
    import java.util.Arrays;
    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 config = ctx.config();
            final var name = config.get("name").orElse("terraform-example");
            var defaultContact = new Contact("defaultContact", ContactArgs.builder()
                .name(name)
                .mobile("13312345678")
                .email("test@example.com")
                .build());
    
            final var default = SslcertificatesserviceFunctions.getContacts(GetContactsArgs.builder()
                .ids(defaultContact.id())
                .name(name)
                .build());
    
            ctx.export("alicloudSslCertificatesServiceContactExampleId", default_.applyValue(_default_ -> _default_.contacts()[0].id()));
        }
    }
    
    configuration:
      name:
        type: string
        default: terraform-example
    resources:
      defaultContact:
        type: alicloud:sslcertificatesservice:Contact
        name: default
        properties:
          name: ${name}
          mobile: '13312345678'
          email: test@example.com
    variables:
      default:
        fn::invoke:
          function: alicloud:sslcertificatesservice:getContacts
          arguments:
            ids:
              - ${defaultContact.id}
            name: ${name}
    outputs:
      alicloudSslCertificatesServiceContactExampleId: ${default.contacts[0].id}
    
    pulumi {
      required_providers {
        alicloud = {
          source = "pulumi/alicloud"
        }
      }
    }
    
    data "alicloud_sslcertificatesservice_getcontacts" "default" {
      ids  = [alicloud_sslcertificatesservice_contact.default.id]
      name = var.name
    }
    
    resource "alicloud_sslcertificatesservice_contact" "default" {
      name   = var.name
      mobile = "13312345678"
      email  = "test@example.com"
    }
    variable "name" {
      type    = string
      default = "terraform-example"
    }
    output "alicloudSslCertificatesServiceContactExampleId" {
      value = data.alicloud_sslcertificatesservice_getcontacts.default.contacts[0].id
    }
    

    Using Contacts

    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 contacts(args: ContactsArgs, opts?: InvokeOptions): Promise<ContactsResult>
    function contactsOutput(args: ContactsOutputArgs, opts?: InvokeOutputOptions): Output<ContactsResult>
    def contacts(enable_details: Optional[bool] = None,
                 ids: Optional[Sequence[str]] = None,
                 name: Optional[str] = None,
                 output_file: Optional[str] = None,
                 opts: Optional[InvokeOptions] = None) -> ContactsResult
    def contacts_output(enable_details: pulumi.Input[Optional[bool]] = None,
                 ids: pulumi.Input[Optional[Sequence[pulumi.Input[str]]]] = None,
                 name: pulumi.Input[Optional[str]] = None,
                 output_file: pulumi.Input[Optional[str]] = None,
                 opts: Optional[InvokeOutputOptions] = None) -> Output[ContactsResult]
    func Contacts(ctx *Context, args *ContactsArgs, opts ...InvokeOption) (*ContactsResult, error)
    func ContactsOutput(ctx *Context, args *ContactsOutputArgs, opts ...InvokeOption) ContactsResultOutput
    public static class Contacts 
    {
        public static Task<ContactsResult> InvokeAsync(ContactsArgs args, InvokeOptions? opts = null)
        public static Output<ContactsResult> Invoke(ContactsInvokeArgs args, InvokeOptions? opts = null)
        public static Output<ContactsResult> Invoke(ContactsInvokeArgs args, InvokeOutputOptions opts)
    }
    public static CompletableFuture<ContactsResult> contacts(ContactsArgs args, InvokeOptions options)
    public static Output<ContactsResult> contacts(ContactsArgs args, InvokeOptions options)
    public static Output<ContactsResult> contacts(ContactsArgs args, InvokeOutputOptions options)
    
    fn::invoke:
      function: alicloud:sslcertificatesservice:Contacts
      arguments:
        # arguments dictionary
    data "alicloud_sslcertificatesservice_contacts" "name" {
        # arguments
    }

    The following arguments are supported:

    EnableDetails bool
    Default to false. Set it to true can output more details about resource attributes.
    Ids List<string>
    A list of Contact IDs.
    Name string
    The name of the resource
    OutputFile string
    File name where to save data source results (after running pulumi preview).
    EnableDetails bool
    Default to false. Set it to true can output more details about resource attributes.
    Ids []string
    A list of Contact IDs.
    Name string
    The name of the resource
    OutputFile string
    File name where to save data source results (after running pulumi preview).
    enable_details bool
    Default to false. Set it to true can output more details about resource attributes.
    ids list(string)
    A list of Contact IDs.
    name string
    The name of the resource
    output_file string
    File name where to save data source results (after running pulumi preview).
    enableDetails Boolean
    Default to false. Set it to true can output more details about resource attributes.
    ids List<String>
    A list of Contact IDs.
    name String
    The name of the resource
    outputFile String
    File name where to save data source results (after running pulumi preview).
    enableDetails boolean
    Default to false. Set it to true can output more details about resource attributes.
    ids string[]
    A list of Contact IDs.
    name string
    The name of the resource
    outputFile string
    File name where to save data source results (after running pulumi preview).
    enable_details bool
    Default to false. Set it to true can output more details about resource attributes.
    ids Sequence[str]
    A list of Contact IDs.
    name str
    The name of the resource
    output_file str
    File name where to save data source results (after running pulumi preview).
    enableDetails Boolean
    Default to false. Set it to true can output more details about resource attributes.
    ids List<String>
    A list of Contact IDs.
    name String
    The name of the resource
    outputFile String
    File name where to save data source results (after running pulumi preview).

    Contacts Result

    The following output properties are available:

    Contacts List<Pulumi.AliCloud.sslCertificatesService.Outputs.ContactsContact>
    A list of Contact Entries. Each element contains the following attributes:
    Id string
    The provider-assigned unique ID for this managed resource.
    Ids List<string>
    A list of Contact IDs.
    EnableDetails bool
    Name string
    The name of the contact.
    OutputFile string
    Contacts []ContactsContact
    A list of Contact Entries. Each element contains the following attributes:
    Id string
    The provider-assigned unique ID for this managed resource.
    Ids []string
    A list of Contact IDs.
    EnableDetails bool
    Name string
    The name of the contact.
    OutputFile string
    contacts list(object)
    A list of Contact Entries. Each element contains the following attributes:
    id string
    The provider-assigned unique ID for this managed resource.
    ids list(string)
    A list of Contact IDs.
    enable_details bool
    name string
    The name of the contact.
    output_file string
    contacts List<ContactsContact>
    A list of Contact Entries. Each element contains the following attributes:
    id String
    The provider-assigned unique ID for this managed resource.
    ids List<String>
    A list of Contact IDs.
    enableDetails Boolean
    name String
    The name of the contact.
    outputFile String
    contacts ContactsContact[]
    A list of Contact Entries. Each element contains the following attributes:
    id string
    The provider-assigned unique ID for this managed resource.
    ids string[]
    A list of Contact IDs.
    enableDetails boolean
    name string
    The name of the contact.
    outputFile string
    contacts Sequence[ContactsContact]
    A list of Contact Entries. Each element contains the following attributes:
    id str
    The provider-assigned unique ID for this managed resource.
    ids Sequence[str]
    A list of Contact IDs.
    enable_details bool
    name str
    The name of the contact.
    output_file str
    contacts List<Property Map>
    A list of Contact Entries. Each element contains the following attributes:
    id String
    The provider-assigned unique ID for this managed resource.
    ids List<String>
    A list of Contact IDs.
    enableDetails Boolean
    name String
    The name of the contact.
    outputFile String

    Supporting Types

    ContactsContact

    ContactId int
    The first ID of the resource.
    Email string
    The email address of the contact. NOTE: This field is only available when enableDetails is true.
    Id int
    The ID of the resource supplied above.
    Mobile string
    The mobile phone number of the contact. NOTE: This field is only available when enableDetails is true.
    Name string
    The name of the resource
    Webhooks string
    The Webhook address used to receive notifications. NOTE: This field is only available when enableDetails is true.
    ContactId int
    The first ID of the resource.
    Email string
    The email address of the contact. NOTE: This field is only available when enableDetails is true.
    Id int
    The ID of the resource supplied above.
    Mobile string
    The mobile phone number of the contact. NOTE: This field is only available when enableDetails is true.
    Name string
    The name of the resource
    Webhooks string
    The Webhook address used to receive notifications. NOTE: This field is only available when enableDetails is true.
    contact_id number
    The first ID of the resource.
    email string
    The email address of the contact. NOTE: This field is only available when enableDetails is true.
    id number
    The ID of the resource supplied above.
    mobile string
    The mobile phone number of the contact. NOTE: This field is only available when enableDetails is true.
    name string
    The name of the resource
    webhooks string
    The Webhook address used to receive notifications. NOTE: This field is only available when enableDetails is true.
    contactId Integer
    The first ID of the resource.
    email String
    The email address of the contact. NOTE: This field is only available when enableDetails is true.
    id Integer
    The ID of the resource supplied above.
    mobile String
    The mobile phone number of the contact. NOTE: This field is only available when enableDetails is true.
    name String
    The name of the resource
    webhooks String
    The Webhook address used to receive notifications. NOTE: This field is only available when enableDetails is true.
    contactId number
    The first ID of the resource.
    email string
    The email address of the contact. NOTE: This field is only available when enableDetails is true.
    id number
    The ID of the resource supplied above.
    mobile string
    The mobile phone number of the contact. NOTE: This field is only available when enableDetails is true.
    name string
    The name of the resource
    webhooks string
    The Webhook address used to receive notifications. NOTE: This field is only available when enableDetails is true.
    contact_id int
    The first ID of the resource.
    email str
    The email address of the contact. NOTE: This field is only available when enableDetails is true.
    id int
    The ID of the resource supplied above.
    mobile str
    The mobile phone number of the contact. NOTE: This field is only available when enableDetails is true.
    name str
    The name of the resource
    webhooks str
    The Webhook address used to receive notifications. NOTE: This field is only available when enableDetails is true.
    contactId Number
    The first ID of the resource.
    email String
    The email address of the contact. NOTE: This field is only available when enableDetails is true.
    id Number
    The ID of the resource supplied above.
    mobile String
    The mobile phone number of the contact. NOTE: This field is only available when enableDetails is true.
    name String
    The name of the resource
    webhooks String
    The Webhook address used to receive notifications. NOTE: This field is only available when enableDetails is true.

    Package Details

    Repository
    Alibaba Cloud pulumi/pulumi-alicloud
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the alicloud Terraform Provider.
    alicloud logo alicloud logo
    Viewing docs for Alibaba Cloud v3.108.0
    published on Thursday, Sep 17, 2026 by Pulumi

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial