The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Phone::Info - Fetches phone info.

VERSION

Version 0.0.1

SYNOPSIS

Quick summary of what the module does.

Perhaps a little code snippet.

    use Phone::Info;

    my $pi = Phone::Info->new();
    ...

METHODS

new

args hash

token

This is the API key to use. Get one at "http://www.whitepages.com/".

If this is not defined $ENV{WHITEPAGESTOKEN} is used.

find_person

For a deeper understanding of values, check the URL below.

http://developer.whitepages.com/docs/Methods/find_person

args hash

firstname

The first name to search for.

lastname

The last name to search for.

name

The name to search for.

house

The house number.

street

The street name to search.

city

The city to search.

state

The 2 letter state to search.

zip

The 5 or 9 digit zip code.

areacode

The phone area code to search.

metro

A boolean value determining if the search should be expanded to the metro areas.

    my $res=$pi->find_person(\%args);
    if($pi->{error}){
        print "Error!\n";
    }

resFormat

Create a string from the results.

args hash

res

This is the returned search data.

format

This is the format string for each item. See the format section for more information on this.

The header that will be attached at the top.

If this is not defined, it is created based on the format.

For no header, set this to ''.

This should also include a new line.

quote

If this is set to true, the fields will be quoted.

This defaults to true.

quotechar

This is the character that should be used for quoting.

The default is '"'.

    my $res=$pi->person(\%args);
    if($pi->{error}){
        print "Error!\n";
    }
    $pi->resFormat({
                    res=>$res,
                    format=>$format,
                    header=>$header,
                    seperator=>',',
                    quote=>1,
                    quotechar=>'"',
                    });
    if($pi->{error}){
        print "Error!\n";
    }

reverse_address

This finds related phone number based on their address.

See the link below for more information.

http://developer.whitepages.com/docs/Methods/reverse_address

args hash

apt

The apt to search for.

house

The house number searched to search for. This can be number take a range, "100-200".

city

The city to search.

state

The state to search.

zip

The sip code to search.

areacode

This is the area code to search.

    my $res=$pi->reverse_address(\%args);
    if($pi->{error}){
        print "Error!\n";
    }

reverse_phone

This finds related addresses based on a phone number.

See the link below for more information.

http://developer.whitepages.com/docs/Methods/reverse_phone

args hash

phone

This is the phone number to look up.

    my $res=$pi->reverse_phone(\%args);
    if($pi->{error}){
        print "Error!\n";
    }

errorblank

This blanks the error storage and is only meant for internal usage.

It does the following.

    $self->{error}=undef;
    $self->{errorString}="";

ERROR CODES

1

$args{token} is not defined and $ENV{WHITEPAGESTOKEN} is also not defined.

2

Failed to create the Net::WhitePages object.

3

find_person errored.

4

No search results passed.

5

No phone number specified.

FORMAT STRING

This is a comma seperated string comprised of various items listed below.

This string sould not include any spaces or etc.

firstname

The first name of the first person found listed for the number.

middlename

The middle name for the first person found listed for the number.

lastname

The last name for the first person found listed for the number.

phone

The phone number.

house

The house number for the address.

street

The street for the address.

city

The city the address is in.

state

The state the address is in.

zip

The zip code for the address.

AUTHOR

Zane C. Bowers, <vvelox at vvelox.net>

BUGS

Please report any bugs or feature requests to bug-phone-info at rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Phone-Info. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.

SUPPORT

You can find documentation for this module with the perldoc command.

    perldoc Phone::Info

You can also look for information at:

ACKNOWLEDGEMENTS

COPYRIGHT & LICENSE

Copyright 2009 Zane C. Bowers, all rights reserved.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.