Skip to main content

budgets

Creates, updates, deletes, gets or lists a budgets resource.

Overview

Namebudgets
TypeResource
Idaws.deadline.budgets

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
actionsarrayThe budget actions for the budget.
approximate_dollar_limitnumber (float)The consumed usage limit for the budget.
budget_idstringThe budget ID. (pattern: <code>budget-[0-9a-f]{32}</code>)
created_atstring (date-time)The date and time the resource was created.
created_bystringThe user or system that created this resource.
descriptionstringThe description of the budget. This field can store any content. Escape or encode this content before displaying it on a webpage or any other system that might interpret the content of this field.
display_namestringThe display name of the budget. This field can store any content. Escape or encode this content before displaying it on a webpage or any other system that might interpret the content of this field.
queue_stopped_atstring (date-time)The date and time the queue stopped.
scheduleobjectThe start and end time of the budget.
statusstringThe status of the budget. ACTIVE–Get a budget being evaluated. INACTIVE–Get an inactive budget. This can include expired, canceled, or deleted statuses. (ACTIVE, INACTIVE)
updated_atstring (date-time)The date and time the resource was updated.
updated_bystringThe user or system that updated this resource.
usage_tracking_resourceobjectThe usage details of the allotted budget.
usagesobjectThe usages of the budget.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_budgetselectfarm_id, budget_id, regionGet a budget.
list_budgetsselectfarm_id, regionnextToken, maxResults, statusA list of budgets in a farm.
create_budgetinsertfarm_id, region, displayName, usageTrackingResource, approximateDollarLimit, actions, scheduleX-Amz-Client-TokenCreates a budget to set spending thresholds for your rendering activity.
update_budgetupdatefarm_id, budget_id, regionX-Amz-Client-TokenUpdates a budget that sets spending thresholds for rendering activity.
delete_budgetdeletefarm_id, budget_id, regionDeletes a budget.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
budget_idstringThe budget ID of the budget to delete.
farm_idstringThe farm ID of the farm to remove from the budget.
regionstringAWS region (default: us-east-1)
X-Amz-Client-TokenstringThe unique token which the server uses to recognize retries of the same request.
maxResultsintegerThe maximum number of results to return. Use this parameter with NextToken to get results as a set of sequential pages.
nextTokenstringThe token for the next set of results, or null to start from the beginning.
statusstringThe status to list for the budgets.

SELECT examples

Get a budget.

SELECT
actions,
approximate_dollar_limit,
budget_id,
created_at,
created_by,
description,
display_name,
queue_stopped_at,
schedule,
status,
updated_at,
updated_by,
usage_tracking_resource,
usages
FROM aws.deadline.budgets
WHERE farm_id = '{{ farm_id }}' -- required
AND budget_id = '{{ budget_id }}' -- required
AND region = '{{ region }}' -- required
;

INSERT examples

Creates a budget to set spending thresholds for your rendering activity.

INSERT INTO aws.deadline.budgets (
displayName,
description,
usageTrackingResource,
approximateDollarLimit,
actions,
schedule,
tags,
farm_id,
region,
`X-Amz-Client-Token`
)
SELECT
'{{ displayName }}' /* required */,
'{{ description }}',
'{{ usageTrackingResource }}' /* required */,
{{ approximateDollarLimit }} /* required */,
'{{ actions }}' /* required */,
'{{ schedule }}' /* required */,
'{{ tags }}',
'{{ farm_id }}',
'{{ region }}',
'{{ X-Amz-Client-Token }}'
RETURNING
budget_id
;

UPDATE examples

Updates a budget that sets spending thresholds for rendering activity.

UPDATE aws.deadline.budgets
SET
displayName = '{{ displayName }}',
description = '{{ description }}',
status = '{{ status }}',
approximateDollarLimit = {{ approximateDollarLimit }},
actionsToAdd = '{{ actionsToAdd }}',
actionsToRemove = '{{ actionsToRemove }}',
schedule = '{{ schedule }}'
WHERE
farm_id = '{{ farm_id }}' --required
AND budget_id = '{{ budget_id }}' --required
AND region = '{{ region }}' --required
AND `X-Amz-Client-Token` = '{{ X-Amz-Client-Token}}';

DELETE examples

Deletes a budget.

DELETE FROM aws.deadline.budgets
WHERE farm_id = '{{ farm_id }}' --required
AND budget_id = '{{ budget_id }}' --required
AND region = '{{ region }}' --required
;