// 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 * as dataintegration from "oci-dataintegration";
import common = require("oci-common");
// Create a default authentication provider that uses the DEFAULT
// profile in the configuration file.
// Refer to <see href="https://docs.cloud.oracle.com/en-us/iaas/Content/API/Concepts/sdkconfig.htm#SDK_and_CLI_Configuration_File>the public documentation</see> on how to prepare a configuration file.
const provider: common.ConfigFileAuthenticationDetailsProvider = new common.ConfigFileAuthenticationDetailsProvider();
(async () => {
try {
// Create a service client
const client = new dataintegration.DataIntegrationClient({
authenticationDetailsProvider: provider
});
// Create a request and dependent object(s).
const createConnectionValidationDetails = {
dataAsset: {
modelType: "FUSION_APP_DATA_ASSET",
serviceUrl: "EXAMPLE-serviceUrl-Value",
defaultConnection: {
modelType: "ORACLE_SIEBEL_CONNECTION",
username: "EXAMPLE-username-Value",
password: "EXAMPLE-password-Value",
passwordSecret: {
secretConfig: {
modelType: "OCI_VAULT_SECRET_CONFIG",
secretId: "ocid1.test.oc1..<unique_ID>EXAMPLE-secretId-Value"
},
value: "EXAMPLE-value-Value"
},
key: "EXAMPLE-key-Value",
modelVersion: "EXAMPLE-modelVersion-Value",
parentRef: {
parent: "EXAMPLE-parent-Value",
rootDocId: "ocid1.test.oc1..<unique_ID>EXAMPLE-rootDocId-Value"
},
name: "EXAMPLE-name-Value",
description: "EXAMPLE-description-Value",
objectStatus: 43,
identifier: "EXAMPLE-identifier-Value",
connectionProperties: [
{
name: "EXAMPLE-name-Value",
value: "EXAMPLE-value-Value"
}
],
registryMetadata: {
aggregatorKey: "EXAMPLE-aggregatorKey-Value",
labels: ["EXAMPLE--Value"],
registryVersion: 525,
key: "EXAMPLE-key-Value",
isFavorite: false
}
},
stagingDataAsset: {
modelType: "ORACLE_OBJECT_STORAGE_DATA_ASSET",
ociRegion: "EXAMPLE-ociRegion-Value",
url: "EXAMPLE-url-Value",
tenancyId: "ocid1.test.oc1..<unique_ID>EXAMPLE-tenancyId-Value",
namespace: "EXAMPLE-namespace-Value",
defaultConnection: {
modelType: "ORACLE_OBJECT_STORAGE_CONNECTION",
credentialFileContent: "EXAMPLE-credentialFileContent-Value",
userId: "ocid1.test.oc1..<unique_ID>EXAMPLE-userId-Value",
fingerPrint: "EXAMPLE-fingerPrint-Value",
passPhrase: "EXAMPLE-passPhrase-Value",
key: "EXAMPLE-key-Value",
modelVersion: "EXAMPLE-modelVersion-Value",
parentRef: {
parent: "EXAMPLE-parent-Value",
rootDocId: "ocid1.test.oc1..<unique_ID>EXAMPLE-rootDocId-Value"
},
name: "EXAMPLE-name-Value",
description: "EXAMPLE-description-Value",
objectVersion: 259,
objectStatus: 379,
identifier: "EXAMPLE-identifier-Value",
primarySchema: {
key: "EXAMPLE-key-Value",
modelType: "EXAMPLE-modelType-Value",
modelVersion: "EXAMPLE-modelVersion-Value",
parentRef: {
parent: "EXAMPLE-parent-Value",
rootDocId: "ocid1.test.oc1..<unique_ID>EXAMPLE-rootDocId-Value"
},
name: "EXAMPLE-name-Value",
resourceName: "EXAMPLE-resourceName-Value",
description: "EXAMPLE-description-Value",
objectVersion: 198,
externalKey: "EXAMPLE-externalKey-Value",
isHasContainers: true,
defaultConnection: "EXAMPLE-defaultConnection-Value",
objectStatus: 775,
identifier: "EXAMPLE-identifier-Value",
metadata: {
createdBy: "EXAMPLE-createdBy-Value",
createdByName: "EXAMPLE-createdByName-Value",
updatedBy: "EXAMPLE-updatedBy-Value",
updatedByName: "EXAMPLE-updatedByName-Value",
timeCreated: new Date("Thu Sep 09 02:10:00 UTC 2038"),
timeUpdated: new Date("Sat Sep 14 11:51:01 UTC 2019"),
aggregatorKey: "EXAMPLE-aggregatorKey-Value",
aggregator: {
type: "EXAMPLE-type-Value",
key: "EXAMPLE-key-Value",
name: "EXAMPLE-name-Value",
identifier: "EXAMPLE-identifier-Value",
description: "EXAMPLE-description-Value"
},
identifierPath: "EXAMPLE-identifierPath-Value",
infoFields: {
EXAMPLE_KEY_A0IMn: "EXAMPLE_VALUE_xCbErcqKqs3QuyvFVyAo"
},
registryVersion: 436,
labels: ["EXAMPLE--Value"],
isFavorite: true,
countStatistics: {
objectTypeCountList: [
{
objectType:
dataintegration.models.CountStatisticSummary.ObjectType.FunctionLibrary,
objectCount: 209
}
]
}
}
},
connectionProperties: [
{
name: "EXAMPLE-name-Value",
value: "EXAMPLE-value-Value"
}
],
isDefault: true,
metadata: {
createdBy: "EXAMPLE-createdBy-Value",
createdByName: "EXAMPLE-createdByName-Value",
updatedBy: "EXAMPLE-updatedBy-Value",
updatedByName: "EXAMPLE-updatedByName-Value",
timeCreated: new Date("Mon Jul 29 12:07:45 UTC 2024"),
timeUpdated: new Date("Mon Apr 15 21:12:12 UTC 2030"),
aggregatorKey: "EXAMPLE-aggregatorKey-Value",
aggregator: {
type: "EXAMPLE-type-Value",
key: "EXAMPLE-key-Value",
name: "EXAMPLE-name-Value",
identifier: "EXAMPLE-identifier-Value",
description: "EXAMPLE-description-Value"
},
identifierPath: "EXAMPLE-identifierPath-Value",
infoFields: {
EXAMPLE_KEY_c45tH: "EXAMPLE_VALUE_xbGEZI5Dst9ovncLPfPe"
},
registryVersion: 757,
labels: ["EXAMPLE--Value"],
isFavorite: false,
countStatistics: {
objectTypeCountList: [
{
objectType: dataintegration.models.CountStatisticSummary.ObjectType.Application,
objectCount: 852
}
]
}
},
keyMap: {
EXAMPLE_KEY_qJcZw: "EXAMPLE_VALUE_ptZ8FSjKypuYUG6y1DXj"
}
},
key: "EXAMPLE-key-Value",
modelVersion: "EXAMPLE-modelVersion-Value",
name: "EXAMPLE-name-Value",
description: "EXAMPLE-description-Value",
objectStatus: 489,
identifier: "EXAMPLE-identifier-Value",
externalKey: "EXAMPLE-externalKey-Value",
assetProperties: {
EXAMPLE_KEY_0ORpw: "EXAMPLE_VALUE_sPArPLVSseuhMuhaL9LX"
},
nativeTypeSystem: {
key: "EXAMPLE-key-Value",
modelType: "EXAMPLE-modelType-Value",
modelVersion: "EXAMPLE-modelVersion-Value",
parentRef: {
parent: "EXAMPLE-parent-Value",
rootDocId: "ocid1.test.oc1..<unique_ID>EXAMPLE-rootDocId-Value"
},
name: "EXAMPLE-name-Value",
description: "EXAMPLE-description-Value",
objectVersion: 842,
typeMappingTo: {
EXAMPLE_KEY_WsEB8: "EXAMPLE_VALUE_t1dIPE6UdeTXqLhtdr4p"
},
typeMappingFrom: {
EXAMPLE_KEY_n3dAj: "EXAMPLE_VALUE_5LmMrYxNSPcGAdl52LPg"
},
objectStatus: 198,
identifier: "EXAMPLE-identifier-Value",
types: [
{
modelType: "DATA_TYPE",
dtType: dataintegration.models.DataType.DtType.Primitive,
typeSystemName: "EXAMPLE-typeSystemName-Value",
configDefinition: {
key: "EXAMPLE-key-Value",
modelType: "EXAMPLE-modelType-Value",
modelVersion: "EXAMPLE-modelVersion-Value",
parentRef: {
parent: "EXAMPLE-parent-Value",
rootDocId: "ocid1.test.oc1..<unique_ID>EXAMPLE-rootDocId-Value"
},
name: "EXAMPLE-name-Value",
isContained: false,
objectStatus: 307,
configParameterDefinitions: {
EXAMPLE_KEY_ateoq: {
parameterType: {
modelType: "JAVA_TYPE",
javaTypeName: "EXAMPLE-javaTypeName-Value",
key: "EXAMPLE-key-Value",
modelVersion: "EXAMPLE-modelVersion-Value",
parentRef: {
parent: "EXAMPLE-parent-Value",
rootDocId: "ocid1.test.oc1..<unique_ID>EXAMPLE-rootDocId-Value"
},
name: "EXAMPLE-name-Value",
objectStatus: 436,
description: "EXAMPLE-description-Value"
},
parameterName: "EXAMPLE-parameterName-Value",
description: "EXAMPLE-description-Value",
defaultValue: "EXAMPLE-defaultValue-Value",
classFieldName: "EXAMPLE-classFieldName-Value",
isStatic: false,
isClassFieldValue: false
}
}
},
key: "EXAMPLE-key-Value",
modelVersion: "EXAMPLE-modelVersion-Value",
parentRef: {
parent: "EXAMPLE-parent-Value",
rootDocId: "ocid1.test.oc1..<unique_ID>EXAMPLE-rootDocId-Value"
},
name: "EXAMPLE-name-Value",
objectStatus: 723,
description: "EXAMPLE-description-Value"
}
]
},
objectVersion: 793,
parentRef: {
parent: "EXAMPLE-parent-Value",
rootDocId: "ocid1.test.oc1..<unique_ID>EXAMPLE-rootDocId-Value"
},
metadata: {
createdBy: "EXAMPLE-createdBy-Value",
createdByName: "EXAMPLE-createdByName-Value",
updatedBy: "EXAMPLE-updatedBy-Value",
updatedByName: "EXAMPLE-updatedByName-Value",
timeCreated: new Date("Wed Sep 26 02:58:20 UTC 2046"),
timeUpdated: new Date("Fri Dec 02 17:51:18 UTC 2022"),
aggregatorKey: "EXAMPLE-aggregatorKey-Value",
aggregator: {
type: "EXAMPLE-type-Value",
key: "EXAMPLE-key-Value",
name: "EXAMPLE-name-Value",
identifier: "EXAMPLE-identifier-Value",
description: "EXAMPLE-description-Value"
},
identifierPath: "EXAMPLE-identifierPath-Value",
infoFields: {
EXAMPLE_KEY_QC8tp: "EXAMPLE_VALUE_20ykDf8vxFB9DzQT7acw"
},
registryVersion: 7,
labels: ["EXAMPLE--Value"],
isFavorite: true,
countStatistics: {
objectTypeCountList: [
{
objectType: dataintegration.models.CountStatisticSummary.ObjectType.Project,
objectCount: 747
}
]
}
}
},
stagingConnection: {
modelType: "ORACLE_OBJECT_STORAGE_CONNECTION",
credentialFileContent: "EXAMPLE-credentialFileContent-Value",
userId: "ocid1.test.oc1..<unique_ID>EXAMPLE-userId-Value",
fingerPrint: "EXAMPLE-fingerPrint-Value",
passPhrase: "EXAMPLE-passPhrase-Value",
key: "EXAMPLE-key-Value",
modelVersion: "EXAMPLE-modelVersion-Value",
parentRef: {
parent: "EXAMPLE-parent-Value",
rootDocId: "ocid1.test.oc1..<unique_ID>EXAMPLE-rootDocId-Value"
},
name: "EXAMPLE-name-Value",
description: "EXAMPLE-description-Value",
objectVersion: 835,
objectStatus: 819,
identifier: "EXAMPLE-identifier-Value",
primarySchema: {
key: "EXAMPLE-key-Value",
modelType: "EXAMPLE-modelType-Value",
modelVersion: "EXAMPLE-modelVersion-Value",
parentRef: {
parent: "EXAMPLE-parent-Value",
rootDocId: "ocid1.test.oc1..<unique_ID>EXAMPLE-rootDocId-Value"
},
name: "EXAMPLE-name-Value",
resourceName: "EXAMPLE-resourceName-Value",
description: "EXAMPLE-description-Value",
objectVersion: 30,
externalKey: "EXAMPLE-externalKey-Value",
isHasContainers: false,
defaultConnection: "EXAMPLE-defaultConnection-Value",
objectStatus: 355,
identifier: "EXAMPLE-identifier-Value",
metadata: {
createdBy: "EXAMPLE-createdBy-Value",
createdByName: "EXAMPLE-createdByName-Value",
updatedBy: "EXAMPLE-updatedBy-Value",
updatedByName: "EXAMPLE-updatedByName-Value",
timeCreated: new Date("Wed May 14 03:56:11 UTC 2031"),
timeUpdated: new Date("Tue May 12 14:57:22 UTC 2037"),
aggregatorKey: "EXAMPLE-aggregatorKey-Value",
aggregator: {
type: "EXAMPLE-type-Value",
key: "EXAMPLE-key-Value",
name: "EXAMPLE-name-Value",
identifier: "EXAMPLE-identifier-Value",
description: "EXAMPLE-description-Value"
},
identifierPath: "EXAMPLE-identifierPath-Value",
infoFields: {
EXAMPLE_KEY_xbsUF: "EXAMPLE_VALUE_k5o51UTpx8wHGG04QsGV"
},
registryVersion: 616,
labels: ["EXAMPLE--Value"],
isFavorite: true,
countStatistics: {
objectTypeCountList: [
{
objectType:
dataintegration.models.CountStatisticSummary.ObjectType.FunctionLibrary,
objectCount: 2
}
]
}
}
},
connectionProperties: [
{
name: "EXAMPLE-name-Value",
value: "EXAMPLE-value-Value"
}
],
isDefault: false,
metadata: {
createdBy: "EXAMPLE-createdBy-Value",
createdByName: "EXAMPLE-createdByName-Value",
updatedBy: "EXAMPLE-updatedBy-Value",
updatedByName: "EXAMPLE-updatedByName-Value",
timeCreated: new Date("Tue Sep 15 21:58:49 UTC 2020"),
timeUpdated: new Date("Mon Jul 21 22:44:45 UTC 2008"),
aggregatorKey: "EXAMPLE-aggregatorKey-Value",
aggregator: {
type: "EXAMPLE-type-Value",
key: "EXAMPLE-key-Value",
name: "EXAMPLE-name-Value",
identifier: "EXAMPLE-identifier-Value",
description: "EXAMPLE-description-Value"
},
identifierPath: "EXAMPLE-identifierPath-Value",
infoFields: {
EXAMPLE_KEY_gyFf5: "EXAMPLE_VALUE_UATS3Cq7EyOIWIoDZPPV"
},
registryVersion: 258,
labels: ["EXAMPLE--Value"],
isFavorite: false,
countStatistics: {
objectTypeCountList: [
{
objectType: dataintegration.models.CountStatisticSummary.ObjectType.DataAsset,
objectCount: 605
}
]
}
},
keyMap: {
EXAMPLE_KEY_LwWgk: "EXAMPLE_VALUE_zMYSgGEfA9pZo9j1CSzE"
}
},
bucketSchema: {
key: "EXAMPLE-key-Value",
modelType: "EXAMPLE-modelType-Value",
modelVersion: "EXAMPLE-modelVersion-Value",
parentRef: {
parent: "EXAMPLE-parent-Value",
rootDocId: "ocid1.test.oc1..<unique_ID>EXAMPLE-rootDocId-Value"
},
name: "EXAMPLE-name-Value",
resourceName: "EXAMPLE-resourceName-Value",
description: "EXAMPLE-description-Value",
objectVersion: 947,
externalKey: "EXAMPLE-externalKey-Value",
isHasContainers: false,
defaultConnection: "EXAMPLE-defaultConnection-Value",
objectStatus: 754,
identifier: "EXAMPLE-identifier-Value",
metadata: {
createdBy: "EXAMPLE-createdBy-Value",
createdByName: "EXAMPLE-createdByName-Value",
updatedBy: "EXAMPLE-updatedBy-Value",
updatedByName: "EXAMPLE-updatedByName-Value",
timeCreated: new Date("Thu Jun 20 16:20:02 UTC 2013"),
timeUpdated: new Date("Fri Mar 28 14:25:40 UTC 2008"),
aggregatorKey: "EXAMPLE-aggregatorKey-Value",
aggregator: {
type: "EXAMPLE-type-Value",
key: "EXAMPLE-key-Value",
name: "EXAMPLE-name-Value",
identifier: "EXAMPLE-identifier-Value",
description: "EXAMPLE-description-Value"
},
identifierPath: "EXAMPLE-identifierPath-Value",
infoFields: {
EXAMPLE_KEY_6SfLB: "EXAMPLE_VALUE_DpcTwXHs7Riwfce6b6MD"
},
registryVersion: 259,
labels: ["EXAMPLE--Value"],
isFavorite: true,
countStatistics: {
objectTypeCountList: [
{
objectType: dataintegration.models.CountStatisticSummary.ObjectType.Task,
objectCount: 724
}
]
}
}
},
key: "EXAMPLE-key-Value",
modelVersion: "EXAMPLE-modelVersion-Value",
name: "EXAMPLE-name-Value",
description: "EXAMPLE-description-Value",
objectStatus: 215,
identifier: "EXAMPLE-identifier-Value",
externalKey: "EXAMPLE-externalKey-Value",
assetProperties: {
EXAMPLE_KEY_QX07X: "EXAMPLE_VALUE_F4MoMBj7dkVsKuHLPUkY"
},
registryMetadata: {
aggregatorKey: "EXAMPLE-aggregatorKey-Value",
labels: ["EXAMPLE--Value"],
registryVersion: 795,
key: "EXAMPLE-key-Value",
isFavorite: false
}
},
connection: {
modelType: "MYSQL_CONNECTION",
username: "EXAMPLE-username-Value",
password: "EXAMPLE-password-Value",
passwordSecret: {
secretConfig: {
modelType: "OCI_VAULT_SECRET_CONFIG",
secretId: "ocid1.test.oc1..<unique_ID>EXAMPLE-secretId-Value"
},
value: "EXAMPLE-value-Value"
},
key: "EXAMPLE-key-Value",
modelVersion: "EXAMPLE-modelVersion-Value",
parentRef: {
parent: "EXAMPLE-parent-Value",
rootDocId: "ocid1.test.oc1..<unique_ID>EXAMPLE-rootDocId-Value"
},
name: "EXAMPLE-name-Value",
description: "EXAMPLE-description-Value",
objectStatus: 652,
identifier: "EXAMPLE-identifier-Value",
connectionProperties: [
{
name: "EXAMPLE-name-Value",
value: "EXAMPLE-value-Value"
}
],
registryMetadata: {
aggregatorKey: "EXAMPLE-aggregatorKey-Value",
labels: ["EXAMPLE--Value"],
registryVersion: 647,
key: "EXAMPLE-key-Value",
isFavorite: false
}
},
registryMetadata: {
aggregatorKey: "EXAMPLE-aggregatorKey-Value",
labels: ["EXAMPLE--Value"],
registryVersion: 440,
key: "EXAMPLE-key-Value",
isFavorite: true
}
};
const createConnectionValidationRequest: dataintegration.requests.CreateConnectionValidationRequest = {
workspaceId: "ocid1.test.oc1..<unique_ID>EXAMPLE-workspaceId-Value",
createConnectionValidationDetails: createConnectionValidationDetails,
opcRequestId: "L52UMG1TH2FY5FG6RLBS<unique_ID>",
opcRetryToken: "EXAMPLE-opcRetryToken-Value"
};
// Send request to the Client.
const createConnectionValidationResponse = await client.createConnectionValidation(
createConnectionValidationRequest
);
} catch (error) {
console.log("createConnectionValidation Failed with error " + error);
}
})();