
Learn to build apis with the Dart framework using vanilla and veneer tooling, covering authentication, product list and detail, search, profile, crud wishlist, crud payments, and notifications.
Discover the furniture app visual in the Dart framework API building course, showing how to approach visual design within a Dart-based API building workflow.
Initialize a vanilla dart furniture API project, install dart veneer, run veneer serve, and launch a hello world app to verify full stack development setup.
Explore configuring the dot env and pubspec.yaml in a laravel-inspired dart framework, including app name, app key, host, port, url, radius, mysql database connection, and dependencies.
Navigate the lib routes folder, learn web root, web socket root, and api root, implement routes by overriding register in the abstract route, and create api endpoints returning JSON.
Learn to create and extend the abstract base controller in the Dart framework, build api controllers like home, auth, and profile, ensure all methods return json responses, and apply middleware.
Extend abstract middleware class with the home middleware and implement the handle method to activate on protected routes using bearer token, while printing debug info and inspecting headers with Postman.
Explore how models map to database tables and how migrations create the users table. Configure the MySQL driver in the env file and run veneer migrate.
Explains providers, including the root service provider, which extends service provider and registers api, web, and websocket routes at boot, using route classes and prefixes.
Explore app config in the Dart framework by examining auth config in app.dart, token checks, and using the user table to authenticate requests and protect routes.
Update the user table via migration, adding name, avatar, email, password, phone, description, birthday, gender, and timestamps, then run migration and prepare an auth controller.
Create an auth controller and register endpoint using a post route, inject the request object, and implement an async register method returning a JSON response, enabling future validation.
Demonstrate field validation in a Dart API by validating name and email on a request object, using try-catch to return a JSON error with 401 status for validation failures.
Handle validation with a try catch bloc by using a validation exception class to extract the first error message and return a structured json with code 500.
Create a login endpoint in the dart framework API, wiring a post /login route, look up the user by email, verify the password, and return 404 or 401 as needed.
Test a login endpoint with Postman by sending a JSON body containing email and password, and interpret 404 and 401 responses. If login succeeds, the server should return a token.
Use the singleton auth object to login and return the user as an object, then access user data with getters and test via postman.
Understand how the auth class uses a singleton with a private constructor and static instance to log in users, create personal access tokens, and store them in a database.
Learn to create a personal access tokens table using a migration workflow, defining fields such as name, token, id, created_at, updated_at, and deleted_at, and manage migrations in development.
Demonstrates creating and returning an access token from a login endpoint, including setting expires in 30 days, testing with postman, and debugging tips like logging and hot reload caveats.
Create a forget password endpoint by adding a put route to update and hash the new password, then save it via user queries with tests.
Learn the upcoming sections to build and connect a backend for your Dart API, including login, register, and forget password APIs, and pull home page images from a database.
Download and unzip the complete furniture database and a Laravel-based admin panel, then import the schema into MySQL Workbench or phpMyAdmin and test user login.
Register and login with the new database, validating user creation and token generation via Postman, using JSON requests, and preparing for the admin panel.
Configure and run a Laravel admin panel by updating app URL and database details, then start the backend with php artisan serve to access the admin login.
Create a home controller to expose a product list API in the vanilla Dart framework. Build a product model linked to the products table and handle category id input.
Group routes with router.group and authenticate middleware to require login before access. Test the get products endpoint in Postman with a bearer token, adjust naming to avoid 404.
Implement a get_product endpoint that returns all or filtered products in JSON, supports category id filtering, and uses try-catch with status codes 200, 204, and 500.
Create a product detail endpoint in the vanilla framework by registering a detail route, validating the id, and returning the detail when found, with authorization and nullable data handling.
Build a search api endpoint with a post route that searches by title, limits results to five, and returns a list of maps as search results from default data.
Build an api for the wishlist that supports adding and removing items, displays the wishlist after login, and keeps each item tied to its product.
Create a wish list model using eloquent to enable queries, then build a profile controller and an endpoint that requires user login to add items.
Implement a wishlist end point in a Dart app by validating the product id, checking the user's wishlist, adding or removing the item in the database, and handling errors.
Test wishlist APIs with postman by adding a wishlist item using a product id, verify token and server responses, fix issues, and confirm database insertion and removal.
Learn to build a user wish list API in Dart by adding a post route, performing inner joins with products, and handling async requests with bearer token and error handling.
Build a place order API in Dart, manage cart items, checkout, Stripe payments, and database payment status with webhooks and JSON decoding across front end and back end.
Add a place order API in a Dart framework by creating an order controller and post route, decoding front-end cart data with jsondecode, and converting JSON to a map.
Learn to model cart data in Dart by building a product bin with nullable fields and a from JSON constructor, then populate a data list from a cart JSON array.
Learn to set up http and Stripe, build a checkout session with Stripe api, loop through cart items to create line items and insert order details into the database.
This lecture guides creating a post request to Stripe from a Dart app, submitting order data, setting headers, encoding as form data, and processing the checkout session URL.
Fix typos, changing 'methods' to 'method' and 'unit price' to 'unit amount', then configure stripe by signing in and inserting the secret key.
Set up ngrok to expose your local server over https for testing. Use postman with a bearer token to place an order and verify the checkout session URL.
learn how webhooks enable ongoing communication between your app and a third-party server like Stripe by registering an endpoint and using a session.
Create a Stripe webhook to listen for checkout.session.completed and update the order status from session metadata. Register the webhook in the Stripe dashboard and manage the public resources folder.
Learn how to configure Stripe webhooks, create API endpoints, register events like checkout session completed, and test payments end-to-end using environment keys and session IDs.
Build and test a get_order_list api to fetch a user's orders by status (paid, delivered, canceled, finished) using auth.id, bearer token, and 200 responses.
Create and test the get_order_detail api endpoint, enforce user authentication, query by user id and order num, and return order details (potentially multiple items) with proper success and error handling.
Create and test a get_profile API within a protected route, retrieving the user by id and returning profile data, then verify with Postman.
Create and test edit profile api by updating user profile fields (name, birthday, gender, phone, description) via a post request, handling update success and server errors.
Create and test the edit password API that accepts old and new passwords, requires re password to match, hashes the new password, updates the user record, and returns appropriate errors.
Build and test the get addresses api to fetch all user addresses, create the addresses model tied to the address table, and prepare for adding addresses.
Insert a new address record in the dart framework api building course, including country, city, zip code, and details, with createdat and updatedat timestamps, and verify success in postman.
Vania is a robust backend framework designed for building high-performance web applications using Dart. With its straightforward approach and powerful features, Vania streamlines the development process for both beginners and experienced developers alike.
Framework Features
Scalability: Built to handle high traffic, Vania effortlessly scales alongside your application's growth.
Developer-Friendly: Enjoy an intuitive API and clear documentation, making web application development a breeze.
Simple Routing: Define and manage routes effortlessly with Vania's efficient routing system, ensuring robust application architecture.
ORM Support: Interact seamlessly with databases using Vania's powerful ORM system, simplifying data management.
Request Data Validation: Easily validate incoming request data to maintain data integrity and enhance security.
Database Migration: Manage and apply schema changes with ease using Vania's built-in database migration support.
WebSocket: Enable real-time communication between server and clients with WebSocket support, enhancing user experience.
Command-Line Interface (CLI): Streamline development tasks with Vania's simple CLI, offering commands for creating migrations, generating models, and more.
Experience the simplicity and power of Vania for your next web application project.
In this tutorial we have covered the following
Installation & Activation
Going through the documents
Vania Dart CLI
Vania Migrations
Controllers, Models and Eloquents
Authentication api
Product list
Product detail
Search products
Profile api (crud)
Wishlist api (crud)
Payment api
Notification api
In this course we have covered in-depth payment detail. We explained ideas like
1. Multiple items in Cart
2. Creating LineItem for
3. Setting up Stripe and secrets
4. Analyze Stripe Log
5. Setting up WebHooks