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

NAME

WebService::HashiCorp::Vault::Base - Perl API for HashiCorp's Vault (Base)

VERSION

version 0.002

SYNOPSIS

 package WebService::HashiCorp::Vault::Something;
 use Moo;
 extends 'WebService::HashiCorp::Vault::Base';

DESCRIPTION

Base class for everything in WebService::HashiCorp::Vault.

Builds on top of WebService::Client, adds a few things.

METHODS

base_url

 my $obj = WebService::HashiCorp::Vault::Something->new(
     base_url => 'https://127.0.0.1:8200'
 );

 my $base_url = $obj->base_url();

The base url of the Vault instance you are talking to. Is read-only once you have created the object.

token

 my $obj = WebService::HashiCorp::Vault::Something->new(
     token => 'xxxxxxxxxxxx'
 );

 my $token = $obj->token();

The authentication token, is read-only after object is created.

version

 my $obj = WebService::HashiCorp::Vault::Something->new(
   version => 'v1'
 );

 my $version = $obj->version();

Allows you to set the API version if it changes in the future. Default to 'v1' and you probably don't need to touch it.

Read-only one the object is created.

mount

 my $obj = WebService::HashiCorp::Vault::Something->new(
   mount => '/something'
 );

 my $version = $obj->mount();

The mount location of the resource. There is no default, but you should apply one in your class that builds upon this class.

list

 my $list = $obj->list('path');

HashiCorp have decided that 'LIST' is a http verb, so we must hack it in.

You can pretend this is now a normal part of WebService::Client upon which this module is based.

SEE ALSO

WebService::HashiCorp::Vault

AUTHOR

Dean Hamstead <dean@bytefoundry.com.au>

COPYRIGHT AND LICENSE

This software is copyright (c) 2017 by Dean Hamstad.

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