https://github.com/prabha1729/spring-boot-restful-api
This is a spring boot REST API that will enable a client to perform CRUD operations on the contact collection
https://github.com/prabha1729/spring-boot-restful-api
contacts-app spring-boot spring-data-jpa springframework
Last synced: 3 months ago
JSON representation
This is a spring boot REST API that will enable a client to perform CRUD operations on the contact collection
- Host: GitHub
- URL: https://github.com/prabha1729/spring-boot-restful-api
- Owner: prabha1729
- Created: 2020-08-04T17:26:07.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2020-08-05T02:22:15.000Z (almost 5 years ago)
- Last Synced: 2025-01-20T06:37:07.771Z (5 months ago)
- Topics: contacts-app, spring-boot, spring-data-jpa, springframework
- Language: Java
- Homepage:
- Size: 59.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Spring-Boot-RESTful-Api for Contact System
This is a spring boot REST API that will enable a client to perform CRUD operations on the contact collection.
# Reach out to me
[](https://www.linkedin.com/in/prabhakargaddam/)
[]()
# Execution
```
# To build the project standard maven build is sufficient
mvn clean install# To start/run the project spring boot maven plugin is included just run
mvn spring-boot:run# The integration test may be executed using
mvn test
```
# Usage
Once the application is started,## To get all the contacts
- Goto http://localhost:8080/contacts/ which return all contacts available.## To get specific contact
- Goto http://localhost:8080/contacts/{id} which return all the information about the contact.## To add or update a new contact
- Execute the following in [cURL](https://en.wikipedia.org/wiki/CURL)
```
##For update replace POST to PUT
$ curl -i -X POST -H "Content-Type:application/json" -d "{
"address": {
"street": "Barton Creek Drive",
"city": "Charlotte",
"state": "North Carolina",
"zip": "28262"
},
"name": {
"first": "Akhilshetty",
"middle": "",
"last": "Madhamshetty"
},
"phones": [
{
"number": "1234567890",
"type": "work"
},
{
"number": "9876543210",
"type": "mobile"
}
],
"email": "[email protected]"
}" http://localhost:8080/contacts/```
## You may also like...
- [Stock Trade ](https://github.com/prabha1729/Hacker-Rank-Stock-Trade-Api) - A RESTful service to manage trades using Spring Boot framework
- [Airport Info](https://github.com/prabha1729/Airport-Info) - A Spring Boot Service for airport information.