The SetHITTypeNotification operation
creates, updates, disables or re-enables notifications for a HIT
type.
When a HIT type has an active notification, Mechanical Turk will
attempt to send a notification message when a HIT of the type
changes state, such as when an assignment is submitted for the
HIT. The state changes to watch and the method of notification
are described in the notification specification given to
SetHITTypeNotification.
If SetHITTypeNotification is called for a
HIT type that already has a notification specification, it
replaces the old specification with a new one.
You can also call SetHITTypeNotification to
enable or disable notifications for the HIT type, without having
to modify the notification specification itself.
You cannot delete a notification specification for a HIT type, you can only disable it.
Note: |
Changes to a HIT type's notification specification may take up
to five minutes to take effect after the call to
|
For more information on notifications, see Notifications. For more information on developing a notification receptor application, see The Notification Receptor API.
The following example of a call to the
SetHITTypeNotification operation sets the
notification specification for a HIT type to send the
Requester e-mail whenever a Worker submits an assignment for a
HIT of the type.
http://mechanicalturk.amazonaws.com/onca/xml?Service=AWSMechanicalTurkRequester &AWSAccessKeyId=[the Requester's Access Key ID]&Operation=SetHITTypeNotification &Signature=[signature for this request]&Timestamp=[your system's local time]&HITTypeId=T100CN9P324W00EXAMPLE &Notification.1.Destination=requester-email@example.com &Notification.1.Transport=Email &Notification.1.Version=2006-08-23 &Notification.1.EventType=AssignmentSubmitted
A request to the Mechanical Turk Service includes parameters that control its behavior and the data it returns. Required parameters must be included for the request to succeed.
SetHITTypeNotification accepts parameters common to all operations. Some common parameters are required. See Common Parameters for more information.
The following parameters are specific to the SetHITTypeNotification operation:
| Name | Description | Type | Value |
|---|---|---|---|
Operation
|
The operation you would like to call. To access the
| Required |
|
HITTypeId
|
The ID of the HIT type whose notification
specification is being updated, as returned by
| Required |
A valid HIT type ID |
Notification
|
The notification specification for the HIT type. This parameter is optional. If not specified, the HIT type's notification specification (if any) is not modified.
Either | Optional |
A Notification data structure. For more information on the data structure of a notification specification, see the Notification Data Structure. |
Active
|
If
This value can be changed for a HIT type at any time
by calling this operation. You can specify changes to
the active status without specifying a new
notification specification (the
This parameter is optional. If omitted, the active status of the HIT type's notification specification is unchanged. All HIT types begin with their notification specifications in the "active" status.
To change the
Either | Optional |
A Boolean value, |