Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/JuanSCaicedo/Api-Ecommerce/llms.txt

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

API Ecommerce is a production-ready REST API built with Laravel 10 that provides everything you need to power a full-featured online store. It handles customer registration and JWT-based authentication (via tymon/jwt-auth), a product catalog with categories, brands, attributes, and variations, a shopping cart with coupon support, checkout with MercadoPago payment integration, and a complete admin panel for managing inventory and promotions. Static assets and product images are stored in OCI Object Storage, while all relational data lives in MySQL 8.0. Two distinct user roles — admins (type_user=1) and customers (type_user=2) — are enforced at the authentication layer, keeping storefront and management concerns cleanly separated.

Quickstart

Clone the repo, run migrations, and make your first authenticated API call in under 10 minutes.

Authentication

Learn how to register, log in as admin or customer, refresh tokens, and manage sessions.

Storefront Endpoints

Browse catalog, manage the cart, apply coupons, and place orders as a customer.

Admin Endpoints

Manage products, categories, brands, sliders, discounts, and coupons as an admin.

What you can build

Customer storefront — Build a fully functional shopping experience on top of the /api/ecommerce/ prefix. Customers can browse the home feed and navigation menu, search and filter products by attributes, manage a persistent cart (including coupon redemption), save delivery addresses, and place orders via direct checkout or MercadoPago. Post-purchase, customers can track orders, leave product reviews, and manage their profile including avatar uploads to OCI Object Storage. Admin panel — Build an internal back-office dashboard backed by the /api/admin/ prefix. Administrators can create and update the full product taxonomy (categories, brands, attributes, specifications, and multi-level variations), upload product images to OCI, configure homepage banners and sliders, define discount rules and coupons, and monitor orders. The admin group is protected by JWT and restricted to accounts with type_user=1, so storefront tokens can never reach management endpoints.

API surface overview

PrefixScopeAuth required
/api/auth/Registration, login (admin & customer), token refresh, logout, email verification, password resetPublic (throttled 10 req/min)
/api/ecommerce/Home feed, menus, product detail, advanced filteringPublic
/api/ecommerce/ (protected)Cart, addresses, checkout, MercadoPago, orders, reviews, profileauth:api (customer token)
/api/admin/Categories, attributes, products, brands, variations, specifications, sliders, coupons, discounts, home-viewauth:api (admin token)

Tech stack

  • PHP 8.1+ — minimum runtime requirement
  • Laravel 10 (laravel/framework ^10.10) — routing, ORM, queues, mail
  • MySQL 8.0 — primary relational data store
  • JWT authenticationtymon/jwt-auth ^2.1 with stateless bearer tokens
  • MercadoPago SDKmercadopago/dx-php ^3.0 for payment processing
  • OCI Object Storage — via league/flysystem-aws-s3-v3 ^3.0 for product images and user avatars
  • Laravel Telescopelaravel/telescope ^5.20 for local request debugging

Build docs developers (and LLMs) love