# Scim Configurations ## CreateSCIMConfiguration `organizations.scim_configurations.create(ScimConfigurationCreateParams**kwargs) -> ScimConfigurationCreateResponse` **post** `/gitpod.v1.OrganizationService/CreateSCIMConfiguration` Creates a new SCIM configuration for automated user provisioning. Use this method to: - Set up SCIM 2.0 provisioning from an identity provider - Generate a bearer token for SCIM API authentication - Link SCIM provisioning to an existing SSO configuration ### Examples - Create basic SCIM configuration: Creates a SCIM configuration linked to an SSO provider with default 1 year token expiration. ```yaml organizationId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047" ssoConfigurationId: "d2c94c27-3b76-4a42-b88c-95a85e392c68" ``` - Create SCIM configuration with custom token expiration: Creates a SCIM configuration with a 90-day token expiration. ```yaml organizationId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047" ssoConfigurationId: "d2c94c27-3b76-4a42-b88c-95a85e392c68" tokenExpiresIn: "7776000s" ``` ### Parameters - `organization_id: str` organization_id is the ID of the organization to create the SCIM configuration for - `sso_configuration_id: str` sso_configuration_id is the SSO configuration to link (required for user provisioning) - `name: Optional[str]` name is a human-readable name for the SCIM configuration - `token_expires_in: Optional[str]` token_expires_in is the duration until the token expires. Defaults to 1 year. Minimum 1 day, maximum 2 years. ### Returns - `class ScimConfigurationCreateResponse: …` - `token: str` token is the bearer token for SCIM API authentication. This is only returned once during creation - store it securely. - `scim_configuration: ScimConfiguration` scim_configuration is the created SCIM configuration - `id: str` id is the unique identifier of the SCIM configuration - `created_at: datetime` created_at is when the SCIM configuration was created - `organization_id: str` organization_id is the ID of the organization this SCIM configuration belongs to - `token_expires_at: datetime` token_expires_at is when the current SCIM token expires - `updated_at: datetime` updated_at is when the SCIM configuration was last updated - `enabled: Optional[bool]` enabled indicates if SCIM provisioning is active - `name: Optional[str]` name is a human-readable name for the SCIM configuration - `sso_configuration_id: Optional[str]` sso_configuration_id is the linked SSO configuration (optional) - `token_expires_at: datetime` token_expires_at is when the token will expire ### Example ```python import os from gitpod import Gitpod client = Gitpod( bearer_token=os.environ.get("GITPOD_API_KEY"), # This is the default and can be omitted ) scim_configuration = client.organizations.scim_configurations.create( organization_id="b0e12f6c-4c67-429d-a4a6-d9838b5da047", sso_configuration_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", ) print(scim_configuration.token) ``` #### Response ```json { "token": "token", "scimConfiguration": { "id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", "createdAt": "2019-12-27T18:11:19.117Z", "organizationId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", "tokenExpiresAt": "2019-12-27T18:11:19.117Z", "updatedAt": "2019-12-27T18:11:19.117Z", "enabled": true, "name": "name", "ssoConfigurationId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e" }, "tokenExpiresAt": "2019-12-27T18:11:19.117Z" } ``` ## DeleteSCIMConfiguration `organizations.scim_configurations.delete(ScimConfigurationDeleteParams**kwargs) -> object` **post** `/gitpod.v1.OrganizationService/DeleteSCIMConfiguration` Removes a SCIM configuration from an organization. Use this method to: - Disable SCIM provisioning completely - Remove unused configurations - Clean up after migration ### Examples - Delete SCIM configuration: Removes a specific SCIM configuration. ```yaml scimConfigurationId: "d2c94c27-3b76-4a42-b88c-95a85e392c68" ``` ### Parameters - `scim_configuration_id: str` scim_configuration_id is the ID of the SCIM configuration to delete ### Returns - `object` ### Example ```python import os from gitpod import Gitpod client = Gitpod( bearer_token=os.environ.get("GITPOD_API_KEY"), # This is the default and can be omitted ) scim_configuration = client.organizations.scim_configurations.delete( scim_configuration_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", ) print(scim_configuration) ``` #### Response ```json {} ``` ## ListSCIMConfigurations `organizations.scim_configurations.list(ScimConfigurationListParams**kwargs) -> SyncScimConfigurationsPage[ScimConfiguration]` **post** `/gitpod.v1.OrganizationService/ListSCIMConfigurations` Lists SCIM configurations for an organization. Use this method to: - View all SCIM configurations - Monitor provisioning status - Audit SCIM settings ### Examples - List SCIM configurations: Shows all SCIM configurations for an organization. ```yaml pagination: pageSize: 20 ``` ### Parameters - `token: Optional[str]` - `page_size: Optional[int]` - `pagination: Optional[Pagination]` - `token: Optional[str]` Token for the next set of results that was returned as next_token of a PaginationResponse - `page_size: Optional[int]` Page size is the maximum number of results to retrieve per page. Defaults to 25. Maximum 100. ### Returns - `class ScimConfiguration: …` SCIMConfiguration represents a SCIM 2.0 provisioning configuration - `id: str` id is the unique identifier of the SCIM configuration - `created_at: datetime` created_at is when the SCIM configuration was created - `organization_id: str` organization_id is the ID of the organization this SCIM configuration belongs to - `token_expires_at: datetime` token_expires_at is when the current SCIM token expires - `updated_at: datetime` updated_at is when the SCIM configuration was last updated - `enabled: Optional[bool]` enabled indicates if SCIM provisioning is active - `name: Optional[str]` name is a human-readable name for the SCIM configuration - `sso_configuration_id: Optional[str]` sso_configuration_id is the linked SSO configuration (optional) ### Example ```python import os from gitpod import Gitpod client = Gitpod( bearer_token=os.environ.get("GITPOD_API_KEY"), # This is the default and can be omitted ) page = client.organizations.scim_configurations.list( pagination={ "page_size": 20 }, ) page = page.scim_configurations[0] print(page.id) ``` #### Response ```json { "pagination": { "nextToken": "nextToken" }, "scimConfigurations": [ { "id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", "createdAt": "2019-12-27T18:11:19.117Z", "organizationId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", "tokenExpiresAt": "2019-12-27T18:11:19.117Z", "updatedAt": "2019-12-27T18:11:19.117Z", "enabled": true, "name": "name", "ssoConfigurationId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e" } ] } ``` ## RegenerateSCIMToken `organizations.scim_configurations.regenerate_token(ScimConfigurationRegenerateTokenParams**kwargs) -> ScimConfigurationRegenerateTokenResponse` **post** `/gitpod.v1.OrganizationService/RegenerateSCIMToken` Regenerates the bearer token for a SCIM configuration. Use this method to: - Rotate SCIM credentials - Recover from token compromise - Update IdP configuration ### Examples - Regenerate token: Creates a new bearer token with the same expiration duration as the previous token. ```yaml scimConfigurationId: "d2c94c27-3b76-4a42-b88c-95a85e392c68" ``` - Regenerate token with new expiration: Creates a new bearer token with a custom 180-day expiration. ```yaml scimConfigurationId: "d2c94c27-3b76-4a42-b88c-95a85e392c68" tokenExpiresIn: "15552000s" ``` ### Parameters - `scim_configuration_id: str` scim_configuration_id is the ID of the SCIM configuration to regenerate token for - `token_expires_in: Optional[str]` token_expires_in is the duration until the new token expires. If not specified, uses the same duration as the previous token. ### Returns - `class ScimConfigurationRegenerateTokenResponse: …` - `token: str` token is the new bearer token for SCIM API authentication. This invalidates the previous token - store it securely. - `token_expires_at: datetime` token_expires_at is when the new token will expire ### Example ```python import os from gitpod import Gitpod client = Gitpod( bearer_token=os.environ.get("GITPOD_API_KEY"), # This is the default and can be omitted ) response = client.organizations.scim_configurations.regenerate_token( scim_configuration_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", ) print(response.token) ``` #### Response ```json { "token": "token", "tokenExpiresAt": "2019-12-27T18:11:19.117Z" } ``` ## GetSCIMConfiguration `organizations.scim_configurations.retrieve(ScimConfigurationRetrieveParams**kwargs) -> ScimConfigurationRetrieveResponse` **post** `/gitpod.v1.OrganizationService/GetSCIMConfiguration` Retrieves a specific SCIM configuration. Use this method to: - View SCIM configuration details - Check if SCIM is enabled - Verify SSO linkage ### Examples - Get SCIM configuration: Retrieves details of a specific SCIM configuration. ```yaml scimConfigurationId: "d2c94c27-3b76-4a42-b88c-95a85e392c68" ``` ### Parameters - `scim_configuration_id: str` scim_configuration_id is the ID of the SCIM configuration to get ### Returns - `class ScimConfigurationRetrieveResponse: …` - `scim_configuration: ScimConfiguration` scim_configuration is the SCIM configuration identified by the ID - `id: str` id is the unique identifier of the SCIM configuration - `created_at: datetime` created_at is when the SCIM configuration was created - `organization_id: str` organization_id is the ID of the organization this SCIM configuration belongs to - `token_expires_at: datetime` token_expires_at is when the current SCIM token expires - `updated_at: datetime` updated_at is when the SCIM configuration was last updated - `enabled: Optional[bool]` enabled indicates if SCIM provisioning is active - `name: Optional[str]` name is a human-readable name for the SCIM configuration - `sso_configuration_id: Optional[str]` sso_configuration_id is the linked SSO configuration (optional) ### Example ```python import os from gitpod import Gitpod client = Gitpod( bearer_token=os.environ.get("GITPOD_API_KEY"), # This is the default and can be omitted ) scim_configuration = client.organizations.scim_configurations.retrieve( scim_configuration_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", ) print(scim_configuration.scim_configuration) ``` #### Response ```json { "scimConfiguration": { "id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", "createdAt": "2019-12-27T18:11:19.117Z", "organizationId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", "tokenExpiresAt": "2019-12-27T18:11:19.117Z", "updatedAt": "2019-12-27T18:11:19.117Z", "enabled": true, "name": "name", "ssoConfigurationId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e" } } ``` ## UpdateSCIMConfiguration `organizations.scim_configurations.update(ScimConfigurationUpdateParams**kwargs) -> ScimConfigurationUpdateResponse` **post** `/gitpod.v1.OrganizationService/UpdateSCIMConfiguration` Updates a SCIM configuration. Use this method to: - Enable or disable SCIM provisioning - Link or unlink SSO configuration - Update configuration name ### Examples - Disable SCIM: Disables SCIM provisioning. ```yaml scimConfigurationId: "d2c94c27-3b76-4a42-b88c-95a85e392c68" enabled: false ``` - Link to SSO: Links SCIM configuration to an SSO provider. ```yaml scimConfigurationId: "d2c94c27-3b76-4a42-b88c-95a85e392c68" ssoConfigurationId: "f53d2330-3795-4c5d-a1f3-453121af9c60" ``` ### Parameters - `scim_configuration_id: str` scim_configuration_id is the ID of the SCIM configuration to update - `enabled: Optional[bool]` enabled controls whether SCIM provisioning is active - `name: Optional[str]` name is a human-readable name for the SCIM configuration - `sso_configuration_id: Optional[str]` sso_configuration_id is the SSO configuration to link ### Returns - `class ScimConfigurationUpdateResponse: …` - `scim_configuration: ScimConfiguration` scim_configuration is the updated SCIM configuration - `id: str` id is the unique identifier of the SCIM configuration - `created_at: datetime` created_at is when the SCIM configuration was created - `organization_id: str` organization_id is the ID of the organization this SCIM configuration belongs to - `token_expires_at: datetime` token_expires_at is when the current SCIM token expires - `updated_at: datetime` updated_at is when the SCIM configuration was last updated - `enabled: Optional[bool]` enabled indicates if SCIM provisioning is active - `name: Optional[str]` name is a human-readable name for the SCIM configuration - `sso_configuration_id: Optional[str]` sso_configuration_id is the linked SSO configuration (optional) ### Example ```python import os from gitpod import Gitpod client = Gitpod( bearer_token=os.environ.get("GITPOD_API_KEY"), # This is the default and can be omitted ) scim_configuration = client.organizations.scim_configurations.update( scim_configuration_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", enabled=False, ) print(scim_configuration.scim_configuration) ``` #### Response ```json { "scimConfiguration": { "id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", "createdAt": "2019-12-27T18:11:19.117Z", "organizationId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", "tokenExpiresAt": "2019-12-27T18:11:19.117Z", "updatedAt": "2019-12-27T18:11:19.117Z", "enabled": true, "name": "name", "ssoConfigurationId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e" } } ``` ## Domain Types ### Scim Configuration - `class ScimConfiguration: …` SCIMConfiguration represents a SCIM 2.0 provisioning configuration - `id: str` id is the unique identifier of the SCIM configuration - `created_at: datetime` created_at is when the SCIM configuration was created - `organization_id: str` organization_id is the ID of the organization this SCIM configuration belongs to - `token_expires_at: datetime` token_expires_at is when the current SCIM token expires - `updated_at: datetime` updated_at is when the SCIM configuration was last updated - `enabled: Optional[bool]` enabled indicates if SCIM provisioning is active - `name: Optional[str]` name is a human-readable name for the SCIM configuration - `sso_configuration_id: Optional[str]` sso_configuration_id is the linked SSO configuration (optional) ### Scim Configuration Create Response - `class ScimConfigurationCreateResponse: …` - `token: str` token is the bearer token for SCIM API authentication. This is only returned once during creation - store it securely. - `scim_configuration: ScimConfiguration` scim_configuration is the created SCIM configuration - `id: str` id is the unique identifier of the SCIM configuration - `created_at: datetime` created_at is when the SCIM configuration was created - `organization_id: str` organization_id is the ID of the organization this SCIM configuration belongs to - `token_expires_at: datetime` token_expires_at is when the current SCIM token expires - `updated_at: datetime` updated_at is when the SCIM configuration was last updated - `enabled: Optional[bool]` enabled indicates if SCIM provisioning is active - `name: Optional[str]` name is a human-readable name for the SCIM configuration - `sso_configuration_id: Optional[str]` sso_configuration_id is the linked SSO configuration (optional) - `token_expires_at: datetime` token_expires_at is when the token will expire ### Scim Configuration Regenerate Token Response - `class ScimConfigurationRegenerateTokenResponse: …` - `token: str` token is the new bearer token for SCIM API authentication. This invalidates the previous token - store it securely. - `token_expires_at: datetime` token_expires_at is when the new token will expire ### Scim Configuration Retrieve Response - `class ScimConfigurationRetrieveResponse: …` - `scim_configuration: ScimConfiguration` scim_configuration is the SCIM configuration identified by the ID - `id: str` id is the unique identifier of the SCIM configuration - `created_at: datetime` created_at is when the SCIM configuration was created - `organization_id: str` organization_id is the ID of the organization this SCIM configuration belongs to - `token_expires_at: datetime` token_expires_at is when the current SCIM token expires - `updated_at: datetime` updated_at is when the SCIM configuration was last updated - `enabled: Optional[bool]` enabled indicates if SCIM provisioning is active - `name: Optional[str]` name is a human-readable name for the SCIM configuration - `sso_configuration_id: Optional[str]` sso_configuration_id is the linked SSO configuration (optional) ### Scim Configuration Update Response - `class ScimConfigurationUpdateResponse: …` - `scim_configuration: ScimConfiguration` scim_configuration is the updated SCIM configuration - `id: str` id is the unique identifier of the SCIM configuration - `created_at: datetime` created_at is when the SCIM configuration was created - `organization_id: str` organization_id is the ID of the organization this SCIM configuration belongs to - `token_expires_at: datetime` token_expires_at is when the current SCIM token expires - `updated_at: datetime` updated_at is when the SCIM configuration was last updated - `enabled: Optional[bool]` enabled indicates if SCIM provisioning is active - `name: Optional[str]` name is a human-readable name for the SCIM configuration - `sso_configuration_id: Optional[str]` sso_configuration_id is the linked SSO configuration (optional)