# 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
from datetime import datetime

# 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
data_connectivity_client = oci.data_connectivity.DataConnectivityManagementClient(
    config)


# Send the request to service, some parameters are not required, see API
# doc for more info
create_execute_operation_job_response = data_connectivity_client.create_execute_operation_job(
    registry_id="ocid1.test.oc1..<unique_ID>EXAMPLE-registryId-Value",
    connection_key="EXAMPLE-connectionKey-Value",
    schema_resource_name="EXAMPLE-schemaResourceName-Value",
    create_execute_operation_job_details=oci.data_connectivity.models.CreateExecuteOperationJobDetails(
        operation=oci.data_connectivity.models.OperationFromApi(
            model_type="API",
            name="EXAMPLE-name-Value",
            resource_name="EXAMPLE-resourceName-Value",
            operation_attributes=oci.data_connectivity.models.GenericRestApiAttributes(
                model_type="GENERIC_REST_API_ATTRIBUTES",
                server_url="EXAMPLE-serverUrl-Value"),
            metadata=oci.data_connectivity.models.ObjectMetadata(
                created_by="EXAMPLE-createdBy-Value",
                created_by_name="EXAMPLE-createdByName-Value",
                updated_by="EXAMPLE-updatedBy-Value",
                updated_by_name="EXAMPLE-updatedByName-Value",
                time_created=datetime.strptime(
                    "2036-12-14T13:55:50.978Z",
                    "%Y-%m-%dT%H:%M:%S.%fZ"),
                time_updated=datetime.strptime(
                    "2033-10-31T09:06:40.152Z",
                    "%Y-%m-%dT%H:%M:%S.%fZ"),
                aggregator_key="EXAMPLE-aggregatorKey-Value",
                aggregator=oci.data_connectivity.models.AggregatorSummary(
                    type="EXAMPLE-type-Value",
                    key="EXAMPLE-key-Value",
                    name="EXAMPLE-name-Value",
                    identifier="EXAMPLE-identifier-Value",
                    description="EXAMPLE-description-Value"),
                identifier_path="EXAMPLE-identifierPath-Value",
                info_fields={
                    'EXAMPLE_KEY_5kUMY': 'EXAMPLE_VALUE_oxUyDfJWbz2IsjVhb3g4'},
                registry_version=158,
                labels=["EXAMPLE--Value"],
                is_favorite=False),
            key="EXAMPLE-key-Value",
            model_version="EXAMPLE-modelVersion-Value",
            parent_ref=oci.data_connectivity.models.ParentReference(
                parent="EXAMPLE-parent-Value"),
            shape=oci.data_connectivity.models.Shape(
                model_type="SHAPE",
                key="EXAMPLE-key-Value",
                model_version="EXAMPLE-modelVersion-Value",
                parent_ref=oci.data_connectivity.models.ParentReference(
                    parent="EXAMPLE-parent-Value"),
                config_values=oci.data_connectivity.models.ConfigValues(
                    config_param_values={
                        'EXAMPLE_KEY_VUH5R': {
                            'stringValue': 'EXAMPLE-stringValue-Value',
                            'intValue': 302,
                            'objectValue': 'EXAMPLE-objectValue-Value',
                            'refValue': 'EXAMPLE-refValue-Value',
                            'parameterValue': 'EXAMPLE-parameterValue-Value'}},
                    parent_ref=oci.data_connectivity.models.ParentReference(
                        parent="EXAMPLE-parent-Value")),
                object_status=39,
                name="EXAMPLE-name-Value",
                description="EXAMPLE-description-Value",
                type=oci.data_connectivity.models.DerivedType(
                    model_type="DERIVED_TYPE",
                    key="EXAMPLE-key-Value",
                    model_version="EXAMPLE-modelVersion-Value",
                    parent_ref=oci.data_connectivity.models.ParentReference(
                        parent="EXAMPLE-parent-Value"),
                    name="EXAMPLE-name-Value",
                    object_status=778,
                    description="EXAMPLE-description-Value")),
            object_version=664,
            external_key="EXAMPLE-externalKey-Value",
            object_status=122),
        call_operation_config=oci.data_connectivity.models.CallOperationConfig(
            in_fields=["EXAMPLE--Value"],
            out_fields=["EXAMPLE--Value"],
            call_attribute=oci.data_connectivity.models.GenericRestCallAttribute(
                model_type="GENERIC_REST_CALL_ATTRIBUTE"),
            push_down_operations=[
                oci.data_connectivity.models.Sort(
                    model_type="SORT",
                    sort_clauses=[
                        oci.data_connectivity.models.SortClause(
                            field=oci.data_connectivity.models.ShapeField(
                                model_type="SHAPE_FIELD",
                                key="EXAMPLE-key-Value",
                                model_version="EXAMPLE-modelVersion-Value",
                                parent_ref=oci.data_connectivity.models.ParentReference(
                                    parent="EXAMPLE-parent-Value"),
                                config_values=oci.data_connectivity.models.ConfigValues(
                                    config_param_values={
                                        'EXAMPLE_KEY_0j40Z': {
                                            'stringValue': 'EXAMPLE-stringValue-Value',
                                            'intValue': 84,
                                            'objectValue': 'EXAMPLE-objectValue-Value',
                                            'refValue': 'EXAMPLE-refValue-Value',
                                            'parameterValue': 'EXAMPLE-parameterValue-Value'}},
                                    parent_ref=oci.data_connectivity.models.ParentReference(
                                        parent="EXAMPLE-parent-Value")),
                                object_status=764,
                                name="EXAMPLE-name-Value",
                                description="EXAMPLE-description-Value",
                                type="EXAMPLE-type-Value",
                                labels=["EXAMPLE--Value"],
                                native_shape_field=oci.data_connectivity.models.NativeShapeField(
                                    model_type="NATIVE_SHAPE_FIELD",
                                    type="EXAMPLE-type-Value",
                                    key="EXAMPLE-key-Value",
                                    model_version="EXAMPLE-modelVersion-Value",
                                    parent_ref=oci.data_connectivity.models.ParentReference(
                                        parent="EXAMPLE-parent-Value"),
                                    config_values=oci.data_connectivity.models.ConfigValues(
                                        config_param_values={
                                            'EXAMPLE_KEY_NcGib': {
                                                'stringValue': 'EXAMPLE-stringValue-Value',
                                                'intValue': 210,
                                                'objectValue': 'EXAMPLE-objectValue-Value',
                                                'refValue': 'EXAMPLE-refValue-Value',
                                                'parameterValue': 'EXAMPLE-parameterValue-Value'}},
                                        parent_ref=oci.data_connectivity.models.ParentReference(
                                            parent="EXAMPLE-parent-Value")),
                                    object_status=629,
                                    name="EXAMPLE-name-Value",
                                    description="EXAMPLE-description-Value",
                                    position=662,
                                    default_value_string="EXAMPLE-defaultValueString-Value",
                                    is_mandatory=False)),
                            order="DESC")])]),
        input_records=[
            oci.data_connectivity.models.OperationInputRecord(
                field_values=["EXAMPLE-fieldValues-Value"])]),
    opc_request_id="KSMVGGKZTBOUUEKZDACG<unique_ID>",
    endpoint_id="ocid1.test.oc1..<unique_ID>EXAMPLE-endpointId-Value",
    opc_retry_token="EXAMPLE-opcRetryToken-Value")

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