Catmandu-Store-REST
view release on metacpan or search on metacpan
123456789101112{
"abstract"
:
"Store/retrieve items from a JSON REST-API endpoint"
,
"author"
: [
"Pieter De Praetere <pieter@packed.be>"
],
"dynamic_config"
: 0,
"generated_by"
:
"Dist::Milla version v1.0.17, Dist::Zilla version 6.009, CPAN::Meta::Converter version 2.150010"
,
"license"
: [
"perl_5"
],
"meta-spec"
: {
123456789101112---
abstract:
'Store/retrieve items from a JSON REST-API endpoint'
author:
-
'Pieter De Praetere <pieter@packed.be>'
build_requires:
Test::More:
'0.96'
configure_requires:
Module::Build::Tiny:
'0.034'
dynamic_config: 0
generated_by:
'Dist::Milla version v1.0.17, Dist::Zilla version 6.009, CPAN::Meta::Converter version 2.150010'
license: perl
meta-spec:
1234567891011121314NAME
Catmandu::Store::REST - Store/retrieve items from a JSON REST-API
endpoint
SYNOPSIS
# From the command line
$ catmandu export REST --id 1234 --base_url https://www.example.org/api/v1/books --query_string /page/1 to YAML
# From a Catmandu Fix
lookup_in_store(
book_id,
REST,
383940414243444546474849505152535455565758
and the API must
accept
JSON
for
PUT/POST requests. The URL must be of
the
format
[base_url]/[id][query_string], where the id is absent
for
POST requests.
PARAMETERS
You must provide the base_url parameter.
base_url
base url of the API endpoint (the entire url
before
the ID) (e.g.
query_string
an optional query string that comes behind the ID (e.g. /page/1 where
the complete URL is https://www.example.org/api/v1/books/1/page/1).
AUTHOR
Pieter De Praetere <pieter
@packed
.be>
lib/Catmandu/Store/REST.pm view on Meta::CPAN
131415161718192021222324252627282930313233has
query_string
=> (
is
=>
'ro'
,
default
=>
sub
{
return
''
; });
# TODO: support basic authentication
1;
__END__
=encoding utf-8
=head1 NAME
Catmandu::Store::REST - Store/retrieve items from a JSON REST-API endpoint
=head1 SYNOPSIS
# From the command line
$ catmandu export REST --id 1234 --base_url https://www.example.org/api/v1/books --query_string /page/1 to YAML
# From a Catmandu Fix
lookup_in_store(
book_id,
REST,
lib/Catmandu/Store/REST.pm view on Meta::CPAN
5657585960616263646566676869707172737475is absent
for
C<POST> requests.
=head1 PARAMETERS
You must provide the C<base_url> parameter.
=over
=item C<base_url>
base url of the API endpoint (the entire url before the ID) (e.g. I<https://www.example.org/api/v1/books>).
=item C<query_string>
an optional query string that comes behind the ID (e.g. I</page/1> where the complete URL is
=back
=head1 AUTHOR
( run in 1.836 second using v1.01-cache-2.11-cpan-26ccb49234f )