browserup_mitmproxy_client
BrowserupMitmProxy - the Ruby gem for the BrowserUp MitmProxy
This is the REST API for controlling the BrowserUp MitmProxy. The BrowserUp MitmProxy is a swiss army knife for automated testing that captures HTTP traffic in HAR files. It is also useful for Selenium/Cypress tests.
This SDK is automatically generated by the OpenAPI Generator project:
- API version: 1.0.0
- Package version: 1.1
- Build package: org.openapitools.codegen.languages.RubyClientCodegen
Installation
Build a gem
To build the Ruby code into a gem:
gem build browserup_mitmproxy_client.gemspec
Then either install the gem locally:
gem install ./browserup_mitmproxy_client-1.1.gem
(for development, run gem install --dev ./browserup_mitmproxy_client-1.1.gem
to install the development dependencies)
or publish the gem to a gem hosting service, e.g. RubyGems.
Finally add this to the Gemfile:
gem 'browserup_mitmproxy_client', '~> 1.1'
Install from Git
If the Ruby gem is hosted at a git repository: https://github.com/GIT_USER_ID/GIT_REPO_ID, then add the following in the Gemfile:
gem 'browserup_mitmproxy_client', :git => 'https://github.com/GIT_USER_ID/GIT_REPO_ID.git'
Include the Ruby code directly
Include the Ruby code directly using -I
as follows:
ruby -Ilib script.rb
Getting Started
Please follow the installation procedure and then run the following code:
# Load the gem
require 'browserup_mitmproxy_client'
api_instance = BrowserupMitmProxy::BrowserUpProxyApi.new
counter = BrowserupMitmProxy::Counter.new({value: 3.56, name: 'name_example'}) # Counter | Receives a new counter to add. The counter is stored, under the hood, in an array in the har under the _counters key
begin
api_instance.add_counter(counter)
rescue BrowserupMitmProxy::ApiError => e
puts "Exception when calling BrowserUpProxyApi->add_counter: #{e}"
end
Documentation for API Endpoints
All URIs are relative to http://localhost:8088
Class | Method | HTTP request | Description |
---|---|---|---|
BrowserupMitmProxy::BrowserUpProxyApi | add_counter | POST /har/counters | |
BrowserupMitmProxy::BrowserUpProxyApi | add_error | POST /har/errors | |
BrowserupMitmProxy::BrowserUpProxyApi | get_har_log | GET /har | |
BrowserupMitmProxy::BrowserUpProxyApi | healthcheck | GET /healthcheck | |
BrowserupMitmProxy::BrowserUpProxyApi | new_page | POST /har/page | |
BrowserupMitmProxy::BrowserUpProxyApi | reset_har_log | PUT /har | |
BrowserupMitmProxy::BrowserUpProxyApi | verify_not_present | POST /verify/not_present/name | |
BrowserupMitmProxy::BrowserUpProxyApi | verify_present | POST /verify/present/name | |
BrowserupMitmProxy::BrowserUpProxyApi | verify_size | POST /verify/size/size/name | |
BrowserupMitmProxy::BrowserUpProxyApi | verify_sla | POST /verify/sla/time/name |
Documentation for Models
- BrowserupMitmProxy::Counter
- BrowserupMitmProxy::Entry
- BrowserupMitmProxy::EntryRequest
- BrowserupMitmProxy::EntryRequestCookies
- BrowserupMitmProxy::EntryRequestQueryString
- BrowserupMitmProxy::EntryResponse
- BrowserupMitmProxy::EntryResponseContent
- BrowserupMitmProxy::EntryTimings
- BrowserupMitmProxy::Error
- BrowserupMitmProxy::Har
- BrowserupMitmProxy::HarLog
- BrowserupMitmProxy::HarLogCreator
- BrowserupMitmProxy::Header
- BrowserupMitmProxy::MatchCriteria
- BrowserupMitmProxy::NameValuePair
- BrowserupMitmProxy::Page
- BrowserupMitmProxy::PagePageTimings
- BrowserupMitmProxy::VerifyResult
- BrowserupMitmProxy::WebSocketMessage
Documentation for Authorization
All endpoints do not require authorization.