stytch 7.6.0 → 7.7.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/stytch/b2b_client.rb +3 -1
- data/lib/stytch/b2b_organizations.rb +9 -0
- data/lib/stytch/client.rb +3 -1
- data/lib/stytch/project.rb +26 -0
- data/lib/stytch/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 596a877d7f9b69bdba72760f0fa015ff8d2c9e5a70959b52bcad95f1717aecee
|
4
|
+
data.tar.gz: 11d3704cb3e3f1d984fb1242d9219a85620d630c1a668e56b10f6a19561c6183
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ca380834e2a6f3d6d6f13b99bdad4462b71cbeff12951c062bb32206ff462cd6a91957ba6c4391bb0de399b007d18ecfee1000312dcff22fd163bb48f8e0d50d
|
7
|
+
data.tar.gz: 5bc2d485ec0ff81b44393552668407abf09f12dae3464caa7bc4bb0329ab29acb3431590ca591e8790c8c36a25cf8fa18afbb63fc0d1853b308239e6cc2321e3
|
data/lib/stytch/b2b_client.rb
CHANGED
@@ -13,13 +13,14 @@ require_relative 'b2b_sessions'
|
|
13
13
|
require_relative 'b2b_sso'
|
14
14
|
require_relative 'b2b_totps'
|
15
15
|
require_relative 'm2m'
|
16
|
+
require_relative 'project'
|
16
17
|
require_relative 'rbac_local'
|
17
18
|
|
18
19
|
module StytchB2B
|
19
20
|
class Client
|
20
21
|
ENVIRONMENTS = %i[live test].freeze
|
21
22
|
|
22
|
-
attr_reader :discovery, :m2m, :magic_links, :oauth, :otps, :organizations, :passwords, :rbac, :recovery_codes, :scim, :sso, :sessions, :totps
|
23
|
+
attr_reader :discovery, :m2m, :magic_links, :oauth, :otps, :organizations, :passwords, :project, :rbac, :recovery_codes, :scim, :sso, :sessions, :totps
|
23
24
|
|
24
25
|
def initialize(project_id:, secret:, env: nil, &block)
|
25
26
|
@api_host = api_host(env, project_id)
|
@@ -38,6 +39,7 @@ module StytchB2B
|
|
38
39
|
@otps = StytchB2B::OTPs.new(@connection)
|
39
40
|
@organizations = StytchB2B::Organizations.new(@connection)
|
40
41
|
@passwords = StytchB2B::Passwords.new(@connection)
|
42
|
+
@project = Stytch::Project.new(@connection)
|
41
43
|
@rbac = StytchB2B::RBAC.new(@connection)
|
42
44
|
@recovery_codes = StytchB2B::RecoveryCodes.new(@connection)
|
43
45
|
@scim = StytchB2B::SCIM.new(@connection)
|
@@ -500,6 +500,15 @@ module StytchB2B
|
|
500
500
|
post_request('/v1/b2b/organizations/search', request, headers)
|
501
501
|
end
|
502
502
|
|
503
|
+
def metrics(
|
504
|
+
organization_id:
|
505
|
+
)
|
506
|
+
headers = {}
|
507
|
+
query_params = {}
|
508
|
+
request = request_with_query_params("/v1/b2b/organizations/#{organization_id}/metrics", query_params)
|
509
|
+
get_request(request, headers)
|
510
|
+
end
|
511
|
+
|
503
512
|
class Members
|
504
513
|
include Stytch::RequestHelper
|
505
514
|
attr_reader :oauth_providers
|
data/lib/stytch/client.rb
CHANGED
@@ -6,6 +6,7 @@ require_relative 'magic_links'
|
|
6
6
|
require_relative 'oauth'
|
7
7
|
require_relative 'otps'
|
8
8
|
require_relative 'passwords'
|
9
|
+
require_relative 'project'
|
9
10
|
require_relative 'sessions'
|
10
11
|
require_relative 'totps'
|
11
12
|
require_relative 'users'
|
@@ -15,7 +16,7 @@ module Stytch
|
|
15
16
|
class Client
|
16
17
|
ENVIRONMENTS = %i[live test].freeze
|
17
18
|
|
18
|
-
attr_reader :crypto_wallets, :m2m, :magic_links, :oauth, :otps, :passwords, :sessions, :totps, :users, :webauthn
|
19
|
+
attr_reader :crypto_wallets, :m2m, :magic_links, :oauth, :otps, :passwords, :project, :sessions, :totps, :users, :webauthn
|
19
20
|
|
20
21
|
def initialize(project_id:, secret:, env: nil, &block)
|
21
22
|
@api_host = api_host(env, project_id)
|
@@ -30,6 +31,7 @@ module Stytch
|
|
30
31
|
@oauth = Stytch::OAuth.new(@connection)
|
31
32
|
@otps = Stytch::OTPs.new(@connection)
|
32
33
|
@passwords = Stytch::Passwords.new(@connection)
|
34
|
+
@project = Stytch::Project.new(@connection)
|
33
35
|
@sessions = Stytch::Sessions.new(@connection, @project_id)
|
34
36
|
@totps = Stytch::TOTPs.new(@connection)
|
35
37
|
@users = Stytch::Users.new(@connection)
|
@@ -0,0 +1,26 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# !!!
|
4
|
+
# WARNING: This file is autogenerated
|
5
|
+
# Only modify code within MANUAL() sections
|
6
|
+
# or your changes may be overwritten later!
|
7
|
+
# !!!
|
8
|
+
|
9
|
+
require_relative 'request_helper'
|
10
|
+
|
11
|
+
module Stytch
|
12
|
+
class Project
|
13
|
+
include Stytch::RequestHelper
|
14
|
+
|
15
|
+
def initialize(connection)
|
16
|
+
@connection = connection
|
17
|
+
end
|
18
|
+
|
19
|
+
def metrics
|
20
|
+
headers = {}
|
21
|
+
query_params = {}
|
22
|
+
request = request_with_query_params('/v1/projects/metrics', query_params)
|
23
|
+
get_request(request, headers)
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
data/lib/stytch/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: stytch
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 7.
|
4
|
+
version: 7.7.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- stytch
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-04-
|
11
|
+
date: 2024-04-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|
@@ -147,6 +147,7 @@ files:
|
|
147
147
|
- lib/stytch/oauth.rb
|
148
148
|
- lib/stytch/otps.rb
|
149
149
|
- lib/stytch/passwords.rb
|
150
|
+
- lib/stytch/project.rb
|
150
151
|
- lib/stytch/rbac_local.rb
|
151
152
|
- lib/stytch/request_helper.rb
|
152
153
|
- lib/stytch/sessions.rb
|