Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/fredy-rizo/tukit/llms.txt

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

TuKit provides two bulk-listing endpoints for browsing the full product catalogue. The first, get-all-products-uni-typo, partitions the catalogue by category — pass a positive numeric value in :typeCategory to receive uniforms, or zero/negative to receive typography products. The second, get-all-products-payment-free, partitions by payment type — positive returns paid products and zero/negative returns free products. Both endpoints support optional pagination through path parameters handled by the Paginate middleware, sort results by newest first (_id: -1), and return the same response shape including a pagination metadata object. POST /api/product/get-all-products-uni-typo/:typeCategory/:pag?/:perpage? POST /api/product/get-all-products-payment-free/:paymentAndFree/:pag?/:perpage?

Authentication

Both endpoints require a valid JWT in the token-access header. Standard user authentication is sufficient — admin privileges are not required.
HeaderValueRequired
token-access<your JWT token>✅ Yes

Endpoint 1 — List by Category

POST /api/product/get-all-products-uni-typo/:typeCategory/:pag?/:perpage?

Path Parameters

typeCategory
number
required
Numeric flag that selects the product category to return.
  • > 0 — Returns products where category = "Uniforme".
  • ≤ 0 (zero or negative) — Returns products where category = "Tipografía".
pag
number
Page number to retrieve. Processed by the Paginate middleware. Optional — defaults to page 1 when omitted.
perpage
number
Results per page. Processed by the Paginate middleware. Optional — the middleware supplies a default when omitted.

Endpoint 2 — List by Payment Type

POST /api/product/get-all-products-payment-free/:paymentAndFree/:pag?/:perpage?

Path Parameters

paymentAndFree
number
required
Numeric flag that selects the product payment type to return.
  • > 0 — Returns products where typeProduct = "Pago".
  • ≤ 0 (zero or negative) — Returns products where typeProduct = "Gratuito".
pag
number
Page number to retrieve. Optional — defaults to page 1 when omitted.
perpage
number
Results per page. Optional — the middleware supplies a default when omitted.

Request Body

Neither endpoint requires a request body. Both rely entirely on path parameters.

Response

Both endpoints share an identical response shape.

200 — Products Loaded

msj
string
"Cargando productos..."
status
boolean
true on success.
data
array
Array of product documents matching the applied filter, sorted by newest first. May be empty if no products exist for the selected category or payment type.
pagination
object
Pagination metadata for the current result set.

Error Responses

StatusCondition
500Unexpected server error

Examples

Fetch page 1 of all uniform products, 12 per page.
cURL
curl -X POST \
  "https://your-api-domain.com/api/product/get-all-products-uni-typo/1/1/12" \
  -H "token-access: <YOUR_TOKEN>"
Success Response
{
  "msj": "Cargando productos...",
  "status": true,
  "data": [
    {
      "_id": "665a1f2e8c4b2a001e3d9f01",
      "title": "Club Deportivo Tigres 2025",
      "description": "Kit completo de uniforme para temporada 2025.",
      "category": "Uniforme",
      "price": 12.99,
      "format": "AI",
      "typeProduct": "Pago",
      "archivoUrl": ["storage/product/23design.ai"],
      "imageUrl": ["storage/product/7preview.png"],
      "shirtGif": ["storage/product/12shirt.gif"],
      "shortsGif": ["storage/product/45shorts.gif"],
      "discount": "Sin descuento",
      "discountPrice": "",
      "minCant": 1,
      "date": "2025-06-01T14:30:00.000Z",
      "user": {
        "_id": "664f0a1c3b2e1a001d2c8e00",
        "userName": "adminuser",
        "email": "admin@tukit.com",
        "roles": [{ "name": "admin", "value": "2" }],
        "activate": [{ "name": "active", "value": "true" }]
      },
      "createdAt": "2025-06-01T14:30:00.000Z",
      "updatedAt": "2025-06-01T14:30:00.000Z"
    }
  ],
  "pagination": {
    "pag": "1",
    "perpage": 12,
    "pags": 4
  }
}

Build docs developers (and LLMs) love