api_demo_v1 0.1.4 → 0.1.5

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 4fa9ab7f121ce4fea30e1cf209caffec5cdd66b33d361cd2f5283fdea4ced8f2
4
- data.tar.gz: 247a5e2380b1d0b0adf39ad074fb577f0cbb67162c7a16e51dfd24b4769381d3
3
+ metadata.gz: b1012927e2c1fad2f421b84571ffa8b33b85997062a907c6ae36a9f76c2d1c08
4
+ data.tar.gz: ce2191ff02621b2b3e1204e1212d0e4333cb84102e4929a57a31521c846fffb7
5
5
  SHA512:
6
- metadata.gz: 172352e913ad391adc72520541d503fd813c8f59f03fea9111f60dd820c51d6797234dc81238fbd141c8756cdd2c13c2f5359344ac0b2cf15c500f041d36fd76
7
- data.tar.gz: 7c006100c0facd123efd0b51c5ff9b8fe5a656775d827fce7920ec209e6fb9c27cfcda8b5f9025d5c99ef89a2400f7c23c081c80a9baa1894668267a68089f72
6
+ metadata.gz: 57a3c2bd5a9fffd6b1f303d3704f3dd899d865a4d5f0021ff4e493e6cf36d4a47f98ebbc8ff497cdbc1af628bc46728d0f201cf1535a0244369761f149ca4bd5
7
+ data.tar.gz: 63fe6fdf89ce60abed564474cd1469bc5efe726077434dd1757ba3bd2a7dc729728ee0273a4fb03193f0a3b88aa3adcb5e27d35dcbb9735aa944ec7b83fb64e2
@@ -1,10 +1,10 @@
1
1
  require "net/http"
2
2
  require "net/https"
3
3
 
4
- module ApiSabeqPsV1
4
+ module ApiDemoV1
5
5
  module SabeqHelpers
6
6
  REQUEST_HEADER = {'Content-Type' => 'application/json'}
7
- SABEQ_URL = "https://sabeq.ps"
7
+ SABEQ_URL = "https://localhost:3001/"
8
8
 
9
9
  # Authorize the request
10
10
  # parameters: login_token
@@ -95,7 +95,7 @@ module ApiSabeqPsV1
95
95
  def make_post_request(url_link, json_content)
96
96
  uri = URI.parse(url_link)
97
97
  http = Net::HTTP.new(uri.host, uri.port)
98
- http.use_ssl = true
98
+ http.use_ssl = false
99
99
  a_request = Net::HTTP::Post.new(uri.request_uri, REQUEST_HEADER)
100
100
  a_request.body = json_content.to_json
101
101
  a_response = http.request(a_request)
@@ -105,7 +105,7 @@ module ApiSabeqPsV1
105
105
  def make_get_request(url_link, json_content)
106
106
  uri = URI.parse(url_link)
107
107
  http = Net::HTTP.new(uri.host, uri.port)
108
- http.use_ssl = true
108
+ http.use_ssl = false
109
109
  the_params = json_content
110
110
  uri.query = URI.encode_www_form(the_params)
111
111
  a_request = Net::HTTP::Get.new(uri.request_uri)
@@ -1,3 +1,3 @@
1
1
  module ApiDemoV1
2
- VERSION = "0.1.4"
2
+ VERSION = "0.1.5"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: api_demo_v1
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.4
4
+ version: 0.1.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - ShaimaKaraki