Skip to content

aws.mturk.get_hit

Example SQL Queries

SELECT * FROM
aws.mturk.get_hit
WHERE
"hit_id" = 'VALUE';

Description

The GetHIT operation retrieves the details of the specified HIT.

Table Definition

Column NameColumn Data Type
hit_id Required Input Column

The ID of the HIT to be retrieved.

VARCHAR
_aws_profile Input Column

The AWS profile defines the AWS identity used. It can be defined via credentials or by assuming a IAM role.

STRUCT(
"type" VARCHAR,
"name" VARCHAR,
"account_id" VARCHAR,
"via_profile_name" VARCHAR,
"assumed_role_arn" VARCHAR,
"organization" STRUCT(
"account_name" VARCHAR,
"id" VARCHAR,
"tags" STRUCT(
"key" VARCHAR,
"value" VARCHAR
)[],
"master_account" STRUCT(
"id" VARCHAR,
"email" VARCHAR
),
"parents" STRUCT(
"type" VARCHAR,
"id" VARCHAR,
"name" VARCHAR,
"tags" STRUCT(
"key" VARCHAR,
"value" VARCHAR
)[]
)[]
)
)
Show child fields
_aws_profile.account_id

The AWS account id

_aws_profile.assumed_role_arn

The ARN of the assumed role

_aws_profile.name

The unique name of the profile.

_aws_profile.organization

Information about this profile's membership in the AWS organization.

Show child fields
_aws_profile.organization.account_name

The name of account speciifed by the organization

_aws_profile.organization.id

The organization id

_aws_profile.organization.master_account
Show child fields
_aws_profile.organization.master_account.email

The organization master account email address

_aws_profile.organization.master_account.id

The organization master account id

_aws_profile.organization.parents[]
Show child fields
_aws_profile.organization.parents[].id

The id of the parent

_aws_profile.organization.parents[].name

The name of the parent

_aws_profile.organization.parents[].tags[]
Show child fields
_aws_profile.organization.parents[].tags[].key
_aws_profile.organization.parents[].tags[].value
_aws_profile.organization.parents[].type

The type of parent can be an organization unit or a root

_aws_profile.organization.tags[]
Show child fields
_aws_profile.organization.tags[].key
_aws_profile.organization.tags[].value
_aws_profile.type

The type of profile, either 'credentials' or 'assumed_role'

_aws_profile.via_profile_name

This IAM role for this profile is assumed by first utilizing another profile with this name to obtain credentials.

hit

Contains the requested HIT data.

STRUCT(
"hit_id" VARCHAR,
"hit_type_id" VARCHAR,
"hit_group_id" VARCHAR,
"hit_layout_id" VARCHAR,
"creation_time" TIMESTAMP_S,
"title" VARCHAR,
"description" VARCHAR,
"question" VARCHAR,
"keywords" VARCHAR,
"hit_status" VARCHAR,
"max_assignments" BIGINT,
"reward" VARCHAR,
"auto_approval_delay_in_seconds" BIGINT,
"expiration" TIMESTAMP_S,
"assignment_duration_in_seconds" BIGINT,
"requester_annotation" VARCHAR,
"qualification_requirements" STRUCT(
"qualification_type_id" VARCHAR,
"comparator" VARCHAR,
"integer_values" BIGINT[],
"locale_values" STRUCT(
"country" VARCHAR,
"subdivision" VARCHAR
)[],
"required_to_preview" BOOLEAN,
"actions_guarded" VARCHAR
)[],
"hit_review_status" VARCHAR,
"number_of_assignments_pending" BIGINT,
"number_of_assignments_available" BIGINT,
"number_of_assignments_completed" BIGINT
)
Show child fields
hit.assignment_duration_in_seconds

The length of time, in seconds, that a Worker has to complete the HIT after accepting it.

hit.auto_approval_delay_in_seconds

The amount of time, in seconds, after the Worker submits an assignment for the HIT that the results are automatically approved by Amazon Mechanical Turk. This is the amount of time the Requester has to reject an assignment submitted by a Worker before the assignment is auto-approved and the Worker is paid.

hit.creation_time

The date and time the HIT was created.

hit.description

A general description of the HIT.

hit.expiration

The date and time the HIT expires.

hit.hit_group_id

The ID of the HIT Group of this HIT.

hit.hit_id

A unique identifier for the HIT.

hit.hit_layout_id

The ID of the HIT Layout of this HIT.

hit.hit_review_status

Indicates the review status of the HIT. Valid Values are NotReviewed | MarkedForReview | ReviewedAppropriate | ReviewedInappropriate.

hit.hit_status

The status of the HIT and its assignments. Valid Values are Assignable | Unassignable | Reviewable | Reviewing | Disposed.

hit.hit_type_id

The ID of the HIT type of this HIT

hit.keywords

One or more words or phrases that describe the HIT, separated by commas. Search terms similar to the keywords of a HIT are more likely to have the HIT in the search results.

hit.max_assignments

The number of times the HIT can be accepted and completed before the HIT becomes unavailable.

hit.number_of_assignments_available

The number of assignments for this HIT that are available for Workers to accept.

hit.number_of_assignments_completed

The number of assignments for this HIT that have been approved or rejected.

hit.number_of_assignments_pending

The number of assignments for this HIT that are being previewed or have been accepted by Workers, but have not yet been submitted, returned, or abandoned.

hit.qualification_requirements[]
Show child fields
hit.qualification_requirements[].actions_guarded

Setting this attribute prevents Workers whose Qualifications do not meet this QualificationRequirement from taking the specified action. Valid arguments include "Accept" (Worker cannot accept the HIT, but can preview the HIT and see it in their search results), "PreviewAndAccept" (Worker cannot accept or preview the HIT, but can see the HIT in their search results), and "DiscoverPreviewAndAccept" (Worker cannot accept, preview, or see the HIT in their search results). It's possible for you to create a HIT with multiple QualificationRequirements (which can have different values for the ActionGuarded attribute). In this case, the Worker is only permitted to perform an action when they have met all QualificationRequirements guarding the action. The actions in the order of least restrictive to most restrictive are Discover, Preview and Accept. For example, if a Worker meets all QualificationRequirements that are set to DiscoverPreviewAndAccept, but do not meet all requirements that are set with PreviewAndAccept, then the Worker will be able to Discover, i.e. see the HIT in their search result, but will not be able to Preview or Accept the HIT. ActionsGuarded should not be used in combination with the RequiredToPreview field.

hit.qualification_requirements[].comparator

The kind of comparison to make against a Qualification's value. You can compare a Qualification's value to an IntegerValue to see if it is LessThan, LessThanOrEqualTo, GreaterThan, GreaterThanOrEqualTo, EqualTo, or NotEqualTo the IntegerValue. You can compare it to a LocaleValue to see if it is EqualTo, or NotEqualTo the LocaleValue. You can check to see if the value is In or NotIn a set of IntegerValue or LocaleValue values. Lastly, a Qualification requirement can also test if a Qualification Exists or DoesNotExist in the user's profile, regardless of its value.

hit.qualification_requirements[].integer_values[]
hit.qualification_requirements[].locale_values[]
Show child fields
hit.qualification_requirements[].locale_values[].country

The country of the locale. Must be a valid ISO 3166 country code. For example, the code US refers to the United States of America.

hit.qualification_requirements[].locale_values[].subdivision

The state or subdivision of the locale. A valid ISO 3166-2 subdivision code. For example, the code WA refers to the state of Washington.

hit.qualification_requirements[].qualification_type_id

The ID of the Qualification type for the requirement.

hit.qualification_requirements[].required_to_preview

DEPRECATED: Use the ActionsGuarded field instead. If RequiredToPreview is true, the question data for the HIT will not be shown when a Worker whose Qualifications do not meet this requirement tries to preview the HIT. That is, a Worker's Qualifications must meet all of the requirements for which RequiredToPreview is true in order to preview the HIT. If a Worker meets all of the requirements where RequiredToPreview is true (or if there are no such requirements), but does not meet all of the requirements for the HIT, the Worker will be allowed to preview the HIT's question data, but will not be allowed to accept and complete the HIT. The default is false. This should not be used in combination with the ActionsGuarded field.

hit.question

The data the Worker completing the HIT uses produce the results. This is either either a QuestionForm, HTMLQuestion or an ExternalQuestion data structure.

hit.requester_annotation

An arbitrary data field the Requester who created the HIT can use. This field is visible only to the creator of the HIT.

hit.reward

A string representing a currency amount.

hit.title

The title of the HIT.