Skip to main content
PUT
/
voucher
/
{id}
Update Voucher
curl --request PUT \
  --url https://blessed-toad-definitely.ngrok-free.app/api/voucher/{id} \
  --header 'Content-Type: application/json' \
  --data '
{
  "namaVoucher": "Voucher Hari Ini",
  "diskonRate": 10,
  "tanggalExpired": "2021-12-31"
}
'

Path Parameters

id
integer
required

Unique identifier for the voucher

Example:

1

Body

application/json
namaVoucher
string
required

Name of the voucher

Example:

"Voucher Hari Ini"

diskonRate
number
required

Discount rate of the voucher

Example:

10

tanggalExpired
string<date>
required

Expired date of the voucher

Example:

"2021-12-31"

Response

200

Voucher updated successfully