cloud-waba-ruby-client 0.0.6 → 0.0.7

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: 94543fc2d4cbaf38614310550b889068b360c516794b11c74bbdeb7ca9234cad
4
- data.tar.gz: a2f7a3d3a8a6607914e22048d5264c87964f59e025e2a7b3bfd402155c766299
3
+ metadata.gz: 8109b7e99d244e79bf1ccff9a3342a630a54bfe3dec3458d2b38dc529a62ca9d
4
+ data.tar.gz: 51c7317afcc5b2381a7d4aeae236b43a58ebf8d960d2342ec2d5a3e46c58e25f
5
5
  SHA512:
6
- metadata.gz: fc34e254370d73934a2aead1328836e671549bf6dcb04f7d4a2c66ec02da2a0f4b5e696a4b1ef28947e75d8f02bb8da12ecb622568360773fe86c504a3e25ee3
7
- data.tar.gz: 2868c940d24dc17277d4ea84b0363af263364aad0b8430df0607c848ec41d66ce10cabd9cdaf02c394b644d6b488675f228d995d228a2ffda6086e739fa85e6c
6
+ metadata.gz: 7d1eb2b16aef7bef41e9d9c83d55b71fe3957b6be69ff82155cb0472b6c932ad86336f93103af8eb0384daa7b528c51c9cf9be158000b3a75621bb3a0a2215d9
7
+ data.tar.gz: 9dfe39bf65f578644527362b6c3d075ea27e7b5beefa35523a3eb72368247664f778963129e45daa67f884d8db2740375b5b099eade0b1754e36996635b3d8e6
data/README.md CHANGED
@@ -7,7 +7,7 @@ Ruby wrapper for [Cloud WhatsApp Business API](https://developers.facebook.com/d
7
7
  Add following line to your Gemfile:
8
8
 
9
9
  ```ruby
10
- gem 'cloud-waba-ruby-client', '~> 0.0.6'
10
+ gem 'cloud-waba-ruby-client', '~> 0.0.7'
11
11
  ```
12
12
 
13
13
  then run
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = "cloud-waba-ruby-client"
3
- s.version = "0.0.6"
3
+ s.version = "0.0.7"
4
4
  s.summary = "Cloud Waba Client for Ruby."
5
5
  s.description = "A simple API wrapper for Cloud Whatsapp Business API"
6
6
  s.authors = ["Ahmed Bassell"]
@@ -253,6 +253,15 @@ module API
253
253
  ::CloudWaba::Models::Media::Response.parse(hash: parsed_response)
254
254
  end
255
255
 
256
+ sig do
257
+ params(media_url: ::String).returns(::StringIO)
258
+ end
259
+ def download_media(media_url:)
260
+ client = ::CloudWaba::HttpClient.new(base_url: media_url, auth_token: @config.access_token)
261
+ response = with_error_handling { client.get }
262
+ StringIO.new(response.body)
263
+ end
264
+
256
265
  private
257
266
 
258
267
  def http_client
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cloud-waba-ruby-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.6
4
+ version: 0.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ahmed Bassell