Lấy danh sách Top members

Lấy danh sách members theo thời gian hoặc mã người giới thiệu

Base URL:

http://<host-name>/api/v2/members-top

Header:

X-Network-Id  :  2
X-Port-Type   :  PUB
Content-Type  :  application/x-www-form-urlencoded
Authorization :	Bearer {access_token}

Params Request

Param Name

Data Type

Required? (Y/N)

Description

page

String

N

Trang hiện tại theo phân trang

page_size

String

N

Số lượng kết quả trả về / 1 trang, mặc định là 10 (Top 10)

from_time

DateTime

Y

Từ ngày tạo member, định dạng yyyy-MM-dd HH:mm:ss

to_time

DateTime

Y

Đến ngày tạo member, định dạng yyyy-MM-dd HH:mm:ssc

campaign_id

Array

N

Các ID chiến dịch của người giới thiệu tham gia

Request data:

https://<host-name>/api/v1/members-top?page=1&from_time=2020-08-01%2000%3A00%3A00&to_time=2020-08-10%2000%3A00%3A00&campaigns_id[]=366,9

Response

{
    "status": "success",
    "data": "eyJpdiI6ImNQeWV0eWpPYzVVMVFnd2JCYmlDYkE9PSIsInZhbHVlIjoiVExrRDhyOGxIdDdvT2xaWGJ2RXVONWovOFQxeWtyVVk4ZWFyd1BZa3R4cTRTVWZpYnlzUVgzNGxSTEhxZnc2QTZabWdoWThyejBBc2E5Wnc4MkVEWHNjOHF4M0RrU29GbWtQNHRRL3hlYlE1elFIdnVza2E1bFBsVkJGNWR4cHY2dEplN3phS2RBNTRjT2NhTXlCQUFaamVMdDR6TlZMTUxDL1lqb0lzTFFGbms1MnVSOE9SWlp0T3BaTHVrK2tYWWx0ZHd3djgrVEhoTEt1bVdMMWdmdHl
STjQxZFZEK1gwQVhpeTRFQ2dBcmZZcDFwLzZRYks4RnBxaXRIUmlXbXQ0ZVQ1dk04Y2V6TnIxMFIrcU9DYjdZRjRIS09uZk8wcmY0NVd2bkIwb3ZUdllNZXd3NDJiam5yQm92cEtiWExHc0o3NzhDMi9rc2N4U1ppcWVqejJzVU9sNWxyUUtyWW1TaDJVcE9OSVNSRmlUYStEa3lJaEg0N25Db2tuTVByemNvSEpOSmR4U0JIaVlFUF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I4UEZGN0JJZk90NjdMS1FJWGRHNmlrWVA1MFNWNWNSWlZjSWtlU1EzczREbnRtVFBFVlNHVHJDb21HMitPNE5XcGdqUGxMUlBZbjh6bm4vUVVTampzSXZGS1M4NlY0cFNOQkYweSsvR3UxdDh0U2gyUDljblRwVUs1VXQrUWh4b2pHWkQ4WldKK1RFSnNFWVJGN3MvZz09IiwibWFjIjoiZmVlMDc4YWRmM2M5NWFjYjgzZjY1Yjg0MmIzZTJkZmEwNWY4NGYyMTYzODIwZWM4NGRmMDZiY2EyOGE0MDMzMiJ9"
}

Data sau giải mã

{
        "members": [
            {
                "id": 30043,
                "sso_id": 49063,
                "level_id": 1,
                "username": "7ce7ea6a18e6a42b402526e0813d6c6b",
                "email": "[email protected]",
                "created_at": "2020-07-08 11:39:47",
                "avatar": null,
                "facebook_id": null,
                "google_id": null,
                "identifier_id": "0000000030",
                "profile": {
                    "first_name": "username30",
                    "last_name": "N/A",
                    "gender": 2,
                    "phone_number": "0000000000",
                    "status": 1,
                    "position": null,
                    "address": null,
                    "date_of_birth": "1990-01-01",
                    "description": null,
                    "model": null
                },
                "roles": [
                    {
                        "id": 3,
                        "name": "PUB_PUBLISHER",
                        "guard_name": "api",
                        "created_at": "2019-09-13 09:58:16",
                        "updated_at": "2019-09-13 09:58:16",
                        "pivot": {
                            "model_id": 30043,
                            "role_id": 3,
                            "model_type": "Isvn\\User\\Entities\\User"
                        }
                    }
                ],
                "user_types": [
                    {
                        "id": 3,
                        "name": "PUBLISHER"
                    }
                ],
                "permissions": [],
                "referring_id": "0000000026",
                "total_commission": 105000,
                "referral_count": 2,
                "referral_total": 2,
                "referral_list": [],
                "campaign_events": [
                   {
                       "campaign_id": "366",
                       "events": [
                           {
                               "conversion_id": "5f2bb7c66c906f5cc089ad94",
                               "event_code": "ACTIVE",
                               "status": "pending",
                               "commission": 0,
                               "created_time": "2020-08-06T14:56:54+0700"
                           },
                           {
                               "conversion_id": "5f2bb8506c906f5cc089ad99",
                               "event_code": "FIRST_LOGIN",
                               "status": "pending",
                               "commission": 5000,
                               "created_time": "2020-08-06T14:59:12+0700"
                           },
                           {
                               "conversion_id": "5f2bb87a6c906f5cc089ad9b",
                               "event_code": "FIRST_TRANSACTION_30D",
                               "status": "pending",
                               "commission": 100000,
                               "created_time": "2020-08-06T14:59:54+0700"
                           }
                       ]
                   }
               ],
	       "referral": {
               	"ACTIVE": 1,
               	"FIRST_LOGIN": 1,
               	"FIRST_TRANSACTION_30D": 1
           	}
 
            },
            {
                "id": 30042,
                "sso_id": 49061,
                "level_id": 1,
                "username": "19ee2db15d1d00e2596120214c79a255",
                "email": "[email protected]",
                "created_at": "2020-07-08 11:39:37",
                "avatar": null,
                "facebook_id": null,
                "google_id": null,
                "identifier_id": "0000000029",
                "profile": {
                    "first_name": "username29",
                    "last_name": "N/A",
                    "gender": 2,
                    "phone_number": "0000000000",
                    "status": 1,
                    "position": null,
                    "address": null,
                    "date_of_birth": "1990-01-01",
                    "description": null,
                    "model": null
                },
                "roles": [
                    {
                        "id": 3,
                        "name": "PUB_PUBLISHER",
                        "guard_name": "api",
                        "created_at": "2019-09-13 09:58:16",
                        "updated_at": "2019-09-13 09:58:16",
                        "pivot": {
                            "model_id": 30042,
                            "role_id": 3,
                            "model_type": "Isvn\\User\\Entities\\User"
                        }
                    }
                ],
                "user_types": [
                    {
                        "id": 3,
                        "name": "PUBLISHER"
                    }
                ],
                "permissions": [],
                "referring_id": "0000000026",
                "total_commission": 105000,
                "referral_count": 2,
                "referral_total": 2,
                "referral_list": [],
                "campaign_events": [
                   {
                       "campaign_id": "366",
                       "events": [
                           {
                               "conversion_id": "5f2bb7c66c906f5cc089ad94",
                               "event_code": "ACTIVE",
                               "status": "pending",
                               "commission": 0,
                               "created_time": "2020-08-06T14:56:54+0700"
                           },
                           {
                               "conversion_id": "5f2bb8506c906f5cc089ad99",
                               "event_code": "FIRST_LOGIN",
                               "status": "pending",
                               "commission": 5000,
                               "created_time": "2020-08-06T14:59:12+0700"
                           },
                           {
                               "conversion_id": "5f2bb87a6c906f5cc089ad9b",
                               "event_code": "FIRST_TRANSACTION_30D",
                               "status": "pending",
                               "commission": 100000,
                               "created_time": "2020-08-06T14:59:54+0700"
                           }
                       ]
                   }
               ],
	       "referral": {
               	"ACTIVE": 1,
               	"FIRST_LOGIN": 1,
               	"FIRST_TRANSACTION_30D": 1
               }
 
            },
         ],
        "meta": {
            "total": 2,
            "per_page": 20,
            "current_page": 1,
            "last_page": 1
        }
    }

Last updated

Was this helpful?