DEV Community

Adekunle Ademola
Adekunle Ademola

Posted on

๐Ÿš€ HNG13 Stage 0 (Backend Track)

Hey everyone ๐Ÿ‘‹

I just completed Stage 0 of the HNG13 Internship (Backend track), and itโ€™s been an awesome start already!

For our first task, we were asked to build a Dynamic Profile Endpoint API that returns our personal information along with a random cat fact fetched from an external API. ๐Ÿฑ

๐Ÿ’ก What the task was about

The goal was to:

  • Build a simple backend API with Node.js and Express
  • Fetch data from a third-party API (Cat Fact API)
  • Return both static and dynamic JSON data
  • Implement rate limiting for better security and performance
  • Handle errors properly and follow clean API design principles
  • This project tested our understanding of APIs, JSON, error handling, and rate limiting; all essential backend skills.

๐Ÿงฐ Tech Stack

  • Backend: Node.js / Express
  • Rate Limiter: express-rate-limit
  • External API: Cat Fact API

โš™๏ธ Setup Guide

To run the project locally:

Clone the repository

git clone https://github.com/Jamal-09/hng_stage_0.git
Enter fullscreen mode Exit fullscreen mode

Navigate into the folder

cd hng_stage_0
Enter fullscreen mode Exit fullscreen mode

Install dependencies

npm install
Enter fullscreen mode Exit fullscreen mode

Declare environment variables

PORT=3000
Enter fullscreen mode Exit fullscreen mode

Start the development server

node server.js
Enter fullscreen mode Exit fullscreen mode

๐Ÿ”— Endpoints

GET /

Returns a welcome message.

{
  "status": "success",
  "message": "Welcome to my dynamic profile API"
}
Enter fullscreen mode Exit fullscreen mode

GET /me

Returns my profile information, timestamp, and a random cat fact.

{
  "status": "success",
  "user": {
    "email": "napg.adekunle@gmail.com",
    "name": "Jamal Ademola",
    "stack": "Node.js/Express"
  },
  "timestamp": "2025-10-15T19:35:01.868Z",
  "fact": "A group of cats is called a โ€œclowder.โ€"
}

Enter fullscreen mode Exit fullscreen mode

๐ŸŒ Live Demo

๐Ÿงญ Lessons Learned

  • Working with third-party APIs in Express
  • Parsing and returning dynamic JSON responses
  • Implementing rate limiting using middleware
  • Handling errors and API reliability properly

๐Ÿ“ฌ Contact

Built with ๐Ÿ’ป & โค๏ธ by Jamal Ademola

โœ… Stage 0 complete!
Excited for the next challenge at #HNG13 ๐Ÿš€

Top comments (0)