Class: Vapi::CompliancePlan
- Inherits:
-
Object
- Object
- Vapi::CompliancePlan
- Defined in:
- lib/vapi_server_sdk/types/compliance_plan.rb
Constant Summary collapse
- OMIT =
Object.new
Instance Attribute Summary collapse
-
#additional_properties ⇒ OpenStruct
readonly
Additional properties unmapped to the current class definition.
-
#hipaa_enabled ⇒ Boolean
readonly
When this is enabled, no logs, recordings, or transcriptions will be stored.
-
#pci_enabled ⇒ Boolean
readonly
When this is enabled, the user will be restricted to use PCI-compliant providers, and no logs or transcripts are stored.
Class Method Summary collapse
-
.from_json(json_object:) ⇒ Vapi::CompliancePlan
Deserialize a JSON object to an instance of CompliancePlan.
-
.validate_raw(obj:) ⇒ Void
Leveraged for Union-type generation, validate_raw attempts to parse the given hash and check each fields type against the current object’s property definitions.
Instance Method Summary collapse
- #initialize(hipaa_enabled: OMIT, pci_enabled: OMIT, additional_properties: nil) ⇒ Vapi::CompliancePlan constructor
-
#to_json(*_args) ⇒ String
Serialize an instance of CompliancePlan to a JSON object.
Constructor Details
#initialize(hipaa_enabled: OMIT, pci_enabled: OMIT, additional_properties: nil) ⇒ Vapi::CompliancePlan
34 35 36 37 38 39 40 41 |
# File 'lib/vapi_server_sdk/types/compliance_plan.rb', line 34 def initialize(hipaa_enabled: OMIT, pci_enabled: OMIT, additional_properties: nil) @hipaa_enabled = hipaa_enabled if hipaa_enabled != OMIT @pci_enabled = pci_enabled if pci_enabled != OMIT @additional_properties = additional_properties @_field_set = { "hipaaEnabled": hipaa_enabled, "pciEnabled": pci_enabled }.reject do |_k, v| v == OMIT end end |
Instance Attribute Details
#additional_properties ⇒ OpenStruct (readonly)
Returns Additional properties unmapped to the current class definition.
18 19 20 |
# File 'lib/vapi_server_sdk/types/compliance_plan.rb', line 18 def additional_properties @additional_properties end |
#hipaa_enabled ⇒ Boolean (readonly)
Returns When this is enabled, no logs, recordings, or transcriptions will be stored. At the end of the call, you will still receive an end-of-call-report message to store on your server. Defaults to false.
11 12 13 |
# File 'lib/vapi_server_sdk/types/compliance_plan.rb', line 11 def hipaa_enabled @hipaa_enabled end |
#pci_enabled ⇒ Boolean (readonly)
Returns When this is enabled, the user will be restricted to use PCI-compliant providers, and no logs or transcripts are stored. At the end of the call, you will receive an end-of-call-report message to store on your server. Defaults to false.
16 17 18 |
# File 'lib/vapi_server_sdk/types/compliance_plan.rb', line 16 def pci_enabled @pci_enabled end |
Class Method Details
.from_json(json_object:) ⇒ Vapi::CompliancePlan
Deserialize a JSON object to an instance of CompliancePlan
47 48 49 50 51 52 53 54 55 56 57 |
# File 'lib/vapi_server_sdk/types/compliance_plan.rb', line 47 def self.from_json(json_object:) struct = JSON.parse(json_object, object_class: OpenStruct) parsed_json = JSON.parse(json_object) hipaa_enabled = parsed_json["hipaaEnabled"] pci_enabled = parsed_json["pciEnabled"] new( hipaa_enabled: hipaa_enabled, pci_enabled: pci_enabled, additional_properties: struct ) end |
.validate_raw(obj:) ⇒ Void
Leveraged for Union-type generation, validate_raw attempts to parse the given
hash and check each fields type against the current object's property
definitions.
72 73 74 75 |
# File 'lib/vapi_server_sdk/types/compliance_plan.rb', line 72 def self.validate_raw(obj:) obj.hipaa_enabled&.is_a?(Boolean) != false || raise("Passed value for field obj.hipaa_enabled is not the expected type, validation failed.") obj.pci_enabled&.is_a?(Boolean) != false || raise("Passed value for field obj.pci_enabled is not the expected type, validation failed.") end |
Instance Method Details
#to_json(*_args) ⇒ String
Serialize an instance of CompliancePlan to a JSON object
62 63 64 |
# File 'lib/vapi_server_sdk/types/compliance_plan.rb', line 62 def to_json(*_args) @_field_set&.to_json end |