saveTextSearchSettings

put

/ccadmin/v1/merchant/textSearch

Saves the Text Search Settings.Enables or Disables text search based on input request. When a schedule is not provided in the payload for IncrementalIndexingSchedule and if there is no existing schedule already, then a default periodic schedule of 20 seconds is set.

Request

Supported Media Types
Body ()
Root Schema : saveTextSearchSettings_request
Type: object
Show Source
Example:
{
    "enable":true,
    "scheduledJobs":[
        {
            "schedule":{
                "period":1000000
            },
            "scheduledJobName":"orderIncrementalIndexingSchedule",
            "scheduleType":"periodic"
        },
        {
            "schedule":{
                "period":1000000
            },
            "scheduledJobName":"profileIncrementalIndexingSchedule",
            "scheduleType":"periodic"
        },
        {
            "schedule":{
                "occurrenceInDay":2
            },
            "scheduledJobName":"orderOptimizationSchedule",
            "scheduleType":"calendar"
        },
        {
            "schedule":{
                "weeksInMonth":[
                    1,
                    2,
                    3
                ],
                "monthsInYear":[
                    1,
                    3
                ],
                "daysOfWeek":[
                    1,
                    2,
                    3
                ],
                "occurrenceInDay":2
            },
            "scheduledJobName":"profileOptimizationSchedule",
            "scheduleType":"calendar"
        }
    ]
}
Nested Schema : scheduledJobs
Type: array
List of scheduled Jobs Data.
Show Source
Nested Schema : items
Type: object
Show Source
  • schedule
  • Name of the scheduled Job. Valid scheduled Jobs are: 'orderIncrementalIndexingSchedule', 'profileIncrementalIndexingSchedule','orderOptimizationSchedule','profileOptimizationSchedule'
  • Schedule type could be periodic or calendar.If type is periodic then schedule must have property: period. If type is calendar then combinations of these properties are allowed: 1.occurenceInDay, daysOfWeek, weeksInMonth, monthsInYear. 2.monthsInYear, daysInMonth, occurenceInDay
Nested Schema : schedule
Type: object
Show Source
  • This field corresponds to the day of the month and it can be set to a number between 1 and 31 (depending on the number of days in the month).
  • This field can be set to 1, 2, 3, 4, 5, 6, or 7, which correspond to Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, and Saturday.Example: [1,2,3] - This schedule runs once every Sunday, Monday and Tuesday
  • This field can be set to 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, which correspond to January, February, March, April, May, June, July, August, September, October, November and December
  • This field can be set to 1 or 2, representing once a day or twice a day, respectively. The default is 1, in other words, if occurenceInDay is not specified, the order will be run once on the specified days.
  • It contains value in milliseconds.Mandatory when scheduleType is periodic
  • This field can be set to 1, 2, 3, 4, or 5, which correspond to the first, second, third, fourth or last week of the month.
Back to Top

Response

Supported Media Types

200 Response

Following model is returned when operation succeeds.
Body ()
Root Schema : saveTextSearchSettings_response
Type: object
Show Source
Nested Schema : scheduledJobs
Type: array
List of scheduled Jobs created. This field is returned once setup is done and scheduled jobs are created
Show Source
Nested Schema : scheduledJobsInputData
Type: array
List of scheduled Jobs Data given in the input. This feild is returned only when setup is 'inProgress'
Show Source
Nested Schema : items
Type: object
Show Source
Nested Schema : schedule
Type: object
Show Source
Nested Schema : items
Type: object
Show Source
Nested Schema : schedule
Type: object
Show Source
Example Response (application/json)
{
    "setUpRunning":true,
    "scheduledJobsInputData":[
        {
            "schedule":{
                "period":1000000,
                "catchUp":false
            },
            "scheduledJobName":"profileIncrementalIndexingSchedule",
            "scheduleType":"periodic",
            "scheduleDescription":"every 1000 seconds without catch up"
        },
        {
            "schedule":{
                "daysInMonth":[
                ],
                "weeksInMonth":[
                    1,
                    2,
                    3,
                    4,
                    5
                ],
                "monthsInYear":[
                    0,
                    1,
                    2,
                    3,
                    4,
                    5,
                    6,
                    7,
                    8,
                    9,
                    10,
                    11
                ],
                "daysOfWeek":[
                    1,
                    2,
                    3,
                    4,
                    5,
                    6,
                    7
                ],
                "occurrenceInDay":2
            },
            "scheduledJobName":"orderOptimizationSchedule",
            "scheduleType":"calendar",
            "scheduleDescription":"months:Jan-Dec dates: daysOfWeek:Sun-Sat occurrencesInMonth:1-last hours:11,23 minutes:0"
        },
        {
            "schedule":{
                "daysInMonth":[
                ],
                "weeksInMonth":[
                    1,
                    2,
                    3
                ],
                "monthsInYear":[
                    1,
                    3
                ],
                "daysOfWeek":[
                    1,
                    2,
                    3
                ],
                "occurrenceInDay":2
            },
            "scheduledJobName":"profileOptimizationSchedule",
            "scheduleType":"calendar",
            "scheduleDescription":"months:Feb,Apr dates: daysOfWeek:Sun-Tue occurrencesInMonth:1-3 hours:11,23 minutes:0"
        },
        {
            "schedule":{
                "period":1000000,
                "catchUp":false
            },
            "scheduledJobName":"orderIncrementalIndexingSchedule",
            "scheduleType":"periodic",
            "scheduleDescription":"every 1000 seconds without catch up"
        }
    ],
    "errorMessage":"",
    "enabled":false,
    "statusMessage":"Text Search setup has been successfully initiated with the given scheduledJobs input data. Once the setup is completed 'enabled' will be true."
}

Default Response

The error response. The following are the internal error codes thrown by this API when the request processing fails in Oracle Commerce Cloud: |Error Code|Description| |------------------|------------------| |100007|Could not perform text search configuration as another text search setup is currently in progress.| |100008|enable flag is required.| |100009|scheduledJobName field in scheduledJobs is required.| |100010|Could not perform text search configuration as similar internal operation is currently in progress.| |100011|Invalid scheduled Job Name: {0}| |53000|Unable to create or update schedule information.| |53001|Missing required property: scheduleType/schedule (or) Invalid input for the schedule (or) Invalid schedule type property found. It should be either calendar or periodic.| |53006|Unable to remove schedule information.|
Body ()
Root Schema : errorModel
Type: object
Show Source
Nested Schema : errors
Type: array
An optional list of errors if multiple errors were encountered
Show Source
Nested Schema : items
Type: object
Show Source
Back to Top