openmates 0.11.0-alpha.29 → 0.11.0-alpha.30

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.
@@ -2915,6 +2915,7 @@ var OpenMatesClient = class _OpenMatesClient {
2915
2915
  content = parseYamlLikeContent(rawContent);
2916
2916
  }
2917
2917
  }
2918
+ content = await this.refreshRemotionVideoCreateContent(embedId, content);
2918
2919
  const strVal = (v) => typeof v === "string" && v.trim() ? v.trim() : null;
2919
2920
  const resolvedType = type ?? strVal(content?.type) ?? null;
2920
2921
  const resolvedAppId = typeof embed.app_id === "string" ? embed.app_id : strVal(content?.app_id) ?? null;
@@ -2930,6 +2931,24 @@ var OpenMatesClient = class _OpenMatesClient {
2930
2931
  createdAt: typeof embed.created_at === "number" ? embed.created_at : null
2931
2932
  };
2932
2933
  }
2934
+ async refreshRemotionVideoCreateContent(embedId, content) {
2935
+ if (!content || content.app_id !== "videos" || content.skill_id !== "create") {
2936
+ return content;
2937
+ }
2938
+ const status = typeof content.status === "string" ? content.status : "";
2939
+ if (!["processing", "rendering", "needs_rerender"].includes(status)) {
2940
+ return content;
2941
+ }
2942
+ const response = await this.http.get(`/v1/videos/remotion/${encodeURIComponent(embedId)}`, this.getCliRequestHeaders());
2943
+ if (!response.ok || !response.data?.content) {
2944
+ return content;
2945
+ }
2946
+ const refreshed = response.data.content;
2947
+ if (refreshed.app_id !== "videos" || refreshed.skill_id !== "create") {
2948
+ return content;
2949
+ }
2950
+ return refreshed;
2951
+ }
2933
2952
  /**
2934
2953
  * Build a slug → DecryptedEmbed index for child embeds of specific parents.
2935
2954
  *
package/dist/cli.js CHANGED
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  getExtForLang,
4
4
  serializeToYaml
5
- } from "./chunk-BCUTLV5E.js";
5
+ } from "./chunk-JQ6D44V5.js";
6
6
  import "./chunk-AXNRPVLE.js";
7
7
  export {
8
8
  getExtForLang,
package/dist/index.d.ts CHANGED
@@ -519,6 +519,7 @@ declare class OpenMatesClient {
519
519
  * hashed_embed_id in the key table = SHA-256(embed.embed_id).
520
520
  */
521
521
  getEmbed(embedIdOrShort: string): Promise<DecryptedEmbed>;
522
+ private refreshRemotionVideoCreateContent;
522
523
  /**
523
524
  * Build a slug → DecryptedEmbed index for child embeds of specific parents.
524
525
  *
package/dist/index.js CHANGED
@@ -7,7 +7,7 @@ import {
7
7
  getExtForLang,
8
8
  parseNewChatSuggestionText,
9
9
  serializeToYaml
10
- } from "./chunk-BCUTLV5E.js";
10
+ } from "./chunk-JQ6D44V5.js";
11
11
  import "./chunk-AXNRPVLE.js";
12
12
  export {
13
13
  MATE_NAMES,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "openmates",
3
- "version": "0.11.0-alpha.29",
3
+ "version": "0.11.0-alpha.30",
4
4
  "description": "OpenMates CLI and SDK",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",