Skip to main content
curl --location 'https://api.mayar.id/credit/v1/credit/generate/immutable/checkout' \
--header 'Authorization: Bearer Paste-Your-API-Key-Here' \
--data-raw '{
    "productId": "0e787345-9aaf-4b72-aa00-1174be6b52b1",
    "creditAmount": 1000, //optional
    "customerInfo": {
        "name" : "memberTambahan",
        "email" : "[email protected]",
        "mobile" : "08777777799"
    }
}'
{
    "statusCode": 200,
    "message": "success",
    "data": {
      "membershipTiers": [
        {
            "id": "6d85f2fa-1012-4cc4-b6fb-21f23cf96f3c",
            "specificPaymentLinkUrl": "https://donasisekutscom.myr.id/m/membership-creditan?immutable=eyJuYW1lIjoiam9obiBkb2UiLCJlbWFpbCI6ImpvaG5kb2U1QGdtYWlsLmNvbSIsIm1vYmlsZSI6IjA4Nzc3Nzc3Nzc3IiwibWVtYmVyc2hpcFRpZXJJZCI6IjZkODVmMmZhLTEwMTItNGNjNC1iNmZiLTIxZjIzY2Y5NmYzYyJ9.65b2b4e9734b8a5f2ec309faee56eb2de1a4b1ad143004a2915d3b3a3ffde289"
        },
        {
            "id": "ea77b959-cdc1-4247-bd96-e3cc481ea64e",
            "specificPaymentLinkUrl": "https://donasisekutscom.myr.id/m/membership-creditan?immutable=eyJuYW1lIjoiam9obiBkb2UiLCJlbWFpbCI6ImpvaG5kb2U1QGdtYWlsLmNvbSIsIm1vYmlsZSI6IjA4Nzc3Nzc3Nzc3IiwibWVtYmVyc2hpcFRpZXJJZCI6ImVhNzdiOTU5LWNkYzEtNDI0Ny1iZDk2LWUzY2M0ODFlYTY0ZSJ9.a8e51137c3beaac9934b38c47bfbfc6fd857c2ed9f724b4e3e5c557732dccbb6"
        }
      ],
      "paymentLinkUrl": "https://donasisekutscom.myr.id/m/membership-creditan"
    }
}
Endpoint:
https://api.mayar.id/credit/v1/credit/generate/immutable/checkout

Authorization

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

Request Body

At least one of customerId or memberId must be provided.

Response

Successful Response
statusCode
integer
required
Indicates the HTTP status of the request (e.g. 200 for success).
message
string
required
A descriptive message about the outcome of the request.
membershipTiers
array
Contains a list of membership tiers, each with its own generated immutable checkout link.
membershipTiers.id
string
required
Unique identifier of the membership tier.
A unique, immutable payment link URL generated specifically for the user and tier combination.
membershipTiers.creditUsageImmutableCheckoutUrl
string
Returned only for credit usage products. A unique immutable checkout URL containing user identity fields and creditAmount.
The general (mutable) payment link URL.