runapi-runway-aleph 0.2.4 → 0.2.5

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: f9cd72262bb14fb7ac29abeb66862282450a02f228d38be91beb26c8d7394b01
4
- data.tar.gz: 87e765ef46036b6ad3c7d3b7f0ab7521bd0655522a31868eb6f6fe7d6cfa1347
3
+ metadata.gz: 56167311723e82f55c4fb956d06b4341f787b73b69a107e12e22d318ecd8366e
4
+ data.tar.gz: 93d5a544147ec1d698971b76ca604926ccd391585ff149c5685e7cb3ea391b71
5
5
  SHA512:
6
- metadata.gz: edeb73e9ee44afb57f8fd39e28462359a24a4176e506936ed2a0129ca457cf9d8960724c1f617d7419e50befba5b676b6af9ab8be139ecb34768443c4a027741
7
- data.tar.gz: b4540434bdb476866a15e98b3f5edfcd9e2cd586f2fa3f1879ac256b25ca98f5404ad2f4bfa27fa26fc8f4c2a17d748d7e35756fff95b368a1b05660efcb4995
6
+ metadata.gz: 7564b5a2e8bcd99e638505fbcf55d87c51ac77c5b2f91a8d8e28b9a4af51acc833167cc8505e6e8dd0f83ed8e0a158602ad7b4e1e8f520ec2b5c9d83967dd44e
7
+ data.tar.gz: b63e2ba44057ea67f67fea3bf7f58aa5724979170b300edc8c7c53f5285196b4125b10d641d8e4f0651e264aae0d1a36eff0765074e2c9f48bdaa0aa40ad6713
data/README.md ADDED
@@ -0,0 +1,45 @@
1
+ # Runway Aleph API Ruby SDK for RunAPI
2
+
3
+ The runway aleph api Ruby SDK is the language-specific package for Runway Aleph on RunAPI. Use this runway aleph api package for prompt-guided video editing when your application needs JSON request bodies, task status lookup, and consistent RunAPI errors in Ruby.
4
+
5
+ This runway aleph api README is the Ruby package guide inside the public `runway-aleph-sdk` repository. For the repository overview, start at `../README.md`; for model details, use https://runapi.ai/models/runway-aleph; for API reference, use https://runapi.ai/docs#runway-aleph; for SDK docs, use https://runapi.ai/docs#sdk-runway-aleph.
6
+
7
+ ## Install
8
+
9
+ ```bash
10
+ gem install runapi-runway_aleph
11
+ ```
12
+
13
+ ## Quick start
14
+
15
+ ```ruby
16
+ require "runapi-runway_aleph"
17
+
18
+ client = RunApi::RunwayAleph::Client.new
19
+ task = client.edit_video.create(
20
+ model: "runway-aleph",
21
+ prompt: "Transform the scene into a watercolor painting style",
22
+ video_url: "https://cdn.runapi.ai/public/samples/video.mp4"
23
+ )
24
+ status = client.edit_video.get(task.id)
25
+ ```
26
+
27
+ Use `create` when you want to submit a task and return quickly, `get` when you need the latest task state, and `run` when a script should create and poll until completion. In web request handlers, prefer `create` plus webhook or later `get` polling so a worker is not held open.
28
+
29
+ ## Language notes
30
+
31
+ Use Ruby keyword arguments and the `RunApi::RunwayAleph` error classes when building video jobs, Rails workers, or scripts. Keep `RUNAPI_API_KEY` in the environment or your secret manager; never commit API keys or callback secrets.
32
+
33
+ ## Links
34
+
35
+ - Model page: https://runapi.ai/models/runway-aleph
36
+ - SDK docs: https://runapi.ai/docs#sdk-runway-aleph
37
+ - Product docs: https://runapi.ai/docs#runway-aleph
38
+ - Pricing and rate limits: https://runapi.ai/models/runway-aleph
39
+ - Provider comparison: https://runapi.ai/providers/runway
40
+ - Full catalog: https://runapi.ai/models
41
+ - Repository: https://github.com/runapi-ai/runway-aleph-sdk
42
+
43
+ ## License
44
+
45
+ Licensed under the Apache License, Version 2.0.
@@ -3,14 +3,14 @@
3
3
  module RunApi
4
4
  module RunwayAleph
5
5
  class Client
6
- attr_reader :video_to_video
6
+ attr_reader :edit_video
7
7
 
8
8
  def initialize(api_key: nil, **options)
9
9
  @api_key = Core::Auth.resolve_api_key(api_key)
10
10
 
11
11
  client_options = Core::ClientOptions.new(api_key: @api_key, **options)
12
12
  http = client_options.http_client || Core::HttpClient.new(client_options)
13
- @video_to_video = Resources::VideoToVideo.new(http)
13
+ @edit_video = Resources::EditVideo.new(http)
14
14
  end
15
15
  end
16
16
  end
@@ -3,12 +3,12 @@
3
3
  module RunApi
4
4
  module RunwayAleph
5
5
  module Resources
6
- class VideoToVideo
6
+ class EditVideo
7
7
  include RunApi::Core::ResourceHelpers
8
8
 
9
- ENDPOINT = "/api/v1/runway_aleph/video_to_video"
9
+ ENDPOINT = "/api/v1/runway_aleph/edit_video"
10
10
  RESPONSE_CLASS = Types::TaskCreateResponse
11
- COMPLETED_RESPONSE_CLASS = Types::CompletedVideoToVideoResponse
11
+ COMPLETED_RESPONSE_CLASS = Types::CompletedEditVideoResponse
12
12
 
13
13
  def initialize(http)
14
14
  @http = http
@@ -33,7 +33,7 @@ module RunApi
33
33
 
34
34
  def validate_params!(params)
35
35
  raise Core::ValidationError, "prompt is required" unless param(params, :prompt)
36
- raise Core::ValidationError, "video_url is required" unless param(params, :video_url)
36
+ raise Core::ValidationError, "source_video_url is required" unless param(params, :source_video_url)
37
37
  validate_optional!(params, :aspect_ratio, Types::ASPECT_RATIOS)
38
38
  end
39
39
  end
@@ -10,19 +10,22 @@ module RunApi
10
10
  required :url, String
11
11
  end
12
12
 
13
- class VideoToVideoResponse < RunApi::Core::TaskResponse
13
+ class Image < RunApi::Core::BaseModel
14
+ required :url, String
15
+ end
16
+
17
+ class EditVideoResponse < RunApi::Core::TaskResponse
14
18
  required :id, String
15
19
  optional :status, String, enum: -> { RunApi::Core::TaskResponse::Status::ALL }
16
- optional :videos, [ -> { Video } ]
17
- optional :image_url, String
18
- optional :parent_task_id, String
20
+ optional :videos, [-> { Video }]
21
+ optional :images, [-> { Image }]
19
22
  optional :error, String
20
23
  end
21
24
 
22
- class TaskCreateResponse < VideoToVideoResponse; end
25
+ class TaskCreateResponse < EditVideoResponse; end
23
26
 
24
- class CompletedVideoToVideoResponse < VideoToVideoResponse
25
- required :videos, [ -> { Video } ]
27
+ class CompletedEditVideoResponse < EditVideoResponse
28
+ required :videos, [-> { Video }]
26
29
  end
27
30
  end
28
31
  end
@@ -2,7 +2,7 @@
2
2
 
3
3
  require "runapi/core"
4
4
  require_relative "runway_aleph/types"
5
- require_relative "runway_aleph/resources/video_to_video"
5
+ require_relative "runway_aleph/resources/edit_video"
6
6
  require_relative "runway_aleph/client"
7
7
 
8
8
  module RunApi
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: runapi-runway-aleph
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.4
4
+ version: 0.2.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - RunAPI
@@ -15,33 +15,38 @@ dependencies:
15
15
  requirements:
16
16
  - - "~>"
17
17
  - !ruby/object:Gem::Version
18
- version: 0.2.4
18
+ version: 0.2.5
19
19
  type: :runtime
20
20
  prerelease: false
21
21
  version_requirements: !ruby/object:Gem::Requirement
22
22
  requirements:
23
23
  - - "~>"
24
24
  - !ruby/object:Gem::Version
25
- version: 0.2.4
26
- description: RunAPI Runway Aleph SDK for JavaScript, Ruby, and Go
25
+ version: 0.2.5
26
+ description: The runway aleph api Ruby SDK is the language-specific package for Runway
27
+ Aleph on RunAPI. Use this runway aleph api package for prompt-guided video editing
28
+ when your application needs JSON request bodies, task status lookup, and consistent
29
+ RunAPI errors in Ruby.
27
30
  email:
28
31
  - support@runapi.ai
29
32
  executables: []
30
33
  extensions: []
31
- extra_rdoc_files: []
34
+ extra_rdoc_files:
35
+ - README.md
32
36
  files:
33
37
  - LICENSE
38
+ - README.md
34
39
  - lib/runapi-runway_aleph.rb
35
40
  - lib/runapi/runway_aleph.rb
36
41
  - lib/runapi/runway_aleph/client.rb
37
- - lib/runapi/runway_aleph/resources/video_to_video.rb
42
+ - lib/runapi/runway_aleph/resources/edit_video.rb
38
43
  - lib/runapi/runway_aleph/types.rb
39
44
  homepage: https://runapi.ai/models/runway-aleph
40
45
  licenses:
41
46
  - Apache-2.0
42
47
  metadata:
43
48
  homepage_uri: https://runapi.ai/models/runway-aleph
44
- documentation_uri: https://github.com/runapi-ai/runway-aleph-sdk/blob/main/README.md
49
+ documentation_uri: https://github.com/runapi-ai/runway-aleph-sdk/blob/main/ruby/README.md
45
50
  source_code_uri: https://github.com/runapi-ai/runway-aleph-sdk
46
51
  changelog_uri: https://github.com/runapi-ai/runway-aleph-sdk/blob/main/CHANGELOG.md
47
52
  rdoc_options: []
@@ -60,5 +65,5 @@ required_rubygems_version: !ruby/object:Gem::Requirement
60
65
  requirements: []
61
66
  rubygems_version: 4.0.10
62
67
  specification_version: 4
63
- summary: Runway Aleph API SDKs for JavaScript, Ruby, and Go on RunAPI.
68
+ summary: Runway Aleph API Ruby SDK for RunAPI
64
69
  test_files: []