twitty 0.1.1 → 0.1.2

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: af1341fc611e8ad730728ce212324edbd3687318c7003ad1383491c38b1e1a6b
4
- data.tar.gz: 63a703de91a973aa35b231bca5aac173af8af39c25d11a6511bdd3671c8e67e9
3
+ metadata.gz: 94a8d618eb91b2e104f808cdb3b4a1bd32663f2b03f03317c5113de4f4a8639c
4
+ data.tar.gz: ea116a4b5eaee3fca8b968dac8ac5dc658602df2b049427a4e78aa870f5bb4cf
5
5
  SHA512:
6
- metadata.gz: aaa0d6a18e8466e558fe5eb643133c1d96e32cba2adcb9ecd5a087a86920b2cb5a73dc2ced7492a076ad1ef30616e584ba9e5f2b0b54af72842026649b98acdb
7
- data.tar.gz: 99586bc08c14a735b480935a08a70476293f583c95754a8458431da2d7740e30ebd276226d2641e30ff703f8a0151968a4defaee3dca10cfb395817459314c4f
6
+ metadata.gz: c66cfe86a7100d07d318e09917327b5fb2e36478b577f768167afa86eb27e1672a55c4915ea546bc4850a88c115f01a985b4edade96fc42e8297d2d5e45aeded
7
+ data.tar.gz: bd8afc3e729fecd14527e07d8c56853df82d587278b7eb3203e43025b78fb51b551652d0aadf5e8529282298b0350482d99c46f99a553397c73a356acafefa26
data/CODE_OF_CONDUCT.md CHANGED
@@ -55,7 +55,7 @@ further defined and clarified by project maintainers.
55
55
  ## Enforcement
56
56
 
57
57
  Instances of abusive, harassing, or otherwise unacceptable behavior may be
58
- reported by contacting the project team at subin.tp@truecaller.com. All
58
+ reported by contacting the project team at hello@chatwoot.com. All
59
59
  complaints will be reviewed and investigated and will result in a response that
60
60
  is deemed necessary and appropriate to the circumstances. The project team is
61
61
  obligated to maintain confidentiality with regard to the reporter of an incident.
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- twitty (0.1.0)
4
+ twitty (0.1.2)
5
5
  oauth
6
6
 
7
7
  GEM
@@ -61,7 +61,37 @@ module Twitty
61
61
  method: :post,
62
62
  endpoint: '/oauth/access_token',
63
63
  required_params: [:oauth_token, :oauth_verifier]
64
+ },
65
+
66
+ destroy_tweet: {
67
+ method: :post,
68
+ endpoint: '/1.1/statuses/destroy/%{tweet_id}.json',
69
+ required_params: [:tweet_id]
70
+ },
71
+
72
+ retweet: {
73
+ method: :post,
74
+ endpoint: '/1.1/statuses/retweet/%{tweet_id}.json',
75
+ required_params: [:tweet_id]
76
+ },
77
+
78
+ unretweet: {
79
+ method: :post,
80
+ endpoint: '/1.1/statuses/unretweet/%{tweet_id}.json',
81
+ required_params: [:tweet_id]
82
+ },
83
+
84
+ like_tweet: {
85
+ method: :post,
86
+ endpoint: '/1.1/favorites/create.json',
87
+ required_params: [:tweet_id]
88
+ },
89
+
90
+ unlike_tweet: {
91
+ method: :post,
92
+ endpoint: '/1.1/favorites/destroy.json',
93
+ required_params: [:tweet_id]
64
94
  }
65
- }.freeze
95
+ }.freeze
66
96
  end
67
97
  end
@@ -1,6 +1,9 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module Twitty
2
4
  module Payload
3
- EMPTY_PAYLOAD_ACTIONS = %w[fetch_webhooks register_webhook unregister_webhook fetch_subscriptions create_subscription remove_subscription].freeze
5
+ EMPTY_PAYLOAD_ACTIONS = %w[fetch_webhooks register_webhook unregister_webhook fetch_subscriptions
6
+ create_subscription remove_subscription destroy_tweet retweet unretweet].freeze
4
7
 
5
8
  EMPTY_PAYLOAD_ACTIONS.each do |action|
6
9
  define_method "#{action.to_s}_payload" do
@@ -48,5 +51,17 @@ module Twitty
48
51
  oauth_verifier: @payload[:oauth_verifier]
49
52
  }
50
53
  end
54
+
55
+ def like_tweet_payload
56
+ {
57
+ "id": @payload[:tweet_id]
58
+ }
59
+ end
60
+
61
+ def unlike_tweet_payload
62
+ {
63
+ "id": @payload[:tweet_id]
64
+ }
65
+ end
51
66
  end
52
67
  end
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module Twitty
2
- VERSION = "0.1.1"
4
+ VERSION = "0.1.2"
3
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: twitty
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Subin T P
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: exe
12
12
  cert_chain: []
13
- date: 2020-05-13 00:00:00.000000000 Z
13
+ date: 2021-03-11 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: bundler
@@ -125,7 +125,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
125
125
  - !ruby/object:Gem::Version
126
126
  version: '0'
127
127
  requirements: []
128
- rubygems_version: 3.1.2
128
+ rubygems_version: 3.2.3
129
129
  signing_key:
130
130
  specification_version: 4
131
131
  summary: Twitter API wrapper