svix 0.63.1 → 0.64.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: fcbe8ea23c6073921b4ed822f0b23a350034ad19a117f2fc7dd6be18a202a9b2
4
- data.tar.gz: aec1bc7b535b3ae50e3317091369eb74df40ca37b8cd8abd7dedd67d6c1fe0da
3
+ metadata.gz: bdd8b8a684e7dba8c2565037728cae3b023244cd741df289e222c7191be3d23f
4
+ data.tar.gz: bd04508ca0fd09443a92bc71f5b9bf11487977fefad03a56dbb1c45b8efec666
5
5
  SHA512:
6
- metadata.gz: a03bfe51e2c3bf79c3123b41b5ed646bf29b978a65540cdea72f648ed1582b0f0003ef8c504b878cff1767fca76bdb5219609743161fe9e19ebff200b23c7cb1
7
- data.tar.gz: 0bbc68fd569ec88033b80e520c91e84b2279c0eab7c79b61980f595d4e53f0f0b49bc3b76ab307bf234e2e1a2f2171cf2f6e40089e42d398340eda9ab6487721
6
+ metadata.gz: e2d9b915ecba49ff062f91f83d1039e8fd3787bafa0aaf1ff6e78d25e7a07bb852dd9f18894c4a25169c65ad278cd8c861005b20486be5ada1cfb58546646576
7
+ data.tar.gz: 83d1a499818993f62d5c856fe1b820943fa23e2ddd6fae991a728ebe1f1f194d1457dae2c1f7c7e6de89f74626b7a47338f1fb9de09477290dbf1ce5c248dbd6
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- svix (0.63.1)
4
+ svix (0.64.0)
5
5
  typhoeus (~> 1.0, >= 1.0.1)
6
6
 
7
7
  GEM
data/lib/svix/svix.rb CHANGED
@@ -21,7 +21,18 @@ module Svix
21
21
  attr_accessor :message_attempt
22
22
 
23
23
  def initialize(auth_token, options = SvixOptions.new)
24
- uri = URI(options.server_url)
24
+
25
+ regional_url = nil
26
+ region = auth_token.split(".").last
27
+ if region == "us"
28
+ regional_url = "https://api.us.svix.com"
29
+ elsif region == "eu"
30
+ regional_url = "https://api.eu.svix.com"
31
+ elsif region == "in"
32
+ regional_url = "https://api.in.svix.com"
33
+ end
34
+
35
+ uri = URI(options.server_url || regional_url)
25
36
 
26
37
  configuration = Configuration.new
27
38
  configuration.debugging = options.debug
data/lib/svix/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Svix
4
- VERSION = "0.63.1"
4
+ VERSION = "0.64.0"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: svix
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.63.1
4
+ version: 0.64.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Svix
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-07-13 00:00:00.000000000 Z
11
+ date: 2022-07-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus