linkedin2 0.0.6 → 0.0.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/linkedin/api/profiles.rb +14 -0
- data/lib/linkedin/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0bfc000809e1a422a5b0d46b8c89d7ead2f19c58
|
4
|
+
data.tar.gz: 4fcd7b7eb82f0dfd1019e7acb44dd67b956974f2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c5ac474c20fbe86185dddbe79799d7e9c2d868c47c6a7f93617a2b02b5b0a8c94a1a5b7414309324cbe7f0ecf125e61900808280d4d80ab0c79dfb648b498b07
|
7
|
+
data.tar.gz: 7123f64b7fe24d02e4ad18971f165e5713496d18dfa33d196ce438397a0084ab1dda7fd523be1b80882bdc023f427ee8833ce11238832446d18c9ba3ba7fb12e
|
@@ -42,6 +42,20 @@ module LinkedIn
|
|
42
42
|
req.body = connection_request.to_json
|
43
43
|
end
|
44
44
|
end
|
45
|
+
|
46
|
+
def message(subject, message, recipients)
|
47
|
+
recipients = [recipients].flatten
|
48
|
+
|
49
|
+
recipients = recipients.map { |recipient| { person: { _path: "/people/#{recipient.to_param}" } } }
|
50
|
+
|
51
|
+
message = { recipients: { values: recipients }, subject: subject, body: message }
|
52
|
+
|
53
|
+
post 'v1/people/~/mailbox' do |req|
|
54
|
+
req.headers['Content-Type'] = 'application/json'
|
55
|
+
req.headers['x-li-format'] = 'json'
|
56
|
+
req.body = message.to_json
|
57
|
+
end
|
58
|
+
end
|
45
59
|
end
|
46
60
|
end
|
47
61
|
end
|
data/lib/linkedin/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: linkedin2
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Bob Breznak
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-02-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: oauth2
|