instagram_connect 0.3.7 → 0.3.8

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: 9cb1aea4b378e02bab73277ace0304ecdd751c54e535bc6840670870b844fddd
4
- data.tar.gz: acc6b2589e468d17333a6920c1c5e4c609d8a636629e4ee62e35d8bb5e8cc6fa
3
+ metadata.gz: e92666f3e02d64943e955f8e20162754255471dc92bd4fc2e54e3f6db3a68111
4
+ data.tar.gz: 4bc700ffa63d750b2ad1313d1015e8f799edc44e56c9520d6b7be10fd494631c
5
5
  SHA512:
6
- metadata.gz: d61e2c92a923fdc3b4fe5b47ecdc9709044635fc658fcc2251928dc0bbf44d3b4234916d4416142a89241caaf667ea2f7635569d0cbd6dfe98cfd478fbd42f42
7
- data.tar.gz: e81459599d577b340e459571f643dace5a94a3a353921147877c89ac6e99a7647a8808da6ad5f5a00b85c943b4bf175b6903431a18efec073834c0aa6944f92f
6
+ metadata.gz: 0ba66b7cabad11d19321d2efa789728a97f5b668fb84c05bf3bf4c80277ab1df483e2e37ad85b87d3c6e3f6a0878a80608550e8ffb91154fb8f2e27f5490c698
7
+ data.tar.gz: de44cfd0f48eeafa8c4d2556d4f72de17c18218f2bba8ae9da9d8fa5f8bc67ceb41a840d8412f7a05181517288afd2c5fd92ff40128d676c6318379d389c595c
data/CHANGELOG.md CHANGED
@@ -6,6 +6,16 @@ All notable changes to this project are documented here. The format follows
6
6
 
7
7
  ## [Unreleased]
8
8
 
9
+ ## [0.3.8] - 2026-07-27
10
+
11
+ ### Added
12
+
13
+ - **Media sync now carries engagement and the poster frame.** `like_count` and `comments_count`
14
+ come straight off the media node (no insights permission needed for the account's own posts) and
15
+ `thumbnail_url` is the poster for videos, whose `media_url` is a playable mp4. All three columns
16
+ existed since 0.3.0; nothing ever asked Meta for them.
17
+
18
+
9
19
  ## [0.3.7] - 2026-07-27
10
20
 
11
21
  ### Added
@@ -17,7 +17,11 @@ module InstagramConnect
17
17
  # enqueueing it once per page view.
18
18
  THROTTLE = 10.minutes
19
19
 
20
- MEDIA_FIELDS = "id,caption,media_type,media_url,permalink,timestamp".freeze
20
+ # like_count and comments_count come straight off the media node — no
21
+ # insights permission needed for the account's own posts. thumbnail_url is
22
+ # the poster frame for videos, whose media_url is a playable mp4.
23
+ MEDIA_FIELDS = "id,caption,media_type,media_url,thumbnail_url,permalink," \
24
+ "timestamp,like_count,comments_count".freeze
21
25
 
22
26
  def self.enqueue_throttled(account)
23
27
  Rails.cache.fetch("instagram_connect:sync_media:#{account.id}", expires_in: THROTTLE) do
@@ -62,6 +66,9 @@ module InstagramConnect
62
66
  caption: item["caption"],
63
67
  permalink: item["permalink"],
64
68
  media_url: item["media_url"],
69
+ thumbnail_url: item["thumbnail_url"],
70
+ like_count: item["like_count"],
71
+ comments_count: item["comments_count"],
65
72
  posted_at: parse_time(item["timestamp"]),
66
73
  synced_at: Time.current
67
74
  )
@@ -133,7 +133,9 @@ module InstagramConnect
133
133
 
134
134
  def list_media(ig_user_id: @ig_user_id, limit: 25)
135
135
  get("/#{require_ig_user_id(ig_user_id)}/media",
136
- { fields: "id,caption,media_type,media_url,permalink,timestamp", limit: limit })
136
+ { fields: "id,caption,media_type,media_url,thumbnail_url,permalink," \
137
+ "timestamp,like_count,comments_count",
138
+ limit: limit })
137
139
  end
138
140
 
139
141
  def media_insights(media_id:, metrics: %w[reach likes comments])
@@ -1,3 +1,3 @@
1
1
  module InstagramConnect
2
- VERSION = "0.3.7"
2
+ VERSION = "0.3.8"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: instagram_connect
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.7
4
+ version: 0.3.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kshitiz Sinha