Skip to content

Commit

Permalink
updated swagger and removed routes from README
Browse files Browse the repository at this point in the history
  • Loading branch information
MineFact committed Sep 18, 2023
1 parent 27eb065 commit 1e09c8c
Show file tree
Hide file tree
Showing 2 changed files with 57 additions and 96 deletions.
47 changes: 1 addition & 46 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,54 +17,9 @@ _A REST-API to interface with data from the BuildTheEarth.net Minecraft Network.
## Routes

These are the routes for the Network API.

Plot System API Docs:
Plot System API Documentation:
https://buildtheearth.github.io/network-api/

### Global Plot System

- **Get Builder Count:** <br>
Returns the number of builders of the global plot system.<br>
[GET] https://psapi.buildtheearth.net/api/plotsystem/builders<br><br>

- **Get Difficulties:** <br>
Returns the available difficulties of the global plot system.<br>
[GET] https://psapi.buildtheearth.net/api/plotsystem/difficulties<br><br>

- **Get All Plot System Countries of a Team:** <br>
Returns the countries of a build team that are available in the global plot system.<br>
[GET] https://psapi.buildtheearth.net/api/plotsystem/teams/%API_KEY%/countries<br><br>

- **Get All Plot System Cities of a Team:** <br>
Returns the cities of a build team that are available in the global plot system.<br>
[GET] https://psapi.buildtheearth.net/api/plotsystem/teams/%API_KEY%/cities<br><br>

- **Get All Plots of a Team:** <br>
Returns the plots of a build team that are available in the global plot system.<br>
[GET] https://psapi.buildtheearth.net/api/plotsystem/teams/%API_KEY%/plots<br><br>

- **Get all reviews of a Team:** <br>
Returns all reviews of a build team that are available in the global plot system.<br>
[GET] https://psapi.buildtheearth.net/api/plotsystem/teams/%API_KEY%/reviews<br><br>

- **Get all servers of a Team:** <br>
Returns all servers of a build team that are available in the global plot system.<br>
[GET] https://psapi.buildtheearth.net/api/plotsystem/teams/%API_KEY%/servers<br><br>

- **Create a Plot for a Team:** <br>
Saved the plot details for a new plot of a build team in the global plot system.<br>
[POST] https://psapi.buildtheearth.net/api/plotsystem/teams/%API_KEY%/plots<br><br>

- **Change a Plot of a Team:** <br>
Changes the plot details of a plot of a build team in the global plot system.<br>
[PUT] https://psapi.buildtheearth.net/api/plotsystem/teams/%API_KEY%/plots<br><br>

### Build Teams

- **Get Information about a Build Team:** <br>
Returns some information about a build team of BuildTheEarth.<br>
[GET] https://psapi.buildtheearth.net/api/teams/%API_KEY%<br><br>

## Installation

Expand Down
106 changes: 56 additions & 50 deletions swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,20 +17,17 @@
],
"tags": [
{
"name": "Builders"
"name": "Global Plot System"
},
{
"name": "Difficulties"
},
{
"name": "Teams"
"name": "Build Teams"
}
],
"paths": {
"/api/plotsystem/builders": {
"get": {
"tags": [
"Builders"
"Global Plot System"
],
"summary": "Get Builder Count",
"description": "Returns the number of builders of the global plot system.",
Expand All @@ -41,48 +38,27 @@
}
}
},
"/api/difficulties": {
"/api/plotsystem/difficulties": {
"get": {
"tags": [
"Difficulties"
"Global Plot System"
],
"summary": "Get Difficulties",
"description": "Returns the available difficulties of the global plot system.",
"responses": {
"200": {
"description": "Success"
}
}
}
},
"/api/teams/{api_key}/cities": {
"get": {
"tags": [
"Teams"
],
"summary": "Get Cities of Build Team",
"parameters": [
{
"name": "api_key",
"in": "path",
"schema": {
"type": "string"
},
"required": true
}
],
"responses": {
"200": {
"description": "Success"
}
}
}
},
"/api/teams/{api_key}/countries": {
"/api/plotsystem/teams/%API_KEY%/cities": {
"get": {
"tags": [
"Teams"
"Global Plot System"
],
"summary": "Get Countries of Build Team",
"summary": "Get All Plot System Cities of a Team",
"description": "Returns the cities of a build team that are available in the global plot system.",
"parameters": [
{
"name": "api_key",
Expand All @@ -100,12 +76,13 @@
}
}
},
"/api/teams/{api_key}/ftp_configuration": {
"/api/plotsystem/teams/%API_KEY%/countries": {
"get": {
"tags": [
"Teams"
"Global Plot System"
],
"summary": "Get the FTP Cofiguration of the Build Team",
"summary": "Get All Plot System Countries of a Team",
"description": "Returns the countries of a build team that are available in the global plot system.",
"parameters": [
{
"name": "api_key",
Expand All @@ -123,12 +100,13 @@
}
}
},
"/api/teams/{api_key}/plots": {
"/api/plotsystem/teams/%API_KEY%/plots": {
"get": {
"tags": [
"Teams"
"Global Plot System"
],
"summary": "Get The Plots of a Build Team",
"summary": "Get All Plots of a Team",
"description": "Returns the plots of a build team that are available in the global plot system.",
"parameters": [
{
"name": "api_key",
Expand All @@ -147,9 +125,10 @@
},
"post": {
"tags": [
"Teams"
"Global Plot System"
],
"summary": "Add a Plot to a Build Team",
"summary": "Create a Plot for a Build Team",
"description": "Saved the plot details for a new plot of a build team in the global plot system.",
"requestBody": {
"content": {
"application/json": {
Expand Down Expand Up @@ -186,9 +165,10 @@
},
"put": {
"tags": [
"Teams"
"Global Plot System"
],
"summary": "Update a Plot of a Build Team",
"summary": "Update a Plot of a Build Team",
"description": "Changes the plot details of a plot of a build team in the global plot system.",
"requestBody": {
"content": {
"application/json": {
Expand Down Expand Up @@ -221,12 +201,37 @@
}
}
},
"/api/teams/{api_key}/reviews": {
"/api/plotsystem/teams/%API_KEY%/reviews": {
"get": {
"tags": [
"Global Plot System"
],
"summary": "Get all reviews of a Build Team",
"description": "Returns all reviews of a build team that are available in the global plot system.",
"parameters": [
{
"name": "api_key",
"in": "path",
"schema": {
"type": "string"
},
"required": true
}
],
"responses": {
"200": {
"description": "Success"
}
}
}
},
"/api/plotsystem/teams/%API_KEY%/servers": {
"get": {
"tags": [
"Teams"
"Global Plot System"
],
"summary": "Get Reviews of a Build Team",
"summary": "Get all servers of a Build Team",
"description": "Returns all servers of a build team that are available in the global plot system.",
"parameters": [
{
"name": "api_key",
Expand All @@ -244,12 +249,13 @@
}
}
},
"/api/teams/{api_key}/servers": {
"/api/teams/%API_KEY%": {
"get": {
"tags": [
"Teams"
"Build Teams"
],
"summary": "Get Servers of a Build Team",
"summary": "Get Information about a Build Team",
"description": "Returns some information about a build team of BuildTheEarth.",
"parameters": [
{
"name": "api_key",
Expand Down

0 comments on commit 1e09c8c

Please sign in to comment.