-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
6 changed files
with
497 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
package b2b | ||
|
||
// !!! | ||
// WARNING: This file is autogenerated | ||
// Only modify code within MANUAL() sections | ||
// or your changes may be overwritten later! | ||
// !!! | ||
|
||
import ( | ||
"github.com/stytchauth/stytch-go/v12/stytch" | ||
) | ||
|
||
type SCIMClient struct { | ||
C stytch.Client | ||
Connections *SCIMConnectionsClient | ||
} | ||
|
||
func NewSCIMClient(c stytch.Client) *SCIMClient { | ||
return &SCIMClient{ | ||
C: c, | ||
|
||
Connections: NewSCIMConnectionsClient(c), | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,200 @@ | ||
package connections | ||
|
||
// !!! | ||
// WARNING: This file is autogenerated | ||
// Only modify code within MANUAL() sections | ||
// or your changes may be overwritten later! | ||
// !!! | ||
|
||
import ( | ||
"github.com/stytchauth/stytch-go/v12/stytch/b2b/scim" | ||
) | ||
|
||
// CreateParams: Request type for `Connections.Create`. | ||
type CreateParams struct { | ||
// OrganizationID: 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. | ||
OrganizationID string `json:"organization_id,omitempty"` | ||
// DisplayName: A human-readable display name for the connection. | ||
DisplayName string `json:"display_name,omitempty"` | ||
IdentityProvider CreateRequestIdp `json:"idp,omitempty"` | ||
} | ||
|
||
// DeleteParams: Request type for `Connections.Delete`. | ||
type DeleteParams struct { | ||
// OrganizationID: 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. | ||
OrganizationID string `json:"organization_id,omitempty"` | ||
// ConnectionID: Globally unique UUID that identifies a specific SSO `connection_id` for a Member. | ||
ConnectionID string `json:"connection_id,omitempty"` | ||
} | ||
|
||
// GetParams: Request type for `Connections.Get`. | ||
type GetParams struct { | ||
// OrganizationID: 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. | ||
OrganizationID string `json:"organization_id,omitempty"` | ||
} | ||
|
||
// RotateCancelParams: Request type for `Connections.RotateCancel`. | ||
type RotateCancelParams struct { | ||
// OrganizationID: 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. | ||
OrganizationID string `json:"organization_id,omitempty"` | ||
// ConnectionID: The ID of the SCIM connection. | ||
ConnectionID string `json:"connection_id,omitempty"` | ||
} | ||
|
||
// RotateCompleteParams: Request type for `Connections.RotateComplete`. | ||
type RotateCompleteParams struct { | ||
// OrganizationID: 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. | ||
OrganizationID string `json:"organization_id,omitempty"` | ||
// ConnectionID: The ID of the SCIM connection. | ||
ConnectionID string `json:"connection_id,omitempty"` | ||
} | ||
|
||
// RotateStartParams: Request type for `Connections.RotateStart`. | ||
type RotateStartParams struct { | ||
// OrganizationID: 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. | ||
OrganizationID string `json:"organization_id,omitempty"` | ||
// ConnectionID: The ID of the SCIM connection. | ||
ConnectionID string `json:"connection_id,omitempty"` | ||
} | ||
|
||
// UpdateParams: Request type for `Connections.Update`. | ||
type UpdateParams struct { | ||
// OrganizationID: 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. | ||
OrganizationID string `json:"organization_id,omitempty"` | ||
// ConnectionID: The ID of the SCIM connection. | ||
ConnectionID string `json:"connection_id,omitempty"` | ||
// DisplayName: A human-readable display name for the connection. | ||
DisplayName string `json:"display_name,omitempty"` | ||
IdentityProvider UpdateRequestIdp `json:"idp,omitempty"` | ||
SCIMGroupImplicitRoleAssignments []*scim.SCIMGroupImplicitRoleAssignments `json:"scim_group_implicit_role_assignments,omitempty"` | ||
} | ||
|
||
// CreateResponse: Response type for `Connections.Create`. | ||
type CreateResponse struct { | ||
// RequestID: 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. | ||
RequestID string `json:"request_id,omitempty"` | ||
// StatusCode: 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. | ||
StatusCode int32 `json:"status_code,omitempty"` | ||
// Connection: The `SCIM Connection` object affected by this API call. See the | ||
// [SCIM Connection Object](https://stytch.com/docs/b2b/api/scim-connection-object) for complete response | ||
// field details. | ||
Connection *scim.SCIMConnectionWithToken `json:"connection,omitempty"` | ||
} | ||
|
||
// DeleteResponse: Response type for `Connections.Delete`. | ||
type DeleteResponse struct { | ||
// RequestID: 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. | ||
RequestID string `json:"request_id,omitempty"` | ||
// ConnectionID: The `connection_id` that was deleted as part of the delete request. | ||
ConnectionID string `json:"connection_id,omitempty"` | ||
// StatusCode: 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. | ||
StatusCode int32 `json:"status_code,omitempty"` | ||
} | ||
|
||
// GetResponse: Response type for `Connections.Get`. | ||
type GetResponse struct { | ||
// RequestID: 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. | ||
RequestID string `json:"request_id,omitempty"` | ||
Connections []scim.SCIMConnection `json:"connections,omitempty"` | ||
// StatusCode: 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. | ||
StatusCode int32 `json:"status_code,omitempty"` | ||
} | ||
|
||
// RotateCancelResponse: Response type for `Connections.RotateCancel`. | ||
type RotateCancelResponse struct { | ||
// RequestID: 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. | ||
RequestID string `json:"request_id,omitempty"` | ||
// StatusCode: 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. | ||
StatusCode int32 `json:"status_code,omitempty"` | ||
// Connection: The `SCIM Connection` object affected by this API call. See the | ||
// [SCIM Connection Object](https://stytch.com/docs/b2b/api/scim-connection-object) for complete response | ||
// field details. | ||
Connection *scim.SCIMConnection `json:"connection,omitempty"` | ||
} | ||
|
||
// RotateCompleteResponse: Response type for `Connections.RotateComplete`. | ||
type RotateCompleteResponse struct { | ||
// RequestID: 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. | ||
RequestID string `json:"request_id,omitempty"` | ||
// StatusCode: 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. | ||
StatusCode int32 `json:"status_code,omitempty"` | ||
// Connection: The `SCIM Connection` object affected by this API call. See the | ||
// [SCIM Connection Object](https://stytch.com/docs/b2b/api/scim-connection-object) for complete response | ||
// field details. | ||
Connection *scim.SCIMConnection `json:"connection,omitempty"` | ||
} | ||
|
||
// RotateStartResponse: Response type for `Connections.RotateStart`. | ||
type RotateStartResponse struct { | ||
// RequestID: 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. | ||
RequestID string `json:"request_id,omitempty"` | ||
// StatusCode: 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. | ||
StatusCode int32 `json:"status_code,omitempty"` | ||
// Connection: The `SCIM Connection` object affected by this API call. See the | ||
// [SCIM Connection Object](https://stytch.com/docs/b2b/api/scim-connection-object) for complete response | ||
// field details. | ||
Connection *scim.SCIMConnectionWithNextToken `json:"connection,omitempty"` | ||
} | ||
|
||
// UpdateResponse: Response type for `Connections.Update`. | ||
type UpdateResponse struct { | ||
// RequestID: 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. | ||
RequestID string `json:"request_id,omitempty"` | ||
// StatusCode: 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. | ||
StatusCode int32 `json:"status_code,omitempty"` | ||
// Connection: The `SAML Connection` object affected by this API call. See the | ||
// [SAML Connection Object](https://stytch.com/docs/b2b/api/saml-connection-object) for complete response | ||
// field details. | ||
Connection *scim.SCIMConnection `json:"connection,omitempty"` | ||
} | ||
|
||
type CreateRequestIdp string | ||
|
||
const ( | ||
CreateRequestIdpUnknown CreateRequestIdp = "unknown" | ||
CreateRequestIdpOkta CreateRequestIdp = "okta" | ||
CreateRequestIdpMicrosoftentra CreateRequestIdp = "microsoft-entra" | ||
) | ||
|
||
type UpdateRequestIdp string | ||
|
||
const ( | ||
UpdateRequestIdpUnknown UpdateRequestIdp = "unknown" | ||
UpdateRequestIdpOkta UpdateRequestIdp = "okta" | ||
UpdateRequestIdpMicrosoftentra UpdateRequestIdp = "microsoft-entra" | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
package scim | ||
|
||
// !!! | ||
// WARNING: This file is autogenerated | ||
// Only modify code within MANUAL() sections | ||
// or your changes may be overwritten later! | ||
// !!! | ||
|
||
import ( | ||
"time" | ||
) | ||
|
||
type SCIMConnection struct { | ||
OrganizationID string `json:"organization_id,omitempty"` | ||
ConnectionID string `json:"connection_id,omitempty"` | ||
Status string `json:"status,omitempty"` | ||
DisplayName string `json:"display_name,omitempty"` | ||
IdentityProvider string `json:"idp,omitempty"` | ||
BaseURL string `json:"base_url,omitempty"` | ||
BearerTokenLastFour string `json:"bearer_token_last_four,omitempty"` | ||
SCIMGroupImplicitRoleAssignments []SCIMGroupImplicitRoleAssignments `json:"scim_group_implicit_role_assignments,omitempty"` | ||
BearerTokenExpiresAt *time.Time `json:"bearer_token_expires_at,omitempty"` | ||
} | ||
|
||
type SCIMConnectionWithNextToken struct { | ||
OrganizationID string `json:"organization_id,omitempty"` | ||
ConnectionID string `json:"connection_id,omitempty"` | ||
Status string `json:"status,omitempty"` | ||
DisplayName string `json:"display_name,omitempty"` | ||
BaseURL string `json:"base_url,omitempty"` | ||
IdentityProvider string `json:"idp,omitempty"` | ||
BearerTokenLastFour string `json:"bearer_token_last_four,omitempty"` | ||
NextBearerToken string `json:"next_bearer_token,omitempty"` | ||
SCIMGroupImplicitRoleAssignments []SCIMGroupImplicitRoleAssignments `json:"scim_group_implicit_role_assignments,omitempty"` | ||
BearerTokenExpiresAt *time.Time `json:"bearer_token_expires_at,omitempty"` | ||
NextBearerTokenExpiresAt *time.Time `json:"next_bearer_token_expires_at,omitempty"` | ||
} | ||
|
||
type SCIMConnectionWithToken struct { | ||
OrganizationID string `json:"organization_id,omitempty"` | ||
ConnectionID string `json:"connection_id,omitempty"` | ||
Status string `json:"status,omitempty"` | ||
DisplayName string `json:"display_name,omitempty"` | ||
IdentityProvider string `json:"idp,omitempty"` | ||
BaseURL string `json:"base_url,omitempty"` | ||
BearerToken string `json:"bearer_token,omitempty"` | ||
SCIMGroupImplicitRoleAssignments []SCIMGroupImplicitRoleAssignments `json:"scim_group_implicit_role_assignments,omitempty"` | ||
BearerTokenExpiresAt *time.Time `json:"bearer_token_expires_at,omitempty"` | ||
} | ||
|
||
type SCIMGroupImplicitRoleAssignments struct { | ||
RoleID string `json:"role_id,omitempty"` | ||
GroupID string `json:"group_id,omitempty"` | ||
GroupName string `json:"group_name,omitempty"` | ||
} |
Oops, something went wrong.