package io.wdd.func.xray.beans.xray.protocol.outbound;

import com.fasterxml.jackson.annotation.JsonProperty;
import io.wdd.func.xray.beans.xray.protocol.inbound.vmess.ClientObject;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.List;

@NoArgsConstructor
@Data
public abstract class OutboundConfigurationObject {

    @JsonProperty("vnext")
    private List<ServerObject> vnext;

    @NoArgsConstructor
    @Data
    public static class ServerObject {
        @JsonProperty("address")
        private String address;
        @JsonProperty("port")
        private Integer port;
        @JsonProperty("users")
        private List<ClientObject> users;

        @NoArgsConstructor
        @Data
        public static class UserObject {
            @JsonProperty("id")
            private String id;
            @JsonProperty("alterId")
            private Integer alterId;
            @JsonProperty("security")
            private String security;
            @JsonProperty("level")
            private Integer level;
        }
    }
}
