DeadlineCloud / Client / update_budget

update_budget#

DeadlineCloud.Client.update_budget(**kwargs)#

Updates a budget that sets spending thresholds for rendering activity.

See also: AWS API Documentation

Request Syntax

response = client.update_budget(
    actionsToAdd=[
        {
            'description': 'string',
            'thresholdPercentage': ...,
            'type': 'STOP_SCHEDULING_AND_COMPLETE_TASKS'|'STOP_SCHEDULING_AND_CANCEL_TASKS'
        },
    ],
    actionsToRemove=[
        {
            'thresholdPercentage': ...,
            'type': 'STOP_SCHEDULING_AND_COMPLETE_TASKS'|'STOP_SCHEDULING_AND_CANCEL_TASKS'
        },
    ],
    approximateDollarLimit=...,
    budgetId='string',
    clientToken='string',
    description='string',
    displayName='string',
    farmId='string',
    schedule={
        'fixed': {
            'endTime': datetime(2015, 1, 1),
            'startTime': datetime(2015, 1, 1)
        }
    },
    status='ACTIVE'|'INACTIVE'
)
Parameters:
  • actionsToAdd (list) –

    The budget actions to add. Budget actions specify what happens when the budget runs out.

    • (dict) –

      The budget action to add.

      • description (string) –

        A description for the budget action to add.

      • thresholdPercentage (float) – [REQUIRED]

        The percentage threshold for the budget action to add.

      • type (string) – [REQUIRED]

        The type of budget action to add.

  • actionsToRemove (list) –

    The budget actions to remove from the budget.

    • (dict) –

      The budget action to remove.

      • thresholdPercentage (float) – [REQUIRED]

        The percentage threshold for the budget action to remove.

      • type (string) – [REQUIRED]

        The type of budget action to remove.

  • approximateDollarLimit (float) – The dollar limit to update on the budget. Based on consumed usage.

  • budgetId (string) –

    [REQUIRED]

    The budget ID to update.

  • clientToken (string) –

    The unique token which the server uses to recognize retries of the same request.

    This field is autopopulated if not provided.

  • description (string) – The description of the budget to update.

  • displayName (string) – The display name of the budget to update.

  • farmId (string) –

    [REQUIRED]

    The farm ID of the budget to update.

  • schedule (dict) –

    The schedule to update.

    Note

    This is a Tagged Union structure. Only one of the following top level keys can be set: fixed.

    • fixed (dict) –

      The fixed start and end time of the budget’s schedule.

      • endTime (datetime) – [REQUIRED]

        When the budget ends.

      • startTime (datetime) – [REQUIRED]

        When the budget starts.

  • status (string) –

    Updates the status of the budget.

    • ACTIVE–The budget is being evaluated.

    • INACTIVE–The budget is inactive. This can include Expired, Canceled, or deleted Deleted statuses.

Return type:

dict

Returns:

Response Syntax

{}

Response Structure

  • (dict) –

Exceptions

  • DeadlineCloud.Client.exceptions.AccessDeniedException

  • DeadlineCloud.Client.exceptions.InternalServerErrorException

  • DeadlineCloud.Client.exceptions.ResourceNotFoundException

  • DeadlineCloud.Client.exceptions.ThrottlingException

  • DeadlineCloud.Client.exceptions.ValidationException