From f9d21619385a00bd73250a71cf9f4b902f3c3086 Mon Sep 17 00:00:00 2001 From: Consultoria AS Date: Tue, 17 Feb 2026 02:34:51 +0000 Subject: [PATCH] feat(web): add getCfdiXml API function Co-Authored-By: Claude Opus 4.5 --- apps/web/lib/api/cfdi.ts | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/apps/web/lib/api/cfdi.ts b/apps/web/lib/api/cfdi.ts index 2eb2895..7cca27a 100644 --- a/apps/web/lib/api/cfdi.ts +++ b/apps/web/lib/api/cfdi.ts @@ -89,3 +89,10 @@ export async function createManyCfdis( export async function deleteCfdi(id: string): Promise { await apiClient.delete(`/cfdi/${id}`); } + +export async function getCfdiXml(id: string): Promise { + const response = await apiClient.get(`/cfdi/${id}/xml`, { + responseType: 'text' + }); + return response.data; +}