pika_sdk 0.2.0 → 0.2.2

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: f985e61fa1c2e22769641a1f921ab539bef8572a042128097daa3463658a9d92
4
- data.tar.gz: d9660b2175c777320ddeee3a22dcc7ac50737ed6399295f8789aa8aca16afad8
3
+ metadata.gz: 761d54b607516e99b86b18976893c99aa08c0443a24406202f7fe1e24f17bf6e
4
+ data.tar.gz: 8b3ca1c82b99e4d6519cdadc267c2dad3ed515124f91a249d9daf4c21cd43889
5
5
  SHA512:
6
- metadata.gz: 581bb27999e356b902858a85ba1dee5e2b5cdf08be4262b314c95d85e69d6cdac5b9ee90b13f5ef66ee3878cbe39fa5ca468046cfecbb2bd381ec638d6ee649a
7
- data.tar.gz: b0ba5c4ff79bf8bb5e78a43d1e9941b7bb88021a232ccbe2c67ffc07aec5af6b83b93790771fe385b56c9fef781c5c7c741c2b87389329a9794a34bd4e17dfe5
6
+ metadata.gz: 1bff87e3d33fdcdbca018763d374b8504d182c7686391692e8c991e684df408d14e4d3348951c25c8e33fe73dffdb2588a67d9837c588222a2c7a3c599345b20
7
+ data.tar.gz: b95bbd4eaa4e58ed74d27fc40bf35a3f4dadb550f22ac2f1f36162a2755d05529e9f9439d79c34bf75f9e5d8a09f4bd925670f23da8da26da8513411690e2621
data/README.md CHANGED
@@ -1,4 +1,6 @@
1
- # PikaApi
1
+ # Pika API Ruby Gem
2
+
3
+ View on Rubygems: [rubygems.org/gems/pika_sdk](https://rubygems.org/gems/pika_sdk)
2
4
 
3
5
  ## Installation
4
6
 
@@ -18,9 +20,9 @@ Or install it yourself as:
18
20
 
19
21
  ## Usage
20
22
 
21
- ### Generate image
23
+ If you don't have your API key, get one from [pika.style](https://pika.style/pricing). Check the documentation on [how to get your API key](https://docs.pika.style/docs/basics/getting-api-key)
22
24
 
23
- Initialise a client
25
+ ### Initialise a client
24
26
 
25
27
  ```ruby
26
28
  require 'pika_sdk'
@@ -28,18 +30,16 @@ require 'pika_sdk'
28
30
  client = PikaSdk::Client.new('sk-he2jdus1cbz1dpt4mktgjyvx')
29
31
  ```
30
32
 
31
- If you don't have your API key, get one from [Pika.style](https://pika.style).
32
-
33
- Check the documentation on [How to get your API key](https://docs.pika.style/docs/basics/getting-api-key).
33
+ ### Generate image
34
34
 
35
35
  ```ruby
36
36
  response = client.generate_image_from_template('open-graph-image-1', {'title': 'From python sdk new'}, 'base64')
37
37
  puts response['data']['base64']
38
38
  ```
39
39
 
40
- **Example:**
40
+ ## Example
41
41
 
42
- `Base64` response format.
42
+ ### `Base64` response format
43
43
 
44
44
  ```ruby
45
45
  require 'pika_sdk'
@@ -56,7 +56,7 @@ Base64 output
56
56
  data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAABLAAAAJ2CAYAAABPQHtcAAAAAXNSR0IArs4c6QAAIABJREFUeJzs3XmYJXdZL/Bvna37dM90FghLCBAQkC1BCBAMShLFBJAgKnofroBeFUUF5LrhiihXcV8BQRYVUUAlIewIGPbFmLCFLWwCYZEtzPR+trp/TM/......
57
57
  ```
58
58
 
59
- `Binary` response format.
59
+ ### `Binary` response format
60
60
 
61
61
  ```ruby
62
62
  require 'pika_sdk'
@@ -70,7 +70,7 @@ File.open("og.png", "w") do |file|
70
70
  end
71
71
  ```
72
72
 
73
- This example writes the binary image to the file `og.png`.
73
+ This example writes the binary image to the file `og.png`
74
74
 
75
75
  ## generate_image_from_template
76
76
 
@@ -82,7 +82,7 @@ Use this function to generate an image. It takes in 3 arguments
82
82
  |`modifications` | Yes | Modifications for the selected template. |
83
83
  |`response_format` | No | `base64` or `binary` (Defaults to `base64`). |
84
84
 
85
- For available templates and it's modifications refer [image generation api templates](https://pika.style/image-generation-api/templates).
85
+ For available templates and their modifications refer [image generation api templates](https://pika.style/image-generation-api/templates)
86
86
 
87
87
  ## Development
88
88
 
@@ -1,3 +1,3 @@
1
1
  module PikaSdk
2
- VERSION = "0.2.0"
2
+ VERSION = "0.2.2"
3
3
  end
data/pika_sdk.gemspec CHANGED
@@ -11,7 +11,7 @@ Gem::Specification.new do |spec|
11
11
 
12
12
  spec.summary = "Pika API sdk for ruby"
13
13
  spec.description = "Pika API sdk for ruby"
14
- spec.homepage = "https://github.com/rishimohan/pika-api-ruby-gem"
14
+ spec.homepage = "https://pika.style/image-generation-api"
15
15
  spec.license = "MIT"
16
16
 
17
17
  # Prevent pushing this gem to RubyGems.org. To allow pushes either set the 'allowed_push_host'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pika_sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - rishimohan
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-01-12 00:00:00.000000000 Z
11
+ date: 2024-02-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -72,12 +72,12 @@ files:
72
72
  - lib/pika_sdk/client.rb
73
73
  - lib/pika_sdk/version.rb
74
74
  - pika_sdk.gemspec
75
- homepage: https://github.com/rishimohan/pika-api-ruby-gem
75
+ homepage: https://pika.style/image-generation-api
76
76
  licenses:
77
77
  - MIT
78
78
  metadata:
79
79
  allowed_push_host: https://rubygems.org/
80
- homepage_uri: https://github.com/rishimohan/pika-api-ruby-gem
80
+ homepage_uri: https://pika.style/image-generation-api
81
81
  source_code_uri: https://github.com/rishimohan/pika-api-ruby-gem
82
82
  changelog_uri: https://github.com/rishimohan/pika-api-ruby-gem
83
83
  post_install_message: