Documentation Index
Fetch the complete documentation index at: https://mintlify.com/Edfermachado/proyectoSistemas/llms.txt
Use this file to discover all available pages before exploring further.
External requests are structured B2B submissions that outside parties — companies, media outlets, academic departments, and streaming platforms — can file against your faculty’s events. Each request is typed, carries a validated metadata payload, and is stored permanently for review from the /faculty-admin/requests dashboard. This page is restricted to tenant_admin users only.
Request Types
UniEvents defines four request types via the requestTypeEnum in the database schema. Each type has its own metadata shape, validated by a dedicated Zod schema.
soporte_academico — Academic Support
Submitted by internal departments that want to collaborate on an event by providing equipment or institutional resources.
const AcademicSupportSchema = z.object({
department: z.string(),
requiredEquipment: z.array(z.string()),
});
Example metadata:
{
"department": "Departamento de Física",
"requiredEquipment": ["Proyector 4K", "Sistema de audio portátil", "Pizarras móviles"]
}
Submitted by companies or organizations offering financial or in-kind contributions in exchange for branding assets at the event.
const SponsorshipSchema = z.object({
companyName: z.string().min(2),
contributionAmount: z.number().positive().optional(),
contactEmail: z.string().email(),
requestedAssets: z.array(z.string()).optional(),
});
Example metadata:
{
"companyName": "Tech Solutions C.A.",
"contributionAmount": 500,
"contactEmail": "marketing@techsolutions.com",
"requestedAssets": ["Logo en banner principal", "Mención en redes sociales", "Stand en el evento"]
}
cobertura_prensa — Press Accreditation
Submitted by journalists or media outlets requesting credentials and access rights to cover the event.
const PressSchema = z.object({
mediaOutlet: z.string().min(2),
journalistName: z.string().min(2),
credentialsId: z.string().optional(),
equipmentDetails: z.string().optional(),
});
Example metadata:
{
"mediaOutlet": "Diario El Nacional",
"journalistName": "Carlos Rodríguez",
"credentialsId": "CNP-12345",
"equipmentDetails": "Cámara DSLR + micrófono de solapa"
}
derechos_transmision — Broadcasting Rights
Submitted by streaming platforms or broadcasters requesting rights to live-stream or record the event.
const BroadcastingRightsSchema = z.object({
platform: z.string(),
exclusivity: z.boolean(),
estimatedAudience: z.number().optional(),
});
Example metadata:
{
"platform": "YouTube Live",
"exclusivity": false,
"estimatedAudience": 5000
}
Viewing Requests
Navigate to /faculty-admin/requests. The page lists all external requests submitted against events belonging to your faculty, ordered by submission date (newest first). Each row in the table shows:
- ID / Date — truncated request UUID and creation date.
- Event — the title of the event the request is linked to.
- Request Type — the
requestTypeEnum value displayed as a badge.
- Metadata — the full Zod-validated JSON payload rendered as a code block.
Requests from events belonging to other faculties are automatically filtered out — you only see requests for your own tenant’s events.
Use the requests list to track all external partnerships and media coverage proposals for your events. The metadata field gives you all the contact details and specifics you need to follow up directly with each requester.
Submitting a Request
External parties (or internal tooling) submit requests by calling the createEventRequest server action. The action requires an authenticated session, validates the metadata with Zod before any database write, and inserts the record into event_requests.
// Server Action signature (src/app/actions/requests.actions.ts)
createEventRequest(
eventId: string,
requestType: "soporte_academico" | "patrocinio" | "cobertura_prensa" | "derechos_transmision",
metadataRaw: any
): Promise<EventRequest>
Example call — submitting a sponsorship request:
import { createEventRequest } from "@/app/actions/requests.actions";
await createEventRequest(
"evt-uuid-1234",
"patrocinio",
{
companyName: "Tech Solutions C.A.",
contributionAmount: 500,
contactEmail: "marketing@techsolutions.com",
requestedAssets: ["Logo en banner principal"]
}
);
If the metadata does not match any of the four Zod schemas, the action throws an error with a descriptive Zod validation message before touching the database. This fail-fast validation ensures only well-structured data ever reaches the event_requests table.
Zod Schemas Reference
All four metadata schemas are exported from src/validations/requests.ts:
import { z } from 'zod';
export const SponsorshipSchema = z.object({
companyName: z.string().min(2),
contributionAmount: z.number().positive().optional(),
contactEmail: z.string().email(),
requestedAssets: z.array(z.string()).optional(),
});
export const PressSchema = z.object({
mediaOutlet: z.string().min(2),
journalistName: z.string().min(2),
credentialsId: z.string().optional(),
equipmentDetails: z.string().optional(),
});
export const AcademicSupportSchema = z.object({
department: z.string(),
requiredEquipment: z.array(z.string()),
});
export const BroadcastingRightsSchema = z.object({
platform: z.string(),
exclusivity: z.boolean(),
estimatedAudience: z.number().optional(),
});
// Union of all four schemas — used for DB type inference
export const EventRequestMetadataSchema = z.union([
SponsorshipSchema,
PressSchema,
AcademicSupportSchema,
BroadcastingRightsSchema,
]);
export type EventRequestMetadata = z.infer<typeof EventRequestMetadataSchema>;
The metadata column in the event_requests table is typed as jsonb with the EventRequestMetadata TypeScript type applied via Drizzle ORM’s .$type<EventRequestMetadata>() helper.