# This is an automatically generated code sample.
# To make this code sample work in your Oracle Cloud tenancy,
# please replace the values for any parameters whose current values do not fit
# your use case (such as resource IDs, strings containing ‘EXAMPLE’ or ‘unique_id’, and
# boolean, number, and enum parameters with values not fitting your use case).

import oci

# Create a default config using DEFAULT profile in default location
# Refer to
# https://docs.cloud.oracle.com/en-us/iaas/Content/API/Concepts/sdkconfig.htm#SDK_and_CLI_Configuration_File
# for more info
config = oci.config.from_file()


# Initialize service client with default config file
identity_domains_client = oci.identity_domains.IdentityDomainsClient(
    config, "https://endpoint_of_this_service.com")


# Send the request to service, some parameters are not required, see API
# doc for more info
put_social_identity_provider_response = identity_domains_client.put_social_identity_provider(
    social_identity_provider_id="ocid1.test.oc1..<unique_ID>EXAMPLE-socialIdentityProviderId-Value",
    authorization="EXAMPLE-authorization-Value",
    resource_type_schema_version="EXAMPLE-resourceTypeSchemaVersion-Value",
    social_identity_provider=oci.identity_domains.models.SocialIdentityProvider(
        schemas=["EXAMPLE--Value"],
        name="EXAMPLE-name-Value",
        enabled=False,
        account_linking_enabled=True,
        registration_enabled=True,
        show_on_login=False,
        consumer_key="EXAMPLE-consumerKey-Value",
        consumer_secret="EXAMPLE-consumerSecret-Value",
        service_provider_name="EXAMPLE-serviceProviderName-Value",
        id="ocid1.test.oc1..<unique_ID>EXAMPLE-id-Value",
        ocid="EXAMPLE-ocid-Value",
        meta=oci.identity_domains.models.Meta(
            resource_type="EXAMPLE-resourceType-Value",
            created="EXAMPLE-created-Value",
            last_modified="EXAMPLE-lastModified-Value",
            location="EXAMPLE-location-Value",
            version="EXAMPLE-version-Value"),
        idcs_created_by=oci.identity_domains.models.IdcsCreatedBy(
            value="EXAMPLE-value-Value",
            ref=None,
            type="User",
            display="EXAMPLE-display-Value",
            ocid="EXAMPLE-ocid-Value"),
        idcs_last_modified_by=oci.identity_domains.models.IdcsLastModifiedBy(
            value="EXAMPLE-value-Value",
            ref=None,
            type="App",
            display="EXAMPLE-display-Value",
            ocid="EXAMPLE-ocid-Value"),
        idcs_prevented_operations=["delete"],
        tags=[
            oci.identity_domains.models.Tags(
                key="EXAMPLE-key-Value",
                value="EXAMPLE-value-Value")],
        delete_in_progress=True,
        idcs_last_upgraded_in_release="EXAMPLE-idcsLastUpgradedInRelease-Value",
        domain_ocid="EXAMPLE-domainOcid-Value",
        compartment_ocid="EXAMPLE-compartmentOcid-Value",
        tenancy_ocid="EXAMPLE-tenancyOcid-Value",
        description="EXAMPLE-description-Value",
        social_jit_provisioning_enabled=True,
        jit_prov_group_static_list_enabled=False,
        jit_prov_assigned_groups=[
            oci.identity_domains.models.SocialIdentityProviderJitProvAssignedGroups(
                value="EXAMPLE-value-Value",
                ref=None,
                display="EXAMPLE-display-Value")],
        auto_redirect_enabled=True,
        status="created",
        id_attribute="EXAMPLE-idAttribute-Value",
        authz_url="EXAMPLE-authzUrl-Value",
        access_token_url="EXAMPLE-accessTokenUrl-Value",
        profile_url="EXAMPLE-profileUrl-Value",
        scope=["EXAMPLE--Value"],
        admin_scope=["EXAMPLE--Value"],
        clock_skew_in_seconds=226,
        redirect_url="EXAMPLE-redirectUrl-Value",
        icon_url="EXAMPLE-iconUrl-Value",
        discovery_url="EXAMPLE-discoveryUrl-Value",
        client_credential_in_payload=False,
        refresh_token_url="EXAMPLE-refreshTokenUrl-Value",
        relay_idp_param_mappings=[
            oci.identity_domains.models.SocialIdentityProviderRelayIdpParamMappings(
                relay_param_key="EXAMPLE-relayParamKey-Value",
                relay_param_value="EXAMPLE-relayParamValue-Value")]),
    if_match="EXAMPLE-ifMatch-Value",
    opc_retry_token="EXAMPLE-opcRetryToken-Value")

# Get the data from response
print(put_social_identity_provider_response.data)

Was this article helpful?