export default defineEventHandler(async (event) => {
    const { public: { apiBase } } = useRuntimeConfig();
    const token = getCookie(event, 'token');
    const body = await readBody(event);
    const query = getQuery(event);
    try {
        const data = await $fetch(`${apiBase}/ticket/${query.id}`, {
            method: 'GET',
            headers: {
                'Accept': 'application/json',
                'Authorization': `Bearer ${token}`
            }
        });
        return data;
    } catch (error) {
        return error;
    }

})