Class: StytchB2B::SCIM::Connections
- Inherits:
-
Object
- Object
- StytchB2B::SCIM::Connections
- Includes:
- Stytch::RequestHelper
- Defined in:
- lib/stytch/b2b_scim.rb
Instance Method Summary collapse
-
#create(organization_id:, display_name: nil, identity_provider: nil) ⇒ Object
Create a new SCIM Connection.
-
#delete(organization_id:, connection_id:) ⇒ Object
Deletes a SCIM Connection.
-
#get(organization_id:) ⇒ Object
Get SCIM Connections.
-
#initialize(connection) ⇒ Connections
constructor
A new instance of Connections.
-
#rotate_cancel(organization_id:, connection_id:) ⇒ Object
Cancel a SCIM token rotation.
-
#rotate_complete(organization_id:, connection_id:) ⇒ Object
Completes a SCIM token rotation.
-
#rotate_start(organization_id:, connection_id:) ⇒ Object
Start a SCIM token rotation.
-
#update(organization_id:, connection_id:, display_name: nil, identity_provider: nil, scim_group_implicit_role_assignments: nil) ⇒ Object
Update a SCIM Connection.
Methods included from Stytch::RequestHelper
#delete_request, #get_request, #post_request, #put_request, #request_with_query_params
Constructor Details
#initialize(connection) ⇒ Connections
Returns a new instance of Connections.
25 26 27 |
# File 'lib/stytch/b2b_scim.rb', line 25 def initialize(connection) @connection = connection end |
Instance Method Details
#create(organization_id:, display_name: nil, identity_provider: nil) ⇒ Object
Create a new SCIM Connection. /%}
Parameters:
- organization_id
-
Globally unique UUID that identifies a specific Organization. The ‘organization_id` is critical to perform operations on an Organization, so be sure to preserve this value. The type of this field is
String
. - display_name
-
A human-readable display name for the connection. The type of this field is nilable
String
. - identity_provider
-
(no documentation yet) The type of this field is nilable
CreateRequestIdp
(string enum).
Returns:
An object with the following fields:
- request_id
-
Globally unique UUID that is returned with every API call. This value is important to log for debugging purposes; we may ask for this value to help identify a specific API call when helping you debug an issue. The type of this field is
String
. - status_code
-
The HTTP status code of the response. Stytch follows standard HTTP response status code patterns, e.g. 2XX values equate to success, 3XX values are redirects, 4XX are client errors, and 5XX are server errors. The type of this field is
Integer
. - connection
-
The ‘SCIM Connection` object affected by this API call. See the [SCIM Connection Object](stytch.com/docs/b2b/api/scim-connection-object) for complete response field details. The type of this field is nilable
SCIMConnectionWithToken
(object
).
221 222 223 224 225 226 227 228 229 230 231 232 |
# File 'lib/stytch/b2b_scim.rb', line 221 def create( organization_id:, display_name: nil, identity_provider: nil ) headers = {} request = {} request[:display_name] = display_name unless display_name.nil? request[:identity_provider] = identity_provider unless identity_provider.nil? post_request("/v1/b2b/scim/#{organization_id}/connections", request, headers) end |
#delete(organization_id:, connection_id:) ⇒ Object
Deletes a SCIM Connection. /%}
Parameters:
- organization_id
-
Globally unique UUID that identifies a specific Organization. The ‘organization_id` is critical to perform operations on an Organization, so be sure to preserve this value. The type of this field is
String
. - connection_id
-
Globally unique UUID that identifies a specific SSO ‘connection_id` for a Member. The type of this field is
String
.
Returns:
An object with the following fields:
- request_id
-
Globally unique UUID that is returned with every API call. This value is important to log for debugging purposes; we may ask for this value to help identify a specific API call when helping you debug an issue. The type of this field is
String
. - connection_id
-
The ‘connection_id` that was deleted as part of the delete request. The type of this field is
String
. - status_code
-
The HTTP status code of the response. Stytch follows standard HTTP response status code patterns, e.g. 2XX values equate to success, 3XX values are redirects, 4XX are client errors, and 5XX are server errors. The type of this field is
Integer
.
96 97 98 99 100 101 102 |
# File 'lib/stytch/b2b_scim.rb', line 96 def delete( organization_id:, connection_id: ) headers = {} delete_request("/v1/b2b/scim/#{organization_id}/connections/#{connection_id}", headers) end |
#get(organization_id:) ⇒ Object
Get SCIM Connections. /%}
Parameters:
- organization_id
-
Globally unique UUID that identifies a specific Organization. The ‘organization_id` is critical to perform operations on an Organization, so be sure to preserve this value. The type of this field is
String
.
Returns:
An object with the following fields:
- request_id
-
Globally unique UUID that is returned with every API call. This value is important to log for debugging purposes; we may ask for this value to help identify a specific API call when helping you debug an issue. The type of this field is
String
. - connections
-
(no documentation yet) The type of this field is list of
SCIMConnection
(object
). - status_code
-
The HTTP status code of the response. Stytch follows standard HTTP response status code patterns, e.g. 2XX values equate to success, 3XX values are redirects, 4XX are client errors, and 5XX are server errors. The type of this field is
Integer
.
252 253 254 255 256 257 258 259 |
# File 'lib/stytch/b2b_scim.rb', line 252 def get( organization_id: ) headers = {} query_params = {} request = request_with_query_params("/v1/b2b/scim/#{organization_id}/connections", query_params) get_request(request, headers) end |
#rotate_cancel(organization_id:, connection_id:) ⇒ Object
Cancel a SCIM token rotation. This will cancel the current token rotation process, keeping the original token active. /%}
Parameters:
- organization_id
-
Globally unique UUID that identifies a specific Organization. The ‘organization_id` is critical to perform operations on an Organization, so be sure to preserve this value. The type of this field is
String
. - connection_id
-
The ID of the SCIM connection. The type of this field is
String
.
Returns:
An object with the following fields:
- request_id
-
Globally unique UUID that is returned with every API call. This value is important to log for debugging purposes; we may ask for this value to help identify a specific API call when helping you debug an issue. The type of this field is
String
. - status_code
-
The HTTP status code of the response. Stytch follows standard HTTP response status code patterns, e.g. 2XX values equate to success, 3XX values are redirects, 4XX are client errors, and 5XX are server errors. The type of this field is
Integer
. - connection
-
The ‘SCIM Connection` object affected by this API call. See the [SCIM Connection Object](stytch.com/docs/b2b/api/scim-connection-object) for complete response field details. The type of this field is nilable
SCIMConnection
(object
).
187 188 189 190 191 192 193 194 195 |
# File 'lib/stytch/b2b_scim.rb', line 187 def rotate_cancel( organization_id:, connection_id: ) headers = {} request = {} post_request("/v1/b2b/scim/#{organization_id}/connections/#{connection_id}/rotate/cancel", request, headers) end |
#rotate_complete(organization_id:, connection_id:) ⇒ Object
Completes a SCIM token rotation. This will complete the current token rotation process and update the active token to be the new token supplied in the [start SCIM token rotation](stytch.com/docs/b2b/api/scim-rotate-token-start) response. /%}
Parameters:
- organization_id
-
Globally unique UUID that identifies a specific Organization. The ‘organization_id` is critical to perform operations on an Organization, so be sure to preserve this value. The type of this field is
String
. - connection_id
-
The ID of the SCIM connection. The type of this field is
String
.
Returns:
An object with the following fields:
- request_id
-
Globally unique UUID that is returned with every API call. This value is important to log for debugging purposes; we may ask for this value to help identify a specific API call when helping you debug an issue. The type of this field is
String
. - status_code
-
The HTTP status code of the response. Stytch follows standard HTTP response status code patterns, e.g. 2XX values equate to success, 3XX values are redirects, 4XX are client errors, and 5XX are server errors. The type of this field is
Integer
. - connection
-
The ‘SCIM Connection` object affected by this API call. See the [SCIM Connection Object](stytch.com/docs/b2b/api/scim-connection-object) for complete response field details. The type of this field is nilable
SCIMConnection
(object
).
156 157 158 159 160 161 162 163 164 |
# File 'lib/stytch/b2b_scim.rb', line 156 def rotate_complete( organization_id:, connection_id: ) headers = {} request = {} post_request("/v1/b2b/scim/#{organization_id}/connections/#{connection_id}/rotate/complete", request, headers) end |
#rotate_start(organization_id:, connection_id:) ⇒ Object
Start a SCIM token rotation. /%}
Parameters:
- organization_id
-
Globally unique UUID that identifies a specific Organization. The ‘organization_id` is critical to perform operations on an Organization, so be sure to preserve this value. The type of this field is
String
. - connection_id
-
The ID of the SCIM connection. The type of this field is
String
.
Returns:
An object with the following fields:
- request_id
-
Globally unique UUID that is returned with every API call. This value is important to log for debugging purposes; we may ask for this value to help identify a specific API call when helping you debug an issue. The type of this field is
String
. - status_code
-
The HTTP status code of the response. Stytch follows standard HTTP response status code patterns, e.g. 2XX values equate to success, 3XX values are redirects, 4XX are client errors, and 5XX are server errors. The type of this field is
Integer
. - connection
-
The ‘SCIM Connection` object affected by this API call. See the [SCIM Connection Object](stytch.com/docs/b2b/api/scim-connection-object) for complete response field details. The type of this field is nilable
SCIMConnectionWithNextToken
(object
).
125 126 127 128 129 130 131 132 133 |
# File 'lib/stytch/b2b_scim.rb', line 125 def rotate_start( organization_id:, connection_id: ) headers = {} request = {} post_request("/v1/b2b/scim/#{organization_id}/connections/#{connection_id}/rotate/start", request, headers) end |
#update(organization_id:, connection_id:, display_name: nil, identity_provider: nil, scim_group_implicit_role_assignments: nil) ⇒ Object
Update a SCIM Connection. /%}
Parameters:
- organization_id
-
Globally unique UUID that identifies a specific Organization. The ‘organization_id` is critical to perform operations on an Organization, so be sure to preserve this value. The type of this field is
String
. - connection_id
-
The ID of the SCIM connection. The type of this field is
String
. - display_name
-
A human-readable display name for the connection. The type of this field is nilable
String
. - identity_provider
-
(no documentation yet) The type of this field is nilable
UpdateRequestIdp
(string enum). - scim_group_implicit_role_assignments
-
(no documentation yet) The type of this field is nilable list of
SCIMGroupImplicitRoleAssignments
.
Returns:
An object with the following fields:
- request_id
-
Globally unique UUID that is returned with every API call. This value is important to log for debugging purposes; we may ask for this value to help identify a specific API call when helping you debug an issue. The type of this field is
String
. - status_code
-
The HTTP status code of the response. Stytch follows standard HTTP response status code patterns, e.g. 2XX values equate to success, 3XX values are redirects, 4XX are client errors, and 5XX are server errors. The type of this field is
Integer
. - connection
-
The ‘SAML Connection` object affected by this API call. See the [SAML Connection Object](stytch.com/docs/b2b/api/saml-connection-object) for complete response field details. The type of this field is nilable
SCIMConnection
(object
).
59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 |
# File 'lib/stytch/b2b_scim.rb', line 59 def update( organization_id:, connection_id:, display_name: nil, identity_provider: nil, scim_group_implicit_role_assignments: nil ) headers = {} request = {} request[:display_name] = display_name unless display_name.nil? request[:identity_provider] = identity_provider unless identity_provider.nil? request[:scim_group_implicit_role_assignments] = scim_group_implicit_role_assignments unless scim_group_implicit_role_assignments.nil? put_request("/v1/b2b/scim/#{organization_id}/connections/#{connection_id}", request, headers) end |