https://github.com/ruben-rdez/jsonplaceholder
A Spring Boot REST API that simulates the functionality of JSONPlaceholder service
https://github.com/ruben-rdez/jsonplaceholder
docker git github java json maven springboot
Last synced: 3 months ago
JSON representation
A Spring Boot REST API that simulates the functionality of JSONPlaceholder service
- Host: GitHub
- URL: https://github.com/ruben-rdez/jsonplaceholder
- Owner: ruben-rdez
- Created: 2025-06-27T17:09:46.000Z (12 months ago)
- Default Branch: main
- Last Pushed: 2025-06-27T19:06:53.000Z (12 months ago)
- Last Synced: 2025-06-27T20:21:17.198Z (12 months ago)
- Topics: docker, git, github, java, json, maven, springboot
- Language: Java
- Homepage:
- Size: 11.7 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# JSONPlaceholder REST API
This project is a Spring Boot REST API that simulates the functionality of the popular JSONPlaceholder service. It provides endpoints for managing posts, mimicking a simple blogging platform.
## Features
- CRUD operations for posts (Create, Read, Update, Delete)
- RESTful API design
- Swagger/OpenAPI documentation
- In-memory data storage
## Technologies Used
- Java
- Spring Boot
- Maven
- Swagger (OpenAPI)
## Getting Started
### Prerequisites
- Java 17 or higher
- Maven
### Running the Application
1. Clone the repository:
```sh
git clone
```
2. Navigate to the project directory:
```sh
cd jsonplaceholder
```
3. Build and run the application:
```sh
./mvnw spring-boot:run
```
Or on Windows:
```sh
mvnw.cmd spring-boot:run
```
The API will be available at `http://localhost:8080/posts`.
### API Documentation
Swagger UI is available at:
```
http://localhost:8080/swagger-ui/index.html
```
## Example Endpoints
- `GET /posts` - List all posts
- `GET /posts/{id}` - Get a post by ID
- `POST /posts` - Create a new post
- `PUT /posts/{id}` - Update a post
- `DELETE /posts/{id}` - Delete a post
## Project Structure
- `controller/` - REST controllers
- `service/` - Business logic
- `model/` - Data models
- `config/` - Configuration (e.g., Swagger)
## License
This project is for educational and demonstration purposes only.