mailersend-ruby 1.5.0 → 1.5.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/main.yml +1 -1
- data/CHANGELOG.md +4 -0
- data/Gemfile +6 -0
- data/lib/mailersend/email/email.rb +13 -7
- data/lib/mailersend/sender_identity/sender_identity.rb +0 -1
- data/lib/mailersend/version.rb +1 -1
- data/mailersend-ruby.gemspec +0 -3
- metadata +5 -47
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6346fa18c1ea9c31c279efee9ad04e00ea9aefbf9404cb809e7b4d03a4a68b39
|
4
|
+
data.tar.gz: ba5a053236908bcf7ddef6d96361637d7939dd0cbeff5064ce6ec99a080b3135
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: aca1d6309de48cd46627023d6d17382349ace946b28d1b01b934b5d1806259c2ab0992ceaee4483b09fe6da70c601ef8b08683b7a0d066a2298eae7a0ef03e70
|
7
|
+
data.tar.gz: fe44c8e8a2563eaf6864c18284c8714feb68677c2fe666b6d1c03ed8a7a00441afab6a01301532fb184487661d15783e7d87ae0757f14be6eb80f4bdc3a1a712
|
data/.github/workflows/main.yml
CHANGED
data/CHANGELOG.md
CHANGED
data/Gemfile
CHANGED
@@ -87,13 +87,19 @@ module Mailersend
|
|
87
87
|
end
|
88
88
|
|
89
89
|
def add_attachment(content:, filename:, disposition:)
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
90
|
+
# content: Can be one of the following:
|
91
|
+
# file_path(String) i.e. 'app/Sample-jpg-image-50kb.jpeg'
|
92
|
+
# Base64 encoded string (String)
|
93
|
+
# Supported types are: https://developers.mailersend.com/api/v1/email.html#supported-file-types
|
94
|
+
|
95
|
+
content_string = content.to_s
|
96
|
+
if File.readable?(content_string)
|
97
|
+
data = File.read(content_string)
|
98
|
+
base64_encoded = Base64.strict_encode64(data)
|
99
|
+
else
|
100
|
+
base64_encoded = content_string
|
101
|
+
end
|
102
|
+
@attachments << { 'content' => base64_encoded, 'filename' => filename, 'disposition' => disposition }
|
97
103
|
end
|
98
104
|
|
99
105
|
def add_send_at(send_at)
|
data/lib/mailersend/version.rb
CHANGED
data/mailersend-ruby.gemspec
CHANGED
@@ -27,9 +27,6 @@ Gem::Specification.new do |spec|
|
|
27
27
|
spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
|
28
28
|
spec.require_paths = ['lib']
|
29
29
|
|
30
|
-
spec.add_development_dependency 'bundler', '~> 2.4.1'
|
31
|
-
spec.add_development_dependency 'rake', '~> 13.0'
|
32
|
-
spec.add_development_dependency 'rubocop', '~> 1.7'
|
33
30
|
spec.add_dependency 'dotenv', '~> 2.7'
|
34
31
|
spec.add_dependency 'http', '~> 5.0'
|
35
32
|
spec.add_dependency 'json', '~> 2.5'
|
metadata
CHANGED
@@ -1,57 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mailersend-ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.5.
|
4
|
+
version: 1.5.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nikola Milojević
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-06-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
|
-
- !ruby/object:Gem::Dependency
|
14
|
-
name: bundler
|
15
|
-
requirement: !ruby/object:Gem::Requirement
|
16
|
-
requirements:
|
17
|
-
- - "~>"
|
18
|
-
- !ruby/object:Gem::Version
|
19
|
-
version: 2.4.1
|
20
|
-
type: :development
|
21
|
-
prerelease: false
|
22
|
-
version_requirements: !ruby/object:Gem::Requirement
|
23
|
-
requirements:
|
24
|
-
- - "~>"
|
25
|
-
- !ruby/object:Gem::Version
|
26
|
-
version: 2.4.1
|
27
|
-
- !ruby/object:Gem::Dependency
|
28
|
-
name: rake
|
29
|
-
requirement: !ruby/object:Gem::Requirement
|
30
|
-
requirements:
|
31
|
-
- - "~>"
|
32
|
-
- !ruby/object:Gem::Version
|
33
|
-
version: '13.0'
|
34
|
-
type: :development
|
35
|
-
prerelease: false
|
36
|
-
version_requirements: !ruby/object:Gem::Requirement
|
37
|
-
requirements:
|
38
|
-
- - "~>"
|
39
|
-
- !ruby/object:Gem::Version
|
40
|
-
version: '13.0'
|
41
|
-
- !ruby/object:Gem::Dependency
|
42
|
-
name: rubocop
|
43
|
-
requirement: !ruby/object:Gem::Requirement
|
44
|
-
requirements:
|
45
|
-
- - "~>"
|
46
|
-
- !ruby/object:Gem::Version
|
47
|
-
version: '1.7'
|
48
|
-
type: :development
|
49
|
-
prerelease: false
|
50
|
-
version_requirements: !ruby/object:Gem::Requirement
|
51
|
-
requirements:
|
52
|
-
- - "~>"
|
53
|
-
- !ruby/object:Gem::Version
|
54
|
-
version: '1.7'
|
55
13
|
- !ruby/object:Gem::Dependency
|
56
14
|
name: dotenv
|
57
15
|
requirement: !ruby/object:Gem::Requirement
|
@@ -169,7 +127,7 @@ metadata:
|
|
169
127
|
source_code_uri: https://github.com/mailersend/mailersend-ruby
|
170
128
|
changelog_uri: https://github.com/mailersend/mailersend-ruby/blob/main/CHANGELOG.md
|
171
129
|
rubygems_mfa_required: 'true'
|
172
|
-
post_install_message:
|
130
|
+
post_install_message:
|
173
131
|
rdoc_options: []
|
174
132
|
require_paths:
|
175
133
|
- lib
|
@@ -185,7 +143,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
185
143
|
version: '0'
|
186
144
|
requirements: []
|
187
145
|
rubygems_version: 3.4.10
|
188
|
-
signing_key:
|
146
|
+
signing_key:
|
189
147
|
specification_version: 4
|
190
148
|
summary: MailerSend's official Ruby SDK
|
191
149
|
test_files: []
|