Skip to main content
PATCH
/
2
/
tasks
/
{taskID}
curl
curl --request PATCH \
  --url https://data.us.algolia.com/2/tasks/6c02aeb1-775e-418e-870b-1faccd4b2c0f \
  --header 'accept: application/json' \
  --header 'content-type: application/json' \
  --header 'x-algolia-api-key: ALGOLIA_API_KEY' \
  --header 'x-algolia-application-id: ALGOLIA_APPLICATION_ID' \
  --data '{"destinationID":"6c02aeb1-775e-418e-870b-1faccd4b2c0f","cron":"* * 1 * *","input":{"mapping":{"format":"mappingkit/v1","actions":[{"id":"lorem","enabled":true,"trigger":"lorem","fieldDirectives":[{"fieldKey":"lorem","value":{}}]}]}},"enabled":true,"subscriptionAction":"replace","failureThreshold":0,"notifications":{"email":{"enabled":true}},"policies":{"criticalThreshold":1}}'
{
  "taskID": "6c02aeb1-775e-418e-870b-1faccd4b2c0f",
  "updatedAt": "<string>"
}

Authorizations

x-algolia-application-id
string
header
required

Your Algolia application ID.

x-algolia-api-key
string
header
required

Your Algolia API key with the necessary permissions to make the request. Permissions are controlled through access control lists (ACL) and access restrictions. The required ACL to make a request is listed in each endpoint's reference.

Path Parameters

taskID
string
required

Unique identifier of a task.

Example:

"6c02aeb1-775e-418e-870b-1faccd4b2c0f"

Body

application/json

API request body for partially updating a task.

destinationID
string

Universally unique identifier (UUID) of a destination resource.

Example:

"6c02aeb1-775e-418e-870b-1faccd4b2c0f"

cron
string

Cron expression for the task's schedule.

Example:

"* * 1 * *"

input
object

Configuration of the task, depending on its type. Input for a streaming task whose source is of type ga4BigqueryExport and for which extracted data is continuously streamed.

  • Option 1
  • Option 2
  • Option 3
enabled
boolean

Whether the task is enabled.

subscriptionAction
enum<string>

Action to perform on the Algolia index.

Available options:
replace,
save,
partial,
partialNoCreate,
append
failureThreshold
integer

Maximum accepted percentage of failures for a task run to finish successfully.

Required range: 0 <= x <= 100
notifications
object

Notifications settings for a task.

policies
object

Set of rules for a task.

Response

OK

API response for updating a task.

taskID
string
required

Universally unique identifier (UUID) of a task.

Example:

"6c02aeb1-775e-418e-870b-1faccd4b2c0f"

updatedAt
string
required

Date of last update in RFC 3339 format.

I