Use the Push API

The Push API exposes services that let you push items and their permission models into a source, and security identities into a security identity provider, rather than letting standard Coveo crawlers pull this content.

The Push API doesn’t have a graphical user interface, so you need to perform your own HTTP calls to use its services.

The articles in this section explain how to use the Push API.

Architecture diagram

The following diagram shows the main interactions between a custom crawler, the Push API, and a Coveo organization.

Push API interaction diagram | Coveo

Prerequisites

To index content using the Push API, you need the following:

  1. A Push source.

  2. A security identity provider, if your Push source is secured.

  3. Fields to receive the metadata you want to push.

See the Push source creation and post-creation steps for detailed instructions.

Push API usage

After completing the setup covered in the prerequisites section, you can use the Push API. This involves writing code that will run periodically to:

Tip

If you haven’t used the Push API before, we recommend checking the Push API usage example or following the tutorials.

Interactive reference documentation for your region is available through the Swagger UI ( US  |  EU  |  AU  |  CA ).

Leading practices

Keep the following leading practices in mind when using the Push API.

Avoid performing Push API operations on product-managed sources

Never perform Push API operations to interact directly with Coveo Crawling Module or Coveo for Sitecore Push sources. Otherwise, you risk causing irreparable damage to your index.

Avoid setting orderingId values

Let the service set the orderingId value automatically, except when performing delete older than operations.

If you have a good reason for setting your own orderingId values, proceed with caution.

Prioritize batch operations

Only use single item and security identity operations when testing or performing small updates. Use batch item and batch security identity operations the rest of the time.

Using batch operations allows you to keep your number of Push API calls per hour relatively low. See Push API limits.

Update your Push source status

Consider updating the status of a Push source before and after each set of content update operations.

For example, right before you start a process to index new or updated content, you should set the status of the source to REBUILD, RESCAN, or REFRESH, as appropriate. When you’re done, you should set the status back to IDLE.

Updating your Push source status allows you to keep coherent source activity logs in your Coveo organization.