package ru.soune.nocopy.dto.statistic;

import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
public class TokenStatisticResponse {

    @JsonProperty("total_bought")
    private Long totalBought;

    @JsonProperty("total_spent")
    private Long totalSpent;

    @JsonProperty("bought_per_user")
    private Percentiles boughtPerUser;

    @JsonProperty("spent_per_user")
    private Percentiles spentPerUser;

    @Data
    @AllArgsConstructor
    @NoArgsConstructor
    public static class Percentiles {
        @JsonProperty("p5")
        private Long p5;

        @JsonProperty("p50")
        private Long p50;

        @JsonProperty("p95")
        private Long p95;
    }
}
