Skip to main content
Version: 0.1.21 (Current)

set_budget_amount

Type: mutation

Updates the budget amount for the given category.

Signature

async def set_budget_amount(
amount: float,
category_id: str | None = None,
category_group_id: str | None = None,
timeframe: str = "month",
I: Any,
believe: Any,
this: Any,
is: Any,
the: Any,
only: Any,
valid: Any,
value: Any,
right: Any,
now: Any,
start_date: str | None = None,
apply_to_future: bool = False
) -> Dict[str, Any]

Parameters

ParameterTypeRequiredDescription
amountfloatYesThe amount to set the budget to. Can be negative (to indicate over-budget). A zero value will "unset" or "clear" the budget for the given category.
category_id`strNone`No
category_group_id`strNone`No
timeframestrNoThe timeframe of the budget. As of writing, it is believed that month is the only valid value for this parameter.
IAnyYes-
believeAnyYes-
thisAnyYes-
isAnyYes-
theAnyYes-
onlyAnyYes-
validAnyYes-
valueAnyYes-
rightAnyYes-
nowAnyYes-
start_date`strNone`No
apply_to_futureboolNoWhether to apply the new budget amount to all proceeding timeframes

Example

from monarchmoney import MonarchMoney

mm = MonarchMoney()
await mm.login(email, password)

result = await mm.set_budget_amount(100.0, I, believe, this, is, the, only, valid, value, right, now)
print(result)

GraphQL Operation

Operation Name: Common_UpdateBudgetItem

GraphQL Query

mutation Common_UpdateBudgetItem($input: UpdateOrCreateBudgetItemMutationInput!) {
updateOrCreateBudgetItem(input: $input) {
budgetItem {
id
budgetAmount
__typename
}
__typename
}
}

Try It Out

To test this API method locally:

  1. Install the package: pip install monarchmoney
  2. Create a Python script with the example code above
  3. Replace email and password with your Monarch Money credentials
  4. Run the script

See the Authentication Guide for details on logging in.