---
title: "Update Discount"
method: PUT
path: "/discounts/{id}"
tags: ["Discounts"]
---

# Update Discount

`PUT /discounts/{id}`

## Request

- Base URL: `http://localhost/app4legal/api/v2/money`
- URL: `http://localhost/app4legal/api/v2/money/discounts/{id}`
- Auth: OAuth 2
  - Password
  - Token URL: `http://localhost/app4legal/api/v2/core/login`
- TypeScript: <https://skmtc.dev/app4legal/apis/a4l-money-api/docs/discounts/:id/put.ts> (a function with typed inputs; its response is checked against the schema)

Update an existing discount record

## Path parameters

- `id` integer, required

## Request body

- object
  - `name` string: Discount Name
  - `fl1name` string: Discount Name(french)
  - `fl2name` string: Discount Name(العربية)
  - `description` string: Description of the Discount
  - `percentage` number, float: Discount Percentage Value

## Response `201`

Discount has been updated successfully.

- object
  - `discount` object
    - `id` integer
    - `user_id` integer
    - `name` string
    - `fl1name` string
    - `fl2name` string
    - `description` string
    - `percentage` number, float
    - `created_by` integer
    - `created_by_name` string
    - `created_on` string, date-time
    - `modified_by` integer
    - `modified_on` string, date-time

## Other responses

- `401`: Unauthenticated
- `403`: Forbidden
- `500`: Internal Server Error

## Changes

- **2026-08-06** `e0d144609998`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/app4legal/apis/a4l-money-api/changes/discounts/:id/put.md)

---

[API](https://skmtc.dev/app4legal/apis/a4l-money-api.md) - [All operations](https://skmtc.dev/app4legal/apis/a4l-money-api/llms.txt) - [OpenAPI document](https://skmtc.dev/app4legal/apis/a4l-money-api/revisions/e0d144609998?raw)
