Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
268 changes: 268 additions & 0 deletions tools/tests/A-B-A.openapi3.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,268 @@
{
"openapi": "3.0.0",
"info": {
"title": "Service for namespace ABA",
"version": "",
"description": "This service is located at [https://localhost/service-root/](https://localhost/service-root/)\n\n## Entity Data Model\n![ER Diagram](https://yuml.me/diagram/class/[A{bg:orange}],[A]->[B{bg:orange}],[B{bg:orange}],[B]->[A{bg:orange}],[A{bg:dodgerblue}]++-*>[A])\n\n### Legend\n![Legend](https://yuml.me/diagram/plain;dir:TB;scale:60/class/[External.Type{bg:whitesmoke}],[ComplexType],[EntityType{bg:orange}],[EntitySet/Singleton/Operation{bg:dodgerblue}])"
},
"servers": [
{
"url": "https://localhost/service-root"
}
],
"tags": [
{
"name": "A"
}
],
"paths": {
"/A": {
"post": {
"summary": "Add new entity to A",
"tags": [
"A"
],
"requestBody": {
"required": true,
"description": "New entity",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ABA.A-create"
}
}
}
},
"responses": {
"201": {
"description": "Created entity",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ABA.A"
}
}
}
},
"4XX": {
"$ref": "#/components/responses/error"
}
}
}
},
"/$batch": {
"post": {
"summary": "Send a group of requests",
"description": "Group multiple requests into a single request payload, see [Batch Requests](http://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html#sec_BatchRequests).\n\n*Please note that \"Try it out\" is not supported for this request.*",
"tags": [
"Batch Requests"
],
"requestBody": {
"required": true,
"description": "Batch request",
"content": {
"multipart/mixed;boundary=request-separator": {
"schema": {
"type": "string"
},
"example": "--request-separator\nContent-Type: application/http\nContent-Transfer-Encoding: binary\n\nGET A HTTP/1.1\nAccept: application/json\n\n\n--request-separator--"
}
}
},
"responses": {
"200": {
"description": "Batch response",
"content": {
"multipart/mixed": {
"schema": {
"type": "string"
},
"example": "--response-separator\nContent-Type: application/http\n\nHTTP/1.1 200 OK\nContent-Type: application/json\n\n{...}\n--response-separator--"
}
}
},
"4XX": {
"$ref": "#/components/responses/error"
}
}
}
}
},
"components": {
"schemas": {
"ABA.A": {
"type": "object",
"properties": {
"ID": {
"type": "string"
},
"B": {
"$ref": "#/components/schemas/ABA.B"
}
},
"title": "A"
},
"ABA.A-create": {
"type": "object",
"properties": {
"ID": {
"type": "string"
},
"B": {
"$ref": "#/components/schemas/ABA.B-create"
}
},
"required": [
"ID"
],
"title": "A (for create)"
},
"ABA.A-update": {
"type": "object",
"title": "A (for update)"
},
"ABA.B": {
"type": "object",
"properties": {
"ID": {
"type": "string"
},
"A": {
"$ref": "#/components/schemas/ABA.A"
}
},
"title": "B"
},
"ABA.B-create": {
"type": "object",
"properties": {
"ID": {
"type": "string"
},
"A": {
"$ref": "#/components/schemas/ABA.A-create"
}
},
"required": [
"ID"
],
"title": "B (for create)"
},
"ABA.B-update": {
"type": "object",
"title": "B (for update)"
},
"count": {
"anyOf": [
{
"type": "number"
},
{
"type": "string"
}
],
"description": "The number of entities in the collection. Available when using the [$count](http://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html#sec_SystemQueryOptioncount) query option."
},
"error": {
"type": "object",
"required": [
"error"
],
"properties": {
"error": {
"type": "object",
"required": [
"code",
"message"
],
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"target": {
"type": "string"
},
"details": {
"type": "array",
"items": {
"type": "object",
"required": [
"code",
"message"
],
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"target": {
"type": "string"
}
}
}
},
"innererror": {
"type": "object",
"description": "The structure of this object is service-specific"
}
}
}
}
}
},
"parameters": {
"top": {
"name": "$top",
"in": "query",
"description": "Show only the first n items, see [Paging - Top](http://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html#sec_SystemQueryOptiontop)",
"schema": {
"type": "integer",
"minimum": 0
},
"example": 50
},
"skip": {
"name": "$skip",
"in": "query",
"description": "Skip the first n items, see [Paging - Skip](http://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html#sec_SystemQueryOptionskip)",
"schema": {
"type": "integer",
"minimum": 0
}
},
"count": {
"name": "$count",
"in": "query",
"description": "Include count of items, see [Count](http://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html#sec_SystemQueryOptioncount)",
"schema": {
"type": "boolean"
}
},
"search": {
"name": "$search",
"in": "query",
"description": "Search items by search phrases, see [Searching](http://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html#sec_SystemQueryOptionsearch)",
"schema": {
"type": "string"
}
}
},
"responses": {
"error": {
"description": "Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/error"
}
}
}
}
}
}
}
Loading