Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jpducassou/perl-webservice-cdnetworks-purge
WebService::CDNetworks::Purge - A client for the CDNetworks's Cache Flush Open API
https://github.com/jpducassou/perl-webservice-cdnetworks-purge
cache cache-service cpan perl perl5
Last synced: 6 days ago
JSON representation
WebService::CDNetworks::Purge - A client for the CDNetworks's Cache Flush Open API
- Host: GitHub
- URL: https://github.com/jpducassou/perl-webservice-cdnetworks-purge
- Owner: jpducassou
- Created: 2017-01-25T03:30:29.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2018-01-02T03:42:40.000Z (about 7 years ago)
- Last Synced: 2024-04-16T18:57:59.744Z (9 months ago)
- Topics: cache, cache-service, cpan, perl, perl5
- Language: Perl
- Homepage:
- Size: 32.2 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# NAME
WebService::CDNetworks::Purge - A client for the CDNetworks's Cache Flush Open API
# SYNOPSIS
my $service = WebService::CDNetworks::Purge -> new(
'username' => 'xxxxxxxx',
'password' => 'yyyyyyyy',
);$service -> location('Korea');
my $listOfPADs = $service -> listPADs();
my $purgeStatus = $service -> purgeItems('test.example.com', ['/a.html', '/images/b.png']);
my $updatedStatus = $service -> status($purgeStatus -> [0] -> {'pid'});
# METHODS
## location
Description: Set the base URL attribute based on a location (US, Korea, etc)
Paramters: The location string
Returns: none## listPADs
Description: get the list of domains (or PADs) handled by user
Parameters: none
Returns: an array ref with the list of domains/PADs## purgeItems
Description: Purges for a certain PAD/domain a list of paths.
If the list is two long it is split and the service is called with each chunk of paths.
Parameters: PAD/domain and an arrayref with the list of paths to purge
Returns: An array ref with the list of responses for each pack of paths.## status
Description: Gets the current status of a certain purge request
Parameters: the purge request id
Returns: A hashref with the parsed JSON response from service# AUTHOR
Jean Pierre Ducassou
# LICENSE
This program is free software; you can redistribute it and/or modify it
under the terms of either: the GNU General Public License as published
by the Free Software Foundation; or the Artistic License.See http://dev.perl.org/licenses/ for more information.
# NO WARRANTY
This software is provided "as-is," without any express or implied warranty. In no event shall the author be held liable for any damages arising from the use of the software.