πŸ”΄ Let’s build an AI Help Bot with NEXT.JS 14! (Neon PostgreSQL, Clerk, AI Agent, OpenAI, IBM)

Sonny Sangha β€’ June 28, 2024
Video Thumbnail
Sonny Sangha Logo

Sonny Sangha

@sonnysangha

About

I'm Sonny. πŸ’― You might also know me as PAPA React! I've been coding for over 10 years now. As a Full Stack developer I've worked both with startups and large corporations to help build & scale their companies. Along the journey I realised my passion existed in helping others excel and pursue their dreams as upcoming developers and if that’s not enough I have cloned most of the applications you have used in your life! 🌟 🚨 Join the world’s BEST developer community β€œZero to Full Stack Hero” NOW: https://www.papareact.com/course

Video Description

1️⃣ Get Started with Clerk Authentication πŸ‘‰ https://go.clerk.com/2TtD63C 2️⃣ Sign up with IBM API Connect Essentials for free πŸ‘‰ https://ibm.biz/BdKBmQ 3️⃣ Setup your Neon PostgreSQL database for free πŸ‘‰ https://fyi.neon.tech/sonny ❗️Get the SQL Seed File for free πŸ‘‰ https://www.papareact.com/intercom-build-opt-in-form 🚨 Join the world’s BEST developer community & course Zero to Full Stack Hero: https://www.papareact.com/course πŸ› οΈ Looking for the Code for this build? (Plus over 50+ others!) https://links.papareact.com/github Join me as I show you how to build an Intercom Clone AI App from scratch with the latest Next.js 14. You'll learn the following in this build: πŸ‘‰ Ability to chat to the AI Agent in a Real-time 1 - 1 Chat which uses the OpenAI Completions API to respond to user queries! πŸ‘‰ Ability to store Admin Details & Prompts in a PostgreSQL DB provided by Neon! πŸ‘‰ How to implement StepZen to introspect the PostgreSQL DB & generate a GraphQL API for efficient data querying and manipulation! πŸ‘‰ How to use Clerk Authentication to add Google User Authentication with ease! πŸ‘‰ Ability to Create New Chatbots with a unique link that allows anyone to chat with the chatbot to assist them with their queries! πŸ‘‰ How to implement an Admin Dashboard to create new chatbots, edit prompts, and view all previous chat histories. πŸ‘‰ How to utilise the power of caching in Next.js to create an optimal & efficient user experience! πŸ‘‰ How to use Next.js Server Components & Client Components and when/where to use them! πŸ‘‰ How to utilise the power of Server Actions & caching in Next.js to create an optimal & efficient user experience! πŸ‘‰ How to use Next.js 14 Server Components & Client Components and when/where to use them! πŸ‘‰ Create a Beautiful UI & UX for our Frontend using the highly Popular Shadcn & Tailwind CSS πŸ‘‰ How to use TypeScript to reduce the overall number of Bugs and Errors πŸ‘‰ How to deploy the final build on Vercel 🎡 WANT TO LISTEN TO THE EXCLUSIVE PAPAFAM PLAYLIST? Sign up for the PAPAFAM Newsletter here πŸ‘‰ https://links.papareact.com/newsletter πŸ• TIMESTAMPS: 00:00 Introduction 01:05 Build Demo 08:50 Build Tech & Explanation 20:05 Initialising the Build 24:05 Setting Up Clerk 30:06 Building the Admin & Guest Section 34:46 Building the Header Component (1/2) 37:26 Building the Avatar Component 39:49 Building the Header Component (2/2) 48:42 Building the Sidebar Component 52:17 Implementing Shadcn/ui 56:28 Building the Create Chatbot Page (1/2) 1:02:35 Setting Up a PostgreSQL DB in Neon 1:08:59 Setting Up IBM API Connect Essentials 1:12:09 Introspecting the PostgreSQL DB with IBM API Connect Essentials (StepZen) 1:22:36 Implementing the Apollo Client 1:24:49 Implementing a Proxy API End Point 1:29:39 Building the GraphQL Backend 1:41:14 Implementing Queries & Mutations 1:42:57 Building the Create Chatbot Page (2/2) 1:47:46 Live Debugging 1:57:10 Building the Edit Chatbot Page (1/3) 2:06:57 Implementing Toast Notifications with Shadcn Sonner 2:08:11 Building the Edit Chatbot Page (2/3) 2:17:20 Building the Characteristic Section of the Chatbot 2:29:06 Building the Edit Chatbot Page (3/3) 2:41:42 Building the View Chatbot Section 2:55:48 Building the Review Sessions Page (1/2) 3:00:38 Building the Chat Bot Sessions Component 3:10:26 Building the Review Sessions Page (2/2) 3:13:58 Creating the Messages Component 3:14:54 Implementing DaisyUI 3:16:49 Building the Messages Component 3:29:26 Building the Login Page 3:36:27 Building the Home Page 3:38:40 Building the Chatbot Page (1/3) 3:48:09 Implementing the New Chat Functionality 3:54:10 Building the Chatbot Page (2/3) 3:59:49 Implementing a Form with Zod & React-Hook-Form 4:06:45 Building the Chatbot Page (3/3) 4:11:28 Implementing OpenAI Completions API 4:24:38 Deploying to Vercel 4:32:39 Tips to Fix CORS Error 4:33:25 Final Deployed Build Demo 4:36:36 Build Summary 4:38:45 Outro Let’s get it PAPAFAM πŸ”₯. DISCLAIMER: This Video is made for informational and educational purposes only. We do not own or affiliate with Intercom and/or any of its subsidiaries in any form. Copyright Disclaimer Under section 107 of the Copyright Act 1976, allowance is made for β€œfair use” of this video for educational purposes. #nextjs #nextjs15 #IBM #ai #chatgpt #neon #Clerk #postgres #stepzen #shadcn #tailwindcss #reactjstutorial #coding #openai #intercom #programming #aiagents #story #javascript

You May Also Like

Upgrade Your iPhone Experience

AI-recommended products based on this video

Loading...
ESR 3 Pack for iPhone 16e/ iPhone 14/ iPhone 13/ iPhone 13 Pro Privacy Screen Protector, Anti-spy Tempered-Glass Privacy Screen Protector, Micro-curved Edges, Case Friendly

ESR 3 Pack for iPhone 16e/ iPhone 14/ iPhone 13/ iPhone 13 Pro Privacy Screen Protector, Anti-spy Tempered-Glass Privacy Screen Protector, Micro-curved Edges, Case Friendly

(5,773)
9.99
PrimeFREE delivery Saturday, June 14 on orders shipped by Amazon over $35
1K+ bought in past month
Loading...
Belkin BoostCharge Lightning Cable - 6.6ft/2M - MFi Certified Apple iPhone Charger USB to Lightning Cable - iPhone Cable - iPhone Charger Cord - Apple Charger - USB Phone Charger - Black

Belkin BoostCharge Lightning Cable - 6.6ft/2M - MFi Certified Apple iPhone Charger USB to Lightning Cable - iPhone Cable - iPhone Charger Cord - Apple Charger - USB Phone Charger - Black

(3,522)
11.99
PrimeFREE delivery Saturday, June 14 on orders shipped by Amazon over $35
100+ bought in past month
Loading...
Apple 20W USB-C Compact Power Adapter: Fast and Convenient Charging, Type C Wall Charger

Apple 20W USB-C Compact Power Adapter: Fast and Convenient Charging, Type C Wall Charger

(5,869)
$14.99$13.47
FREE delivery Thu, Sep 4 on $35 of items shipped by Amazon
10K+ bought in past month
Loading...
Temdan for Travel Essentials,3 in 2 USB C Cable for Apple Watch Charger/iPhone 16 Charger/Lightning,Multi Charging Cable Cord,Camping Essentials,Portable Designed for iWatch Series &iPhone 16-12-4FT Global Recycled Standard

Temdan for Travel Essentials,3 in 2 USB C Cable for Apple Watch Charger/iPhone 16 Charger/Lightning,Multi Charging Cable Cord,Camping Essentials,Portable Designed for iWatch Series &iPhone 16-12-4FT Global Recycled Standard

(2,378)
$8.49
FREE delivery Sat, Aug 9 on $35 of items shipped by Amazon
10K+ bought in past month
Loading...
Apple AirPods Pro 2 Wireless Earbuds, Active Noise Cancellation, Hearing Aid Feature, Bluetooth Headphones, Transparency, Personalized Spatial Audio, High-Fidelity Sound, H2 Chip, USB-C Charging

Apple AirPods Pro 2 Wireless Earbuds, Active Noise Cancellation, Hearing Aid Feature, Bluetooth Headphones, Transparency, Personalized Spatial Audio, High-Fidelity Sound, H2 Chip, USB-C Charging

(38,487)
$199.00$187.32
FREE delivery Fri, Oct 3
10K+ bought in past month
Loading...
Anker iPhone 16 Charger, 2-Pack 20W Fast USB C Charger Block, for iPhone 16/16 Pro Max/15 Series/iPad Pro and More (White, 2 Pack & 2 Cable)

Anker iPhone 16 Charger, 2-Pack 20W Fast USB C Charger Block, for iPhone 16/16 Pro Max/15 Series/iPad Pro and More (White, 2 Pack & 2 Cable)

(16,565)
13.99
PrimeFREE delivery Saturday, June 14 on orders shipped by Amazon over $35
10K+ bought in past month
Loading...
ANKER 737 Power Bank, 24,000mAh 3-Port Laptop Portable Charger with 140W Fast Charging, Smart Display, for Outdoor Work, Compatible with iPhone 16/15/14 Series, Vision Pro, Samsung, MacBook, and More

ANKER 737 Power Bank, 24,000mAh 3-Port Laptop Portable Charger with 140W Fast Charging, Smart Display, for Outdoor Work, Compatible with iPhone 16/15/14 Series, Vision Pro, Samsung, MacBook, and More

(13,939)
109.99
FREE delivery Saturday, June 14
9K+ bought in past month
Loading...
ESR 3 Pack for iPhone 16e/ iPhone 14/ iPhone 13/ iPhone 13 Pro Privacy Screen Protector, Anti-spy Tempered-Glass Privacy Screen Protector, Micro-curved Edges, Case Friendly

ESR 3 Pack for iPhone 16e/ iPhone 14/ iPhone 13/ iPhone 13 Pro Privacy Screen Protector, Anti-spy Tempered-Glass Privacy Screen Protector, Micro-curved Edges, Case Friendly

(5,773)
9.99
PrimeFREE delivery Saturday, June 14 on orders shipped by Amazon over $35
1K+ bought in past month
Loading...
FNTCASE for iPhone 17 Pro-Max Case: Clear Magnetic Phone Cases with Screen Protector Compatible with Magsafe Slim Anti Yellowing Rugged Shockproof Protective Transparent Cell Cover (A-Clear) Recycled Claim Standard Blended

FNTCASE for iPhone 17 Pro-Max Case: Clear Magnetic Phone Cases with Screen Protector Compatible with Magsafe Slim Anti Yellowing Rugged Shockproof Protective Transparent Cell Cover (A-Clear) Recycled Claim Standard Blended

(0)
$3.95
FREE delivery Wed, Nov 19 on $35 of items shipped by Amazon
10K+ bought in past month
Loading...
PQRQP 3 in 1 Professional Wireless Lavalier Microphone for iPhone, Android, Camera, Wireless Microphones, Mini Microphone, Crystal Clear Sound Quality for Recording, Live Streaming, YouTube, TikTok
Best Seller

PQRQP 3 in 1 Professional Wireless Lavalier Microphone for iPhone, Android, Camera, Wireless Microphones, Mini Microphone, Crystal Clear Sound Quality for Recording, Live Streaming, YouTube, TikTok

(675)
$29.98
FREE delivery Thu, Sep 4 on $35 of items shipped by Amazon
9K+ bought in past month
Loading...
Agfabric 40" x 75 Feet Natural Burlap Fabric Roll,Gardening Burlap Roll,High Density Jute Material for Winter Plants Tree Cover Protection,Weed Barrier,Decorations,Crafts

Agfabric 40" x 75 Feet Natural Burlap Fabric Roll,Gardening Burlap Roll,High Density Jute Material for Winter Plants Tree Cover Protection,Weed Barrier,Decorations,Crafts

(127)
47.84
PrimeFREE delivery Saturday, June 14