Welcome to One Piece Spring! This is a project aimed at creating a web application for fans of the popular manga and anime series, One Piece.
- Clone the repository:
git clone https://github.com/marceljsh/onepiece-spring.git
- Enjoy!
Contributions are welcome! If you'd like to contribute to the project, please follow these steps:
- Fork the repository.
- Create a new branch:
git checkout -b feature/your-feature
- Make your changes and commit them:
git commit -m 'Add your changes'
- Push to the branch:
git push origin feature/your-feature
- Open a pull request.
GET
/
None
http code content-type response 200
application/json
{"message":"one piece api"}
curl -X POST -H "Content-Type: application/json" --data @post.json http://localhost:8080/
GET
/ping
None
http code content-type response 200
application/json
{"message":"host is reachable"}
curl -X POST -H "Content-Type: application/json" --data @post.json http://localhost:8080/ping
GET
/api/v1/affiliations/{id}
Gets a specific Affiliation by its ID
name type data type description id
required integer The specific affiliation numeric id
http code content-type response 200
text/plain;charset=UTF-8
JSON string 500
application/json
JSON string
curl -X GET -H "Content-Type: application/json" http://localhost:8080/api/v1/3
GET
/api/v1/affiliations?keyword={keyword}&page={page}&size={size}
Gets Affiliations where by default page is 1 and size is 10
None
name type data type description keyword
optional string search keyword page
optional integer page index size
optional string max number of items in a page
http code content-type response 200
text/plain;charset=UTF-8
JSON string 500
text/plain;charset=UTF-8
JSON string
curl -X GET -H "Content-Type: application/json" http://localhost:8080/api/v1/affiliations?keyword=pirates&page=2&size=5
POST
/api/v1/affiliations
Creates a new Affiliation
None
http code content-type response 200
text/plain;charset=UTF-8
JSON string 500
text/plain;charset=UTF-8
JSON string
curl -X POST -H "Content-Type: application/json" http://localhost:8080/api/v1/affiliations
PUT
/api/v1/affiliations/{id}
Updates an existing Affiliation
None
http code content-type response 200
text/plain;charset=UTF-8
JSON string 400
text/plain;charset=UTF-8
JSON string 500
text/plain;charset=UTF-8
JSON string
curl -X GET -H "Content-Type: application/json" http://localhost:8080/api/v1/affiliations/69
DELETE
/api/v1/affiliations/{id}
Deletes an existing Affiliation
None
http code content-type response 200
application/json
{"message", "affiliation deleted successfully"}
curl -X DELETE -H "Content-Type: application/json" http://localhost:8080/api/v1/affiliations/{id}
GET
/api/v1/df-types/{id}
Gets a specific Devil Fruit Type by its ID
name type data type description id
required integer The specific devil fruit type numeric id
http code content-type response 200
text/plain;charset=UTF-8
JSON string 500
application/json
JSON string
curl -X GET -H "Content-Type: application/json" http://localhost:8080/api/v1/df-types/2
GET
/api/v1/df-types?keyword={keyword}&page={page}&size={size}
Gets Devil Fruit Types where by default page is 1 and size is 10
None
name type data type description keyword
optional string search keyword page
optional integer page index size
optional string max number of items in a page
http code content-type response 200
text/plain;charset=UTF-8
JSON string 500
text/plain;charset=UTF-8
JSON string
curl -X GET -H "Content-Type: application/json" http://localhost:8080/api/v1/df-types?keyword=zoan&page=2&size=2
POST
/api/v1/df-types
Creates a new Devil Fruit Type
None
http code content-type response 200
text/plain;charset=UTF-8
JSON string 500
text/plain;charset=UTF-8
JSON string
curl -X POST -H "Content-Type: application/json" http://localhost:8080/api/v1/df-types
PUT
/api/v1/df-types/{id}
Updates an existing Devil Fruit Type
None
http code content-type response 200
text/plain;charset=UTF-8
JSON string 400
text/plain;charset=UTF-8
JSON string 500
text/plain;charset=UTF-8
JSON string
curl -X GET -H "Content-Type: application/json" http://localhost:8080/api/v1/df-types/69
DELETE
/api/v1/df-types/{id}
Deletes an existing Devil Fruit Type
None
http code content-type response 200
application/json
{"message", "devil fruit type deleted successfully"}
curl -X DELETE -H "Content-Type: application/json" http://localhost:8080/api/v1/df-types/{id}
GET
/api/v1/occupations/{id}
Gets a specific Occupation by its ID
name type data type description id
required integer The specific occupation numeric id
http code content-type response 200
text/plain;charset=UTF-8
JSON string 500
application/json
JSON string
curl -X GET -H "Content-Type: application/json" http://localhost:8080/api/v1/occupations/2
GET
/api/v1/occupations?keyword={keyword}&page={page}&size={size}
Gets Occupations where by default page is 1 and size is 10
None
name type data type description keyword
optional string search keyword page
optional integer page index size
optional string max number of items in a page
http code content-type response 200
text/plain;charset=UTF-8
JSON string 500
text/plain;charset=UTF-8
JSON string
curl -X GET -H "Content-Type: application/json" http://localhost:8080/api/v1/occupations?keyword=pirates&page=2&size=5
POST
/api/v1/occupations
Creates a new Occupation
None
http code content-type response 200
text/plain;charset=UTF-8
JSON string 500
text/plain;charset=UTF-8
JSON string
curl -X POST -H "Content-Type: application/json" http://localhost:8080/api/v1/occupations
PUT
/api/v1/occupations/{id}
Updates an existing Occupation
None
http code content-type response 200
text/plain;charset=UTF-8
JSON string 400
text/plain;charset=UTF-8
JSON string 500
text/plain;charset=UTF-8
JSON string
curl -X GET -H "Content-Type: application/json" http://localhost:8080/api/v1/occupations/69
DELETE
/api/v1/occupations/{id}
Deletes an existing Occupation
None
http code content-type response 200
application/json
{"message", ""occupation deleted successfully"}
curl -X DELETE -H "Content-Type: application/json" http://localhost:8080/api/v1/occupations/{id}
GET
/api/v1/regions/{id}
Gets a specific Region by its ID
name type data type description id
required integer The specific region numeric id
http code content-type response 200
text/plain;charset=UTF-8
JSON string 500
application/json
JSON string
curl -X GET -H "Content-Type: application/json" http://localhost:8080/api/v1/regions/2
GET
/api/v1/regions?keyword={keyword}&page={page}&size={size}
Gets Regions where by default page is 1 and size is 10
None
name type data type description keyword
optional string search keyword page
optional integer page index size
optional string max number of items in a page
http code content-type response 200
text/plain;charset=UTF-8
JSON string 500
text/plain;charset=UTF-8
JSON string
curl -X GET -H "Content-Type: application/json" http://localhost:8080/api/v1/regions?keyword=pirates&page=2&size=5
POST
/api/v1/regions
Creates a new Region
None
http code content-type response 200
text/plain;charset=UTF-8
JSON string 500
text/plain;charset=UTF-8
JSON string
curl -X POST -H "Content-Type: application/json" http://localhost:8080/api/v1/regions
PUT
/api/v1/regions/{id}
Updates an existing Region
None
http code content-type response 200
text/plain;charset=UTF-8
JSON string 400
text/plain;charset=UTF-8
JSON string 500
text/plain;charset=UTF-8
JSON string
curl -X GET -H "Content-Type: application/json" http://localhost:8080/api/v1/regions/69
DELETE
/api/v1/regions/{id}
Deletes an existing Region
None
http code content-type response 200
application/json
{"message", {"region deleted successfully"}
curl -X DELETE -H "Content-Type: application/json" http://localhost:8080/api/v1/regions/{id}
GET
/api/v1/devil-fruits/{id}
Gets a specific Devil Fruit by its ID
name type data type description id
required integer The specific devil fruit numeric id
http code content-type response 200
text/plain;charset=UTF-8
JSON string 500
application/json
JSON string
curl -X GET -H "Content-Type: application/json" http://localhost:8080/api/v1/devil-fruits/2
GET
/api/v1/devil-fruits?keyword={keyword}&page={page}&size={size}
Gets Devil Fruits where by default page is 1 and size is 10
None
name type data type description keyword
optional string search keyword page
optional integer page index size
optional string max number of items in a page
http code content-type response 200
text/plain;charset=UTF-8
JSON string 500
text/plain;charset=UTF-8
JSON string
curl -X GET -H "Content-Type: application/json" http://localhost:8080/api/v1/devil-fruits?keyword=pirates&page=2&size=5
POST
/api/v1/devil-fruits
Creates a new Devil Fruit
None
http code content-type response 200
text/plain;charset=UTF-8
JSON string 500
text/plain;charset=UTF-8
JSON string
curl -X POST -H "Content-Type: application/json" http://localhost:8080/api/v1/devil-fruits
PUT
/api/v1/devil-fruits/{id}
Updates an existing Devil Fruit
None
http code content-type response 200
text/plain;charset=UTF-8
JSON string 400
text/plain;charset=UTF-8
JSON string 500
text/plain;charset=UTF-8
JSON string
curl -X GET -H "Content-Type: application/json" http://localhost:8080/api/v1/devil-fruits/69
DELETE
/api/v1/devil-fruits/{id}
Deletes an existing Devil Fruit
None
http code content-type response 200
application/json
{"message", {"devil fruit deleted successfully"}
curl -X DELETE -H "Content-Type: application/json" http://localhost:8080/api/v1/devil-fruits/{id}
GET
/api/v1/figures/{id}
Gets a specific Figure by its ID
name type data type description id
required integer The specific figure numeric id
http code content-type response 200
text/plain;charset=UTF-8
JSON string 500
application/json
JSON string
curl -X GET -H "Content-Type: application/json" http://localhost:8080/api/v1/figures/2
GET
/api/v1/figures?keyword={keyword}&page={page}&size={size}
Gets Figures where by default page is 1 and size is 10
None
name type data type description keyword
optional string search keyword page
optional integer page index size
optional string max number of items in a page
http code content-type response 200
text/plain;charset=UTF-8
JSON string 500
text/plain;charset=UTF-8
JSON string
curl -X GET -H "Content-Type: application/json" http://localhost:8080/api/v1/figures?keyword=pirates&page=2&size=5
POST
/api/v1/figures
Creates a new Figure
None
http code content-type response 200
text/plain;charset=UTF-8
JSON string 500
text/plain;charset=UTF-8
JSON string
curl -X POST -H "Content-Type: application/json" http://localhost:8080/api/v1/figures
PUT
/api/v1/figures/{id}
Updates an existing Figure
None
http code content-type response 200
text/plain;charset=UTF-8
JSON string 400
text/plain;charset=UTF-8
JSON string 500
text/plain;charset=UTF-8
JSON string
curl -X GET -H "Content-Type: application/json" http://localhost:8080/api/v1/figures/69
DELETE
/api/v1/figures/{id}
Deletes an existing Figure
None
http code content-type response 200
application/json
{"message", {"figure deleted successfully"}
curl -X DELETE -H "Content-Type: application/json" http://localhost:8080/api/v1/figures/{id}