package dev.sonpx.loyalty.mcp.model;

import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.Getter;
import lombok.RequiredArgsConstructor;

/**
 * Created by SonPhung on Monday, 20-Jul-2026
 */
@Getter
@RequiredArgsConstructor(staticName = "of")
public class Result<T> {

    private final T data;

    @JsonProperty("_agent_instruction")
    private String agentInstruction;

    public static <T> Result<T> of(T data, String instruction) {
        Result<T> result = of(data);
        result.instruction(instruction);
        return result;
    }

    public void instruction(String instruction) {
        this.agentInstruction = instruction;
    }
}
