amazonka-chime-2.0: Amazon Chime SDK.
Copyright(c) 2013-2023 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellSafe-Inferred
LanguageHaskell2010

Amazonka.Chime.CreateSipRule

Description

Creates a SIP rule which can be used to run a SIP media application as a target for a specific trigger type.

Synopsis

Creating a Request

data CreateSipRule Source #

See: newCreateSipRule smart constructor.

Constructors

CreateSipRule' 

Fields

  • disabled :: Maybe Bool

    Enables or disables a rule. You must disable rules before you can delete them.

  • name :: Text

    The name of the SIP rule.

  • triggerType :: SipRuleTriggerType

    The type of trigger assigned to the SIP rule in TriggerValue, currently RequestUriHostname or ToPhoneNumber.

  • triggerValue :: Text

    If TriggerType is RequestUriHostname, the value can be the outbound host name of an Amazon Chime Voice Connector. If TriggerType is ToPhoneNumber, the value can be a customer-owned phone number in the E164 format. The SipMediaApplication specified in the SipRule 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 ToPhoneNumber value.

  • targetApplications :: NonEmpty SipRuleTargetApplication

    List of SIP media applications with priority and AWS Region. Only one SIP application per AWS Region can be used.

Instances

Instances details
ToJSON CreateSipRule Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

ToHeaders CreateSipRule Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

ToPath CreateSipRule Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

ToQuery CreateSipRule Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

AWSRequest CreateSipRule Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

Associated Types

type AWSResponse CreateSipRule #

Generic CreateSipRule Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

Associated Types

type Rep CreateSipRule :: Type -> Type #

Read CreateSipRule Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

Show CreateSipRule Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

NFData CreateSipRule Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

Methods

rnf :: CreateSipRule -> () #

Eq CreateSipRule Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

Hashable CreateSipRule Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

type AWSResponse CreateSipRule Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

type Rep CreateSipRule Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

type Rep CreateSipRule = D1 ('MetaData "CreateSipRule" "Amazonka.Chime.CreateSipRule" "amazonka-chime-2.0-AQIuSSkHccQ9VXokPBc5Nb" 'False) (C1 ('MetaCons "CreateSipRule'" 'PrefixI 'True) ((S1 ('MetaSel ('Just "disabled") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Bool)) :*: S1 ('MetaSel ('Just "name") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text)) :*: (S1 ('MetaSel ('Just "triggerType") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 SipRuleTriggerType) :*: (S1 ('MetaSel ('Just "triggerValue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text) :*: S1 ('MetaSel ('Just "targetApplications") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (NonEmpty SipRuleTargetApplication))))))

newCreateSipRule Source #

Create a value of CreateSipRule with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

CreateSipRule, createSipRule_disabled - Enables or disables a rule. You must disable rules before you can delete them.

CreateSipRule, createSipRule_name - The name of the SIP rule.

CreateSipRule, createSipRule_triggerType - The type of trigger assigned to the SIP rule in TriggerValue, currently RequestUriHostname or ToPhoneNumber.

CreateSipRule, createSipRule_triggerValue - If TriggerType is RequestUriHostname, the value can be the outbound host name of an Amazon Chime Voice Connector. If TriggerType is ToPhoneNumber, the value can be a customer-owned phone number in the E164 format. The SipMediaApplication specified in the SipRule 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 ToPhoneNumber value.

CreateSipRule, createSipRule_targetApplications - List of SIP media applications with priority and AWS Region. Only one SIP application per AWS Region can be used.

Request Lenses

createSipRule_disabled :: Lens' CreateSipRule (Maybe Bool) Source #

Enables or disables a rule. You must disable rules before you can delete them.

createSipRule_name :: Lens' CreateSipRule Text Source #

The name of the SIP rule.

createSipRule_triggerType :: Lens' CreateSipRule SipRuleTriggerType Source #

The type of trigger assigned to the SIP rule in TriggerValue, currently RequestUriHostname or ToPhoneNumber.

createSipRule_triggerValue :: Lens' CreateSipRule Text Source #

If TriggerType is RequestUriHostname, the value can be the outbound host name of an Amazon Chime Voice Connector. If TriggerType is ToPhoneNumber, the value can be a customer-owned phone number in the E164 format. The SipMediaApplication specified in the SipRule 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 ToPhoneNumber value.

createSipRule_targetApplications :: Lens' CreateSipRule (NonEmpty SipRuleTargetApplication) Source #

List of SIP media applications with priority and AWS Region. Only one SIP application per AWS Region can be used.

Destructuring the Response

data CreateSipRuleResponse Source #

See: newCreateSipRuleResponse smart constructor.

Constructors

CreateSipRuleResponse' 

Fields

  • sipRule :: Maybe SipRule

    Returns the SIP rule information, including the rule ID, triggers, and target applications.

  • httpStatus :: Int

    The response's http status code.

Instances

Instances details
Generic CreateSipRuleResponse Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

Associated Types

type Rep CreateSipRuleResponse :: Type -> Type #

Read CreateSipRuleResponse Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

Show CreateSipRuleResponse Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

NFData CreateSipRuleResponse Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

Methods

rnf :: CreateSipRuleResponse -> () #

Eq CreateSipRuleResponse Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

type Rep CreateSipRuleResponse Source # 
Instance details

Defined in Amazonka.Chime.CreateSipRule

type Rep CreateSipRuleResponse = D1 ('MetaData "CreateSipRuleResponse" "Amazonka.Chime.CreateSipRule" "amazonka-chime-2.0-AQIuSSkHccQ9VXokPBc5Nb" 'False) (C1 ('MetaCons "CreateSipRuleResponse'" 'PrefixI 'True) (S1 ('MetaSel ('Just "sipRule") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe SipRule)) :*: S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int)))

newCreateSipRuleResponse Source #

Create a value of CreateSipRuleResponse with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:sipRule:CreateSipRuleResponse', createSipRuleResponse_sipRule - Returns the SIP rule information, including the rule ID, triggers, and target applications.

$sel:httpStatus:CreateSipRuleResponse', createSipRuleResponse_httpStatus - The response's http status code.

Response Lenses

createSipRuleResponse_sipRule :: Lens' CreateSipRuleResponse (Maybe SipRule) Source #

Returns the SIP rule information, including the rule ID, triggers, and target applications.