How to Fetch Data Extract Schedules in Oracle RODS Using REST APIs

While you can easily view extract schedules using the RODS Data Extraction UI, you may sometimes need to fetch them programmatically via REST APIs. This is useful for automating tasks, such as cleaning up completed or old schedules.

Data Extraction Schedules UI:


RODS REST API Endpoint:

GET https://fa-test.fa.ocs.oraclecloud.com/api/boss/data/objects/ora/scmCore/dataExtract/v1/extractSchedules?$filter=frequency%20=%20%27Immediate%27&$limit=25&$offset=0&$sortBy=scheduleId%3AAsc&$fields=extractType,name,scheduleId,status,frequency,extractDefinition.name,extractDefinition.overrideProperties

Query parameters:

$filter : Filters results based on criteria like schedule name or frequency (e.g., frequency = 'Immediate')

$limit : Sets the maximum number of records returned in a single response (e.g., 25)

$offset : Defines the starting index for pagination.

$sortBy : Sorts the output by a specific field (e.g., scheduleId:Asc).

$fields : Specifies which attributes to include in the response payload.

Response:

{

    "items": [

        {

            "extractType": "Incremental",

            "name": "TEST_HP_JOB_11052026_01",

            "scheduleId": "9976262",

            "status": null,

            "frequency": "Immediate",

            "$id": "300005596387893",

            "$context": {

                "links": {

                    "$self": {

                        "href": "https://fatest-test.fa.ocs.oraclecloud.com/api/boss/data/objects/ora/scmCore/dataExtract/v1/extractSchedules/300005596387893"

                    }

                }

            },

            "extractDefinition": {

                "name": "TEST_EXTRACT_SAMPLE_SO_HDRS",

                "overrideProperties": "{\"outputDataFormat\":\"CSV\",\"historyStartDate\":\"2026-04-01T00:00:00+00:00\",\"type\":\"BV\",\"csvDelimiter\":\",\"}",

                "$id": "300005596387887",

                "$context": {

                    "links": {

                        "$self": {

                            "href": "https://fatest-test.fa.ocs.oraclecloud.com/api/boss/data/objects/ora/commonBoss/dataExport/v1/exportGroupDefinitions/300005596387887"

                        }

                    }

                }

            }

        }

    ],

    "hasMore": true

}

The API response includes a boolean field called hasMore: 

  • If hasMore is true, there are additional records to fetch. 
  • You can write a loop that increments the $offset parameter by the $limit value (e.g., offset 0, then 25, then 50) to fetch all available schedule records sequentially.



*/

No comments:

Post a Comment