Skip to main content
curl --request POST 'https://api.mayar.id/hl/v2/products/event/7f992557-8791-41b5-a1c8-c5641c3e72b5/update' \
--header 'Authorization: Bearer Paste-Your-API-Key-Here' \
--data-raw '{
        "id": "7f992557-8791-41b5-a1c8-c5641c3e72b5",
        "name": "Bootcamp Coding Fullstack Asix Batch 2",
        "description": "Workshop fullstack development 2 hari",
        "amount": 3500000,
        "redirectUrl": "https://example.com/event-thanks",
        "expiredAt": "2026-07-10T17:00:00.000Z",
        "event": {
            "eventAddress": "jl perjuangan no 32",
            "isOnlineEvent": false,
            "maxTicket": 5
        }
    }'
{
    "statusCode": 200,
    "messages": "success",
    "data": {
        "id": "7f992557-8791-41b5-a1c8-c5641c3e72b5",
        "link": "https://testingmayar.myr.id/event/Bootcamp-Coding-Fullstack-Asix"
    }
}
Endpoint:
https://api.mayar.id/hl/v2/products/event/{id}/update
The product to edit is identified by the id field in the request body, not by the {id} segment in the URL path.

Authorization

Authorization
string
required
Example:Authorization | Bearer Paste-Your-API-Key-Here

Request Body

id
string
required
Unique identifier of the event product to edit. This is read from the request body.
name
string
Event product name.
description
string
Event product description in text or HTML format.
amount
integer
Event ticket or product price amount.
crossoutPrice
integer
Crossed-out price displayed as the original price.
eventUrl
string
Event URL, such as an online meeting link.
redirectUrl
string
URL where the customer will be redirected after completing payment.
expiredAt
string | datetime
Event product expiration date in ISO 8601 format.
event
object
Additional event details.

event Structure (Object)

event.eventAddress
string
Event location or address.
event.isOnlineEvent
boolean
Indicates whether the event is conducted online.
event.maxTicket
number
Maximum number of tickets that can be purchased per transaction.

Response

Successful Response

Main Structure (Root)

statusCode
integer
Status code from API.
messages
string
Status message that describes the status code.
data
object
The updated event product data.

data Structure (Object)

data.id
string
Unique identifier of the event product.
Public URL of the updated event product.

Errors

200 OK (validation failed)
object
When the request body fails validation, this endpoint still responds with HTTP 200 but sets messages to failed and returns the validator errors in data: { "statusCode": 200, "messages": "failed", "data": { ... } }.
401 Unauthorized
object
Returned when the product does not belong to the authenticated account: { "statusCode": 401, "messages": "Unauthorized" }.
404 Not Found
object
Returned when the product does not exist: { "statusCode": 404, "messages": "Product not found" }.