Skip to content

Conversation

@mishraa-G
Copy link

What has changed?

This PR adds a focused quick-starter for the PHP + PostgreSQL example and improves the existing C++ + MongoDB quickstart so both match the level of other sample quickstarts (e.g., PetClinic). Changes include clear prerequisites, exact endpoints, Docker/compose/service notes, Keploy record/replay commands, project structure, troubleshooting, and a quick commands cheat-sheet.

This PR Resolves #3521

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue).
  • New feature (non-breaking change which adds functionality).
  • Breaking change (fix or feature that would cause existing functionality to not work as expected).
  • Documentation update (if none of the other choices apply).

How Has This Been Tested?

I verified the quickstart content against the upstream example README files for both repos (C++ and PHP) and ensured the endpoints and Keploy command flags match those READMEs.

To validate the docs render locally and to produce screenshots for the PR:

  1. From the repo root:
npm install
npm run build
npm run serve
  1. Open the built site (usually at http://localhost:3000) and navigate to the versioned quickstart pages:
    • versioned_docs/version-4.0.0/quickstart/cpp-mongodb-quickstart.md
    • versioned_docs/version-4.0.0/quickstart/php-postgressql-quickstart.md
  2. Capture screenshots of the npm run build and npm run serve outputs and the rendered pages and attach them to this PR.

To validate the quickstart steps themselves (optional):

  • Clone the referenced example repos and run:
    • docker network create keploy-network || true
    • docker compose up --build
    • Exercise the endpoints (curl examples in the docs)
    • Run Keploy record and Keploy test in a Linux environment (Codespaces recommended) to confirm recording and replay.

Files changed

  • versioned_docs/version-4.0.0/quickstart/cpp-mongodb-quickstart.md — cleaned and expanded C++ quickstart with prerequisites, endpoints (GET /health, POST /items, GET /items), Docker/Keploy notes, project structure, troubleshooting, and cheat-sheet.
  • versioned_docs/version-4.0.0/quickstart/php-postgressql-quickstart.md — new quick-starter for PHP + PostgreSQL example repo (https://github.com/mishraa-G/keploy-php-postgres-quickstart): clone → docker → test → keploy record/replay, project structure, DB init note, and cheat-sheet.

Checklist:

  • My code follows the style guidelines of this project.
  • I have performed a self-review of my own code.

Copilot AI review requested due to automatic review settings February 1, 2026 12:48
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you and congratulations 🎉 for opening your very first pull request in keploy

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a new PHP + PostgreSQL quickstart guide and improves the existing C++ + MongoDB quickstart documentation for version 4.0.0. Both guides aim to provide focused, step-by-step instructions for users to clone example repositories, run applications with Docker, and use Keploy for API traffic recording and test replay.

Changes:

  • Added comprehensive PHP + PostgreSQL quickstart with detailed setup instructions, endpoints documentation, and Docker/Keploy usage
  • Enhanced C++ + MongoDB quickstart with improved structure, clear prerequisites, Docker workflows, and troubleshooting guidance

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 6 comments.

File Description
versioned_docs/version-4.0.0/quickstart/php-postgressql-quickstart.md New quickstart guide for PHP + PostgreSQL example with complete setup, recording, and replay instructions
versioned_docs/version-4.0.0/quickstart/cpp-mongodb-quickstart.md Improved C++ + MongoDB quickstart with enhanced documentation structure and detailed workflows

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

- API Test generator
---

import Link from '@docusaurus/Link'
Copy link

Copilot AI Feb 1, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Link component is imported but never used in the document. Remove this unused import to keep the code clean.

Suggested change
import Link from '@docusaurus/Link'

Copilot uses AI. Check for mistakes.

import Link from '@docusaurus/Link'
import InstallReminder from '@site/src/components/InstallReminder';
import SectionDivider from '@site/src/components/SectionDivider';
Copy link

Copilot AI Feb 1, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The SectionDivider component is imported but never used in the document. Remove this unused import to keep the code clean.

Suggested change
import SectionDivider from '@site/src/components/SectionDivider';

Copilot uses AI. Check for mistakes.
Comment on lines +1 to +54
---
````markdown
---
id: samples-cpp-mongodb
title: Sample CRUD App (C++)
sidebar_label: C++ + MongoDB
description: A beginner-friendly quickstart showing how to use a C++ REST API with MongoDB and Keploy record & replay.
tags:
- cpp
- mongodb
- quickstart
- samples
- examples
- tutorial
- mongo-c-driver
keyword:
- C++
- MongoDB
- cpp-httplib
- Keploy
- API Test generator
---

import Link from '@docusaurus/Link'
import InstallReminder from '@site/src/components/InstallReminder';
import SectionDivider from '@site/src/components/SectionDivider';
import ProductTier from '@site/src/components/ProductTier';

<ProductTier tiers="Open Source, Enterprise" offerings="Self-Hosted, Dedicated" />

<InstallReminder />

## Overview

This quickstart shows how to run a small C++ REST API (built using `cpp-httplib`) backed by **MongoDB**, and how to use Keploy to record and replay API tests. The repo contains both Docker and non-Docker workflows so you can follow whichever matches your environment.

---

## Clone the example repository

```bash
git clone https://github.com/mishraa-G/keploy-cpp-mongodb-quickstart.git
cd keploy-cpp-mongodb-quickstart
```

## Prerequisites

- A C++17 compatible compiler (gcc/clang)
- CMake
- MongoDB C Driver (libmongoc / libbson)
- Docker & docker-compose (recommended for an isolated run)

Install helpers (examples):
````markdown
Copy link

Copilot AI Feb 1, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The frontmatter section has incorrect markdown fencing. Line 2 contains markdown which starts a code block, and line 54 contains markdown which appears to be attempting to close it. This causes the entire frontmatter and content between lines 1-53 to be duplicated starting at line 54. The file should start with just --- (line 1) and the frontmatter should end with --- (which should be at line 22), without any markdown code block fencing.

Copilot uses AI. Check for mistakes.

Happy testing! 🚀

```` No newline at end of file
Copy link

Copilot AI Feb 1, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The file ends with ```` which is incorrect. This appears to be an attempt to close a markdown code block that was incorrectly opened at line 2. Remove this line as it should not be present in a properly formatted markdown file.

Copilot uses AI. Check for mistakes.
Comment on lines +157 to +163

If you'd like, I can:

- Add this quick-starter to the top-level `docs/quickstart/` folder so it's available in the main docs site
- Add a short `devcontainer` snippet (Codespaces) that pre-installs the Keploy CLI and helper scripts (`scripts/record.sh`, `scripts/replay.sh`) as suggested in the upstream README

Which would you like next?
Copy link

Copilot AI Feb 1, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These lines appear to be conversational text directed at someone reviewing the document, rather than documentation content for end users. This content should be removed as it's not appropriate for a published quickstart guide. It seems like placeholder text that was not meant to be included in the final documentation.

Suggested change
If you'd like, I can:
- Add this quick-starter to the top-level `docs/quickstart/` folder so it's available in the main docs site
- Add a short `devcontainer` snippet (Codespaces) that pre-installs the Keploy CLI and helper scripts (`scripts/record.sh`, `scripts/replay.sh`) as suggested in the upstream README
Which would you like next?

Copilot uses AI. Check for mistakes.
# PHP + PostgreSQL — Quick Starter

import InstallReminder from '@site/src/components/InstallReminder';
import SectionDivider from '@site/src/components/SectionDivider';
Copy link

Copilot AI Feb 1, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The SectionDivider component is imported but never used in the document. Remove this unused import to keep the code clean.

Suggested change
import SectionDivider from '@site/src/components/SectionDivider';

Copilot uses AI. Check for mistakes.
Copy link
Member

@Achanandhi-M Achanandhi-M left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @mishraa-G , thanks a lot for adding the changes—really appreciate the effort. There are a few small things that still need to be added; you can use this guide as a reference: https://github.com/keploy/docs/blob/main/ADDING_A_QUICKSTART.md

Also, if possible, could you please include a short video showcasing your changes? That would be very helpful

@mishraa-G
Copy link
Author

Hey @mishraa-G , thanks a lot for adding the changes—really appreciate the effort. There are a few small things that still need to be added; you can use this guide as a reference: https://github.com/keploy/docs/blob/main/ADDING_A_QUICKSTART.md

Also, if possible, could you please include a short video showcasing your changes? That would be very helpful

Sure i'll work on it rightaway

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants