API get top publisher

Base URL (develop enviroment) : https://pub-be-dev.mp.directsale.vn/api/v1

ENDPOINT: /report/publisher/rank

METHOD: POST

PARAMETERS: None

BODY:

{
    "field": "pub_commission",
    "order": "desc",
    "page": 1,
    "page_size": 20,
    "from_date": "2020-09-01",
    "to_date": "2020-10-05"
}

RESPONSE:

1.Status: Error

 {
     "status": "fail",
     "message": "Something went wrong!"
 }

1.Status: Success

 {
     "status": "success",
     "data": {
         "field": "pub_commission",
         "order": "desc",
         "size": 20,
         "from_date": "2020-09-01 00:00:00",
         "to_date": "2020-10-05 00:00:00",
         "report_data": [
             {
                 "publisher_id": "17075",
                 "avatar": "https://admin-be-dev.mp.directsale.vn/storage/photos/users/avatar/oyZnKy3jyovcjYVhREq9YMVQT2LwesTHgZ4uNppR.png",
                 "first_name": "Stark",
                 "last_name": "Arya",
                 "atsp": 408640
             },
             {
                 "publisher_id": "39",
                 "atsp": 320000
             },
             {
                 "publisher_id": "16813",
                 "avatar": null,
                 "first_name": "huyentrinh",
                 "last_name": "N/A",
                 "atsp": 190222.22
             },
             {
                 "publisher_id": "9",
                 "avatar": "https://admin-be-dev.mp.directsale.vn/storage/photos/users/avatar/zaxZnYpcpeSicCSl5ztA6VH8LqS7wUY2WlFFHXpO.jpeg",
                 "first_name": "FName Huyền",
                 "last_name": "L Name Trịnh",
                 "atsp": 1000
             },
             {
                 "publisher_id": "11",
                 "avatar": null,
                 "first_name": "Mr",
                 "last_name": "PUB3",
                 "atsp": 0
             },
             {
                 "publisher_id": "17026",
                 "avatar": null,
                 "first_name": "Thế Thái",
                 "last_name": "Thế Thái",
                 "atsp": 0
             },
             {
                 "publisher_id": "17059",
                 "avatar": null,
                 "first_name": "username69",
                 "last_name": "N/A",
                 "atsp": 0
             },
             {
                 "publisher_id": "17156",
                 "avatar": null,
                 "first_name": "V600",
                 "last_name": "N/A",
                 "atsp": 0
             }
         ]
     }
 }

Last updated

Was this helpful?