Managed Sources API Step-by-Step

API endpoints allow you to create, update and delete managed sources, add or remove individual resources or access tokens, and pause or restart existing sources.

Creating and consuming data from a source

To consume data using a managed source:

  1. Before you can consume data from a managed source you need to agree to the license agreement for the source.

    Go to your dashboard and select the managed source you'd like to use. Agree to the license agreement.

  2. Create a source using /source/create.

    You will need to provide your DataSift credentials as well as a list of resources to monitor and credentials specific to a particular data source. A new Managed Source is available as soon as you create it.

    Options available for each source are detailed on the /source/create endpoint page.

  3. Make a note of the id returned by /source/create.

    This id will be used to manage your source and obtain information about its status via /source/get. It is also required by /source/update and /source/delete.

  4. Reference the source instance in a filter.

    You can use the target to filter for data specific to that source: == "2bd73078a7cb430769a1c128025d7c7f"

    or the interaction.type target for data specific to a source type:

    interaction.type == "facebook_page"

  5. Start consuming the output of the filter.

    warning icon

    You must begin to consume the output before you hit /source/start to start your Managed Source. When you start the source, it sends a backlog of interactions in a burst before it starts to send interactions in real time.

  6. Call /source/start to kick off your managed source.

Managing your source

Once your source is running you can manage the source as follows:

  • To check the status of your sources call /source/get and check the status field for each source.

  • To stop a source call /source/stop, this will pause delivery of interactions. Calling /source/start on a stopped source will restart the source and resume delivery of interactions.

  • To update the settings for a source you can use the following endpoints:

  • To delete a source /source/delete.

  • To check the health of a source call /source/log. This endpoint returns any errors logged by a source.