NAME
Regru::API::User - REG.API v2 user account management
VERSION
version 0.053
DESCRIPTION
REG.API account management methods such as create new user, fetch some statistics and deposit funds to an account.
ATTRIBUTES
namespace
Always returns the name of category: user
. For internal uses only.
REG.API METHODS
nop
For testing purposes. Scope: everyone. Typical usage:
$resp = $client->user->nop;
Returns success response.
More info at Account management: nop.
create
Creates a new user account. Scope: partners. Typical usage:
$resp = $client->user->create(
# required fields
user_login => 'digory',
user_password => 'gof4iSewvy8aK5at',
user_email => 'digory.kirke@wardrobe.co.uk',
user_country => 'GB',
# optional extra fields
...
set_me_as_referer => 1,
);
Answer will contains an user_id
field for newly created user account or error otherwise.
There are a lot of optional fields related to user account so check the documentation if you wish to use them. More info at Account management: create.
get_statistics
Fetch usage statistic for current account. Scope: clients. Typical usage:
$resp = $client->user->get_statistics(
date_from => '2013-01-01',
date_till => '2013-06-30',
);
Parameters date_from
and date_till
are optional. Answer will contains a set of metrics such as number of active domain names, number of domain names which are subject to renewal, number of folders, etc.
More info at Account management: get_statistics.
get_balance
Shows a current user account balance. Scope: clients. Typical usage:
$resp = $client->user->get_balance(
currency => 'EUR',
);
Answer will contains a set of fields like amount of available funds, amount of a blocked funds. For resellers (partners) will be shown amount of available credit additionally.
More info at Account management: get_balance.
SEE ALSO
BUGS
Please report any bugs or feature requests on the bugtracker website https://github.com/regru/regru-api-perl/issues
When submitting a bug or request, please include a test-file or a patch to an existing test-file that illustrates the bug or desired feature.
AUTHORS
Polina Shubina <shubina@reg.ru>
Anton Gerasimov <a.gerasimov@reg.ru>
COPYRIGHT AND LICENSE
This software is copyright (c) 2013 by REG.RU LLC.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.