volcano-sdk 0.12.0 → 0.14.0

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: eaa80b61692bb50c4f4dded06c64b7a966ad56bbb398550434dc36697c5637b8
4
- data.tar.gz: 6f6a65a481030da826c9965ce95ebeeff81d4ce7951bf2122eb4ccd4cbf7cce2
3
+ metadata.gz: 622a0435dd5b8a92d9ddfc0a662f5052db23a05edac5a152cafe3c9acd828164
4
+ data.tar.gz: 9a2285451b0abfff42d93e253a42b0471fd3c0094b9702612f0882b5a71b9982
5
5
  SHA512:
6
- metadata.gz: f4f25bab1fb679a7d8797198b7df307b8c004abddfe22aa3e7ad015976e93a2a9c68221c6f594493ac064caa45b67d974bed756c2e6d6eec893ade4de9342caa
7
- data.tar.gz: cfe849efb80bfc79d25969e2b72b501ccd899fed1f8b5d65b52dd6bdd5924cdf771ca36aae305c08adc95a5e295631795ed8724ed854a0dd3c6e1103b3cf551f
6
+ metadata.gz: 1874db8a08a64658af2e7783e7c70d04e3b5833bbc9fce348476dcca1afe6f9a250c08c3673c1558d189169efd17b90c2f5acd70bcb12a04907c1fccfe87ab80
7
+ data.tar.gz: d3b90b7472ef2d541ce96f0254c1bdc18d36388abe6f45f5383a8c32d6c8c9369095dab3e3b4a8e9a5adda61385efb5e07a73d1cf639352dacb835eec9209e32
@@ -36,7 +36,7 @@ module Volcano
36
36
 
37
37
  def database_connection_prefix_end(value)
38
38
  prefix = CONNECTION_URI_PREFIX.match(value)
39
- return prefix.end(0) if prefix && !INVALID_PERCENT_ENCODING.match?(value)
39
+ return prefix.to_s.length if prefix && !INVALID_PERCENT_ENCODING.match?(value)
40
40
 
41
41
  raise ArgumentError,
42
42
  'database_connection_string: base_connection_string is not a valid connection URL',
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Volcano
4
- VERSION = '0.12.0'
4
+ VERSION = '0.14.0'
5
5
  end
@@ -0,0 +1,3 @@
1
+ module Volcano
2
+ def self?.database_connection_string: (String base_connection_string, ?user_id: String?) -> String
3
+ end
data/sig/session.rbs ADDED
@@ -0,0 +1,26 @@
1
+ module Volcano
2
+ type json_value = nil | bool | Integer | Float | String | Array[json_value] | Hash[String, json_value]
3
+ type session_input = nil | bool | Integer | Float | String | Symbol | Time | Array[session_input] | Hash[String | Symbol, session_input]
4
+ type session_user_input = Hash[String, session_input] | Hash[Symbol, session_input] | Hash[String | Symbol, session_input]
5
+
6
+ class Session < Data
7
+ attr_reader access_token: String
8
+ attr_reader refresh_token: String?
9
+ attr_reader user_id: String?
10
+ attr_reader user: Hash[String, json_value]?
11
+
12
+ def self.new: (String access_token, ?String? refresh_token, ?String? user_id, ?session_user_input? user) -> Session
13
+ | (access_token: String, ?refresh_token: String?, ?user_id: String?, ?user: session_user_input?) -> Session
14
+ def self.[]: (String access_token, ?String? refresh_token, ?String? user_id, ?session_user_input? user) -> Session
15
+ | (access_token: String, ?refresh_token: String?, ?user_id: String?, ?user: session_user_input?) -> Session
16
+ def self.members: () -> [:access_token, :refresh_token, :user_id, :user]
17
+
18
+ def initialize: (access_token: String, ?refresh_token: String?, ?user_id: String?, ?user: session_user_input?) -> void
19
+ def members: () -> [:access_token, :refresh_token, :user_id, :user]
20
+ def with: (?access_token: String, ?refresh_token: String?, ?user_id: String?, ?user: session_user_input?) -> Session
21
+ def to_h: () -> { access_token: String, refresh_token: String?, user_id: String?, user: Hash[String, json_value]? }
22
+ | [K, V] () { (Symbol, String | Hash[String, json_value] | nil) -> [K, V] } -> Hash[K, V]
23
+ def deconstruct: () -> [String, String?, String?, Hash[String, json_value]?]
24
+ def deconstruct_keys: (Array[Symbol]?) -> Hash[Symbol, String | Hash[String, json_value] | nil]
25
+ end
26
+ end
@@ -0,0 +1,21 @@
1
+ module Volcano
2
+ class SignUpResult < Data
3
+ attr_reader confirmation_required: bool
4
+ attr_reader message: String
5
+ attr_reader session: Session?
6
+
7
+ def self.new: (bool confirmation_required, String message, ?Session? session) -> SignUpResult
8
+ | (confirmation_required: bool, message: String, ?session: Session?) -> SignUpResult
9
+ def self.[]: (bool confirmation_required, String message, ?Session? session) -> SignUpResult
10
+ | (confirmation_required: bool, message: String, ?session: Session?) -> SignUpResult
11
+ def self.members: () -> [:confirmation_required, :message, :session]
12
+
13
+ def initialize: (confirmation_required: bool, message: String, ?session: Session?) -> void
14
+ def members: () -> [:confirmation_required, :message, :session]
15
+ def with: (?confirmation_required: bool, ?message: String, ?session: Session?) -> SignUpResult
16
+ def to_h: () -> { confirmation_required: bool, message: String, session: Session? }
17
+ | [K, V] () { (Symbol, bool | String | Session?) -> [K, V] } -> Hash[K, V]
18
+ def deconstruct: () -> [bool, String, Session?]
19
+ def deconstruct_keys: (Array[Symbol]?) -> Hash[Symbol, bool | String | Session?]
20
+ end
21
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: volcano-sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.12.0
4
+ version: 0.14.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kong
@@ -603,7 +603,10 @@ files:
603
603
  - lib/volcano/transport.rb
604
604
  - lib/volcano/user.rb
605
605
  - lib/volcano/version.rb
606
+ - sig/connection_string.rbs
606
607
  - sig/errors.rbs
608
+ - sig/session.rbs
609
+ - sig/sign_up_result.rbs
607
610
  homepage: https://github.com/Kong/volcano-sdk-ruby
608
611
  licenses:
609
612
  - Apache-2.0