sub postSnippetsFile { my ( $self, %options ) = @_; my $headers = { "Content-type" => 'multipart/form-data', "Content" => [ file => [$options{file}]], "Authorization" => 'Basic '. encode_base64($options{username} . ':' . $options{password}), }; $self->{_client}->POST( $options{url}, encode_json({file => $options{file}}), $headers ); return $self->{_client}->responseContent(); }