push/stop

Stop a Historics query or a live stream that is running with Push.

An HTTP PUT request sent to:

https://api.datasift.com/v1.3/push/stop

A successful call to this endpoint returns: 200 OK.

Parameters

Parameter Description
id
required

The id of the Subscription you want to stop.

Example values: 08b923395b6ce8bfa4d96f57f863a1c3

Examples

Stop a Historics query or a live stream that is running with Push.

curl -X PUT 'https://api.datasift.com/v1.3/push/stop' 
    -d 'id=d468655cfe5f93741ddcd30bb309a8c7' 
    -H 'Authorization: datasift-user:your-datasift-api-key'

Here's an example of the JSON output:

{
    "id": "d468655cfe5f93741ddcd30bb309a8c7",
    "output_type": "dynamodb",
    "name": "mypushsubscription",
    "created_at": 1365430066,
    "user_id": 12635,
    "hash": "0dddb9bb2f6e8f3f2de405f6c1a2b21e",
    "hash_type": "stream",
    "output_params": {
        "region": "dynamodb.eu-west-1.amazonaws.com",
        "bucket": "datasift-s3",
        "directory": "interactions",
        "acl": "private",
        "delivery_frequency": 60,
        "max_size": 102400,
        "file_prefix": "Datasift"
    },
    "status": "finishing",
    "last_request": 1365438298,
    "last_success": 1365435315,
    "remaining_bytes": null,
    "lost_data": false,
    "start": null,
    "end": null
}

Property: Description:
id A unique ID of the newly created Push subscription. Each new subscription has a different ID, even when they are based on the same stream and the data is delivered to the same destination.
output_type The name of the output type. See the list of the values of the output_type parameter elsewhere on this page.
name A user-defined name of the subscription.
created_at A Unix timestamp that represents the date and time when the subscription was created.
user_id The DataSift ID of the user who created the subscription.
hash A stream ID or Historics query ID.
hash_type Can be either "hash" (when the hash element represents a stream) or "historics" (when the hash element represents a Historics query).
output_params output_parameters used in the call to /push/create.
status Subscription status.
last_request The time of the most recent Push delivery request sent to the associate data destination. A Unix timestamp.
last_success The time of the most recent successful delivery. A Unix timestamp.
remaining_bytes The number of bytes queued for delivery.
lost_data Set to true if data was removed from the Push delivery queue because it could not be delivered.
start Subscription start time/date. A Unix timestamp.
end Subscription end time. A Unix timestamp.

Notes

  1. All calls to the API must be properly authenticated with a DataSift username and API key.
  2. The /push/stop endpoint allows you to stop a Historics query or a live stream that is running with Push.
  3. For more details, take a look at the Push API overview.
  4. All calls to the API must be versioned. The current version is v1.3.

Resource information

Rate limit cost: 1

Requires authentication: Yes

Response formats: JSON, JSONP