BZ-Client

 view release on metacpan or  search on metacpan

lib/BZ/Client/Group.pm  view on Meta::CPAN

#!/bin/false
# PODNAME: BZ::Client::Group
# ABSTRACT: The API for creating, changing, and getting info on Groups

use strict;
use warnings 'all';

package BZ::Client::Group;
$BZ::Client::Group::VERSION = '4.4004';

use parent qw( BZ::Client::API );

# See https://www.bugzilla.org/docs/tip/en/html/api/Bugzilla/WebService/Group.html

## functions

sub create {
    my($class, $client, $params) = @_;
    return $class->_create($client, 'Group.create', $params);
}

sub update {
    my($class, $client, $params) = @_;
    return $class->_returns_array($client, 'Group.update', $params, 'groups');
}

sub get {
    my($class, $client, $params) = @_;
    my $result = $class->api_call($client, 'Group.get', $params);
    return wantarray ? %$result : $result
}

1;

__END__

=pod

=encoding UTF-8

=head1 NAME

BZ::Client::Group - The API for creating, changing, and getting info on Groups

=head1 VERSION

version 4.4004

=head1 SYNOPSIS

This class provides methods for accessing and managing Groups in Bugzilla.

 my $client = BZ::Client->new( url       => $url,
                               user      => $user,
                               password  => $password );

 my $id = BZ::Client::Group->create( $client, \%params );

=head1 CLASS METHODS

This section lists the class methods, which are available in this module.

=head2 create

 $id = BZ::Client::Group->create( $client, \%params );

This allows you to create a new Group in Bugzilla.

=head3 History

Marked as unstable as of Bugzilla 5.0.

=head3 Parameters

Some params must be set, or an error will be thrown. These params are noted as Required.

=over 4

=item name

I<name> (string) A short name for this group. Must be unique.



( run in 1.637 second using v1.01-cache-2.11-cpan-39bf76dae61 )