@chilfish/gallery-dl-instagram 0.2.2 → 0.2.3

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.
package/dist/dl-ins.mjs CHANGED
@@ -2968,7 +2968,7 @@ function useColor() {
2968
2968
  new Command();
2969
2969
  //#endregion
2970
2970
  //#region package.json
2971
- var version = "0.2.1";
2971
+ var version = "0.2.3";
2972
2972
  //#endregion
2973
2973
  //#region src/utils/id-codec.ts
2974
2974
  /**
@@ -3550,6 +3550,7 @@ function parsePostRest(post, cfg) {
3550
3550
  owner_id: owner.pk,
3551
3551
  username: owner.username ?? "",
3552
3552
  fullname: owner.full_name ?? "",
3553
+ user: owner,
3553
3554
  post_date: date,
3554
3555
  date,
3555
3556
  description: caption ? caption.text : "",
@@ -3595,7 +3596,7 @@ function parsePostRest(post, cfg) {
3595
3596
  if (post.music_metadata) {
3596
3597
  const info = post.music_metadata.music_info;
3597
3598
  if (info) {
3598
- const audio = extractAudio(post, data, { music_asset_info: info }, cfg);
3599
+ const audio = extractAudio(post, data, info, cfg);
3599
3600
  if (audio) {
3600
3601
  audio.num = items.length;
3601
3602
  data._files.push(audio);
@@ -3756,11 +3757,16 @@ function extractAudio(src, dest, sticker, cfg) {
3756
3757
  const info = sticker.music_asset_info;
3757
3758
  if (!info) return null;
3758
3759
  const cinfo = sticker.music_consumption_info ?? info;
3759
- dest.audio_title = info.title;
3760
+ dest.audio_title = info.title ?? info.sanitized_title;
3761
+ dest.audio_subtitle = info.subtitle;
3760
3762
  dest.audio_duration = (info.duration_in_ms ?? 0) / 1e3;
3761
3763
  dest.audio_timestamps = info.highlight_start_times_in_ms;
3762
3764
  dest.audio_artist = info.display_artist ?? cinfo.display_artist;
3763
3765
  dest.audio_user = info.ig_artist ?? cinfo.ig_artist;
3766
+ dest.audio_has_lyrics = info.has_lyrics;
3767
+ dest.audio_is_explicit = info.is_explicit;
3768
+ dest.audio_cover_artwork_uri = info.cover_artwork_uri;
3769
+ dest.audio_cover_artwork_thumbnail_uri = info.cover_artwork_thumbnail_uri;
3764
3770
  const url = info.progressive_download_url;
3765
3771
  if (!url) return null;
3766
3772
  return {
@@ -3777,10 +3783,15 @@ function extractAudio(src, dest, sticker, cfg) {
3777
3783
  height_original: 0,
3778
3784
  tagged_users: [],
3779
3785
  audio_user: info.ig_artist ?? cinfo.ig_artist,
3780
- audio_title: info.title,
3786
+ audio_title: info.title ?? info.sanitized_title,
3787
+ audio_subtitle: info.subtitle,
3781
3788
  audio_artist: info.display_artist ?? cinfo.display_artist,
3782
3789
  audio_duration: (info.duration_in_ms ?? 0) / 1e3,
3783
- audio_timestamps: info.highlight_start_times_in_ms
3790
+ audio_timestamps: info.highlight_start_times_in_ms,
3791
+ audio_cover_artwork_uri: info.cover_artwork_uri,
3792
+ audio_cover_artwork_thumbnail_uri: info.cover_artwork_thumbnail_uri,
3793
+ audio_has_lyrics: info.has_lyrics,
3794
+ audio_is_explicit: info.is_explicit
3784
3795
  };
3785
3796
  }
3786
3797
  function extractPinned(post) {
@@ -3803,6 +3814,7 @@ function parsePostGraphql(post, cfg) {
3803
3814
  owner_id: owner.id ?? owner.pk,
3804
3815
  username: owner.username ?? "",
3805
3816
  fullname: owner.full_name ?? "",
3817
+ user: owner,
3806
3818
  post_id: post.id,
3807
3819
  post_shortcode: post.shortcode,
3808
3820
  post_url: `${cfg.root}/p/${post.shortcode}/`,
@@ -4571,7 +4583,13 @@ var PrintJob = class PrintJob extends Job {
4571
4583
  width: meta.width ?? 0,
4572
4584
  height: meta.height ?? 0,
4573
4585
  videoUrl: meta.video_url ?? null,
4574
- audioUrl: meta.audio_url ?? null
4586
+ audioUrl: meta.audio_url ?? null,
4587
+ audioTitle: meta.audio_title ?? void 0,
4588
+ audioArtist: meta.audio_artist ?? void 0,
4589
+ audioDuration: meta.audio_duration ?? void 0,
4590
+ audioHasLyrics: meta.audio_has_lyrics ?? void 0,
4591
+ audioIsExplicit: meta.audio_is_explicit ?? void 0,
4592
+ coverArtworkUri: meta.audio_cover_artwork_uri ?? meta.audio_cover_artwork_thumbnail_uri ?? void 0
4575
4593
  });
4576
4594
  }
4577
4595
  async handleQueue(msg) {
@@ -4667,6 +4685,26 @@ var PrintJob = class PrintJob extends Job {
4667
4685
  process.stdout.write(`${line}\n`);
4668
4686
  }
4669
4687
  }
4688
+ const audioFiles = this._files.filter((f) => f.audioUrl);
4689
+ if (audioFiles.length > 0) {
4690
+ process.stdout.write(` ${dim("│")}\n`);
4691
+ process.stdout.write(` ${dim("│")} ${b("Music:")}\n`);
4692
+ for (const af of audioFiles) {
4693
+ if (af.audioTitle) {
4694
+ const title = af.audioArtist ? `${af.audioTitle} — ${af.audioArtist}` : af.audioTitle;
4695
+ process.stdout.write(` ${dim("│")} ${g("♪")} ${title}\n`);
4696
+ }
4697
+ if (af.audioDuration) {
4698
+ const mins = Math.floor(af.audioDuration / 60);
4699
+ const secs = Math.round(af.audioDuration % 60);
4700
+ const badges = [`${mins}:${String(secs).padStart(2, "0")}`];
4701
+ if (af.audioHasLyrics) badges.push("lyrics");
4702
+ if (af.audioIsExplicit) badges.push(`${_YELLOW}explicit${_RESET}`);
4703
+ process.stdout.write(` ${dim("│")} ${dim(badges.join(" · "))}\n`);
4704
+ }
4705
+ if (af.coverArtworkUri) process.stdout.write(` ${dim("│")} ${dim("Art:")} ${dim(`${af.coverArtworkUri.slice(0, 60)}…`)}\n`);
4706
+ }
4707
+ }
4670
4708
  process.stdout.write(` ${dim("└")}${"─".repeat(w - 2)}${dim("┘")}\n`);
4671
4709
  }
4672
4710
  _wrap(text, maxLen) {
package/dist/index.cjs CHANGED
@@ -1,5 +1,5 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_sdk = require("./sdk-BClg0Kv2.cjs");
2
+ const require_sdk = require("./sdk-D8q2Rjw2.cjs");
3
3
  //#region src/core/print-job.ts
4
4
  var PrintJob = class PrintJob extends require_sdk.Job {
5
5
  _currentDir = {};
@@ -31,7 +31,13 @@ var PrintJob = class PrintJob extends require_sdk.Job {
31
31
  width: meta.width ?? 0,
32
32
  height: meta.height ?? 0,
33
33
  videoUrl: meta.video_url ?? null,
34
- audioUrl: meta.audio_url ?? null
34
+ audioUrl: meta.audio_url ?? null,
35
+ audioTitle: meta.audio_title ?? void 0,
36
+ audioArtist: meta.audio_artist ?? void 0,
37
+ audioDuration: meta.audio_duration ?? void 0,
38
+ audioHasLyrics: meta.audio_has_lyrics ?? void 0,
39
+ audioIsExplicit: meta.audio_is_explicit ?? void 0,
40
+ coverArtworkUri: meta.audio_cover_artwork_uri ?? meta.audio_cover_artwork_thumbnail_uri ?? void 0
35
41
  });
36
42
  }
37
43
  async handleQueue(msg) {
@@ -127,6 +133,26 @@ var PrintJob = class PrintJob extends require_sdk.Job {
127
133
  process.stdout.write(`${line}\n`);
128
134
  }
129
135
  }
136
+ const audioFiles = this._files.filter((f) => f.audioUrl);
137
+ if (audioFiles.length > 0) {
138
+ process.stdout.write(` ${require_sdk.dim("│")}\n`);
139
+ process.stdout.write(` ${require_sdk.dim("│")} ${require_sdk.b("Music:")}\n`);
140
+ for (const af of audioFiles) {
141
+ if (af.audioTitle) {
142
+ const title = af.audioArtist ? `${af.audioTitle} — ${af.audioArtist}` : af.audioTitle;
143
+ process.stdout.write(` ${require_sdk.dim("│")} ${require_sdk.g("♪")} ${title}\n`);
144
+ }
145
+ if (af.audioDuration) {
146
+ const mins = Math.floor(af.audioDuration / 60);
147
+ const secs = Math.round(af.audioDuration % 60);
148
+ const badges = [`${mins}:${String(secs).padStart(2, "0")}`];
149
+ if (af.audioHasLyrics) badges.push("lyrics");
150
+ if (af.audioIsExplicit) badges.push(`${require_sdk._YELLOW}explicit${require_sdk._RESET}`);
151
+ process.stdout.write(` ${require_sdk.dim("│")} ${require_sdk.dim(badges.join(" · "))}\n`);
152
+ }
153
+ if (af.coverArtworkUri) process.stdout.write(` ${require_sdk.dim("│")} ${require_sdk.dim("Art:")} ${require_sdk.dim(`${af.coverArtworkUri.slice(0, 60)}…`)}\n`);
154
+ }
155
+ }
130
156
  process.stdout.write(` ${require_sdk.dim("└")}${"─".repeat(w - 2)}${require_sdk.dim("┘")}\n`);
131
157
  }
132
158
  _wrap(text, maxLen) {
package/dist/index.d.cts CHANGED
@@ -97,6 +97,7 @@ interface InstagramUser {
97
97
  count: number;
98
98
  };
99
99
  followed_by_viewer?: boolean;
100
+ is_verified?: boolean;
100
101
  }
101
102
  interface ImageCandidate {
102
103
  url: string;
@@ -141,19 +142,25 @@ interface MusicSticker {
141
142
  interface MusicAssetInfo {
142
143
  id: string;
143
144
  title?: string;
145
+ sanitized_title?: string;
146
+ subtitle?: string;
144
147
  display_artist?: string;
145
148
  ig_artist?: string;
149
+ ig_username?: string;
146
150
  duration_in_ms?: number;
147
151
  highlight_start_times_in_ms?: number[];
148
152
  progressive_download_url: string;
149
153
  cover_artwork_uri?: string;
154
+ cover_artwork_thumbnail_uri?: string;
155
+ has_lyrics?: boolean;
156
+ is_explicit?: boolean;
150
157
  }
151
158
  interface MusicConsumptionInfo {
152
159
  display_artist?: string;
153
160
  ig_artist?: string;
154
161
  }
155
162
  interface MusicMetadata {
156
- music_info?: MusicAssetInfo;
163
+ music_info?: MusicSticker;
157
164
  }
158
165
  interface InstagramPost {
159
166
  pk: string;
@@ -274,9 +281,14 @@ interface ParsedMedia {
274
281
  audio_url?: string;
275
282
  audio_user?: string;
276
283
  audio_title?: string;
284
+ audio_subtitle?: string;
277
285
  audio_artist?: string;
278
286
  audio_duration?: number;
279
287
  audio_timestamps?: number[];
288
+ audio_cover_artwork_uri?: string;
289
+ audio_cover_artwork_thumbnail_uri?: string;
290
+ audio_has_lyrics?: boolean;
291
+ audio_is_explicit?: boolean;
280
292
  _ytdl_manifest_data?: string;
281
293
  sidecar_media_id?: string;
282
294
  sidecar_shortcode?: string;
package/dist/index.d.mts CHANGED
@@ -97,6 +97,7 @@ interface InstagramUser {
97
97
  count: number;
98
98
  };
99
99
  followed_by_viewer?: boolean;
100
+ is_verified?: boolean;
100
101
  }
101
102
  interface ImageCandidate {
102
103
  url: string;
@@ -141,19 +142,25 @@ interface MusicSticker {
141
142
  interface MusicAssetInfo {
142
143
  id: string;
143
144
  title?: string;
145
+ sanitized_title?: string;
146
+ subtitle?: string;
144
147
  display_artist?: string;
145
148
  ig_artist?: string;
149
+ ig_username?: string;
146
150
  duration_in_ms?: number;
147
151
  highlight_start_times_in_ms?: number[];
148
152
  progressive_download_url: string;
149
153
  cover_artwork_uri?: string;
154
+ cover_artwork_thumbnail_uri?: string;
155
+ has_lyrics?: boolean;
156
+ is_explicit?: boolean;
150
157
  }
151
158
  interface MusicConsumptionInfo {
152
159
  display_artist?: string;
153
160
  ig_artist?: string;
154
161
  }
155
162
  interface MusicMetadata {
156
- music_info?: MusicAssetInfo;
163
+ music_info?: MusicSticker;
157
164
  }
158
165
  interface InstagramPost {
159
166
  pk: string;
@@ -274,9 +281,14 @@ interface ParsedMedia {
274
281
  audio_url?: string;
275
282
  audio_user?: string;
276
283
  audio_title?: string;
284
+ audio_subtitle?: string;
277
285
  audio_artist?: string;
278
286
  audio_duration?: number;
279
287
  audio_timestamps?: number[];
288
+ audio_cover_artwork_uri?: string;
289
+ audio_cover_artwork_thumbnail_uri?: string;
290
+ audio_has_lyrics?: boolean;
291
+ audio_is_explicit?: boolean;
280
292
  _ytdl_manifest_data?: string;
281
293
  sidecar_media_id?: string;
282
294
  sidecar_shortcode?: string;
package/dist/index.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { A as directory, B as _YELLOW, C as extract, D as parseUnicodeEscapes, E as parseInt, F as Extractor, G as pad, H as c, I as noopLogger, K as ConfigManager, L as DownloadJob, M as url, N as idFromShortcode, O as unescape, P as shortcodeFromId, R as Job, S as extr, T as nameExtFromURL, U as dim, V as b, W as g, _ as extractAudio, a as InstagramTaggedExtractor, b as InstagramRestAPI, c as InstagramSavedExtractor, d as InstagramPostExtractor, f as InstagramInfoExtractor, g as parsePostGraphql, h as InstagramExtractor, i as InstagramUserExtractor, j as queue, k as unquote, l as InstagramReelsExtractor, m as InstagramAvatarExtractor, o as InstagramTagExtractor, p as InstagramHighlightsExtractor, s as InstagramStoriesExtractor, t as InstagramSDK, u as InstagramPostsExtractor, v as extractTaggedUsers, w as findTags, x as ensureHttpScheme, y as parsePostRest, z as _RESET } from "./sdk-CovBsEps.mjs";
1
+ import { A as directory, B as _YELLOW, C as extract, D as parseUnicodeEscapes, E as parseInt, F as Extractor, G as pad, H as c, I as noopLogger, K as ConfigManager, L as DownloadJob, M as url, N as idFromShortcode, O as unescape, P as shortcodeFromId, R as Job, S as extr, T as nameExtFromURL, U as dim, V as b, W as g, _ as extractAudio, a as InstagramTaggedExtractor, b as InstagramRestAPI, c as InstagramSavedExtractor, d as InstagramPostExtractor, f as InstagramInfoExtractor, g as parsePostGraphql, h as InstagramExtractor, i as InstagramUserExtractor, j as queue, k as unquote, l as InstagramReelsExtractor, m as InstagramAvatarExtractor, o as InstagramTagExtractor, p as InstagramHighlightsExtractor, s as InstagramStoriesExtractor, t as InstagramSDK, u as InstagramPostsExtractor, v as extractTaggedUsers, w as findTags, x as ensureHttpScheme, y as parsePostRest, z as _RESET } from "./sdk-E0L5ISZC.mjs";
2
2
  //#region src/core/print-job.ts
3
3
  var PrintJob = class PrintJob extends Job {
4
4
  _currentDir = {};
@@ -30,7 +30,13 @@ var PrintJob = class PrintJob extends Job {
30
30
  width: meta.width ?? 0,
31
31
  height: meta.height ?? 0,
32
32
  videoUrl: meta.video_url ?? null,
33
- audioUrl: meta.audio_url ?? null
33
+ audioUrl: meta.audio_url ?? null,
34
+ audioTitle: meta.audio_title ?? void 0,
35
+ audioArtist: meta.audio_artist ?? void 0,
36
+ audioDuration: meta.audio_duration ?? void 0,
37
+ audioHasLyrics: meta.audio_has_lyrics ?? void 0,
38
+ audioIsExplicit: meta.audio_is_explicit ?? void 0,
39
+ coverArtworkUri: meta.audio_cover_artwork_uri ?? meta.audio_cover_artwork_thumbnail_uri ?? void 0
34
40
  });
35
41
  }
36
42
  async handleQueue(msg) {
@@ -126,6 +132,26 @@ var PrintJob = class PrintJob extends Job {
126
132
  process.stdout.write(`${line}\n`);
127
133
  }
128
134
  }
135
+ const audioFiles = this._files.filter((f) => f.audioUrl);
136
+ if (audioFiles.length > 0) {
137
+ process.stdout.write(` ${dim("│")}\n`);
138
+ process.stdout.write(` ${dim("│")} ${b("Music:")}\n`);
139
+ for (const af of audioFiles) {
140
+ if (af.audioTitle) {
141
+ const title = af.audioArtist ? `${af.audioTitle} — ${af.audioArtist}` : af.audioTitle;
142
+ process.stdout.write(` ${dim("│")} ${g("♪")} ${title}\n`);
143
+ }
144
+ if (af.audioDuration) {
145
+ const mins = Math.floor(af.audioDuration / 60);
146
+ const secs = Math.round(af.audioDuration % 60);
147
+ const badges = [`${mins}:${String(secs).padStart(2, "0")}`];
148
+ if (af.audioHasLyrics) badges.push("lyrics");
149
+ if (af.audioIsExplicit) badges.push(`${_YELLOW}explicit${_RESET}`);
150
+ process.stdout.write(` ${dim("│")} ${dim(badges.join(" · "))}\n`);
151
+ }
152
+ if (af.coverArtworkUri) process.stdout.write(` ${dim("│")} ${dim("Art:")} ${dim(`${af.coverArtworkUri.slice(0, 60)}…`)}\n`);
153
+ }
154
+ }
129
155
  process.stdout.write(` ${dim("└")}${"─".repeat(w - 2)}${dim("┘")}\n`);
130
156
  }
131
157
  _wrap(text, maxLen) {
package/dist/node.cjs CHANGED
@@ -1,5 +1,5 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_sdk = require("./sdk-BClg0Kv2.cjs");
2
+ const require_sdk = require("./sdk-D8q2Rjw2.cjs");
3
3
  //#region src/node-factory.ts
4
4
  /**
5
5
  * Create an SDK instance with Node.js defaults.
package/dist/node.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { I as noopLogger, n as createFetchHttpClient, r as extractCsrf, t as InstagramSDK } from "./sdk-CovBsEps.mjs";
1
+ import { I as noopLogger, n as createFetchHttpClient, r as extractCsrf, t as InstagramSDK } from "./sdk-E0L5ISZC.mjs";
2
2
  //#region src/node-factory.ts
3
3
  /**
4
4
  * Create an SDK instance with Node.js defaults.
@@ -907,6 +907,7 @@ function parsePostRest(post, cfg) {
907
907
  owner_id: owner.pk,
908
908
  username: owner.username ?? "",
909
909
  fullname: owner.full_name ?? "",
910
+ user: owner,
910
911
  post_date: date,
911
912
  date,
912
913
  description: caption ? caption.text : "",
@@ -952,7 +953,7 @@ function parsePostRest(post, cfg) {
952
953
  if (post.music_metadata) {
953
954
  const info = post.music_metadata.music_info;
954
955
  if (info) {
955
- const audio = extractAudio(post, data, { music_asset_info: info }, cfg);
956
+ const audio = extractAudio(post, data, info, cfg);
956
957
  if (audio) {
957
958
  audio.num = items.length;
958
959
  data._files.push(audio);
@@ -1113,11 +1114,16 @@ function extractAudio(src, dest, sticker, cfg) {
1113
1114
  const info = sticker.music_asset_info;
1114
1115
  if (!info) return null;
1115
1116
  const cinfo = sticker.music_consumption_info ?? info;
1116
- dest.audio_title = info.title;
1117
+ dest.audio_title = info.title ?? info.sanitized_title;
1118
+ dest.audio_subtitle = info.subtitle;
1117
1119
  dest.audio_duration = (info.duration_in_ms ?? 0) / 1e3;
1118
1120
  dest.audio_timestamps = info.highlight_start_times_in_ms;
1119
1121
  dest.audio_artist = info.display_artist ?? cinfo.display_artist;
1120
1122
  dest.audio_user = info.ig_artist ?? cinfo.ig_artist;
1123
+ dest.audio_has_lyrics = info.has_lyrics;
1124
+ dest.audio_is_explicit = info.is_explicit;
1125
+ dest.audio_cover_artwork_uri = info.cover_artwork_uri;
1126
+ dest.audio_cover_artwork_thumbnail_uri = info.cover_artwork_thumbnail_uri;
1121
1127
  const url = info.progressive_download_url;
1122
1128
  if (!url) return null;
1123
1129
  return {
@@ -1134,10 +1140,15 @@ function extractAudio(src, dest, sticker, cfg) {
1134
1140
  height_original: 0,
1135
1141
  tagged_users: [],
1136
1142
  audio_user: info.ig_artist ?? cinfo.ig_artist,
1137
- audio_title: info.title,
1143
+ audio_title: info.title ?? info.sanitized_title,
1144
+ audio_subtitle: info.subtitle,
1138
1145
  audio_artist: info.display_artist ?? cinfo.display_artist,
1139
1146
  audio_duration: (info.duration_in_ms ?? 0) / 1e3,
1140
- audio_timestamps: info.highlight_start_times_in_ms
1147
+ audio_timestamps: info.highlight_start_times_in_ms,
1148
+ audio_cover_artwork_uri: info.cover_artwork_uri,
1149
+ audio_cover_artwork_thumbnail_uri: info.cover_artwork_thumbnail_uri,
1150
+ audio_has_lyrics: info.has_lyrics,
1151
+ audio_is_explicit: info.is_explicit
1141
1152
  };
1142
1153
  }
1143
1154
  function extractPinned(post) {
@@ -1160,6 +1171,7 @@ function parsePostGraphql(post, cfg) {
1160
1171
  owner_id: owner.id ?? owner.pk,
1161
1172
  username: owner.username ?? "",
1162
1173
  fullname: owner.full_name ?? "",
1174
+ user: owner,
1163
1175
  post_id: post.id,
1164
1176
  post_shortcode: post.shortcode,
1165
1177
  post_url: `${cfg.root}/p/${post.shortcode}/`,
@@ -907,6 +907,7 @@ function parsePostRest(post, cfg) {
907
907
  owner_id: owner.pk,
908
908
  username: owner.username ?? "",
909
909
  fullname: owner.full_name ?? "",
910
+ user: owner,
910
911
  post_date: date,
911
912
  date,
912
913
  description: caption ? caption.text : "",
@@ -952,7 +953,7 @@ function parsePostRest(post, cfg) {
952
953
  if (post.music_metadata) {
953
954
  const info = post.music_metadata.music_info;
954
955
  if (info) {
955
- const audio = extractAudio(post, data, { music_asset_info: info }, cfg);
956
+ const audio = extractAudio(post, data, info, cfg);
956
957
  if (audio) {
957
958
  audio.num = items.length;
958
959
  data._files.push(audio);
@@ -1113,11 +1114,16 @@ function extractAudio(src, dest, sticker, cfg) {
1113
1114
  const info = sticker.music_asset_info;
1114
1115
  if (!info) return null;
1115
1116
  const cinfo = sticker.music_consumption_info ?? info;
1116
- dest.audio_title = info.title;
1117
+ dest.audio_title = info.title ?? info.sanitized_title;
1118
+ dest.audio_subtitle = info.subtitle;
1117
1119
  dest.audio_duration = (info.duration_in_ms ?? 0) / 1e3;
1118
1120
  dest.audio_timestamps = info.highlight_start_times_in_ms;
1119
1121
  dest.audio_artist = info.display_artist ?? cinfo.display_artist;
1120
1122
  dest.audio_user = info.ig_artist ?? cinfo.ig_artist;
1123
+ dest.audio_has_lyrics = info.has_lyrics;
1124
+ dest.audio_is_explicit = info.is_explicit;
1125
+ dest.audio_cover_artwork_uri = info.cover_artwork_uri;
1126
+ dest.audio_cover_artwork_thumbnail_uri = info.cover_artwork_thumbnail_uri;
1121
1127
  const url = info.progressive_download_url;
1122
1128
  if (!url) return null;
1123
1129
  return {
@@ -1134,10 +1140,15 @@ function extractAudio(src, dest, sticker, cfg) {
1134
1140
  height_original: 0,
1135
1141
  tagged_users: [],
1136
1142
  audio_user: info.ig_artist ?? cinfo.ig_artist,
1137
- audio_title: info.title,
1143
+ audio_title: info.title ?? info.sanitized_title,
1144
+ audio_subtitle: info.subtitle,
1138
1145
  audio_artist: info.display_artist ?? cinfo.display_artist,
1139
1146
  audio_duration: (info.duration_in_ms ?? 0) / 1e3,
1140
- audio_timestamps: info.highlight_start_times_in_ms
1147
+ audio_timestamps: info.highlight_start_times_in_ms,
1148
+ audio_cover_artwork_uri: info.cover_artwork_uri,
1149
+ audio_cover_artwork_thumbnail_uri: info.cover_artwork_thumbnail_uri,
1150
+ audio_has_lyrics: info.has_lyrics,
1151
+ audio_is_explicit: info.is_explicit
1141
1152
  };
1142
1153
  }
1143
1154
  function extractPinned(post) {
@@ -1160,6 +1171,7 @@ function parsePostGraphql(post, cfg) {
1160
1171
  owner_id: owner.id ?? owner.pk,
1161
1172
  username: owner.username ?? "",
1162
1173
  fullname: owner.full_name ?? "",
1174
+ user: owner,
1163
1175
  post_id: post.id,
1164
1176
  post_shortcode: post.shortcode,
1165
1177
  post_url: `${cfg.root}/p/${post.shortcode}/`,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@chilfish/gallery-dl-instagram",
3
3
  "type": "module",
4
- "version": "0.2.2",
4
+ "version": "0.2.3",
5
5
  "description": "Instagram extraction pipeline — platform-agnostic SDK + CLI",
6
6
  "license": "GPL-2.0-only",
7
7
  "keywords": [