> ## Documentation Index
> Fetch the complete documentation index at: https://docs.devin.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Update a budget's name, limits or parent

> Rename the budget, set or clear its own limits, or move it under another
budget.

Authorized like the internal budgets API: limits need budget.configure
on the budget's parent (the wildcard for the root); a rename needs
budget.configure and budget.share on the parent; a move needs both on
both the old and the new parent.
The limit caps the consumption charged to the budget and its
descendants in a monthly billing window; an org-linked budget's
cycle_acu_limit is also written back to the organization's ACU limit.

See [Budgets](https://docs.devin.ai/admin/billing/budgets.md#update-a-budget) for field details and examples.

## Permissions

Requires a [service user](https://docs.devin.ai/api-reference/v3/service-users/members-service-users.md) or [personal access token](https://docs.devin.ai/api-reference/personal-access-tokens.md) with the `ManageAcuLimits` permission at the enterprise level, or [delegated access](https://docs.devin.ai/admin/billing/budgets.md#who-can-manage-a-budget) to the budget.


## OpenAPI

````yaml v3-openapi.yaml PATCH /v3/enterprise/usage-policies/budgets/{budget_id}
openapi: 3.1.0
info:
  description: Devin v3 API with Service User authentication and RBAC
  title: Devin API v3
  version: 3.0.0
servers: []
security:
  - bearerAuth: []
paths:
  /v3/enterprise/usage-policies/budgets/{budget_id}:
    patch:
      tags:
        - usage-policy-budgets
      summary: Update a budget's name, limits or parent
      description: |-
        Rename the budget, set or clear its own limits, or move it under another
        budget.

        Authorized like the internal budgets API: limits need budget.configure
        on the budget's parent (the wildcard for the root); a rename needs
        budget.configure and budget.share on the parent; a move needs both on
        both the old and the new parent.
        The limit caps the consumption charged to the budget and its
        descendants in a monthly billing window; an org-linked budget's
        cycle_acu_limit is also written back to the organization's ACU limit.
      operationId: >-
        handle_update_usage_policy_budget_v3_enterprise_usage_policies_budgets__budget_id__patch
      parameters:
        - in: path
          name: budget_id
          required: true
          schema:
            title: Budget Id
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UsagePolicyBudgetUpdateRequest'
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UsagePolicyBudgetResponse'
          description: Successful Response
        '401':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Unauthorized
        '403':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Forbidden
        '404':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Not Found
        '409':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Conflict
        '410':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Gone
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Unprocessable Content
        '429':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Too Many Requests
components:
  schemas:
    UsagePolicyBudgetUpdateRequest:
      description: |-
        Partial update of a budget's name, own limits or parent. Omitted fields
        are left unchanged; null clears a limit.
      properties:
        cycle_acu_limit:
          anyOf:
            - maximum: 9223372036854776000
              minimum: 0
              type: integer
            - type: 'null'
          description: The budget's new per-cycle ACU limit; null clears it.
          title: Cycle Acu Limit
        name:
          anyOf:
            - maxLength: 255
              minLength: 1
              pattern: \S
              type: string
            - type: 'null'
          description: New display name of the budget.
          title: Name
        parent_budget_id:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            Move the budget, with its sub-budgets, under this active budget. The
            root budget cannot be moved.
          title: Parent Budget Id
        temporary_cycle_acu_limit:
          anyOf:
            - maximum: 9223372036854776000
              minimum: 0
              type: integer
            - type: 'null'
          description: >-
            Limit that overrides cycle_acu_limit until the end of the current
            monthly billing window; null clears it.
          title: Temporary Cycle Acu Limit
      title: UsagePolicyBudgetUpdateRequest
      type: object
    UsagePolicyBudgetResponse:
      description: |-
        A budget whose usage policies are managed under
        /usage-policies/budgets/{budget_id}/...
      properties:
        budget_id:
          description: Stable external identifier of the budget.
          title: Budget Id
          type: string
        cycle_acu_limit:
          anyOf:
            - type: integer
            - type: 'null'
          description: >-
            The budget's per-cycle ACU limit on the consumption charged to it
            and its descendants; null means unlimited.
          title: Cycle Acu Limit
        name:
          description: Display name of the budget.
          title: Name
          type: string
        org_ids:
          description: >-
            The organizations linked to this budget. Their usage counts against
            it. Empty when no organization is linked.
          items:
            type: string
          title: Org Ids
          type: array
        parent_budget_id:
          anyOf:
            - type: string
            - type: 'null'
          description: The parent budget; null for the account's root budget.
          title: Parent Budget Id
        status:
          description: Lifecycle status of the budget.
          enum:
            - active
            - archived
          title: Status
          type: string
        temporary_cycle_acu_limit:
          anyOf:
            - type: integer
            - type: 'null'
          description: >-
            A limit that overrides cycle_acu_limit until the end of the current
            monthly billing window, present only while it is live.
          title: Temporary Cycle Acu Limit
      required:
        - budget_id
        - name
        - parent_budget_id
        - org_ids
        - status
        - cycle_acu_limit
        - temporary_cycle_acu_limit
      title: UsagePolicyBudgetResponse
      type: object
    ProblemDetail:
      description: >-
        RFC 9457 application/problem+json error body for the v3 API.


        detail is retained from the legacy {"detail": ...} body for back-compat;
        the

        other members are additive. errors carries field-level validation
        failures

        (422 only).
      properties:
        detail:
          anyOf:
            - type: string
            - type: 'null'
          description: A human-readable explanation specific to this occurrence.
          title: Detail
        error_code:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            Machine-readable code for blocked-action refusals (e.g.
            "user_frozen", "migrated_session").
          title: Error Code
        errors:
          anyOf:
            - items:
                additionalProperties: true
                type: object
              type: array
            - type: 'null'
          description: Field-level validation errors (422 responses only).
          title: Errors
        instance:
          anyOf:
            - type: string
            - type: 'null'
          description: A URI reference (the request path) for this occurrence.
          title: Instance
        status:
          description: The HTTP status code.
          title: Status
          type: integer
        title:
          description: A short, human-readable summary of the problem type.
          title: Title
          type: string
        type:
          default: about:blank
          description: A URI reference identifying the problem type.
          title: Type
          type: string
      required:
        - title
        - status
      title: ProblemDetail
      type: object
  securitySchemes:
    bearerAuth:
      description: 'Service User credential (prefix: cog_)'
      scheme: bearer
      type: http

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.