Tuesday, June 30, 2026

OIC – Automate OIC Observability Instance Report and Send via Email

Requirement

Build an Oracle Integration Cloud (OIC) integration that fetches OIC Observability / Integration Instance details for a given From Date and To Date, generates a report file, and sends it over email as an attachment.

Use Case

Operations/support teams often need execution details for a specific date range. Instead of manually downloading instance reports from monitoring, this integration automates the process.

Solution Flow

REST Trigger (Input Dates)

→ Call OIC Factory/Monitoring REST API

→ Fetch Instance Details

→ Write Response into File

→ Send Notification Email with Attachment

Step 1: Create REST Trigger Integration

Create an App Driven Orchestration.

Configure trigger request payload:

{

  "MyId": "101",

  "Email": "test@test.com",

  "Query": "{startdate:'2026-01-14 10:00:00',enddate:'2026-01-15 10:00:00'}"

}

Input Parameters:

MyId – Request identifier

Email – Recipient email

Query – Date filter containing:

startdate

enddate

Step 2: Configure OIC Factory / Monitoring Service

Add REST Invoke.

Example configuration:

Endpoint Name

GetOICInstances

Relative URI

/ic/api/integration/v1/monitoring/integrations

Method:

GET

Enable:

Add and review parameters

Configure endpoint to receive response


Step 3: Map Query Parameters

Map the incoming Query field to REST query parameter.

Example:

startdate → request input

enddate → request input

This allows runtime filtering of observability/instance records.

Step 4: Invoke Monitoring API

Construct request dynamically.

Example:

?fromDate=2026-01-14T10:00:00

&toDate=2026-01-15T10:00:00

Expected output:

Integration Name

Instance Id

Status

Start Time

End Time

Execution details

Sample Response:

{

  "items": [

    {

      "code": "CUSTOMER_COMMON_01|DVS_RTP|01.0.0000",

      "projectCode": "CUSTOMER_COMMON_01",

      "integrationName": "DVS_RTP",

      "integrationId": "DVS_RTP",

      "integrationVersion": "01.0.0000",

      "scheduled": false,

      "flowStatus": "ACTIVATED",

      "noOfMsgs": 120,

      "noOfMsgsSuccess": 115,

      "noOfMsgsFailed": 3,

      "noOfMsgsAborted": 2,

      "lastUpdated": "2026-06-30T07:45:22.000+0000"

    },

    {

      "code": "COMMON|CLP_COMMON_GET|01.0.0001",

      "projectCode": "COMMON",

      "integrationName": "CLP_COMMON_GET",

      "integrationId": "CLP_COMMON_GET",

      "integrationVersion": "01.0.0001",

      "scheduled": true,

      "flowStatus": "ACTIVATED",

      "noOfMsgs": 580,

      "noOfMsgsSuccess": 570,

      "noOfMsgsFailed": 10,

      "noOfMsgsAborted": 0,

      "lastUpdated": "2026-06-30T08:15:30.000+0000"

    }

  ],

  "totalResults": 2,

  "limit": 100,

  "offset": 0,

  "hasMore": false

}

Step 5: Write Response to Stage File

Add Stage File → Write File.

Example:

Directory:

/tmp

File:

OIC_Instance_Report.json

Write API response into file.

You may also convert JSON → CSV before writing if business users prefer Excel-friendly output.




Step 6: Send Email Notification

Use Notification Action.

Configure:

To → Email input

Subject

OIC Observability Instance Report

Body:

Please find attached OIC instance execution report for requested date range.

Attach generated file from Stage File.


Benefits

Removes manual monitoring effort

Easy reporting for support teams

Date-driven execution

Reusable utility integration for observability reporting

You can additionally enhance this by:

Generating CSV instead of JSON

Scheduling via Scheduled Integration

Uploading reports to UCM/Object Storage before emailing

Reference:

https://docs.oracle.com/en/cloud/paas/integration-cloud/rest-api/op-ic-api-integration-v1-monitoring-integrations-get.html?source=%3Aow%3Ams%3Apt%3A%3A&utm_source=chatgpt.com 

No comments:

Post a Comment

Featured Post

OIC – Automate OIC Observability Instance Report and Send via Email

Requirement Build an Oracle Integration Cloud (OIC) integration that fetches OIC Observability / Integration Instance details for a given Fr...