Skip to content

Commit

Permalink
Add more detail to OpenAPI specification
Browse files Browse the repository at this point in the history
  • Loading branch information
iainsproat committed Dec 31, 2024
1 parent 62abdcb commit 7691195
Show file tree
Hide file tree
Showing 2 changed files with 182 additions and 6 deletions.
3 changes: 2 additions & 1 deletion setup/fuzzer/settings.restler.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@
"per_resource_settings": {},
"max_combinations": 20,
"target_ip": "127.0.0.1",
"target_port": 3000
"target_port": 3000,
"ignore_decoding_failures": true
}
185 changes: 180 additions & 5 deletions setup/fuzzer/speckle-server.openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -116,9 +116,16 @@
}
},
"/api/stream/{streamId}/blobs": {
"parameters": [
{
"in": "path",
"name": "streamId",
"required": true,
"schema": { "type": "string" }
}
],
"get": {
"description": "Gets all the blobs of a project (stream)",
"parameters": [{ "in": "path", "name": "streamId", "required": true }],
"responses": {
"200": {
"description": "Successfully retrieved all the blobs from the project"
Expand All @@ -127,7 +134,6 @@
},
"delete": {
"description": "Deletes all the blobs from a project (stream)",
"parameters": [{ "in": "path", "name": "streamId", "required": true }],
"responses": { "501": { "description": "Not implemented." } }
}
},
Expand Down Expand Up @@ -160,6 +166,14 @@
}
},
"/objects/{streamId}": {
"parameters": [
{
"in": "path",
"name": "streamId",
"required": true,
"schema": { "type": "string" }
}
],
"options": {
"description": "The options for this endpoint",
"responses": { "200": { "description": "Options were retrieved." } }
Expand All @@ -172,6 +186,20 @@
}
},
"/objects/{streamId}/{objectId}": {
"parameters": [
{
"in": "path",
"name": "streamId",
"required": true,
"schema": { "type": "string" }
},
{
"in": "path",
"name": "objectId",
"required": true,
"schema": { "type": "string" }
}
],
"options": {
"description": "Options for downloading an object from a project (stream)",
"responses": { "200": { "description": "Options were retrieved." } }
Expand All @@ -182,6 +210,20 @@
}
},
"/objects/{streamId}/{objectId}/single": {
"parameters": [
{
"in": "path",
"name": "streamId",
"required": true,
"schema": { "type": "string" }
},
{
"in": "path",
"name": "objectId",
"required": true,
"schema": { "type": "string" }
}
],
"options": {
"description": "Options for downloading a single object from a project (stream)",
"responses": { "200": { "description": "Options were retrieved." } }
Expand All @@ -192,6 +234,14 @@
}
},
"/api/diff/{streamId}": {
"parameters": [
{
"in": "path",
"name": "streamId",
"required": true,
"schema": { "type": "string" }
}
],
"options": {
"description": "Options for the endpoint",
"responses": { "200": { "description": "Options were retrieved." } }
Expand All @@ -204,6 +254,14 @@
}
},
"/api/getobjects/{streamId}": {
"parameters": [
{
"in": "path",
"name": "streamId",
"required": true,
"schema": { "type": "string" }
}
],
"options": {
"description": "Options for the endpoint",
"responses": { "200": { "description": "Options were retrieved." } }
Expand All @@ -223,6 +281,26 @@
}
},
"/api/file/{fileType}/{streamId}/{branchName}": {
"parameters": [
{
"in": "path",
"name": "fileType",
"required": true,
"schema": { "type": "string" }
},
{
"in": "path",
"name": "streamId",
"required": true,
"schema": { "type": "string" }
},
{
"in": "path",
"name": "branchName",
"required": true,
"schema": { "type": "string" }
}
],
"post": {
"description": "Uploads a file to a project (stream)",
"responses": {
Expand All @@ -240,6 +318,25 @@
}
},
"/preview/{streamId}/{angle}": {
"parameters": [
{
"in": "path",
"name": "streamId",
"required": true,
"schema": { "type": "string" }
},
{
"in": "path",
"name": "angle",
"required": true,
"schema": {
"oneOf": [
{ "type": "integer", "minimum": 0 },
{ "type": "string", "enum": ["all"] }
]
}
}
],
"options": {
"description": "Options for the endpoint",
"responses": {
Expand All @@ -261,14 +358,37 @@
}
},
"/preview/{streamId}/branches/{branchName}/{angle}": {
"parameters": [
{
"in": "path",
"name": "streamId",
"required": true,
"schema": { "type": "string" }
},
{
"in": "path",
"name": "branchName",
"required": true,
"schema": { "type": "string" }
},
{
"in": "path",
"name": "angle",
"required": true,
"schema": {
"oneOf": [
{ "type": "integer", "minimum": 0 },
{ "type": "string", "enum": ["all"] }
]
}
}
],
"options": {
"description": "Options for the endpoint",
"responses": {
"200": { "description": "Options successfully retrieved." }
}
}
},
"/preview/{streamId}/branches/{branchname}/{angle}": {
},
"get": {
"description": "Retrieve a preview for the project (stream) and model (branch), at an optional angle",
"responses": {
Expand All @@ -284,6 +404,31 @@
}
},
"/preview/{streamId}/commits/{commitId}/{angle}": {
"parameters": [
{
"in": "path",
"name": "streamId",
"required": true,
"schema": { "type": "string" }
},
{
"in": "path",
"name": "commitId",
"required": true,
"schema": { "type": "string" }
},
{
"in": "path",
"name": "angle",
"required": true,
"schema": {
"oneOf": [
{ "type": "integer", "minimum": 0 },
{ "type": "string", "enum": ["all"] }
]
}
}
],
"options": {
"description": "Options for the endpoint",
"responses": {
Expand All @@ -305,6 +450,31 @@
}
},
"/preview/{streamId}/objects/{objectId}/{angle}": {
"parameters": [
{
"in": "path",
"name": "streamId",
"required": true,
"schema": { "type": "string" }
},
{
"in": "path",
"name": "objectId",
"required": true,
"schema": { "type": "string" }
},
{
"in": "path",
"name": "angle",
"required": true,
"schema": {
"oneOf": [
{ "type": "integer", "minimum": 0 },
{ "type": "string", "enum": ["all"] }
]
}
}
],
"options": {
"description": "Options for the endpoint",
"responses": {
Expand Down Expand Up @@ -345,6 +515,11 @@
},
"/graphql": {
"post": {
"requestBody": {
"content": {
"application/json": {}
}
},
"summary": "GraphQL",
"description": "GraphQL endpoint",
"responses": { "default": { "description": "GraphQL endpoint" } }
Expand Down

0 comments on commit 7691195

Please sign in to comment.