aws.chime.SdkvoiceSipRule
Explore with Pulumi AI
A SIP rule associates your SIP media application with a phone number or a Request URI hostname. You can associate a SIP rule with more than one SIP media application. Each application then runs only that rule.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const example = new aws.chime.SdkvoiceSipRule("example", {
    name: "example-sip-rule",
    triggerType: "RequestUriHostname",
    triggerValue: example_voice_connector.outboundHostName,
    targetApplications: [{
        priority: 1,
        sipMediaApplicationId: example_sma.id,
        awsRegion: "us-east-1",
    }],
});
import pulumi
import pulumi_aws as aws
example = aws.chime.SdkvoiceSipRule("example",
    name="example-sip-rule",
    trigger_type="RequestUriHostname",
    trigger_value=example_voice_connector["outboundHostName"],
    target_applications=[{
        "priority": 1,
        "sip_media_application_id": example_sma["id"],
        "aws_region": "us-east-1",
    }])
package main
import (
	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/chime"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := chime.NewSdkvoiceSipRule(ctx, "example", &chime.SdkvoiceSipRuleArgs{
			Name:         pulumi.String("example-sip-rule"),
			TriggerType:  pulumi.String("RequestUriHostname"),
			TriggerValue: pulumi.Any(example_voice_connector.OutboundHostName),
			TargetApplications: chime.SdkvoiceSipRuleTargetApplicationArray{
				&chime.SdkvoiceSipRuleTargetApplicationArgs{
					Priority:              pulumi.Int(1),
					SipMediaApplicationId: pulumi.Any(example_sma.Id),
					AwsRegion:             pulumi.String("us-east-1"),
				},
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() => 
{
    var example = new Aws.Chime.SdkvoiceSipRule("example", new()
    {
        Name = "example-sip-rule",
        TriggerType = "RequestUriHostname",
        TriggerValue = example_voice_connector.OutboundHostName,
        TargetApplications = new[]
        {
            new Aws.Chime.Inputs.SdkvoiceSipRuleTargetApplicationArgs
            {
                Priority = 1,
                SipMediaApplicationId = example_sma.Id,
                AwsRegion = "us-east-1",
            },
        },
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.chime.SdkvoiceSipRule;
import com.pulumi.aws.chime.SdkvoiceSipRuleArgs;
import com.pulumi.aws.chime.inputs.SdkvoiceSipRuleTargetApplicationArgs;
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 example = new SdkvoiceSipRule("example", SdkvoiceSipRuleArgs.builder()
            .name("example-sip-rule")
            .triggerType("RequestUriHostname")
            .triggerValue(example_voice_connector.outboundHostName())
            .targetApplications(SdkvoiceSipRuleTargetApplicationArgs.builder()
                .priority(1)
                .sipMediaApplicationId(example_sma.id())
                .awsRegion("us-east-1")
                .build())
            .build());
    }
}
resources:
  example:
    type: aws:chime:SdkvoiceSipRule
    properties:
      name: example-sip-rule
      triggerType: RequestUriHostname
      triggerValue: ${["example-voice-connector"].outboundHostName}
      targetApplications:
        - priority: 1
          sipMediaApplicationId: ${["example-sma"].id}
          awsRegion: us-east-1
Create SdkvoiceSipRule Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new SdkvoiceSipRule(name: string, args: SdkvoiceSipRuleArgs, opts?: CustomResourceOptions);@overload
def SdkvoiceSipRule(resource_name: str,
                    args: SdkvoiceSipRuleArgs,
                    opts: Optional[ResourceOptions] = None)
@overload
def SdkvoiceSipRule(resource_name: str,
                    opts: Optional[ResourceOptions] = None,
                    target_applications: Optional[Sequence[SdkvoiceSipRuleTargetApplicationArgs]] = None,
                    trigger_type: Optional[str] = None,
                    trigger_value: Optional[str] = None,
                    disabled: Optional[bool] = None,
                    name: Optional[str] = None)func NewSdkvoiceSipRule(ctx *Context, name string, args SdkvoiceSipRuleArgs, opts ...ResourceOption) (*SdkvoiceSipRule, error)public SdkvoiceSipRule(string name, SdkvoiceSipRuleArgs args, CustomResourceOptions? opts = null)
public SdkvoiceSipRule(String name, SdkvoiceSipRuleArgs args)
public SdkvoiceSipRule(String name, SdkvoiceSipRuleArgs args, CustomResourceOptions options)
type: aws:chime:SdkvoiceSipRule
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args SdkvoiceSipRuleArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args SdkvoiceSipRuleArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args SdkvoiceSipRuleArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args SdkvoiceSipRuleArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args SdkvoiceSipRuleArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var sdkvoiceSipRuleResource = new Aws.Chime.SdkvoiceSipRule("sdkvoiceSipRuleResource", new()
{
    TargetApplications = new[]
    {
        new Aws.Chime.Inputs.SdkvoiceSipRuleTargetApplicationArgs
        {
            AwsRegion = "string",
            Priority = 0,
            SipMediaApplicationId = "string",
        },
    },
    TriggerType = "string",
    TriggerValue = "string",
    Disabled = false,
    Name = "string",
});
example, err := chime.NewSdkvoiceSipRule(ctx, "sdkvoiceSipRuleResource", &chime.SdkvoiceSipRuleArgs{
	TargetApplications: chime.SdkvoiceSipRuleTargetApplicationArray{
		&chime.SdkvoiceSipRuleTargetApplicationArgs{
			AwsRegion:             pulumi.String("string"),
			Priority:              pulumi.Int(0),
			SipMediaApplicationId: pulumi.String("string"),
		},
	},
	TriggerType:  pulumi.String("string"),
	TriggerValue: pulumi.String("string"),
	Disabled:     pulumi.Bool(false),
	Name:         pulumi.String("string"),
})
var sdkvoiceSipRuleResource = new SdkvoiceSipRule("sdkvoiceSipRuleResource", SdkvoiceSipRuleArgs.builder()
    .targetApplications(SdkvoiceSipRuleTargetApplicationArgs.builder()
        .awsRegion("string")
        .priority(0)
        .sipMediaApplicationId("string")
        .build())
    .triggerType("string")
    .triggerValue("string")
    .disabled(false)
    .name("string")
    .build());
sdkvoice_sip_rule_resource = aws.chime.SdkvoiceSipRule("sdkvoiceSipRuleResource",
    target_applications=[{
        "aws_region": "string",
        "priority": 0,
        "sip_media_application_id": "string",
    }],
    trigger_type="string",
    trigger_value="string",
    disabled=False,
    name="string")
const sdkvoiceSipRuleResource = new aws.chime.SdkvoiceSipRule("sdkvoiceSipRuleResource", {
    targetApplications: [{
        awsRegion: "string",
        priority: 0,
        sipMediaApplicationId: "string",
    }],
    triggerType: "string",
    triggerValue: "string",
    disabled: false,
    name: "string",
});
type: aws:chime:SdkvoiceSipRule
properties:
    disabled: false
    name: string
    targetApplications:
        - awsRegion: string
          priority: 0
          sipMediaApplicationId: string
    triggerType: string
    triggerValue: string
SdkvoiceSipRule Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The SdkvoiceSipRule resource accepts the following input properties:
- TargetApplications List<SdkvoiceSip Rule Target Application> 
- List of SIP media applications with priority and AWS Region. Only one SIP application per AWS Region can be used. See target_applications.
- TriggerType string
- The type of trigger assigned to the SIP rule in trigger_value. Valid values areRequestUriHostnameorToPhoneNumber.
- TriggerValue string
- If - trigger_typeis- RequestUriHostname, the value can be the outbound host name of an Amazon Chime Voice Connector. If- trigger_typeis- ToPhoneNumber, the value can be a customer-owned phone number in the E164 format. The Sip Media Application specified in the Sip Rule is triggered if the request URI in an incoming SIP request matches the- RequestUriHostname, or if the "To" header in the incoming SIP request matches the- ToPhoneNumbervalue.- The following arguments are optional: 
- Disabled bool
- Enables or disables a rule. You must disable rules before you can delete them.
- Name string
- The name of the SIP rule.
- TargetApplications []SdkvoiceSip Rule Target Application Args 
- List of SIP media applications with priority and AWS Region. Only one SIP application per AWS Region can be used. See target_applications.
- TriggerType string
- The type of trigger assigned to the SIP rule in trigger_value. Valid values areRequestUriHostnameorToPhoneNumber.
- TriggerValue string
- If - trigger_typeis- RequestUriHostname, the value can be the outbound host name of an Amazon Chime Voice Connector. If- trigger_typeis- ToPhoneNumber, the value can be a customer-owned phone number in the E164 format. The Sip Media Application specified in the Sip Rule is triggered if the request URI in an incoming SIP request matches the- RequestUriHostname, or if the "To" header in the incoming SIP request matches the- ToPhoneNumbervalue.- The following arguments are optional: 
- Disabled bool
- Enables or disables a rule. You must disable rules before you can delete them.
- Name string
- The name of the SIP rule.
- targetApplications List<SdkvoiceSip Rule Target Application> 
- List of SIP media applications with priority and AWS Region. Only one SIP application per AWS Region can be used. See target_applications.
- triggerType String
- The type of trigger assigned to the SIP rule in trigger_value. Valid values areRequestUriHostnameorToPhoneNumber.
- triggerValue String
- If - trigger_typeis- RequestUriHostname, the value can be the outbound host name of an Amazon Chime Voice Connector. If- trigger_typeis- ToPhoneNumber, the value can be a customer-owned phone number in the E164 format. The Sip Media Application specified in the Sip Rule is triggered if the request URI in an incoming SIP request matches the- RequestUriHostname, or if the "To" header in the incoming SIP request matches the- ToPhoneNumbervalue.- The following arguments are optional: 
- disabled Boolean
- Enables or disables a rule. You must disable rules before you can delete them.
- name String
- The name of the SIP rule.
- targetApplications SdkvoiceSip Rule Target Application[] 
- List of SIP media applications with priority and AWS Region. Only one SIP application per AWS Region can be used. See target_applications.
- triggerType string
- The type of trigger assigned to the SIP rule in trigger_value. Valid values areRequestUriHostnameorToPhoneNumber.
- triggerValue string
- If - trigger_typeis- RequestUriHostname, the value can be the outbound host name of an Amazon Chime Voice Connector. If- trigger_typeis- ToPhoneNumber, the value can be a customer-owned phone number in the E164 format. The Sip Media Application specified in the Sip Rule is triggered if the request URI in an incoming SIP request matches the- RequestUriHostname, or if the "To" header in the incoming SIP request matches the- ToPhoneNumbervalue.- The following arguments are optional: 
- disabled boolean
- Enables or disables a rule. You must disable rules before you can delete them.
- name string
- The name of the SIP rule.
- target_applications Sequence[SdkvoiceSip Rule Target Application Args] 
- List of SIP media applications with priority and AWS Region. Only one SIP application per AWS Region can be used. See target_applications.
- trigger_type str
- The type of trigger assigned to the SIP rule in trigger_value. Valid values areRequestUriHostnameorToPhoneNumber.
- trigger_value str
- If - trigger_typeis- RequestUriHostname, the value can be the outbound host name of an Amazon Chime Voice Connector. If- trigger_typeis- ToPhoneNumber, the value can be a customer-owned phone number in the E164 format. The Sip Media Application specified in the Sip Rule is triggered if the request URI in an incoming SIP request matches the- RequestUriHostname, or if the "To" header in the incoming SIP request matches the- ToPhoneNumbervalue.- The following arguments are optional: 
- disabled bool
- Enables or disables a rule. You must disable rules before you can delete them.
- name str
- The name of the SIP rule.
- targetApplications List<Property Map>
- List of SIP media applications with priority and AWS Region. Only one SIP application per AWS Region can be used. See target_applications.
- triggerType String
- The type of trigger assigned to the SIP rule in trigger_value. Valid values areRequestUriHostnameorToPhoneNumber.
- triggerValue String
- If - trigger_typeis- RequestUriHostname, the value can be the outbound host name of an Amazon Chime Voice Connector. If- trigger_typeis- ToPhoneNumber, the value can be a customer-owned phone number in the E164 format. The Sip Media Application specified in the Sip Rule is triggered if the request URI in an incoming SIP request matches the- RequestUriHostname, or if the "To" header in the incoming SIP request matches the- ToPhoneNumbervalue.- The following arguments are optional: 
- disabled Boolean
- Enables or disables a rule. You must disable rules before you can delete them.
- name String
- The name of the SIP rule.
Outputs
All input properties are implicitly available as output properties. Additionally, the SdkvoiceSipRule resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing SdkvoiceSipRule Resource
Get an existing SdkvoiceSipRule resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: SdkvoiceSipRuleState, opts?: CustomResourceOptions): SdkvoiceSipRule@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        disabled: Optional[bool] = None,
        name: Optional[str] = None,
        target_applications: Optional[Sequence[SdkvoiceSipRuleTargetApplicationArgs]] = None,
        trigger_type: Optional[str] = None,
        trigger_value: Optional[str] = None) -> SdkvoiceSipRulefunc GetSdkvoiceSipRule(ctx *Context, name string, id IDInput, state *SdkvoiceSipRuleState, opts ...ResourceOption) (*SdkvoiceSipRule, error)public static SdkvoiceSipRule Get(string name, Input<string> id, SdkvoiceSipRuleState? state, CustomResourceOptions? opts = null)public static SdkvoiceSipRule get(String name, Output<String> id, SdkvoiceSipRuleState state, CustomResourceOptions options)resources:  _:    type: aws:chime:SdkvoiceSipRule    get:      id: ${id}- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Disabled bool
- Enables or disables a rule. You must disable rules before you can delete them.
- Name string
- The name of the SIP rule.
- TargetApplications List<SdkvoiceSip Rule Target Application> 
- List of SIP media applications with priority and AWS Region. Only one SIP application per AWS Region can be used. See target_applications.
- TriggerType string
- The type of trigger assigned to the SIP rule in trigger_value. Valid values areRequestUriHostnameorToPhoneNumber.
- TriggerValue string
- If - trigger_typeis- RequestUriHostname, the value can be the outbound host name of an Amazon Chime Voice Connector. If- trigger_typeis- ToPhoneNumber, the value can be a customer-owned phone number in the E164 format. The Sip Media Application specified in the Sip Rule is triggered if the request URI in an incoming SIP request matches the- RequestUriHostname, or if the "To" header in the incoming SIP request matches the- ToPhoneNumbervalue.- The following arguments are optional: 
- Disabled bool
- Enables or disables a rule. You must disable rules before you can delete them.
- Name string
- The name of the SIP rule.
- TargetApplications []SdkvoiceSip Rule Target Application Args 
- List of SIP media applications with priority and AWS Region. Only one SIP application per AWS Region can be used. See target_applications.
- TriggerType string
- The type of trigger assigned to the SIP rule in trigger_value. Valid values areRequestUriHostnameorToPhoneNumber.
- TriggerValue string
- If - trigger_typeis- RequestUriHostname, the value can be the outbound host name of an Amazon Chime Voice Connector. If- trigger_typeis- ToPhoneNumber, the value can be a customer-owned phone number in the E164 format. The Sip Media Application specified in the Sip Rule is triggered if the request URI in an incoming SIP request matches the- RequestUriHostname, or if the "To" header in the incoming SIP request matches the- ToPhoneNumbervalue.- The following arguments are optional: 
- disabled Boolean
- Enables or disables a rule. You must disable rules before you can delete them.
- name String
- The name of the SIP rule.
- targetApplications List<SdkvoiceSip Rule Target Application> 
- List of SIP media applications with priority and AWS Region. Only one SIP application per AWS Region can be used. See target_applications.
- triggerType String
- The type of trigger assigned to the SIP rule in trigger_value. Valid values areRequestUriHostnameorToPhoneNumber.
- triggerValue String
- If - trigger_typeis- RequestUriHostname, the value can be the outbound host name of an Amazon Chime Voice Connector. If- trigger_typeis- ToPhoneNumber, the value can be a customer-owned phone number in the E164 format. The Sip Media Application specified in the Sip Rule is triggered if the request URI in an incoming SIP request matches the- RequestUriHostname, or if the "To" header in the incoming SIP request matches the- ToPhoneNumbervalue.- The following arguments are optional: 
- disabled boolean
- Enables or disables a rule. You must disable rules before you can delete them.
- name string
- The name of the SIP rule.
- targetApplications SdkvoiceSip Rule Target Application[] 
- List of SIP media applications with priority and AWS Region. Only one SIP application per AWS Region can be used. See target_applications.
- triggerType string
- The type of trigger assigned to the SIP rule in trigger_value. Valid values areRequestUriHostnameorToPhoneNumber.
- triggerValue string
- If - trigger_typeis- RequestUriHostname, the value can be the outbound host name of an Amazon Chime Voice Connector. If- trigger_typeis- ToPhoneNumber, the value can be a customer-owned phone number in the E164 format. The Sip Media Application specified in the Sip Rule is triggered if the request URI in an incoming SIP request matches the- RequestUriHostname, or if the "To" header in the incoming SIP request matches the- ToPhoneNumbervalue.- The following arguments are optional: 
- disabled bool
- Enables or disables a rule. You must disable rules before you can delete them.
- name str
- The name of the SIP rule.
- target_applications Sequence[SdkvoiceSip Rule Target Application Args] 
- List of SIP media applications with priority and AWS Region. Only one SIP application per AWS Region can be used. See target_applications.
- trigger_type str
- The type of trigger assigned to the SIP rule in trigger_value. Valid values areRequestUriHostnameorToPhoneNumber.
- trigger_value str
- If - trigger_typeis- RequestUriHostname, the value can be the outbound host name of an Amazon Chime Voice Connector. If- trigger_typeis- ToPhoneNumber, the value can be a customer-owned phone number in the E164 format. The Sip Media Application specified in the Sip Rule is triggered if the request URI in an incoming SIP request matches the- RequestUriHostname, or if the "To" header in the incoming SIP request matches the- ToPhoneNumbervalue.- The following arguments are optional: 
- disabled Boolean
- Enables or disables a rule. You must disable rules before you can delete them.
- name String
- The name of the SIP rule.
- targetApplications List<Property Map>
- List of SIP media applications with priority and AWS Region. Only one SIP application per AWS Region can be used. See target_applications.
- triggerType String
- The type of trigger assigned to the SIP rule in trigger_value. Valid values areRequestUriHostnameorToPhoneNumber.
- triggerValue String
- If - trigger_typeis- RequestUriHostname, the value can be the outbound host name of an Amazon Chime Voice Connector. If- trigger_typeis- ToPhoneNumber, the value can be a customer-owned phone number in the E164 format. The Sip Media Application specified in the Sip Rule is triggered if the request URI in an incoming SIP request matches the- RequestUriHostname, or if the "To" header in the incoming SIP request matches the- ToPhoneNumbervalue.- The following arguments are optional: 
Supporting Types
SdkvoiceSipRuleTargetApplication, SdkvoiceSipRuleTargetApplicationArgs          
- AwsRegion string
- The AWS Region of the target application.
- Priority int
- Priority of the SIP media application in the target list.
- SipMedia stringApplication Id 
- The SIP media application ID.
- AwsRegion string
- The AWS Region of the target application.
- Priority int
- Priority of the SIP media application in the target list.
- SipMedia stringApplication Id 
- The SIP media application ID.
- awsRegion String
- The AWS Region of the target application.
- priority Integer
- Priority of the SIP media application in the target list.
- sipMedia StringApplication Id 
- The SIP media application ID.
- awsRegion string
- The AWS Region of the target application.
- priority number
- Priority of the SIP media application in the target list.
- sipMedia stringApplication Id 
- The SIP media application ID.
- aws_region str
- The AWS Region of the target application.
- priority int
- Priority of the SIP media application in the target list.
- sip_media_ strapplication_ id 
- The SIP media application ID.
- awsRegion String
- The AWS Region of the target application.
- priority Number
- Priority of the SIP media application in the target list.
- sipMedia StringApplication Id 
- The SIP media application ID.
Import
Using pulumi import, import a ChimeSDKVoice SIP Rule using the id. For example:
$ pulumi import aws:chime/sdkvoiceSipRule:SdkvoiceSipRule example abcdef123456
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- AWS Classic pulumi/pulumi-aws
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the awsTerraform Provider.