##
#    This code was generated by
#    ___ _ _ _ _ _    _ ____    ____ ____ _    ____ ____ _  _ ____ ____ ____ ___ __   __
#     |  | | | | |    | |  | __ |  | |__| | __ | __ |___ |\ | |___ |__/ |__|  | |  | |__/
#     |  |_|_| | |___ | |__|    |__| |  | |    |__] |___ | \| |___ |  \ |  |  | |__| |  \
#
#    Twilio - Insights
#    This is the public Twilio REST API.
#
#    NOTE: This class is auto generated by OpenAPI Generator.
#    https://openapi-generator.tech
#    Do not edit the class manually.
#

module Twilio
    module REST
        class Insights
            class V1 < Version
                ##
                # Initialize the V1 version of Insights
                def initialize(domain)
                    super
                    @version = 'v1'
                    @calls = nil
                    @call_summaries = nil
                    @conferences = nil
                    @rooms = nil
                    @settings = nil
                end

                ##
                # @param [String] sid 
                # @return [Twilio::REST::Insights::V1::CallContext] if sid was passed.
                # @return [Twilio::REST::Insights::V1::CallList]
                def calls(sid=:unset)
                    if sid.nil?
                        raise ArgumentError, 'sid cannot be nil'
                    end
                    if sid == :unset
                        @calls ||= CallList.new self
                    else
                        CallContext.new(self, sid)
                    end
                end
                ##
                # @return [Twilio::REST::Insights::V1::CallSummariesList]
                def call_summaries
                    @call_summaries ||= CallSummariesList.new self
                end
                ##
                # @param [String] conference_sid The unique SID identifier of the Conference.
                # @return [Twilio::REST::Insights::V1::ConferenceContext] if conferenceSid was passed.
                # @return [Twilio::REST::Insights::V1::ConferenceList]
                def conferences(conference_sid=:unset)
                    if conference_sid.nil?
                        raise ArgumentError, 'conference_sid cannot be nil'
                    end
                    if conference_sid == :unset
                        @conferences ||= ConferenceList.new self
                    else
                        ConferenceContext.new(self, conference_sid)
                    end
                end
                ##
                # @param [String] room_sid The SID of the Room resource.
                # @return [Twilio::REST::Insights::V1::RoomContext] if roomSid was passed.
                # @return [Twilio::REST::Insights::V1::RoomList]
                def rooms(room_sid=:unset)
                    if room_sid.nil?
                        raise ArgumentError, 'room_sid cannot be nil'
                    end
                    if room_sid == :unset
                        @rooms ||= RoomList.new self
                    else
                        RoomContext.new(self, room_sid)
                    end
                end
                ##
                # @return [Twilio::REST::Insights::V1::settingsContext]
                def settings
                    @settings ||= SettingContext.new self
                end
                ##
                # Provide a user friendly representation
                def to_s
                    '<Twilio::REST::Insights::V1>';
                end
            end
        end
    end
end
