package com.mosquito.project.dto;

import lombok.Data;
import lombok.NoArgsConstructor;
import com.fasterxml.jackson.annotation.JsonInclude;

/**
 * API密钥响应DTO
 */
@Data
@NoArgsConstructor
@JsonInclude(JsonInclude.Include.NON_NULL)
public class ApiKeyResponse {
    private String message;
    private String data;
    private String error;
    
    public ApiKeyResponse(String message, String data, String error) {
        this.message = message;
        this.data = data;
        this.error = error;
    }
    
    public static ApiKeyResponse success(String data) {
        return new ApiKeyResponse("操作成功", data, null);
    }
    
    public static ApiKeyResponse error(String error) {
        return new ApiKeyResponse("操作失败", null, error);
    }
}
