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

NAME

WebService::Pingboard

DESCRIPTION

Interaction with Pingboard

This module uses MooseX::Log::Log4perl for logging - be sure to initialize!

ATTRIBUTES

cache

Optional.

Provided by MooseX::WithX - optionally pass a Cache::FileCache object to cache and avoid unnecessary requests

refresh_token
password
username
timeout

Timeout when communicating with Pingboard in seconds. Optional. Default: 10 Will only be in effect if you allow the useragent to be built in this module.

default_backoff

Optional. Default: 10 Time in seconds to back off before retrying request. If a 429 response is given and the Retry-Time header is provided by the api this will be overridden.

default_page_size

Optional. Default: 100

retry_on_status

Optional. Default: [ 429, 500, 502, 503, 504 ] Which http response codes should we retry on?

max_tries

Optional. Default: undef

Limit maximum number of times a query should be attempted before failing. If undefined then unlimited retries

api_url

Default: https://app.pingboard.com/api/v2/

user_agent

Optional. A new LWP::UserAgent will be created for you if you don't already have one you'd like to reuse.

loglevel

Optionally override the global loglevel for this module

METHODS

valid_access_token

Will return a valid access token.

access_token_is_valid

Returns true if a valid access token exists (with at least 5 seconds validity remaining).

headers

Returns a HTTP::Headers object with the Authorization header set with a valid access token

get_users
id

Optional. The user id to get

limit

Optional. Maximum number of entries to fetch.

page_size

Optional. Page size to use when fetching.

get_groups
id (optional)

The group id to get

limit

Optional. Maximum number of entries to fetch.

page_size

Optional. Page size to use when fetching.

get_custom_fields
id (optional)

The resource id to get

limit

Optional. Maximum number of entries to fetch.

page_size

Optional. Page size to use when fetching.

get_linked_accounts
id

The resource id to get

get_linked_account_providers
id (optional)

The resource id to get

limit

Optional. Maximum number of entries to fetch.

page_size

Optional. Page size to use when fetching.

get_statuses
id (optional)

The resource id to get

limit

Optional. Maximum number of entries to fetch.

page_size

Optional. Page size to use when fetching.

clear_cache_object_id

Clears an object from the cache.

object_id

Required. Object id to clear from the cache.

Returns whether cache_del was successful or not

COPYRIGHT

Copyright 2015, Robin Clarke

AUTHOR

Robin Clarke <robin@robinclarke.net>

Jeremy Falling <projects@falling.se>