Class: SignalWire::REST::Namespaces::AutoMaterializedWebhook
- Inherits:
-
FabricResource
- Object
- BaseResource
- CrudResource
- FabricResource
- SignalWire::REST::Namespaces::AutoMaterializedWebhook
- Defined in:
- lib/signalwire/rest/namespaces/fabric.rb
Overview
Fabric webhook resource that’s normally auto-created by phone_numbers.set_*_webhook. Exposed for backwards compatibility.
The binding model for these resources is on the phone number (see phone_numbers.set_swml_webhook / set_cxml_webhook) – setting call_handler on a phone number auto-materializes the webhook Fabric resource. Calling create directly here produces an orphan resource that isn’t bound to any phone number.
Direct Known Subclasses
Constant Summary collapse
- AUTO_HELPER_NAME =
Subclasses override to advertise the correct helper in the warning.
'phone_numbers.set_*_webhook'
Instance Method Summary collapse
-
#create(**kwargs) ⇒ Object
deprecated
Deprecated.
Creating a webhook Fabric resource directly produces an orphan that isn’t bound to any phone number. Use the matching phone_numbers.set_*_webhook helper instead; it updates the phone number and the server auto-materializes the resource. See porting-sdk’s
phone-binding.md.
Methods inherited from FabricResource
Methods inherited from CrudResource
#delete, #get, #list, #update, update_method, update_method=
Methods inherited from BaseResource
Constructor Details
This class inherits a constructor from SignalWire::REST::BaseResource
Instance Method Details
#create(**kwargs) ⇒ Object
Creating a webhook Fabric resource directly produces an orphan that isn’t bound to any phone number. Use the matching phone_numbers.set_*_webhook helper instead; it updates the phone number and the server auto-materializes the resource. See porting-sdk’s phone-binding.md.
35 36 37 38 39 40 41 42 43 44 45 |
# File 'lib/signalwire/rest/namespaces/fabric.rb', line 35 def create(**kwargs) Kernel.warn( "DEPRECATION: creating a webhook Fabric resource directly produces " \ "an orphan not bound to any phone number. Use " \ "#{self.class::AUTO_HELPER_NAME} instead; it updates the phone " \ "number and the server auto-materializes the resource. " \ "See porting-sdk's phone-binding.md.", uplevel: 1 ) super end |