Skip to main content
GET
/
projects
Get All Projects
curl --request GET \
  --url https://api.example.com/projects \
  --header 'Authorization: <authorization>'
{
  "idProyecto": 123,
  "nombre": "<string>",
  "descripcion": "<string>",
  "estado": "<string>",
  "presupuesto": 123,
  "fuenteFinanciacion": "<string>",
  "startDate": "<string>",
  "endDate": "<string>",
  "notas": "<string>",
  "subproyectos": [
    {}
  ],
  "actividades": [
    {}
  ],
  "pdfPath": [
    {}
  ],
  "responsable": {},
  "responsableId": 123,
  "detallesActividades": [
    {}
  ]
}
Retrieves all projects with their associated activities and responsible users.

Authentication

Authorization
string
required
Bearer token for authentication
Required Roles: monitor or admin

Response

idProyecto
number
Unique identifier for the project
nombre
string
Project name
descripcion
string
Project description
estado
string
Current project status
presupuesto
number
Project budget (decimal)
fuenteFinanciacion
string
Funding source
startDate
date
Project start date (YYYY-MM-DD)
endDate
date
Project end date (YYYY-MM-DD)
notas
string
Additional notes about the project
subproyectos
array
Array of subproject identifiers
actividades
array
Array of activity IDs associated with the project
pdfPath
array
Array of PDF file paths uploaded for the project. Each path is in the format /uploads/projects/{filename}
responsable
object
User object representing the project manager
responsableId
number
ID of the responsible user
detallesActividades
array
Array of activity details with id and nombre for each associated activity

Example Response

[
  {
    "idProyecto": 1,
    "nombre": "Community Development Project",
    "descripcion": "A project to improve community infrastructure",
    "estado": "En Progreso",
    "presupuesto": 50000.00,
    "fuenteFinanciacion": "Municipal Budget",
    "startDate": "2024-01-15",
    "endDate": "2024-12-31",
    "notas": "Quarterly reviews required",
    "subproyectos": [],
    "actividades": ["1", "2", "3"],
    "pdfPath": ["/uploads/projects/pdf-1234567890-123456789.pdf"],
    "responsable": {
      "IdUsuario": 5,
      "Nombre": "John",
      "Apellido": "Doe"
    },
    "responsableId": 5,
    "detallesActividades": [
      { "id": 1, "nombre": "Planning" },
      { "id": 2, "nombre": "Execution" },
      { "id": 3, "nombre": "Review" }
    ]
  }
]

Build docs developers (and LLMs) love