API-BigBlueButton

 view release on metacpan or  search on metacpan

lib/API/BigBlueButton/Requests.pm  view on Meta::CPAN


use 5.008008;
use strict;
use warnings;

use Digest::SHA1 qw/ sha1_hex /;
use Carp qw/ confess /;

use constant {
    REQUIRE_CREATE_PARAMS => [ qw/ meetingID / ],
    REQUIRE_JOIN_PARAMS   => [ qw/ fullName meetingID password / ],
    REQUIRE_ISMEETINGRUNNING_PARAMS  => [ qw/ meetingID / ],
    REQUIRE_END_PARAMS    => [ qw/ meetingID password / ],
    REQUIRE_GETMEETINGINFO_PARAMS    => [ qw/ meetingID password / ],
    REQUIRE_PUBLISHRECORDINGS_PARAMS => [ qw/ recordID publish / ],
    REQUIRE_DELETERECORDINGS_PARAMS  => [ qw/ recordID / ],
    REQUIRE_SETCONFIGXML_PARAMS      => [ qw/ meetingID configXML / ],
};

our $VERSION = "0.015";

=head1 VERSION
 
version 0.015

lib/API/BigBlueButton/Requests.pm  view on Meta::CPAN

fullName

    This parameter is mandatory.
    The full name that is to be used to identify this user to other conference attendees.

meetingID

    This parameter is mandatory.
    The meeting ID that identifies the meeting you are attempting to join.

password

    This parameter is mandatory.
    The password that this attendee is using. If the moderator password is supplied,
    he will be given moderator status (and the same for attendee password, etc)

createTime

    This parameter is optional.

userID

    This parameter is optional.

webVoiceConf

lib/API/BigBlueButton/Requests.pm  view on Meta::CPAN


Use this to forcibly end a meeting and kick all participants out of the meeting.

%params:

meetingID

    This parameter is mandatory.
    The meeting ID that identifies the meeting you are attempting to end.

password

    This parameter is mandatory.
    The moderator password for this meeting. You can not end a meeting using the attendee password.

=cut

sub end {
    my ( $self, %params ) = @_;

    my $data = $self->_generate_data( 'end', \%params );
    return $self->abstract_request( $data );
}

lib/API/BigBlueButton/Requests.pm  view on Meta::CPAN

This call will return all of a meeting's information,
including the list of attendees as well as start and end times.

%params:

meetingID

    This parameter is mandatory.
    The meeting ID that identifies the meeting you are attempting to check on.

password

    This parameter is mandatory.
    The moderator password for this meeting.
    You can not get the meeting information using the attendee password.

=cut

sub getmeetinginfo {
    my ( $self, %params ) = @_;

    my $data = $self->_generate_data( 'getMeetingInfo', \%params );
    return $self->abstract_request( $data );
}

t/003_bigbluebutton_requests.t  view on Meta::CPAN

            ok( $@ );
            like( $@, qr/Parameter meetingID required!/ );
        };
    };

    describe "join" => sub {
        it "Normal run" => sub {
            ok( $bbb->join(
                fullName  => 'myname',
                meetingID => 'mymeeting',
                password  => 'mypass',
                )
            );
            like( $url, qr/join\?fullName=myname&meetingID=mymeeting&password=mypass/ );
        };
    };

    describe "ismeetingrunning" => sub {
        it "Normal run" => sub {
            ok( $bbb->ismeetingrunning( meetingID => 'mymeeting' ) );
            like( $url, qr/isMeetingRunning\?meetingID=mymeeting/ );
        };
    };

    describe "end" => sub {
        it "Normal run" => sub {
            ok( $bbb->end( meetingID => 'mymeeting', password  => 'mypass' ) );
            like( $url, qr/end\?meetingID=mymeeting&password=mypass/ );
        }
    };

    describe "getmeetinginfo" => sub {
        it "Normal run" => sub {
            ok( $bbb->getmeetinginfo( meetingID => 'mymeeting', password  => 'mypass' ) );
            like( $url, qr/getMeetingInfo\?meetingID=mymeeting&password=mypass/ );
        }
    };

    describe "getmeetings" => sub {
        it "Normal run" => sub {
            ok( $bbb->getmeetings );
            like( $url, qr/getMeetings/ );
        }
    };

    describe "getrecordings" => sub {
        it "Normal run" => sub {
            ok( $bbb->getrecordings( meetingID => 'mymeeting', password  => 'mypass' ) );
            like( $url, qr/getRecordings\?meetingID=mymeeting&password=mypass/ );
        }
    };
};

runtests unless caller;



( run in 1.246 second using v1.01-cache-2.11-cpan-49f99fa48dc )