Skip to main content

Exploring API Integration: From Landing Page to Data Fetching

Published 6 min readMarkdown
Part of seriesMy Frontend Developer Internship With Mently
Exploring API Integration: From Landing Page to Data Fetching

In the world of web development, one of the most essential skills is the ability to integrate external data into your applications. In my journey as a frontend developer intern at mently, I started by replicating a landing page, but soon after, I was introduced to the concept of fetching data from APIs (Application Programming Interfaces). This new challenge opened my eyes to how applications interact with external services, and how dynamic data can flow into the frontend, enhancing user experience. This article explores my progression from the basic landing page setup to understanding and implementing effective API integration using both the .then() method and the async/await pattern. Through this exploration, I’ve gained deeper insights into the asynchronous nature of web development and how to manage data fetching more efficiently.

Introduction to Swagger UI

As I progress further in my internship at Mently and prepare for working on explore page which is my next task, I got the opportunity to explore Swagger UI, guided by Ms. Ruqouyyah Muhammad and Mr. Victor Orlunda. Swagger UI is an interactive documentation tool that provides a visual interface for exploring, testing, and understanding APIs. Instead of reading through plain technical docs or guessing how an endpoint works, Swagger UI allows me to see all available endpoints, the request formats, the required parameters, and the types of responses I can expect, all in one place.

Through their guidance, I learned that Swagger UI is not just documentation, it’s also a sandbox for experimentation. I can test different API calls directly within the interface, passing in sample data and observing real-time responses. This hands-on experience helped me:

  • Understand endpoints clearly – I can see what each endpoint does, whether it’s retrieving data with a GET request, sending new data with a POST, or updating/deleting data with PUT and DELETE.

  • Visualize request/response flow – Instead of trial and error, I get structured input fields and see exactly how the response looks in JSON format.

  • Practice integration with confidence – Before writing any code, I can confirm that an endpoint works and what kind of data I’ll be handling.

What makes this especially powerful is how it ties back to the tasks I’m working on. With Swagger UI, I no longer treat APIs as abstract concepts, I interact with them directly, understand their behavior, and then integrate them into my frontend code using .then() or async/await. It transforms API integration from something theoretical into a practical, confidence-building process.

Replicating Mently’s Explore Page:

The explore page toggles between mentors’ details and programs created in the platform.
I started with the mentor’s component where I created the mentors card

My Line Manager’s UI Review: Mentor Card Corrections (by Ruqouyyah)

After I populated the Mentors Card with data from the API, my line manager, Ms. Ruqouyyah Muhammad, reviewed the component and requested the following corrections to align it with Mently’s design system and layout principles:

  1. The user’s image should serve as the card’s background, filling the entire card area without distortion.

  2. The profile section must span the full width of the card to improve readability and visual balance.

  3. She also noted that the card’s UI does not currently match our established styles: spacing, and typography should be brought into compliance.

  4. Finally, all mentor cards need to be centralized within their container so the grid appears balanced across screen sizes. This guidance sharpened my attention to consistency and accessibility, and it’s shaping how I approach component polish going forward. The images below is what I had before implemented the corrections from my line manager.

    Implementing the highlights from my line Manager and Getting rid of alt message and Missing Image Icon

    I cleaned up my image handling based on my line manager’s notes and the UI feels so much more professional. You know that little “broken image” icon browsers show when an image fails to load? I banished it. The rule is simple: don’t render an image tag unless you have a valid URL; and if loading fails, swap to a safe default instead of showing the browser’s error chrome.

    What I changed:

    • Conditional rendering: Only render the image component when a real src exists.

    • Graceful fallback: If the request fails, immediately replace it with a default profile image, no flashing icons, no “alt” text leak.

    • Consistent experience: Users who never uploaded a photo still get a clean avatar, so the layout never breaks.

      Below are screenshots after implementing my line manager’s corrections and adding a default image for invalid image sources or failed uploads.

Implementing pagination

I shipped pagination so pages load faster and feel calmer. Instead of dumping everything at once, I served content in bite-sized pages (e.g., 12 items per view), with Next/Previous controls and clear counts. The wins: quicker initial load, less scrolling fatigue, and smoother navigation especially on slower networks.

What I changed

  • API & params: added ?page=1&limit=12 (with server-side bounds + validation).

  • UI state: disabled buttons at edges, spinner for loading, and an empty state when there are no results.

  • Accessibility: focus moves to the results region on page change; buttons have aria-labels.

  • Find the Right Mentor Fast ; Search by Name, Company, or Role (with Newest/Oldest sorting)

    Based on guidance from my line manager, Ms. Ruqouyyah Muhammad, I upgraded the Dormy dataset with a cleaner Search by Industry experience. A user can now find mentors by name, company, or role from a single search box, just start typing and relevant results appear instantly. I also added simple sorting (Newest ↔ Oldest) so users can scan fresh profiles first or explore long-standing entries. Behind the scenes, I trimmed noise with partial-match logic, added a short debounce for speed, and kept the UI friendly with highlighted matches and clear “no results” messages. The result is a fast search that helps you get to the right person without wrestling the interface.

    Responsiveness

    Earlier projects taught me a simple truth: great UI isn’t great unless it works everywhere. So, I made responsiveness a first-class feature here. I designed mobile-first, then layered in breakpoints to progressively enhance the layout from small screens up to widescreens. That means content stacks cleanly on phones, expands into balanced grids on tablets, and breathes with comfortable whitespace on desktops without ever feeling cramped or broken.

    Practically, I used semantic grids and flexible units so containers flow instead of forcing fixed widths. Breakpoints handle layout shifts (single-column → two/three-column), typography scales smoothly for readability, and images are constrained with proper aspect ratios to avoid layout jumps.

    My ongoing goal is simple: every project I ship should be usable, readable, and delightful on any screen size.

    Conclusion
    This internship turned me from a “static page” builder into a developer who can confidently ship data-driven features. I learned to read and test APIs with Swagger UI, fetch data cleanly using .then() and async/await, and design resilient UIs with proper loading, error states, and image fallbacks. Implementing pagination, search, and sorting sharpened my performance and accessibility mindset, while design-system reviews improved my layout, spacing, and typography skills. Overall, I now approach problems end-to-end, understanding the API, managing state, and delivering polished, usable components.

About the author

  • Gloria is a passionate web developer with a strong drive for creating intuitive, dynamic, and responsive web applications. Always eager to learn new technologies and improve coding skills, Gloria is dedicated to building seamless user experiences through clean and efficient code. Stay tuned for insights and tips on web development, shared from a developer’s perspective.

user interface is a bomb.. very intuitive

1

Thank you so much