Module: ProxyFetcher::Client
- Defined in:
- lib/proxy_fetcher/client/client.rb,
lib/proxy_fetcher/client/request.rb,
lib/proxy_fetcher/client/proxies_registry.rb
Overview
ProxyFetcher HTTP client that encapsulates all the logic for sending HTTP(S) requests using proxies, automatically fetched and validated by the gem.
Defined Under Namespace
Classes: ProxiesRegistry, Request
Class Method Summary collapse
-
.delete(url, headers: {}, options: {}) ⇒ String
Sends HTTP DELETE request.
-
.get(url, headers: {}, options: {}) ⇒ String
Sends HTTP GET request.
-
.head(url, headers: {}, options: {}) ⇒ String
Sends HTTP HEAD request.
-
.patch(url, payload, headers: {}, options: {}) ⇒ String
Sends HTTP PATCH request.
-
.post(url, payload, headers: {}, options: {}) ⇒ String
Sends HTTP POST request.
-
.put(url, payload, headers: {}, options: {}) ⇒ String
Sends HTTP PUT request.
Class Method Details
.delete(url, headers: {}, options: {}) ⇒ String
Sends HTTP DELETE request.
79 80 81 |
# File 'lib/proxy_fetcher/client/client.rb', line 79 def delete(url, headers: {}, options: {}) request_without_payload(:delete, url, headers, ) end |
.get(url, headers: {}, options: {}) ⇒ String
Sends HTTP GET request.
22 23 24 |
# File 'lib/proxy_fetcher/client/client.rb', line 22 def get(url, headers: {}, options: {}) request_without_payload(:get, url, headers, ) end |
.head(url, headers: {}, options: {}) ⇒ String
Sends HTTP HEAD request.
40 41 42 |
# File 'lib/proxy_fetcher/client/client.rb', line 40 def head(url, headers: {}, options: {}) request_without_payload(:head, url, headers, ) end |
.patch(url, payload, headers: {}, options: {}) ⇒ String
Sends HTTP PATCH request.
121 122 123 |
# File 'lib/proxy_fetcher/client/client.rb', line 121 def patch(url, payload, headers: {}, options: {}) request_with_payload(:patch, url, payload, headers, ) end |
.post(url, payload, headers: {}, options: {}) ⇒ String
Sends HTTP POST request.
61 62 63 |
# File 'lib/proxy_fetcher/client/client.rb', line 61 def post(url, payload, headers: {}, options: {}) request_with_payload(:post, url, payload, headers, ) end |
.put(url, payload, headers: {}, options: {}) ⇒ String
Sends HTTP PUT request.
100 101 102 |
# File 'lib/proxy_fetcher/client/client.rb', line 100 def put(url, payload, headers: {}, options: {}) request_with_payload(:put, url, payload, headers, ) end |