🤝Friend

Friend List

Get Friend List

GET [endpoint]/v3/friend/list

online_only will show friends that make API activity on last 30 seconds. Currently this feature is not reliable if no game send user's activity via REST API. This will have better reliability after development of WebSocket as we will ping-pong the user every 5 seconds.

Headers

NameTypeDescription

Authorization*

String

Bearer token

X-Api-Key*

String

API Key

Request Body

NameTypeDescription

favorite_only

Boolean

Only show favorite friends. Default false

online_only

Boolean

Only show online friends (read notes above). Default false

limit

Integer

Limit amount of data shows. Default no limit

offset

Integer

Start showing data from number of offset. Default no offset

{
    "status": "success",
    "data": [
        {
            "komo_username": "kokomo",
            "in_game_display_name": "[PBR] Komodo",
            "profile_picture_url": "https://komo.s3.ap-southeast-1.amazonaws.com/profile-account/kokomo-XYXJ.jpg",
            "is_favorite": 0,
            "last_online": "2023-06-27 07:38:17"
        },
        ....
        {
            "komo_username": "dasdsa",
            "in_game_display_name": "dasdsa",
            "profile_picture_url": null,
            "is_favorite": 0,
            "last_online": "2023-06-27 07:37:51"
        }
    ]
}

Friend Request

Make a Friend Request

POST [endpoint]/v3/friend/request

Headers

NameTypeDescription

Authorization*

String

Bearer token

X-Api-Key*

String

API Key

Request Body

NameTypeDescription

target_komo_username*

String

KOMO username to make friend request

{
    "status": "error",
    "messages": "Can not make friend request to itself"
}

Get Incoming Friend Request

GET [endpoint]/v3/friend/request/incoming

{
    "status": "success",
    "data": [
        {
            "relation_id": 1,
            "requester": "Aviabee",
            "requestee": "kokomo",
            "is_accepted": 0,
            "request_time": "2023-06-27 03:51:15",
            "accept_time": null
        },
        {
            "relation_id": 4,
            "requester": "polycrest",
            "requestee": "kokomo",
            "is_accepted": 0,
            "request_time": "2023-06-27 04:04:55",
            "accept_time": null
        }
    ]
}

Get Outgoing Friend Request

GET [endpoint]/v3/friend/request/outgoing

Headers

NameTypeDescription

Authorization*

String

Bearer token

X-Api-Key*

String

API Key

{
    "status": "success",
    "data": [
        {
            "relation_id": 1,
            "requester": "Aviabee",
            "requestee": "kokomo",
            "is_accepted": 0,
            "request_time": "2023-06-27 03:51:15",
            "accept_time": null
        },
        {
            "relation_id": 2,
            "requester": "Aviabee",
            "requestee": "dasdsa",
            "is_accepted": 0,
            "request_time": "2023-06-27 03:59:38",
            "accept_time": null
        },
        {
            "relation_id": 3,
            "requester": "Aviabee",
            "requestee": "polycrest",
            "is_accepted": 0,
            "request_time": "2023-06-27 03:59:44",
            "accept_time": null
        }
    ]
}

Accepting Friend Request

Accepting a Friend Request

POST [endpoint]/v3/friend/request/accept

Headers

NameTypeDescription

Authorization*

String

Bearer token

X-Api-Key*

String

API Key

Request Body

NameTypeDescription

relation_id*

Integer

Relation ID

{
    "status": "success",
    "messages": "Friend request accepted"
}

Accepting All Pending Friend Request

GET [endpoint]/v3/friend/request/accept-all

Headers

NameTypeDescription

Authorization*

String

Bearer token

X-Api-Key*

String

API Key

{
    "status": "success",
    "messages": "All pending friend request accepted"
}

Favorite Friends

Adding Friend to Favorites

POST [endpoint]/v3/friend/favorites/add

Headers

NameTypeDescription

Authorization*

String

Bearer Token

X-Api-Key*

String

API Key

Request Body

NameTypeDescription

target_komo_username*

String

KOMO username to add favorites

{
    "status": "success",
    "messages": "Friend added to favorites"
}

Removing Friend from Favorites

POST [endpoint]/v3/friend/favorites/remove

Headers

NameTypeDescription

Authorization*

String

Bearer token

X-Api-Key*

String

API Key

Request Body

NameTypeDescription

target_komo_username*

String

KOMO username to remove favorites

{
    "status": "success",
    "messages": "Friend removed from favorites"
}

Removing Friend

Removing a Friend from Friend List

POST [endpoint]/v3/friend/remove

WARNING!!! This will remove friend relation from both friend list

Headers

NameTypeDescription

Authorization*

String

Bearer token

X-Api-Key*

String

API Key

Request Body

NameTypeDescription

target_komo_username*

String

KOMO username of friends to remove

{
    "status": "success",
    "messages": "Friend removed successfully"
}

Last updated