#ifndef INFINITE_CANVAS_AGENT_RESPONSE_H
#define INFINITE_CANVAS_AGENT_RESPONSE_H

#include "infinite_canvas/canvas.h"

#define CANVAS_AGENT_MAX_CREATED_ENTITIES 8

typedef struct {
    Canvas_Entity_Type type;
    char label[128];
    char text[CANVAS_ENTITY_TEXT_CAPACITY];
    Vector2 position;
    Vector2 size;
    int32 value;
    boolean has_position;
    boolean has_size;
    boolean has_value;
} Canvas_Agent_Entity_Spec;

typedef struct {
    char action[32];
    char presentation[32];
    uint32 conversation_id;
    char title[128];
    char response[CANVAS_ENTITY_TEXT_CAPACITY];
    Canvas_Agent_Entity_Spec entities[CANVAS_AGENT_MAX_CREATED_ENTITIES];
    uint32 entity_count;
} Canvas_Agent_Response;

boolean Canvas_Agent_Response_Parse(
    const char *p_json,
    Canvas_Agent_Response *p_response);

#endif
