---
# System prepended metadata

title: 'Project: loan - hot fix layer II pagination'

---

# Project: loan - hot fix layer II pagination

## DGP Loaning Report Update - layer I

## End-point: report
### Method: GET
>```
>{{host}}/api/loanings/report?limit=5&perspective=1&period=7&reportOptions=option1,option2
>```
### Query Params

|Param|value|
|---|---|
|limit|5|
|pageSize|10|
|perspective|1|
|period|7 (7/30/60/90)|
|reportOptions|option1,option2,...|
|sortBy|claimedDate<br/>questType<br/>註:<br/>1.default ?sortBy=claimedDate desc<br/>2.格式:fieldName asc\|desc|

### 🔑 Authentication bearer

|Param|value|Type|
|---|---|---|
|token|{{token}}|string|


### Response: 200
```json
{
  "pageSize": 100,
  "page": 1,
  "totalRows": 2000,
  "message": "Succeeded", // status code !== 200
  "results": [
    {
      "rankNo": 1,
      "userName": null,
      "oplEarned": 1755,
      "totalRevenue": 100,
      "receiverWalletAddress": "73DC877B07B4E54585A39AA0F7B8A2C9",
      "claimDetails": [
        {
          "seqId": 1,
          "questCategory": 0,
          "questType": "Weekly",
          "questName": "Weekly Quest: Increase the levels of any DGPs 18 times",
          "oplEarned": 290,
          "claimedDate": "2022-11-29T05:28:58.718221Z",
          "receiverWalletAddress": "73DC877B07B4E54585A39AA0F7B8A2C9",
          "ownerWalletAddress": "73DC877B07B4E54585A39AA0F7B8A2C9",
          "scholarWalletAddress": "E22CD5397EC66F4E94C4EBE0AA046926",
          "splitDetail": {
            "totalOplEarned": 290,
            "ownerDistribution": 100,
            "scholarDistribution": 0,
            "guildLeaderDistribution": 0,
            "operationFeeDistribution": 0,
            "oplEarnedOwner": 290,
            "oplEarnedScholar": 0,
            "oplEarnedGuildLeader": 0,
            "oplEarnedOperationFee": 0,
            "guildLeaderWalletAddress": null
          }
        },
        {
          "seqId": 2,
          "questCategory": 0,
          "questType": "Weekly",
          "questName": "Weekly Quest: Increase the levels of any DGPs 18 times",
          "oplEarned": 290,
          "claimedDate": "2022-11-29T05:29:01.496334Z",
          "receiverWalletAddress": "73DC877B07B4E54585A39AA0F7B8A2C9",
          "ownerWalletAddress": "73DC877B07B4E54585A39AA0F7B8A2C9",
          "scholarWalletAddress": "E22CD5397EC66F4E94C4EBE0AA046926",
          "splitDetail": {
            "totalOplEarned": 290,
            "ownerDistribution": null,
            "scholarDistribution": null,
            "guildLeaderDistribution": null,
            "operationFeeDistribution": null,
            "oplEarnedOwner": 290,
            "oplEarnedScholar": 0,
            "oplEarnedGuildLeader": 0,
            "oplEarnedOperationFee": 0,
            "guildLeaderWalletAddress": null
          }
        }
      ]
    }
  ]
}
```

## DGP Loaning Report Update - layer II

## End-point: report
### Method: GET
>```
>{{host}}/api/loanings/report/claimDetails?rankNo=1&pageSize=10&page=1&perspective=1&period=7&reportOptions=option1,option2
>```
### Query Params

|Param|value|
|---|---|
|rankNo|1|
|page|1|
|說明|子報表查詢，除了父參數外，多了<br/> page, rankNo|
### 🔑 Authentication bearer

|Param|value|Type|
|---|---|---|
|token|{{token}}|string|


### Response: 200
```json
{
    "pageSize":100,
    "page":1,
    "totalRows":2000,
    "message": "Succeeded", // status code !== 200
    "results":[
    {
      "seqId": 1,
      "questCategory": 0,
      "questType": "Weekly",
      "questName": "Weekly Quest: Increase the levels of any DGPs 18 times",
      "oplEarned": 290,
      "claimedDate": "2022-11-29T05:28:58.718221Z",
      "receiverWalletAddress": "73DC877B07B4E54585A39AA0F7B8A2C9",
      "ownerWalletAddress": "73DC877B07B4E54585A39AA0F7B8A2C9",
      "scholarWalletAddress": "E22CD5397EC66F4E94C4EBE0AA046926",
      "splitDetail": {
        "totalOplEarned": 290,
        "ownerDistribution": 100,
        "scholarDistribution": 0,
        "guildLeaderDistribution": 0,
        "operationFeeDistribution": 0,
        "oplEarnedOwner": 290,
        "oplEarnedScholar": 0,
        "oplEarnedGuildLeader": 0,
        "oplEarnedOperationFee": 0,
        "guildLeaderWalletAddress": null
      }
    },
    {
      "seqId": 2,
      "questCategory": 0,
      "questType": "Weekly",
      "questName": "Weekly Quest: Increase the levels of any DGPs 18 times",
      "oplEarned": 290,
      "claimedDate": "2022-11-29T05:29:01.496334Z",
      "receiverWalletAddress": "73DC877B07B4E54585A39AA0F7B8A2C9",
      "ownerWalletAddress": "73DC877B07B4E54585A39AA0F7B8A2C9",
      "scholarWalletAddress": "E22CD5397EC66F4E94C4EBE0AA046926",
      "splitDetail": {
        "totalOplEarned": 290,
        "ownerDistribution": null,
        "scholarDistribution": null,
        "guildLeaderDistribution": null,
        "operationFeeDistribution": null,
        "oplEarnedOwner": 290,
        "oplEarnedScholar": 0,
        "oplEarnedGuildLeader": 0,
        "oplEarnedOperationFee": 0,
        "guildLeaderWalletAddress": null
      }
    }
  ]
}
```
## End-point: report for download - zip file
### Method: GET
>```
>{{host}}/api/loanings/report-downloa-csv?limit=5&perspective=1&period=7&reportOptions=option1,option2&rewardType=mysteryChest
>```
### Query Params

|Param|value|
|---|---|
|limit|5|
|perspective|1|
|period|7 (7/30/60/90)|
|reportOptions|option1,option2,...|
|rewardType|[opl \| mysteryChest]|
|sortBy|claimedDate<br/>questType<br/>註:<br/>1.default ?sortBy=claimedDate desc<br/>2.格式:fieldName asc\|desc|


### 🔑 Authentication bearer

|Param|value|Type|
|---|---|---|
|token|{{token}}|string|


### Response: 200
zip file stream