Class: NeverBounce::CLI::Script::JobsDownload
- Inherits:
-
RequestMaker
- Object
- Base
- Meaningful
- RequestMaker
- NeverBounce::CLI::Script::JobsDownload
- Defined in:
- lib/never_bounce/cli/script/jobs_download.rb
Constant Summary
Constants inherited from RequestMaker
Instance Attribute Summary collapse
- #manifest ⇒ Manifest
-
#request ⇒ Object
An
API::Request::JobsDownload
.
Attributes inherited from RequestMaker
#api_key, #api_url, #request_curl, #response, #server_raw, #session, #user_config
Attributes inherited from Meaningful
#banner_text, #envar_text, #help_text, #options_text
Attributes inherited from Base
Instance Method Summary collapse
Methods inherited from RequestMaker
#get_table_value, #inil, #print_curl_request, #print_error_response, #print_server_raw, #slim_main1
Methods inherited from Meaningful
#call_slim_main, error_klasses, format_envar_examples, #handle_help_and_options, #help?, #main, #option_parser, #options
Methods inherited from Base
#env_falsey?, #env_truthy?, env_value_truthy?, #main, #system, #verbose?
Instance Attribute Details
#manifest ⇒ Manifest
26 27 28 29 30 31 32 |
# File 'lib/never_bounce/cli/script/jobs_download.rb', line 26 def manifest @manifest ||= Manifest.new( name: "nb-jobs-download", function: "Download job results as CSV", cmdline: "[options] [VAR1=value] [VAR2=value] ...", ) end |
#request ⇒ Object
An API::Request::JobsDownload
.
15 16 17 18 19 20 |
# File 'lib/never_bounce/cli/script/jobs_download.rb', line 15 def request @request ||= API::Request::JobsDownload.new({ api_key: api_key, job_id: job_id, }) end |
Instance Method Details
#slim_main ⇒ Integer
37 38 39 40 41 42 |
# File 'lib/never_bounce/cli/script/jobs_download.rb', line 37 def slim_main # Print CSV as is. stdout.puts server_raw 0 end |