pk ID_Post · sk URL ·
fuente final_production_package_control.csv · @catrina_nortena
analytics Streamlit+Plotly/Power BI · ingest CSV upsert · Teams webhook + logs JSON
Tablero editorial que revisa, corrige y enruta posts diarios de @catrina_nortena para el área editorial de Terrauniversalis. Integra el pipeline Panchita (narración), QA automático y verificación de fuentes.
Los datos se guardan en memoria en la sesión actual del navegador y se exportan hacia SharePoint / Power Automate. Este paquete es lo que necesita el área de Sistemas para replicar el modelo en un backend propio (Postgres, SharePoint, Fabric, etc.).
Fuente canónica: final_production_package_control.csv · pk ID_Post · sk URL
| # | columna | tipo | origen | descripcion |
|---|---|---|---|---|
| cargando… | ||||
JWT Azure AD (tenant Terrauniversalis). Rate limit: 120 req/min por token.
Authorization: Bearer $CATRINA_API_TOKEN
curl -X GET "https://api.terrauniversalis.mx/catrina/v1/posts?estado=REVISAR&limit=50" \
-H "Authorization: Bearer $CATRINA_API_TOKEN"
curl -X PATCH "https://api.terrauniversalis.mx/catrina/v1/posts/2054615748157604003" \
-H "Authorization: Bearer $CATRINA_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{"Estado_Revision":"Aprobado","QA_Status":"PASS","Revisor":"alfonso"}'
base: https://api.terrauniversalis.mx/catrina/v1
| # | método | path | uso |
|---|---|---|---|
| 1 | GET | /posts | Listar · filtros estado/community/qa/batch · page/limit |
| 2 | GET | /posts/{ID_Post} | Obtener por pk |
| 3 | POST | /posts | Crear · upsert ?upsert=1 |
| 4 | PATCH | /posts/{ID_Post} | Actualización parcial |
| 5 | DELETE | /posts/{ID_Post} | Soft-delete · ?hard=1 admin |
| 6 | GET | /export/csv | descargar csv · 51 cols |
| 7 | GET | /export/json | descargar json · snapshot |
| 8 | POST | /ingest/csv | multipart file · upsert ID_Post |
| 9 | GET | /stats | KPIs Streamlit / Power BI |
| 10 | POST | /webhook/post-updated | Power Automate / Teams |
cargando…
catrina_streamlit_app.py — KPIs, Plotly por community/verification, tabla editorial, PATCH en línea.
pip install streamlit pandas requests plotly export CATRINA_API_BASE="https://api.terrauniversalis.mx/catrina/v1" export CATRINA_API_TOKEN="eyJhbGciOi..." streamlit run catrina_streamlit_app.py
ID_Post (índice único). SK URL.POST /ingest/csv con final_production_package_control.csv (upsert)./webhook/post-updated → Teams #catrina-editorial.contacto::sistemas · owner alfonso @ terrauniversalis · sistemas@terrauniversalis.mx · #catrina-editorial
entrega::sistemas · csv · json · openapi · streamlit.py