Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/Miguel-Rodriguez15/msvc/llms.txt

Use this file to discover all available pages before exploring further.

Accepts a list of user IDs as a repeated query parameter and returns the matching Usuario records as a JSON array. This endpoint is called internally by msvc-cursos via OpenFeign whenever course details are fetched and the service needs to hydrate the enrolled-student list with full user objects. It can also be called directly for batch user lookups. A valid OAuth2 Bearer token is required — the endpoint falls under the .anyRequest().authenticated() rule in SecurityConfig, meaning any valid JWT grants access regardless of scope. Base URL: http://localhost:8001
Gateway URL: http://localhost:8090/api/usuarios

Endpoint

GET http://localhost:8001/usuarios-por-curso

Request

Headers

HeaderValue
AuthorizationBearer <access_token>

Query Parameters

ids
List<Long>
required
A comma-separated list of user IDs to retrieve. At least one ID must be provided. IDs that do not match any existing user are silently omitted from the result — no error is raised for missing IDs.Example: ?ids=1,2,3

Response

200 OK

Returns a JSON array of Usuario objects whose id values match those supplied in the ids parameter. Users whose IDs are not found are silently omitted from the array.
[].id
number
Auto-generated primary key of the user.
[].nombre
string
The user’s display name.
[].email
string
The user’s unique email address.
[].password
string
The BCrypt-encoded password hash stored for the user.

Example

Request

curl -X GET 'http://localhost:8001/usuarios-por-curso?ids=1,2,3' \
  -H "Authorization: Bearer <access_token>"
Via the API Gateway:
curl -X GET 'http://localhost:8090/api/usuarios/usuarios-por-curso?ids=1,2,3' \
  -H "Authorization: Bearer <access_token>"

200 Response

[
  {
    "id": 1,
    "nombre": "Ana García",
    "email": "ana.garcia@example.com",
    "password": "$2a$10$Xv3k8qW2mN5pL9oJ1rT6uO7yZ4hB0cD3eF5gH8iJ2kM4nP6qR8sU"
  },
  {
    "id": 2,
    "nombre": "Carlos López",
    "email": "carlos.lopez@example.com",
    "password": "$2a$10$Ab1cDe2fGh3iJk4lMn5oPq6rSt7uVw8xYz9aAbBcCdDeEfFgGhHiI"
  },
  {
    "id": 3,
    "nombre": "María Torres",
    "email": "maria.torres@example.com",
    "password": "$2a$10$Cd2eEf3gHi4jKl5mNo6pQr7sSt8uUv9wWx0xYy1yZz2zA3aBbBcCc"
  }
]

Partial Match Response

If ID 99 does not exist, only the matching records are returned — no error is raised:
curl -X GET 'http://localhost:8001/usuarios-por-curso?ids=1,99' \
  -H "Authorization: Bearer <access_token>"
[
  {
    "id": 1,
    "nombre": "Ana García",
    "email": "ana.garcia@example.com",
    "password": "$2a$10$Xv3k8qW2mN5pL9oJ1rT6uO7yZ4hB0cD3eF5gH8iJ2kM4nP6qR8sU"
  }
]

Build docs developers (and LLMs) love