browsermob-rest 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: ac04266b4f1376dd35f3fbf8526e8fc2d7f21225
4
+ data.tar.gz: f70d6136d177da530991871ba2d72475f7d66f8b
5
+ SHA512:
6
+ metadata.gz: 8a2e042ebb5f9f8939e22cd24d064ab937c5314d4649b829f843101aadcfb974097478a4c02024957e387ab6782935c99c217b9e16ceb094228aa4e587693dfc
7
+ data.tar.gz: 616b983c2bc97f36c0b31418e67d673b88a3d2df1bc4567fd3de5b6b1a73b6c70b209490d739f7089c2666ab042c729a0d240a7c2a1b0b1741a08cd489a8e440
data/.gitignore ADDED
@@ -0,0 +1,9 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /Gemfile.lock
4
+ /_yardoc/
5
+ /coverage/
6
+ /doc/
7
+ /pkg/
8
+ /spec/reports/
9
+ /tmp/
data/.rspec ADDED
@@ -0,0 +1,2 @@
1
+ --format documentation
2
+ --color
data/.travis.yml ADDED
@@ -0,0 +1,5 @@
1
+ sudo: false
2
+ language: ruby
3
+ rvm:
4
+ - 2.3.0
5
+ before_install: gem install bundler -v 1.12.4
@@ -0,0 +1,49 @@
1
+ # Contributor Code of Conduct
2
+
3
+ As contributors and maintainers of this project, and in the interest of
4
+ fostering an open and welcoming community, we pledge to respect all people who
5
+ contribute through reporting issues, posting feature requests, updating
6
+ documentation, submitting pull requests or patches, and other activities.
7
+
8
+ We are committed to making participation in this project a harassment-free
9
+ experience for everyone, regardless of level of experience, gender, gender
10
+ identity and expression, sexual orientation, disability, personal appearance,
11
+ body size, race, ethnicity, age, religion, or nationality.
12
+
13
+ Examples of unacceptable behavior by participants include:
14
+
15
+ * The use of sexualized language or imagery
16
+ * Personal attacks
17
+ * Trolling or insulting/derogatory comments
18
+ * Public or private harassment
19
+ * Publishing other's private information, such as physical or electronic
20
+ addresses, without explicit permission
21
+ * Other unethical or unprofessional conduct
22
+
23
+ Project maintainers have the right and responsibility to remove, edit, or
24
+ reject comments, commits, code, wiki edits, issues, and other contributions
25
+ that are not aligned to this Code of Conduct, or to ban temporarily or
26
+ permanently any contributor for other behaviors that they deem inappropriate,
27
+ threatening, offensive, or harmful.
28
+
29
+ By adopting this Code of Conduct, project maintainers commit themselves to
30
+ fairly and consistently applying these principles to every aspect of managing
31
+ this project. Project maintainers who do not follow or enforce the Code of
32
+ Conduct may be permanently removed from the project team.
33
+
34
+ This code of conduct applies both within project spaces and in public spaces
35
+ when an individual is representing the project or its community.
36
+
37
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be
38
+ reported by contacting a project maintainer at TODO: Write your email address. All
39
+ complaints will be reviewed and investigated and will result in a response that
40
+ is deemed necessary and appropriate to the circumstances. Maintainers are
41
+ obligated to maintain confidentiality with regard to the reporter of an
42
+ incident.
43
+
44
+ This Code of Conduct is adapted from the [Contributor Covenant][homepage],
45
+ version 1.3.0, available at
46
+ [http://contributor-covenant.org/version/1/3/0/][version]
47
+
48
+ [homepage]: http://contributor-covenant.org
49
+ [version]: http://contributor-covenant.org/version/1/3/0/
data/Gemfile ADDED
@@ -0,0 +1,8 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in browsermob-rest.gemspec
4
+ gemspec
5
+
6
+ gem 'rspec'
7
+ gem 'simplecov'
8
+ gem "rest-client"
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2016 TODO: Write your name
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,39 @@
1
+ # Browsermob::Rest
2
+
3
+ [![Build Status](https://travis-ci.org/thamilton2014/browsermob-rest.svg?branch=master)](https://travis-ci.org/thamilton2014/browsermob-rest)
4
+
5
+ ## Installation
6
+
7
+ Add this line to your application's Gemfile:
8
+
9
+ ```ruby
10
+ gem 'browsermob-rest'
11
+ ```
12
+
13
+ And then execute:
14
+
15
+ $ bundle
16
+
17
+ Or install it yourself as:
18
+
19
+ $ gem install browsermob-rest
20
+
21
+ ## Usage
22
+
23
+ TODO: Write usage instructions here
24
+
25
+ ## Development
26
+
27
+ After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
28
+
29
+ To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
30
+
31
+ ## Contributing
32
+
33
+ Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/browsermob-rest. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.
34
+
35
+
36
+ ## License
37
+
38
+ The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
39
+
data/Rakefile ADDED
@@ -0,0 +1,6 @@
1
+ require "bundler/gem_tasks"
2
+ require "rspec/core/rake_task"
3
+
4
+ RSpec::Core::RakeTask.new(:spec)
5
+
6
+ task :default => :spec
data/bin/console ADDED
@@ -0,0 +1,14 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require "bundler/setup"
4
+ require "browsermob/rest"
5
+
6
+ # You can add fixtures and/or initialization code here to make experimenting
7
+ # with your gem easier. You can also use a different console, if you like.
8
+
9
+ # (If you use this, don't forget to add pry to your Gemfile!)
10
+ # require "pry"
11
+ # Pry.start
12
+
13
+ require "irb"
14
+ IRB.start
data/bin/setup ADDED
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+ set -vx
5
+
6
+ bundle install
7
+
8
+ # Do any other automated setup that you need to do here
@@ -0,0 +1,32 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'browsermob/rest/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "browsermob-rest"
8
+ spec.version = Browsermob::Rest::VERSION
9
+ spec.authors = ["THamilton2014@gmail.com"]
10
+ spec.email = ["THamilton2014@gmail.com"]
11
+
12
+ spec.summary = %q{Browsermob Rest Client}
13
+ spec.homepage = "https://github.com/thamilton2014/browsermob-rest"
14
+ spec.license = "MIT"
15
+
16
+ # Prevent pushing this gem to RubyGems.org. To allow pushes either set the 'allowed_push_host'
17
+ # to allow pushing to a single host or delete this section to allow pushing to any host.
18
+ if spec.respond_to?(:metadata)
19
+ spec.metadata['allowed_push_host'] = "https://rubygems.org"
20
+ else
21
+ raise "RubyGems 2.0 or newer is required to protect against public gem pushes."
22
+ end
23
+
24
+ spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
25
+ spec.bindir = "exe"
26
+ spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
27
+ spec.require_paths = ["lib"]
28
+
29
+ spec.add_development_dependency "bundler", "~> 1.12"
30
+ spec.add_development_dependency "rake", "~> 10.0"
31
+ spec.add_development_dependency "rspec", "~> 3.0"
32
+ end
@@ -0,0 +1,103 @@
1
+ #
2
+ # api.rb
3
+ # Browsermob
4
+ #
5
+ module Browsermob
6
+ module Rest
7
+ class Api
8
+
9
+ def initialize
10
+
11
+ end
12
+
13
+ def get_proxies
14
+ Services::ProxyService.get_proxies()
15
+ end
16
+
17
+ def remove_proxy(port)
18
+ Services::ProxyService.remove_proxy(port)
19
+ end
20
+
21
+ def update_proxy_har(port, data)
22
+ Services::HarService.update_proxy_har(port, data)
23
+ end
24
+
25
+ def update_proxy_har_pageref(port, data)
26
+ Services::HarService.update_proxy_har_pageref(port, data)
27
+ end
28
+
29
+ def get_proxy_har(port)
30
+ Services::HarService.get_proxy_har(port)
31
+ end
32
+
33
+ def get_proxy_whitelist(port)
34
+ Services::WhitelistService.get_proxy_whitelist(port)
35
+ end
36
+
37
+ def update_proxy_whitelist(port, data)
38
+ Services::WhitelistService.update_proxy_whitelist(port, data)
39
+ end
40
+
41
+ def remove_proxy_whitelist(port)
42
+ Services::WhitelistService::remove_proxy_whitelist(port)
43
+ end
44
+
45
+ def get_proxy_blacklist(port)
46
+ Services::BlacklistService.get_proxy_blacklist(port)
47
+ end
48
+
49
+ def update_proxy_blacklist(port, data)
50
+ Services::BlacklistService.update_proxy_blacklist(port, data)
51
+ end
52
+
53
+ def remove_proxy_blacklist(port)
54
+ Services::BlacklistService.remove_proxy_blacklist(port)
55
+ end
56
+
57
+ def update_proxy_limit(port, data)
58
+ Services::ProxyService.update_proxy_limit(port, data)
59
+ end
60
+
61
+ def get_proxy_limit(port)
62
+ Services::ProxyService.get_proxy_limit(port)
63
+ end
64
+
65
+ def add_proxy_headers(port, data)
66
+ Services::ProxyService.add_proxy_headers(port, data)
67
+ end
68
+
69
+ def add_proxy_hosts(port, data)
70
+ Services::ProxyService.add_proxy_hosts(port, data)
71
+ end
72
+
73
+ def add_proxy_authentication(port, domain, data)
74
+ Services::ProxyService.add_proxy_authentication(port, domain, data)
75
+ end
76
+
77
+ def update_proxy_wait(port, data)
78
+ Services::ProxyService.update_proxy_wait(port, data)
79
+ end
80
+
81
+ def update_proxy_timeout(port, data)
82
+ Services::ProxyService.update_proxy_timeout(port, data)
83
+ end
84
+
85
+ def update_proxy_redirect(port, data)
86
+ Services::ProxyService.update_proxy_redirect(port, data)
87
+ end
88
+
89
+ def remove_proxy_redirect(port)
90
+ Services::ProxyService.remove_proxy_redirect(port)
91
+ end
92
+
93
+ def add_proxy_retry_count(port, data)
94
+ Services::ProxyService::add_proxy_retry_count(port, data)
95
+ end
96
+
97
+ def remove_proxy_dns_cache(port)
98
+ Services::ProxyService.remove_proxy_dns_cache(port)
99
+ end
100
+
101
+ end
102
+ end
103
+ end
@@ -0,0 +1,52 @@
1
+ #
2
+ # base_service.rb
3
+ #
4
+ module Browsermob
5
+ module Rest
6
+ module Services
7
+ class BaseService
8
+ class << self
9
+
10
+ protected
11
+
12
+ # Return required headers for making an http request
13
+ # @param [String] content_type - The MIME type of the body of the request, default is 'application/json'
14
+ # @return [Hash] - authorization headers
15
+ def get_headers(content_type = 'application/json')
16
+ {
17
+ :content_type => content_type,
18
+ :accept => 'application/json',
19
+ # :Authorization => "Basic #{BaseService.api_key}"
20
+ }
21
+ end
22
+
23
+ def base_url
24
+ Util::Config.get("endpoints.base_url")
25
+ end
26
+
27
+ def add_request(endpoint, data)
28
+ url = base_url() + endpoint
29
+ RestClient.post(url, data, get_headers())
30
+ end
31
+
32
+ def remove_request(endpoint)
33
+ url = base_url() + endpoint
34
+ RestClient.delete(url, get_headers())
35
+ end
36
+
37
+ def update_request(endpoint, data)
38
+ url = base_url() + endpoint
39
+ RestClient.put(url, data, get_headers())
40
+ end
41
+
42
+ def get_request(endpoint)
43
+ url = base_url() + endpoint
44
+ RestClient.get(url, get_headers())
45
+ end
46
+
47
+
48
+ end # =>
49
+ end # =>
50
+ end # =>
51
+ end # =>
52
+ end # =>
@@ -0,0 +1,29 @@
1
+ #
2
+ # blacklist_service.rb
3
+ #
4
+ module Browsermob
5
+ module Rest
6
+ module Services
7
+ class BlacklistService < BaseService
8
+ class << self
9
+
10
+ def get_proxy_blacklist(port)
11
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_BLACKLIST, port)
12
+ get_request(url)
13
+ end
14
+
15
+ def update_proxy_blacklist(port, list)
16
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_BLACKLIST, port)
17
+ update_request(url, list)
18
+ end
19
+
20
+ def remove_proxy_blacklist(port)
21
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_BLACKLIST, port)
22
+ remove_request(url)
23
+ end
24
+
25
+ end # =>
26
+ end # =>
27
+ end # =>
28
+ end # =>
29
+ end # =>
@@ -0,0 +1,29 @@
1
+ #
2
+ # har_service.rb
3
+ #
4
+ module Browsermob
5
+ module Rest
6
+ module Services
7
+ class HarService < BaseService
8
+ class << self
9
+
10
+ def get_proxy_har(port)
11
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_HAR, port)
12
+ response = get_request(url)
13
+ end
14
+
15
+ def update_proxy_har(port, data)
16
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_HAR, port)
17
+ response = update_request(url, data)
18
+ end
19
+
20
+ def update_proxy_har_pageref(port, data)
21
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_HAR_PAGEREF, port)
22
+ response = update_request(url, data)
23
+ end
24
+
25
+ end # =>
26
+ end # =>
27
+ end # =>
28
+ end # =>
29
+ end # =>
@@ -0,0 +1,79 @@
1
+ #
2
+ # proxy_service.rb
3
+ #
4
+ module Browsermob
5
+ module Rest
6
+ module Services
7
+ class ProxyService < BaseService
8
+ class << self
9
+
10
+ def get_proxies
11
+ url = base_url + Util::Endpoints::PROXY
12
+ get_request(url)
13
+ end
14
+
15
+ def remove_proxy(port)
16
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT, port)
17
+ remove_request(url)
18
+ end
19
+
20
+ def update_proxy_limit(port, data)
21
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_LIMIT, port)
22
+ update_request(url, data)
23
+ end
24
+
25
+ def get_proxy_limit(port)
26
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_LIMIT, port)
27
+ get_request(url)
28
+ end
29
+
30
+ def add_proxy_headers(port, data)
31
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_HEADERS, port)
32
+ add_request(url, data)
33
+ end
34
+
35
+ def add_proxy_hosts(port, data)
36
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_HOSTS, port)
37
+ add_request(url, data)
38
+ end
39
+
40
+ def add_proxy_authentication(port, domain, data)
41
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_AUTH_BASIC, port, domain)
42
+ add_request(url, data)
43
+ end
44
+
45
+ def update_proxy_wait(port, data)
46
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_WAIT, port)
47
+ update_request(url, data)
48
+ end
49
+
50
+ def update_proxy_timeout(port, data)
51
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_TIMEOUT, port)
52
+ update_request(url, data)
53
+ end
54
+
55
+ def update_proxy_redirect(port, data)
56
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_REWRITE, port)
57
+ update_request(url, data)
58
+ end
59
+
60
+ def remove_proxy_redirect(port)
61
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_REWRITE, port)
62
+ remove_request(url)
63
+ end
64
+
65
+ def add_proxy_retry_count(port, data)
66
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_RETRY, port)
67
+ add_request(url, data)
68
+ end
69
+
70
+ def remove_proxy_dns_cache(port)
71
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_DNS_CACHE, port)
72
+ remove_request(url)
73
+ end
74
+
75
+ end # =>
76
+ end # =>
77
+ end # =>
78
+ end # =>
79
+ end # =>
@@ -0,0 +1,29 @@
1
+ #
2
+ # whitelist_service.rb
3
+ #
4
+ module Browsermob
5
+ module Rest
6
+ module Services
7
+ class WhitelistService < BaseService
8
+ class << self
9
+
10
+ def get_proxy_whitelist(port)
11
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_WHITELIST, port)
12
+ get_request(url)
13
+ end
14
+
15
+ def update_proxy_whitelist(port, data)
16
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_WHITELIST, port)
17
+ update_request(url, data)
18
+ end
19
+
20
+ def remove_proxy_whitelist(port)
21
+ url = base_url + sprintf(Util::Endpoints::PROXY_PORT_WHITELIST, port)
22
+ remove_request(url)
23
+ end
24
+
25
+ end # =>
26
+ end # =>
27
+ end # =>
28
+ end # =>
29
+ end # =>
@@ -0,0 +1,72 @@
1
+ #
2
+ # config.rb
3
+ #
4
+ module Browsermob
5
+ module Rest
6
+ module Util
7
+ class Config
8
+ # Return a hash of configuration strings
9
+ # @return [Hash] - hash of configuration properties
10
+ @props = {
11
+ # REST endpoints
12
+ :endpoints => {
13
+ :base_url => '',
14
+ },
15
+
16
+ # OAuth2 Authorization related configuration options
17
+ :auth => {
18
+ :base_url => '',
19
+ :response_type_code => '',
20
+ :response_type_token => '',
21
+ :authorization_code_grant_type => '',
22
+ :authorization_endpoint => '',
23
+ :token_endpoint => '',
24
+ :token_info => '',
25
+ :api_key => '',
26
+ :api_secret => '',
27
+ :redirect_uri => ''
28
+ },
29
+
30
+ # Errors to be returned for various exceptions
31
+ :errors => {
32
+ :api_key_missing => 'api_key required either explicitly or in configuration.',
33
+ :access_token_missing => 'access_token required explicitly.',
34
+ :id_or_object => 'Only an id or %s object are allowed for this method.',
35
+ :invalid_webhook => 'Invalid Webhook. The x-ctct-hmac-sha256 does not correspond to message encryption.',
36
+ :api_secret_missing => 'The api_secret is missing in explicit call or configuration.'
37
+ }
38
+ }
39
+
40
+ class << self
41
+ attr_accessor :props
42
+
43
+ def configure
44
+ yield props if block_given?
45
+ end
46
+
47
+ # Get a configuration property given a specified location, example usage: Config::get('auth.token_endpoint')
48
+ # @param [String] index - location of the property to obtain
49
+ # @return [String]
50
+ def get(index)
51
+ properties = index.split('.')
52
+ get_value(properties, props)
53
+ end
54
+
55
+ private
56
+
57
+ # Navigate through a config array looking for a particular index
58
+ # @param [Array] index The index sequence we are navigating down
59
+ # @param [Hash, String] value The portion of the config array to process
60
+ # @return [String]
61
+ def get_value(index, value)
62
+ index = index.is_a?(Array) ? index : [index]
63
+ key = index.shift.to_sym
64
+ value.is_a?(Hash) and value[key] and value[key].is_a?(Hash) ?
65
+ get_value(index, value[key]) :
66
+ value[key]
67
+ end
68
+ end
69
+ end
70
+ end
71
+ end
72
+ end
@@ -0,0 +1,29 @@
1
+ #
2
+
3
+ # endpoints.rb
4
+ #
5
+ module Browsermob
6
+ module Rest
7
+ module Util
8
+ class Endpoints
9
+
10
+ PROXY = "proxy/"
11
+ PROXY_PORT = "proxy/%s/"
12
+ PROXY_PORT_HAR = "proxy/%s/har/"
13
+ PROXY_PORT_HAR_PAGEREF = "proxy/%s/har/pageRef/"
14
+ PROXY_PORT_WHITELIST = "proxy/%s/whitelist/"
15
+ PROXY_PORT_BLACKLIST = "proxy/%s/blacklist/"
16
+ PROXY_PORT_LIMIT = "proxy/%s/limit/"
17
+ PROXY_PORT_HEADERS = "proxy/%s/headers/"
18
+ PROXY_PORT_HOSTS = "proxy/%s/hosts/"
19
+ PROXY_PORT_AUTH_BASIC = "proxy/%s/auth/basic/%s/"
20
+ PROXY_PORT_WAIT = "proxy/%s/wait/"
21
+ PROXY_PORT_TIMEOUT = "proxy/%s/timeout/"
22
+ PROXY_PORT_REWRITE = "proxy/%s/rewrite/"
23
+ PROXY_PORT_RETRY = "proxy/%s/retry/"
24
+ PROXY_PORT_DNS_CACHE = "proxy/%s/dns/cache/"
25
+
26
+ end # =>
27
+ end # =>
28
+ end # =>
29
+ end # =>
@@ -0,0 +1,5 @@
1
+ module Browsermob
2
+ module Rest
3
+ VERSION = "0.1.0"
4
+ end
5
+ end
@@ -0,0 +1,22 @@
1
+ require "browsermob/rest/version"
2
+ require "rest-client"
3
+ module Browsermob
4
+ module Rest
5
+
6
+ require_relative "rest/api"
7
+
8
+ module Services
9
+ require_relative "rest/services/base_service"
10
+ require_relative "rest/services/blacklist_service"
11
+ require_relative "rest/services/whitelist_service"
12
+ require_relative "rest/services/proxy_service"
13
+ require_relative "rest/services/har_service"
14
+ end
15
+
16
+ module Util
17
+ require_relative "rest/util/config"
18
+ require_relative "rest/util/endpoints"
19
+ end
20
+
21
+ end
22
+ end
metadata ADDED
@@ -0,0 +1,108 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: browsermob-rest
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - THamilton2014@gmail.com
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2016-05-21 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: bundler
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.12'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.12'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '10.0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '10.0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rspec
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '3.0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '3.0'
55
+ description:
56
+ email:
57
+ - THamilton2014@gmail.com
58
+ executables: []
59
+ extensions: []
60
+ extra_rdoc_files: []
61
+ files:
62
+ - ".gitignore"
63
+ - ".rspec"
64
+ - ".travis.yml"
65
+ - CODE_OF_CONDUCT.md
66
+ - Gemfile
67
+ - LICENSE.txt
68
+ - README.md
69
+ - Rakefile
70
+ - bin/console
71
+ - bin/setup
72
+ - browsermob-rest.gemspec
73
+ - lib/browsermob/rest.rb
74
+ - lib/browsermob/rest/api.rb
75
+ - lib/browsermob/rest/services/base_service.rb
76
+ - lib/browsermob/rest/services/blacklist_service.rb
77
+ - lib/browsermob/rest/services/har_service.rb
78
+ - lib/browsermob/rest/services/proxy_service.rb
79
+ - lib/browsermob/rest/services/whitelist_service.rb
80
+ - lib/browsermob/rest/util/config.rb
81
+ - lib/browsermob/rest/util/endpoints.rb
82
+ - lib/browsermob/rest/version.rb
83
+ homepage: https://github.com/thamilton2014/browsermob-rest
84
+ licenses:
85
+ - MIT
86
+ metadata:
87
+ allowed_push_host: https://rubygems.org
88
+ post_install_message:
89
+ rdoc_options: []
90
+ require_paths:
91
+ - lib
92
+ required_ruby_version: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - ">="
95
+ - !ruby/object:Gem::Version
96
+ version: '0'
97
+ required_rubygems_version: !ruby/object:Gem::Requirement
98
+ requirements:
99
+ - - ">="
100
+ - !ruby/object:Gem::Version
101
+ version: '0'
102
+ requirements: []
103
+ rubyforge_project:
104
+ rubygems_version: 2.2.2
105
+ signing_key:
106
+ specification_version: 4
107
+ summary: Browsermob Rest Client
108
+ test_files: []