runapi-flux-kontext 0.2.5 → 0.2.6

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: 9ca7b5863c0ddfe15a6fe0f308e1098494cede66606aff70563003379d53e127
4
- data.tar.gz: abc26292fc5b3debd3048e39c2a9388eeb656b9cb75f11ba61e55483494eb5dc
3
+ metadata.gz: a7a15941bf71d6217337b7d0dfa6b1136a57f2f9763c24b3a1d4aed5533d8278
4
+ data.tar.gz: 0b126bee144555fba38ffe81675fdbef5933c3eb21017e54c70e86cf75a2c96f
5
5
  SHA512:
6
- metadata.gz: 839a8767907dd6ed7a1c19a87d86c0145a5d5f2e9739ff8a0ebecddf65bfb750701156522edaf7f40e373905603b00b25a2d2bdaeb5b1828922a215127d6d9bb
7
- data.tar.gz: d85d4b53ee990810bd516fe8fe1bcddd4e5d0d9848c02e648642fc0a68682f2264e7874bf199c14e90e00d450210888fb56cdda5bf5172e6ef5dcdf0dc843b7a
6
+ metadata.gz: 43a7d9be562a0877a517d0a36fe7c485f82e6ea543443787fc158721de1e968661108d0f6875a61da7e115856987384f1c9bb254f7ee239ac10b4458d5ca515c
7
+ data.tar.gz: 9c441b767fb721514c06266d43a3198599c27ac597b79c7cac0c8b0e630766844221a0b9f00d99d8363c5e1e38eca88ebc3d37f8272f9a74c90453ab0fa51723
data/README.md CHANGED
@@ -24,6 +24,8 @@ status = client.generations.get(task.id)
24
24
 
25
25
  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.
26
26
 
27
+ RunAPI-generated file URLs are temporary. Download and store generated images, videos, audio, or other files in your own durable storage within 7 days; do not treat returned URLs as long-term assets.
28
+
27
29
  ## Language notes
28
30
 
29
31
  Use Ruby keyword arguments and the `RunApi::FluxKontext` error classes when building image jobs, Rails workers, or scripts. The available resources include generations. Keep `RUNAPI_API_KEY` in the environment or your secret manager; never commit API keys or callback secrets.
@@ -2,22 +2,22 @@
2
2
 
3
3
  module RunApi
4
4
  module FluxKontext
5
- # Flux Kontext image generation API client.
5
+ # Flux Kontext image generation and editing API client.
6
+ #
7
+ # Supports pure text-to-image generation and image editing via
8
+ # source_image_url. Pro and max quality tiers available.
6
9
  #
7
10
  # @example
8
11
  # client = RunApi::FluxKontext::Client.new(api_key: "your-api-key")
9
12
  # result = client.text_to_image.run(
10
13
  # model: "flux-kontext-pro", prompt: "A futuristic cityscape"
11
14
  # )
12
- class Client
15
+ class Client < RunApi::Core::Client
13
16
  # @return [Resources::TextToImage] Image generation operations.
14
17
  attr_reader :text_to_image
15
18
 
16
19
  def initialize(api_key: nil, **options)
17
- @api_key = Core::Auth.resolve_api_key(api_key)
18
-
19
- client_options = Core::ClientOptions.new(api_key: @api_key, **options)
20
- http = client_options.http_client || Core::HttpClient.new(client_options)
20
+ super
21
21
  @text_to_image = Resources::TextToImage.new(http)
22
22
  end
23
23
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: runapi-flux-kontext
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.5
4
+ version: 0.2.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - RunAPI
@@ -15,14 +15,14 @@ dependencies:
15
15
  requirements:
16
16
  - - "~>"
17
17
  - !ruby/object:Gem::Version
18
- version: 0.2.5
18
+ version: 0.2.6
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.5
25
+ version: 0.2.6
26
26
  description: The flux kontext api Ruby SDK is the language-specific package for Flux
27
27
  Kontext on RunAPI. Use this flux kontext api package for text-to-image, image editing,
28
28
  and creative production flows when your application needs JSON request bodies, task