Hayaa Backend Revamp API (1.1.0)

Download OpenAPI specification:

Authentication

Hayaa support three types of authentication method:

  • Jsonwebtoken
  • OAuth2
  • Manual

OAuth2 - an open protocol to allow secure authorization in a simple and standard method from web, mobile and desktop applications.

System

Health Check

Endpoint to check if the API is up and running.

Responses

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}

Send Custom Push Notification

Sends a custom push notification to a specific device

Authorizations:
SecretAuth
Request Body schema: application/json
required
tokenDevice
string

Firebase device token to send notification to

title
string

Title of the notification

body
string

Body content of the notification

object

Responses

Request samples

Content type
application/json
{
  • "tokenDevice": "string",
  • "title": "string",
  • "body": "string",
  • "data": {
    }
}

Response samples

Content type
application/json
{
  • "status": "success"
}

Dashboard

Attach role to user

Allows admin to attach a role to a user.

Authorizations:
BearerAuth
Request Body schema: application/json
required
id
required
integer >= 1

User ID to attach role to

role
required
string (Role)
Enum: "ustadz-master" "ustadz"

Role to attach

Responses

Request samples

Content type
application/json
{
  • "id": 1,
  • "role": "ustadz-master"
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}

Add subscription

Add standalone subscription

Authorizations:
BearerAuth
Request Body schema: application/json
required
id
required
integer >= 1
status
required
string (SubscriptionType)
Enum: "premium" "plus" "gold" "platinum"

SubscriptionType

duration_in_days
required
number
Enum: 7 30 180 360

Duration In Days Subscription Valid

Responses

Request samples

Content type
application/json
{
  • "id": 1,
  • "status": "premium",
  • "duration_in_days": 7
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}

Add boost

Add standalone boost

Authorizations:
BearerAuth
Request Body schema: application/json
required
id
required
integer >= 1
type
required
string
Enum: "hayaa_1_boost" "hayaa_5_boost" "hayaa_10_boost"

Responses

Request samples

Content type
application/json
{
  • "id": 1,
  • "type": "hayaa_1_boost"
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}

Verify User ID Card and Selfie

Verify User ID Card and Selfie

Authorizations:
BearerAuth
Request Body schema: application/json
required
id
required
integer >= 1

User ID to verify to

status
required
string
Enum: "success" "rejected"

Status to updated

Responses

Request samples

Content type
application/json
{
  • "id": 1,
  • "status": "success"
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}

Sign in to the dashboard

Allows admin users to sign in to the dashboard.

Request Body schema: application/json
required
username
string

Username of the admin user.

password
string

Password of the admin user.

Responses

Request samples

Content type
application/json
{
  • "username": "string",
  • "password": "string"
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Get list of notifications

Retrieve a list of system notifications configured in the system.

Authorizations:
BearerAuth

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/dashboard/notifications" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "ok",
  • "message": null,
  • "data": {
    }
}

Get list of users

Fetches a list of users for the dashboard with various filtering and sorting options. The endpoint supports filtering by name, email, phone number, registration status, and subscription status. It also supports sorting by registration status and profile completion percentage.

query Parameters
offset
integer >= 0

The number of items to skip before starting to collect the result set.

id
integer >= 1

Profile id to find

limit
integer >= 10

The number of items to return.

name
string

Filter users by name.

email
string

Filter users by email.

phone_number
string

Filter users by phone number.

is_active
boolean

Filter users by active status.

register_status
string

Filter users by registration status.

order_register_status
string
Enum: "asc" "desc"

Sort users by registration status.

order_profile_percentage
string
Enum: "asc" "desc"

Sort users by profile completion percentage.

subscription_status
string
Enum: "basic" "premium"

Filter users by subscription status.

role
string (Role)
Enum: "ustadz-master" "ustadz"

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/dashboard/users?limit=10&offset=0" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "count": 0,
  • "users": [
    ]
}

Verify or reject a user registration

Allows an admin to verify or reject a user's registration process. The admin must provide the user ID, desired status, and optionally a rejection message.

Request Body schema: application/json
required
user_id
integer

The ID of the user to verify or reject.

status
string
Enum: "partially_success" "rejected"

The desired status for the user's registration process.

rejected_message
string

The message explaining the reason for rejection, if applicable.

Responses

Request samples

Content type
application/json
{
  • "user_id": 0,
  • "status": "partially_success",
  • "rejected_message": "string"
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "message": "string"
}

Delete a user from dashboard

Deletes a user account from the dashboard. This action records the reason for deletion and soft-deletes the user's credential.

Authorizations:
BearerAuth
Request Body schema: application/json
required
id
required
integer

The ID of the user to delete

reason
string

The reason for deleting the user

Responses

Request samples

Content type
application/json
{
  • "id": 0,
  • "reason": "string"
}

Response samples

Content type
application/json
{
  • "status": "success"
}

Get detailed information about a specific user

Retrieves comprehensive details about a user by their ID. This endpoint is intended for admin dashboard use.

Authorizations:
BearerAuth
path Parameters
id
required
integer

The ID of the user to retrieve details for.

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/dashboard/user/123" \
-H "Authorization: Bearer your_admin_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Ustadz

Attach role to user

Allows admin to attach a role to a user.

Authorizations:
BearerAuth
Request Body schema: application/json
required
id
required
integer >= 1

User ID to attach role to

role
required
string (Role)
Enum: "ustadz-master" "ustadz"

Role to attach

Responses

Request samples

Content type
application/json
{
  • "id": 1,
  • "role": "ustadz-master"
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}

Credential

Register a new user

Allows users to register either manually with an email, phone number OTP, or Google OAuth.

Request Body schema: application/json
required
One of
email
string non-empty
otpCode
string or null
password
string non-empty
object or null

Responses

Request samples

Content type
application/json
{
  • "oauthToken": "string",
  • "session": {
    }
}

Response samples

Content type
application/json
Example
{
  • "status": "ok",
  • "data": {
    }
}

Claim old token

Convert old token from old app to support new token.

Request Body schema: application/json
required
oldToken
string non-empty
object

Responses

Request samples

Content type
application/json
{
  • "oldToken": "string",
  • "session": {
    }
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Send OTP code through email

Sends an OTP code to the user's email for password reset.

Request Body schema: application/json
required
email
string <email>

The email address to send the OTP code to.

Responses

Request samples

Content type
application/json
{
  • "email": "user@example.com"
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": null
}

Update password

Updates the user's password using the provided OTP code. This endpoint requires a valid OTP code sent to the user's email and the new password to be set.

Request Body schema: application/json
required
email
string non-empty
otpCode
string >= 4 characters

The OTP code sent to the user's email for verification.

newPassword
string non-empty

The new password to be set for the user.

Responses

Request samples

Content type
application/json
{
  • "email": "string",
  • "otpCode": "string",
  • "newPassword": "string"
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": null
}

Update session data

Updates the session data for the user.

Request Body schema: application/json
required
deviceID
string or null

Unique identifier for the device.

deviceType
string or null
Enum: "WEB" "ANDROID" "IOS"

Type of the device.

firebaseToken
string or null

Firebase token for push notifications.

appVersion
string or null

Version of the application.

advertisingID
string or null

Advertising identifier for tracking.

language
string or null

Preferred language of the user.

object or null

Responses

Request samples

Content type
application/json
{
  • "deviceID": "string",
  • "deviceType": "WEB",
  • "firebaseToken": "string",
  • "appVersion": "string",
  • "advertisingID": "string",
  • "language": "string",
  • "location": {
    }
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Log out user

Logs out the current user by invalidating their session.

Authorizations:
BearerAuth

Responses

Response samples

Content type
application/json
{
  • "status": "success"
}

Profile

Update user profile and referral code

Allows users to update their profile information, referral code, and background information.

Authorizations:
BearerAuth
Request Body schema: application/json
optional
nickname
string or null >= 2 characters
birthday
string or null <date-time>
gender
string or null
Enum: "male" "female"
referral
string or null non-empty
bio
string or null
birthPlace
string or null
enableBlur
boolean or null
object (Backgrounds)

Responses

Request samples

Content type
application/json
{
  • "nickname": "string",
  • "birthday": "2019-08-24T14:15:22Z",
  • "gender": "male",
  • "referral": "string",
  • "bio": "string",
  • "birthPlace": "string",
  • "enableBlur": true,
  • "backgrounds": {
    }
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Get user profile

Retrieves the profile information of the user.

Authorizations:
BearerAuth

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/profile" \
-H "Authorization: Bearer your_token_here" \
-H "Content-Type: application/json"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Update registration to success

Move registration from partially_success to success

Authorizations:
BearerAuth

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/profile/success" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}

Reorder profile cover images

Allows an authenticated user to reorder their profile cover images.

Authorizations:
BearerAuth
Request Body schema: application/json
required
newOrderURLs
required
Array of strings <uri> [ 1 .. 6 ] items [ items <uri > ]

An array of image URLs in the desired new order.

Responses

Request samples

Content type
application/json

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}

Get partner profile

Retrieves the profile information of the partner.

Authorizations:
BearerAuth
path Parameters
partner-id
required
integer

The ID of the partner.

header Parameters
Profile-Signature
required
string
Example: 098f6bcd4621d373cade4e832627b4f6

Signature for partner profile

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/profile/2506" \
-H "Authorization: Bearer your_token_here"
-H "Profile-Signature: 098f6bcd4621d373cade4e832627b4f6"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Update user background information

Allows users to update their background information.

Authorizations:
BearerAuth
Request Body schema: application/json
required
Array (non-empty)
backgroundType
required
string
Enum: "mariageStatus" "targetMariage" "sect" "spokeLanguages" "educationLevel" "profession" "currentChildren" "selfDescribe" "physicalDescription" "partnerCriteria" "financialSituation" "faith" "interest" "familyInformation" "religiousRoutine" "dependents" "familyMadzhab" "quranReadingRoutine" "prayerRoutine" "selfWeakness" "selfStrengths" "selfThinkLikes" "selfThinkDislikes" "partnerPhysicalPreference" "partnerKeyValue" "height" "weight" "desiredChildren" "marriageMission" "marriageVision" "lifeAfterMariage" "sunnahRoutine"
required
string or number or spokeLanguages (any) or object

Responses

Request samples

Content type
application/json
[
  • {
    }
]

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Upload cover, identity photos

Allows users to upload a cover, identity, face verification, selfie, driver license, passport, introduction video, and marriage certificate photos.

Authorizations:
BearerAuth
Request Body schema: multipart/form-data
required
cover
string <binary>
identity
string <binary>
faceVerification
string <binary>
selfie
string <binary>
driverLicense
string <binary>
passport
string <binary>
marriageCertificate
string <binary>
introductionVideo
string <binary>

Responses

Request samples

curl -X POST https://api.production.hayaa.app/profile/image \
-H "Authorization: Bearer your_token_here" \
-H "Content-Type: multipart/form-data" \
-F "cover=@/path/to/your/cover.jpg"

Response samples

Content type
application/json
{}

Delete profile images

Allows users to delete one or more profile images by their Source URLs.

Authorizations:
BearerAuth
Request Body schema: application/json
required
sourceURLs
Array of strings <uri> [ items <uri > ]

Responses

Request samples

Content type
application/json
{}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": null
}

Delete user profile

Allows users to delete their profile.

Authorizations:
BearerAuth
Request Body schema: application/json
required
category
string
Enum: "found-a-partner" "pause-momentarily" "dislike-application" "something-not-working" "other"

Reason for deleting the profile.

reason
string or null

Additional details for the reason.

Responses

Request samples

Content type
application/json
{
  • "category": "found-a-partner",
  • "reason": "string"
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": null
}

(50%)

Get user profile

Retrieves the profile information of the user.

Authorizations:
BearerAuth

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/profile" \
-H "Authorization: Bearer your_token_here" \
-H "Content-Type: application/json"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Swipe left on a partner

Allows a user to swipe left on a partner, indicating disinterest.

Authorizations:
BearerAuth
path Parameters
partner-id
required
integer

The ID of the partner to swipe left on.

header Parameters
Profile-Signature
required
string
Example: 098f6bcd4621d373cade4e832627b4f6

Signature for profile verification.

Responses

Request samples

curl -X POST "https://api.production.hayaa.app/relation/{partner-id}/swipe-left" \
-H "Authorization: Bearer your_token_here" \
-H "Profile-Signature: 098f6bcd4621d373cade4e832627b4f6" \

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": null
}

Swipe right on a partner

Allows a user to swipe right on a partner, indicating interest.

Authorizations:
BearerAuth
path Parameters
partner-id
required
integer

The ID of the partner to swipe right on.

query Parameters
superlike
string
Default: "false"
Enum: "true" "false"

Use superlike powerup

header Parameters
Profile-Signature
required
string
Example: 098f6bcd4621d373cade4e832627b4f6

Signature for profile verification.

Responses

Request samples

curl -X POST "https://api.production.hayaa.app/relation/{partner-id}/swipe-right" \
-H "Authorization: Bearer your_token_here" \
-H "Profile-Signature: 098f6bcd4621d373cade4e832627b4f6" \

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Rewind the last swipe

Allows a user to rewind their last swipe action.

Authorizations:
BearerAuth

Responses

Request samples

curl -X DELETE "https://api.production.hayaa.app/relation/rewind" \
-H "Authorization: Bearer your_token_here" \

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Get Matches

Get all relations who matched, but no created channel yet.

Authorizations:
BearerAuth

Responses

Request samples

curl "https://api.production.hayaa.app/relation/matches" \
-H "Authorization: Bearer your_token_here" \

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Get profiles you may like

Retrieve a list of profiles that you may like.

Authorizations:
BearerAuth

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/discover/you-may-like" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Get Channels

API to get channels after match.

Authorizations:
BearerAuth
query Parameters
sortBy
string
Enum: "recent" "unread" "nearby"
channelType
string
Enum: "regular" "ustadz" "taaruf"
channelID
number
offset
number

Responses

Request samples

curl https://api.production.hayaa.app/chat \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <auth-token>"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Get channel messages

API to get channel messages

Authorizations:
BearerAuth
path Parameters
channel-id
required
number
query Parameters
limit
number
lastID
number

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/chat/200/message" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <auth-token>"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Encounter

Update user preference

Update filter search of user

Authorizations:
BearerAuth
Request Body schema: application/json
required
distanceMax
integer or null

Maximum distance in kilometers for matches.

object or null
hasCompanion
boolean or null

Indicates if the user has a companion.

marriedReadiness
string or null
Enum: "later" "soon"

User's preference on when to marry.

religionLevel
Array of strings or null or null (Faith)
Enum: "other" "moderate" "devout" "very-devout" "practical" "seeking-improvement" "uncertain" "religious-social"

User's level of religious observance.

education
Array of strings or null (Education)
Enum: "sd" "smp" "sma" "d3" "s1" "s2" "s3" "dropout" "non-formal" "other"

List of educational qualifications.

maritalStatus
Array of strings or null
Enum: "single" "marriage" "living-divorce" "widowed"

User's marital status.

sect
Array of strings or null
Enum: "sunni" "nahdlatul-ulama" "muhammadiyah" "ahmadiyah" "salafi" "syiah" "other"

User's sect.

hasAChild
boolean or null

Indicates if the user has children.

interests
Array of strings or null (Interest)
Enum: "ashura" "arbaeen" "charity" "completed-hajj" "completed-umrah" "hafith" "khatam" "islamic-events" "islamic-lectures" "islamic-studies" "masjid-regularly" "mawlid" "muharram" "reading-quran" "dua-for-others" "fasting" "pengajian" "yasin" "tajwid-learning" "fiqh-learning" "basketball" "badminton" "baseball" "bouldering" "bowling" "boxing" "cricket" "cycling" "golf" "football" "gym" "hiking" "hokey" "horse-riding" "kayaking" "martial-arts" "netball" "motorbiking" "scuba-diving" "snowboarding" "soccer" "softball" "squash" "tennis" "volley" "padel" "boba-tea" "coffee" "pizza" "cooking" "chocolate" "eating-out" "fish-and-chips" "sushi" "vegetarian" "cake" "meatlover" "pescatarian" "vegan" "plant-based" "healthy-food" "art-galleries" "acting" "creative-writing" "design" "board-games" "film-and-cinema" "painting" "photography" "theatre" "live-music" "standup-comedy" "reading" "music" "anime" "tv-show" "video-games" "roblox" "online-gaming" "coding" "tech" "blogging" "content-creation" "live-streaming" "digital-art" "animation" "meditation" "pilates" "yoga" "camping" "fishing" "gardening" "nature-walks" "travel-islamic-countries"

List of user interests.

verifiedOnly
boolean or null

Indicates if the user is verified.

activeSort
boolean or null

Sort by last active

Responses

Request samples

Content type
application/json
{
  • "distanceMax": 0,
  • "age": {
    },
  • "hasCompanion": true,
  • "marriedReadiness": "later",
  • "religionLevel": [
    ],
  • "education": [
    ],
  • "maritalStatus": [
    ],
  • "sect": [
    ],
  • "hasAChild": true,
  • "interests": [
    ],
  • "verifiedOnly": true,
  • "activeSort": true
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Retrieve user preference

Fetch the current preference of the user.

Authorizations:
BearerAuth

Responses

Request samples

curl -X GET https://api.production.hayaa.app/encounter/preference \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Retrieve user encounters

Fetch the user's subscription, power ups, and swipe limits.

Authorizations:
BearerAuth
query Parameters
limit
integer

Limit the number of encounter list, 0 for only retrieving the encounter state.

role
string
Enum: "ustadz" "ustadz-master"

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/encounter?limit=10" \
-H "Authorization: Bearer your_token_here" \

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Relation

Visit a user encounter

Allows visiting a specific user's encounter profile by user ID.

Authorizations:
BearerAuth
path Parameters
user-id
required
integer

The ID of the user to visit.

header Parameters
Profile-Signature
required
string
Example: 098f6bcd4621d373cade4e832627b4f6

Signature for profile verification.

Responses

Request samples

curl -X POST "https://api.production.hayaa.app/relation/{user-id}/visit" \
-H "Authorization: Bearer your_token_here" \
-H "Profile-Signature: signature token"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": null
}

Report a relation issue

Allows users to report an issue with a relation.

Authorizations:
BearerAuth
path Parameters
partner-id
required
integer

The ID of the partner to report.

header Parameters
Profile-Signature
required
string
Example: 098f6bcd4621d373cade4e832627b4f6

Signature for profile verification.

Request Body schema: multipart/form-data
required
reason
string
attachment
string or null <binary>

Image file to be sent as a multipart file

Responses

Request samples

curl -X POST "https://api.production.hayaa.app/relation/{partner-id}/report" \
-H "Authorization: Bearer your_token_here" \
-H "Profile-Signature: 098f6bcd4621d373cade4e832627b4f6" \
-F "reason=Your reason here" \
-F "attachment=@/path/to/your/image.jpg"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": null
}

Block an user

Allows blocking user, and never to see again for the blocker sides.

Authorizations:
BearerAuth
path Parameters
partner-id
required
integer

The ID of the partner to report.

Request Body schema: application/json
required
reason
string or null
Enum: "fake-profile" "spammer" "inappropriate-bio" "inappropriate-photo" "inappropriate-message" "underage" "other"

Additional details about the block.

Responses

Request samples

Content type
application/json
{
  • "reason": "fake-profile"
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": null
}

Unblock an user

Allows unblocking a previously blocked user, making them visible again in encounters.

Authorizations:
BearerAuth
path Parameters
partner-id
required
integer

The ID of the partner to unblock.

Responses

Request samples

curl -X DELETE "https://api.production.hayaa.app/relation/{partner-id}/unblock" \
-H "Authorization: Bearer your_token_here" \
-H "Content-Type: application/json"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": null
}

Swipe left on a partner

Allows a user to swipe left on a partner, indicating disinterest.

Authorizations:
BearerAuth
path Parameters
partner-id
required
integer

The ID of the partner to swipe left on.

header Parameters
Profile-Signature
required
string
Example: 098f6bcd4621d373cade4e832627b4f6

Signature for profile verification.

Responses

Request samples

curl -X POST "https://api.production.hayaa.app/relation/{partner-id}/swipe-left" \
-H "Authorization: Bearer your_token_here" \
-H "Profile-Signature: 098f6bcd4621d373cade4e832627b4f6" \

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": null
}

Swipe right on a partner

Allows a user to swipe right on a partner, indicating interest.

Authorizations:
BearerAuth
path Parameters
partner-id
required
integer

The ID of the partner to swipe right on.

query Parameters
superlike
string
Default: "false"
Enum: "true" "false"

Use superlike powerup

header Parameters
Profile-Signature
required
string
Example: 098f6bcd4621d373cade4e832627b4f6

Signature for profile verification.

Responses

Request samples

curl -X POST "https://api.production.hayaa.app/relation/{partner-id}/swipe-right" \
-H "Authorization: Bearer your_token_here" \
-H "Profile-Signature: 098f6bcd4621d373cade4e832627b4f6" \

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Rewind the last swipe

Allows a user to rewind their last swipe action.

Authorizations:
BearerAuth

Responses

Request samples

curl -X DELETE "https://api.production.hayaa.app/relation/rewind" \
-H "Authorization: Bearer your_token_here" \

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Get Matches

Get all relations who matched, but no created channel yet.

Authorizations:
BearerAuth

Responses

Request samples

curl "https://api.production.hayaa.app/relation/matches" \
-H "Authorization: Bearer your_token_here" \

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Initiate a direct chat with a partner

Allows a user to start a direct chat with a specified partner.

Authorizations:
BearerAuth
path Parameters
partner-id
required
integer

The ID of the partner to initiate a chat with.

header Parameters
Profile-Signature
required
string
Example: 098f6bcd4621d373cade4e832627b4f6

Signature for profile verification.

Responses

Request samples

curl -X POST "https://api.production.hayaa.app/relation/{partner-id}/direct-chat" \
-H "Authorization: Bearer your_token_here" \
-H "Profile-Signature: 098f6bcd4621d373cade4e832627b4f6"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

(Not Complete)

Initiate a direct chat with a partner

Allows a user to start a direct chat with a specified partner.

Authorizations:
BearerAuth
path Parameters
partner-id
required
integer

The ID of the partner to initiate a chat with.

header Parameters
Profile-Signature
required
string
Example: 098f6bcd4621d373cade4e832627b4f6

Signature for profile verification.

Responses

Request samples

curl -X POST "https://api.production.hayaa.app/relation/{partner-id}/direct-chat" \
-H "Authorization: Bearer your_token_here" \
-H "Profile-Signature: 098f6bcd4621d373cade4e832627b4f6"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Retrieve product details

Fetches the details of available products.

Authorizations:
BearerAuth

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/product" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Initiate a payment

Allows users to initiate a payment for a product.

Authorizations:
BearerAuth
Request Body schema: application/json
required
productCode
string

Code of the product to purchase.

paymentCode
string

Code of the payment method.

phoneNumber
string or null

Optional phone number for the payment.

Responses

Request samples

Content type
application/json
{
  • "productCode": "string",
  • "paymentCode": "string",
  • "phoneNumber": "string"
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Retrieve payment history

Fetches the payment history for the user.

Authorizations:
BearerAuth
query Parameters
limit
integer
Default: 10

Maximum number of payment records to return.

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/payment/history?limit=10" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ],
  • "meta": {
    }
}

Retrieve payment methods

Fetches the available payment methods.

Authorizations:
BearerAuth

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/payment/method" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Get activities

Get activities based on the specified type.

Authorizations:
BearerAuth
query Parameters
type
required
string
Enum: "promo" "explore" "purchase" "match"

Type of activities

Responses

Request samples

curl -X DELETE "https://api.production.hayaa.app/activities?type=message" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Handle external listener events

Accepts events from external sources such as xendit and revenue cat.

Authorizations:
None
path Parameters
source
required
string
Enum: "xendit" "revenuecat"

The source of the event.

Request Body schema: application/json
required
property name*
additional property
any

Responses

Request samples

Content type
application/json
{ }

Response samples

Content type
application/json
{
  • "status": "success",
  • "message": "string",
  • "data": { }
}

Update Channel State

API to update channel state in a channel, can only be used from WebSocket.

Authorizations:
SecretAuth
path Parameters
id
required
number

ID of the channel to update the state

Responses

Request samples

curl -X PATCH https://api.production.hayaa.app/ws/channel-state/1 \
-H "Authorization: App-Secret <app-secret>"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}

Get channel detail

API to get channel members

Authorizations:
BearerAuth
path Parameters
channel-id
required
number

Responses

Request samples

curl https://api.production.hayaa.app/chat/100/detail \
-H "Authorization: Bearer <auth-token>"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Enable or disable blur

API to update blur status to partner and companion

Authorizations:
BearerAuth
path Parameters
channel-id
required
number
Request Body schema: application/json
required
blur
boolean

Responses

Request samples

Content type
application/json
{
  • "blur": true
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}

Propose taaruf

Propose taaruf to partner with companions

Authorizations:
BearerAuth
path Parameters
channel-id
required
number
Request Body schema: application/json
required
companionIDs
Array of numbers

Responses

Request samples

Content type
application/json
{
  • "companionIDs": [
    ]
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}

Get taaruf invitation

Get taaruf invitation / proposal

Authorizations:
BearerAuth

Responses

Request samples

curl "https://api.production.hayaa.app/taaruf/invitation" \
-H "Authorization: Bearer <auth-token>"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Confirm taaruf invitation

Accept or reject taaruf invitation

Authorizations:
BearerAuth
Request Body schema: application/json
required
status
string
Enum: "reject" "accept"

Responses

Request samples

Content type
application/json
{
  • "status": "reject"
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Companion

Add or update a companion

Allows users to add a new companion or update an existing one. Supports file uploads for profile image and identity card.

Authorizations:
BearerAuth
Request Body schema: multipart/form-data
required
id
integer or null

Companion ID. Required for updating an existing companion, omit for new companion.

name
string

Name of the companion. Required for new companion.

email
string

Email of the companion. Required for new companion.

phoneNumber
string or null

Phone number of the companion.

relation
string
Enum: "father" "mother" "grandfather" "grandmother" "uncle" "aunt" "sibling" "in-law"

Relation to the companion. Required for new companion.

profileImage
string or null <binary>

Profile image of the companion.

identityCard
string or null <binary>

Identity card of the companion.

Responses

Request samples

curl -X POST "https://api.production.hayaa.app/companion" \
-H "Authorization: Bearer your_token_here" \
-H "Content-Type: multipart/form-data" \
-F "name=John Doe" \
-F "email=johndoe@example.com" \
-F "phoneNumber=6281234567890" \
-F "relation=father" \
-F "profileImage=@path/to/your/image.jpg" \
-F "identityCard=@path/to/your/idcard.jpg"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Get list of companions

Retrieves a list of companions associated with the user.

Authorizations:
BearerAuth

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/companion" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Delete a companion

Allows users to delete a companion by their ID.

Authorizations:
BearerAuth
path Parameters
id
required
integer

The ID of the companion to delete.

Responses

Request samples

curl -X DELETE "https://api.production.hayaa.app/companion/{id}" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": null
}

Discover

Get trending profiles

Retrieve a list of trending profiles based on the specified category and limit.

Authorizations:
BearerAuth
query Parameters
category
string
Enum: "nearest" "newest"

Category to filter trending profiles.

limit
integer
Default: 10

Maximum number of profiles to return.

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/discover/trending?category=nearest&limit=10" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Get profiles you may like

Retrieve a list of profiles that you may like.

Authorizations:
BearerAuth

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/discover/you-may-like" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Get profiles that like you

Retrieve a list of profiles that have shown interest in you.

Authorizations:
BearerAuth

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/discover/likes-you" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Get profiles you have visited

Retrieve a list of profiles that you have visited.

Authorizations:
BearerAuth

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/discover/visit" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Get profiles you have blocked

Retrieve a list of profiles that you have blocked.

Authorizations:
BearerAuth

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/discover/block" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Product

Retrieve product details

Fetches the details of available products.

Authorizations:
BearerAuth

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/product" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Payment

Initiate a payment

Allows users to initiate a payment for a product.

Authorizations:
BearerAuth
Request Body schema: application/json
required
productCode
string

Code of the product to purchase.

paymentCode
string

Code of the payment method.

phoneNumber
string or null

Optional phone number for the payment.

Responses

Request samples

Content type
application/json
{
  • "productCode": "string",
  • "paymentCode": "string",
  • "phoneNumber": "string"
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

RevenueCat webhook callback

Endpoint for receiving RevenueCat subscription and purchase events

Request Body schema: application/json
required
api_version
string

RevenueCat API version

object

Responses

Request samples

Content type
application/json
{
  • "api_version": "1.0",
  • "event": {
    }
}

Response samples

Content type
application/json
{
  • "status": "success"
}

Retrieve payment history

Fetches the payment history for the user.

Authorizations:
BearerAuth
query Parameters
limit
integer
Default: 10

Maximum number of payment records to return.

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/payment/history?limit=10" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ],
  • "meta": {
    }
}

Retrieve payment methods

Fetches the available payment methods.

Authorizations:
BearerAuth

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/payment/method" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Activities

Get activities

Get activities based on the specified type.

Authorizations:
BearerAuth
query Parameters
type
required
string
Enum: "promo" "explore" "purchase" "match"

Type of activities

Responses

Request samples

curl -X DELETE "https://api.production.hayaa.app/activities?type=message" \
-H "Authorization: Bearer your_token_here"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Webhook

Handle external listener events

Accepts events from external sources such as xendit and revenue cat.

Authorizations:
None
path Parameters
source
required
string
Enum: "xendit" "revenuecat"

The source of the event.

Request Body schema: application/json
required
property name*
additional property
any

Responses

Request samples

Content type
application/json
{ }

Response samples

Content type
application/json
{
  • "status": "success",
  • "message": "string",
  • "data": { }
}

Feedback

Submit user feedback

Allows authenticated users to submit feedback.

Authorizations:
BearerAuth
Request Body schema: application/json
required
content
required
string [ 4 .. 1024 ] characters

The feedback message content.

rating
number [ 1 .. 5 ]

The feedback rating.

Responses

Request samples

Content type
application/json
{
  • "content": "string",
  • "rating": 1
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": null
}

WebSocket

Authenticate websocket auth token

validate auth token and response user data

Authorizations:
SecretAuth
Request Body schema: application/json
required
token
string

JWT Auth token

Responses

Request samples

Content type
application/json
{
  • "token": "string"
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Send Message from Websocket

API for send message in one channel, can only be used from websocket

Authorizations:
SecretAuth
path Parameters
id
required
number

ID of the channel

Request Body schema: application/json
required
senderID
number

Sender user id

text
string

The message content to be sent

confirmationID
string

ID for message confirmation

Responses

Request samples

Content type
application/json
{
  • "senderID": 0,
  • "text": "string",
  • "confirmationID": "string"
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Update open channel state

API for updating unread count to zero and last seen at channel

Authorizations:
SecretAuth
path Parameters
id
required
number

ID of the channel

Request Body schema: application/json
required
userID
number

Responses

Request samples

Content type
application/json
{
  • "userID": 0
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}

Update last active user in websocket

API for updating last active in encounter pool and profile from websocket

Authorizations:
SecretAuth
Request Body schema: application/json
required
ids
Array of numbers

Responses

Request samples

Content type
application/json
{
  • "ids": [
    ]
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}

Update Channel State

API to update channel state in a channel, can only be used from WebSocket.

Authorizations:
SecretAuth
path Parameters
id
required
number

ID of the channel to update the state

Responses

Request samples

curl -X PATCH https://api.production.hayaa.app/ws/channel-state/1 \
-H "Authorization: App-Secret <app-secret>"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}

Create a new chat

API to create a new chat (channel) using a partner ID. And notify channel-created to WS. User profile signature for create channel without match first

Authorizations:
BearerAuth
path Parameters
partner-id
required
number
header Parameters
Profile-Signature
string
Example: 098f6bcd4621d373cade4e832627b4f6

Required when create channel without match first

Responses

Request samples

curl -X POST https://api.production.hayaa.app/chat/2506 \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <auth-token>"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Chat

Leave Channel

Allows a user to leave a chat channel

Authorizations:
BearerAuth
path Parameters
channel-id
required
number

The ID of the channel to leave

Responses

Request samples

curl -X DELETE "https://api.production.hayaa.app/chat/123/leave" \
-H "Authorization: Bearer <auth-token>"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}

Create a new chat

API to create a new chat (channel) using a partner ID. And notify channel-created to WS. User profile signature for create channel without match first

Authorizations:
BearerAuth
path Parameters
partner-id
required
number
header Parameters
Profile-Signature
string
Example: 098f6bcd4621d373cade4e832627b4f6

Required when create channel without match first

Responses

Request samples

curl -X POST https://api.production.hayaa.app/chat/2506 \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <auth-token>"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Get Channels

API to get channels after match.

Authorizations:
BearerAuth
query Parameters
sortBy
string
Enum: "recent" "unread" "nearby"
channelType
string
Enum: "regular" "ustadz" "taaruf"
channelID
number
offset
number

Responses

Request samples

curl https://api.production.hayaa.app/chat \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <auth-token>"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Get channel detail

API to get channel members

Authorizations:
BearerAuth
path Parameters
channel-id
required
number

Responses

Request samples

curl https://api.production.hayaa.app/chat/100/detail \
-H "Authorization: Bearer <auth-token>"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Send Message

API for send message in channel. Max 2 image at the same time.

Authorizations:
BearerAuth
path Parameters
channel-id
required
number
Request Body schema: multipart/form-data
required
text
string

The message content to be sent

image_1
string or null <binary>

Image file to be sent as a multipart file

image_2
string or null <binary>

Image file to be sent as a multipart file

confirmationID
string

ID for message confirmation

Responses

Request samples

curl -X POST https://api.production.hayaa.app/chat/123/message \
-H "Content-Type: multipart/form-data" \
-H "Authorization: Bearer <auth-token>" \
-F "text=Hello" \
-F "image_1=@/path/to/image.jpg" \
-F "confirmationID=12345"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Get channel messages

API to get channel messages

Authorizations:
BearerAuth
path Parameters
channel-id
required
number
query Parameters
limit
number
lastID
number

Responses

Request samples

curl -X GET "https://api.production.hayaa.app/chat/200/message" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <auth-token>"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

Enable or disable blur

API to update blur status to partner and companion

Authorizations:
BearerAuth
path Parameters
channel-id
required
number
Request Body schema: application/json
required
blur
boolean

Responses

Request samples

Content type
application/json
{
  • "blur": true
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}

Taaruf

Propose taaruf

Propose taaruf to partner with companions

Authorizations:
BearerAuth
path Parameters
channel-id
required
number
Request Body schema: application/json
required
companionIDs
Array of numbers

Responses

Request samples

Content type
application/json
{
  • "companionIDs": [
    ]
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}

Get taaruf invitation

Get taaruf invitation / proposal

Authorizations:
BearerAuth

Responses

Request samples

curl "https://api.production.hayaa.app/taaruf/invitation" \
-H "Authorization: Bearer <auth-token>"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Confirm taaruf invitation

Accept or reject taaruf invitation

Authorizations:
BearerAuth
Request Body schema: application/json
required
status
string
Enum: "reject" "accept"

Responses

Request samples

Content type
application/json
{
  • "status": "reject"
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Internal

Broadcast notifications to users

This endpoint broadcasts notifications to users based on their language preferences. It is intended for internal use.

Authorizations:
SecretAuth

Responses

Request samples

curl -X POST "https://api.production.hayaa.app/internal/broadcast" \
-H "Authorization: App-Secret your_internal_token_here" \
-H "Content-Type: application/json"

Response samples

Content type
application/json
{
  • "status": "success",
  • "message": "string"
}

Send the statistic of log level

Get log level with count in range of time.

Authorizations:
SecretAuth
Request Body schema: application/json
required
groupID
string
queryRangeMinutes
number

Responses

Request samples

Content type
application/json
{
  • "groupID": "string",
  • "queryRangeMinutes": 0
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "message": null
}

Decrypt App ID

This endpoint decrypts an encrypted App ID. It is intended for internal use.

Authorizations:
SecretAuth
Request Body schema: application/json
required
appID
required
string [ 8 .. 512 ] characters

The encrypted App ID to decrypt

Responses

Request samples

Content type
application/json
{
  • "appID": "stringst"
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Ustadz Auto Reply

This endpoint handles auto-replies from Ustadz. It is intended for internal use.

Authorizations:
SecretAuth

Responses

Request samples

curl -X POST "https://api.production.hayaa.app/internal/ustadz-reply" \
-H "Authorization: App-Secret your_internal_token_here" \
-H "Content-Type: application/json"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

Refresh weekly trending

Authorizations:
SecretAuth

Responses

Request samples

curl -X POST "https://api.production.hayaa.app/internal/refresh-trending" \
-H "Authorization: App-Secret your_internal_token_here" \
-H "Content-Type: application/json"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}

PowerUp

Enable Boost

Activates a boost powerup for the user's profile, making them more visible in the encounter pool for 30 minutes. Requires available boost credits.

Authorizations:
BearerAuth

Responses

Request samples

curl -X POST https://api.production.hayaa.app/powerup/boost \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <user-token>"

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": { }
}