OpenAPI.NET.OData/test/Microsoft.OpenAPI.OData.Reader.Tests/Resources/TripService.OpenApi.yaml

1558 lines
44 KiB
YAML

openapi: 3.0.0
info:
title: OData Service for namespace Microsoft.OData.Service.Sample.TrippinInMemory.Models
version: 1.0.1
servers:
- url: http://services.odata.org/TrippinRESTierService/
paths:
/People:
get:
tags:
- name: People
summary: Get entities from People
parameters:
- $ref: '#/components/parameters/top'
- $ref: '#/components/parameters/skip'
- $ref: '#/components/parameters/search'
- $ref: '#/components/parameters/filter'
- $ref: '#/components/parameters/count'
- name: $orderby
in: query
description: Order items by property values
schema:
uniqueItems: true
type: array
items:
enum:
- UserName
- UserName desc
- FirstName
- FirstName desc
- LastName
- LastName desc
- MiddleName
- MiddleName desc
- Gender
- Gender desc
- Age
- Age desc
- Emails
- Emails desc
- AddressInfo
- AddressInfo desc
- HomeAddress
- HomeAddress desc
- FavoriteFeature
- FavoriteFeature desc
- Features
- Features desc
type: string
- name: $select
in: query
description: Select properties to be returned
schema:
uniqueItems: true
type: array
items:
enum:
- UserName
- FirstName
- LastName
- MiddleName
- Gender
- Age
- Emails
- AddressInfo
- HomeAddress
- FavoriteFeature
- Features
type: string
- name: $expand
in: query
description: Expand related entities
schema:
uniqueItems: true
type: array
items:
enum:
- *
- Friends
- BestFriend
- Trips
type: string
responses:
200:
description: Retrieved entities
content:
application/json:
schema:
title: Collection of People
type: object
properties:
value:
type: array
items:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
default:
$ref: '#/components/responses/error'
callbacks: { }
post:
tags:
- name: People
summary: Add new entity to People
requestBody:
description: New entity
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
required: true
responses:
201:
description: Created entity
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
default:
$ref: '#/components/responses/error'
callbacks: { }
/People('{UserName}'):
get:
tags:
- name: People
summary: Get entity from People by key
parameters:
- name: UserName
in: path
description: key: UserName
required: true
schema:
type: string
- name: $select
in: query
description: Select properties to be returned
schema:
uniqueItems: true
type: array
items:
enum:
- UserName
- FirstName
- LastName
- MiddleName
- Gender
- Age
- Emails
- AddressInfo
- HomeAddress
- FavoriteFeature
- Features
type: string
- name: $expand
in: query
description: Expand related entities
schema:
uniqueItems: true
type: array
items:
enum:
- *
- Friends
- BestFriend
- Trips
type: string
responses:
200:
description: Retrieved entity
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
default:
$ref: '#/components/responses/error'
callbacks: { }
patch:
tags:
- name: People
summary: Update entity in People
parameters:
- name: UserName
in: path
description: key: UserName
required: true
schema:
type: string
requestBody:
description: New property values
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
required: true
responses:
204:
description: Success
default:
$ref: '#/components/responses/error'
callbacks: { }
delete:
tags:
- name: People
summary: Delete entity from People
parameters:
- name: UserName
in: path
description: key: UserName
required: true
schema:
type: string
- name: If-Match
in: header
description: ETag
schema:
type: string
responses:
204:
description: Success
default:
$ref: '#/components/responses/error'
callbacks: { }
/People('{UserName}')/GetFavoriteAirline(person={person}):
get:
tags:
- name: person
summary: Invoke function GetFavoriteAirline
parameters:
- name: person
in: path
required: true
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
responses:
200:
description: Success
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airline'
default:
$ref: '#/components/responses/error'
callbacks: { }
/People('{UserName}')/GetFriendsTrips(person={person},userName={userName}):
get:
summary: Invoke function GetFriendsTrips
parameters:
- name: person
in: path
required: true
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
- name: userName
in: path
required: true
schema:
type: string
responses:
200:
description: Success
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Trip'
default:
$ref: '#/components/responses/error'
callbacks: { }
/People('{UserName}')/UpdatePersonLastName(person={person},lastName={lastName}):
get:
summary: Invoke function UpdatePersonLastName
parameters:
- name: person
in: path
required: true
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
- name: lastName
in: path
required: true
schema:
type: string
responses:
200:
description: Success
content:
application/json:
schema:
type: boolean
default: false
default:
$ref: '#/components/responses/error'
callbacks: { }
/People('{UserName}')/ShareTrip:
post:
summary: Invoke action ShareTrip
parameters:
- name: personInstance
in: path
required: true
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
- name: userName
in: path
required: true
schema:
type: string
- name: tripId
in: path
required: true
schema:
maximum: 2147483647
minimum: -2147483648
type: integer
format: int32
responses:
204:
description: Success
default:
$ref: '#/components/responses/error'
callbacks: { }
/Airlines:
get:
tags:
- name: Airlines
summary: Get entities from Airlines
parameters:
- $ref: '#/components/parameters/top'
- $ref: '#/components/parameters/skip'
- $ref: '#/components/parameters/search'
- $ref: '#/components/parameters/filter'
- $ref: '#/components/parameters/count'
- name: $orderby
in: query
description: Order items by property values
schema:
uniqueItems: true
type: array
items:
enum:
- AirlineCode
- AirlineCode desc
- Name
- Name desc
type: string
- name: $select
in: query
description: Select properties to be returned
schema:
uniqueItems: true
type: array
items:
enum:
- AirlineCode
- Name
type: string
- name: $expand
in: query
description: Expand related entities
schema:
uniqueItems: true
type: array
items:
enum:
- *
type: string
responses:
200:
description: Retrieved entities
content:
application/json:
schema:
title: Collection of Airlines
type: object
properties:
value:
type: array
items:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airline'
default:
$ref: '#/components/responses/error'
callbacks: { }
post:
tags:
- name: Airlines
summary: Add new entity to Airlines
requestBody:
description: New entity
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airline'
required: true
responses:
201:
description: Created entity
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airline'
default:
$ref: '#/components/responses/error'
callbacks: { }
/Airlines('{AirlineCode}'):
get:
tags:
- name: Airlines
summary: Get entity from Airlines by key
parameters:
- name: AirlineCode
in: path
description: key: AirlineCode
required: true
schema:
type: string
- name: $select
in: query
description: Select properties to be returned
schema:
uniqueItems: true
type: array
items:
enum:
- AirlineCode
- Name
type: string
- name: $expand
in: query
description: Expand related entities
schema:
uniqueItems: true
type: array
items:
enum:
- *
type: string
responses:
200:
description: Retrieved entity
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airline'
default:
$ref: '#/components/responses/error'
callbacks: { }
patch:
tags:
- name: Airlines
summary: Update entity in Airlines
parameters:
- name: AirlineCode
in: path
description: key: AirlineCode
required: true
schema:
type: string
requestBody:
description: New property values
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airline'
required: true
responses:
204:
description: Success
default:
$ref: '#/components/responses/error'
callbacks: { }
delete:
tags:
- name: Airlines
summary: Delete entity from Airlines
parameters:
- name: AirlineCode
in: path
description: key: AirlineCode
required: true
schema:
type: string
- name: If-Match
in: header
description: ETag
schema:
type: string
responses:
204:
description: Success
default:
$ref: '#/components/responses/error'
callbacks: { }
/Airports:
get:
tags:
- name: Airports
summary: Get entities from Airports
parameters:
- $ref: '#/components/parameters/top'
- $ref: '#/components/parameters/skip'
- $ref: '#/components/parameters/search'
- $ref: '#/components/parameters/filter'
- $ref: '#/components/parameters/count'
- name: $orderby
in: query
description: Order items by property values
schema:
uniqueItems: true
type: array
items:
enum:
- Name
- Name desc
- IcaoCode
- IcaoCode desc
- IataCode
- IataCode desc
- Location
- Location desc
type: string
- name: $select
in: query
description: Select properties to be returned
schema:
uniqueItems: true
type: array
items:
enum:
- Name
- IcaoCode
- IataCode
- Location
type: string
- name: $expand
in: query
description: Expand related entities
schema:
uniqueItems: true
type: array
items:
enum:
- *
type: string
responses:
200:
description: Retrieved entities
content:
application/json:
schema:
title: Collection of Airports
type: object
properties:
value:
type: array
items:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airport'
default:
$ref: '#/components/responses/error'
callbacks: { }
post:
tags:
- name: Airports
summary: Add new entity to Airports
requestBody:
description: New entity
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airport'
required: true
responses:
201:
description: Created entity
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airport'
default:
$ref: '#/components/responses/error'
callbacks: { }
/Airports('{IcaoCode}'):
get:
tags:
- name: Airports
summary: Get entity from Airports by key
parameters:
- name: IcaoCode
in: path
description: key: IcaoCode
required: true
schema:
type: string
- name: $select
in: query
description: Select properties to be returned
schema:
uniqueItems: true
type: array
items:
enum:
- Name
- IcaoCode
- IataCode
- Location
type: string
- name: $expand
in: query
description: Expand related entities
schema:
uniqueItems: true
type: array
items:
enum:
- *
type: string
responses:
200:
description: Retrieved entity
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airport'
default:
$ref: '#/components/responses/error'
callbacks: { }
patch:
tags:
- name: Airports
summary: Update entity in Airports
parameters:
- name: IcaoCode
in: path
description: key: IcaoCode
required: true
schema:
type: string
requestBody:
description: New property values
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airport'
required: true
responses:
204:
description: Success
default:
$ref: '#/components/responses/error'
callbacks: { }
delete:
tags:
- name: Airports
summary: Delete entity from Airports
parameters:
- name: IcaoCode
in: path
description: key: IcaoCode
required: true
schema:
type: string
- name: If-Match
in: header
description: ETag
schema:
type: string
responses:
204:
description: Success
default:
$ref: '#/components/responses/error'
callbacks: { }
/NewComePeople:
get:
tags:
- name: NewComePeople
summary: Get entities from NewComePeople
parameters:
- $ref: '#/components/parameters/top'
- $ref: '#/components/parameters/skip'
- $ref: '#/components/parameters/search'
- $ref: '#/components/parameters/filter'
- $ref: '#/components/parameters/count'
- name: $orderby
in: query
description: Order items by property values
schema:
uniqueItems: true
type: array
items:
enum:
- UserName
- UserName desc
- FirstName
- FirstName desc
- LastName
- LastName desc
- MiddleName
- MiddleName desc
- Gender
- Gender desc
- Age
- Age desc
- Emails
- Emails desc
- AddressInfo
- AddressInfo desc
- HomeAddress
- HomeAddress desc
- FavoriteFeature
- FavoriteFeature desc
- Features
- Features desc
type: string
- name: $select
in: query
description: Select properties to be returned
schema:
uniqueItems: true
type: array
items:
enum:
- UserName
- FirstName
- LastName
- MiddleName
- Gender
- Age
- Emails
- AddressInfo
- HomeAddress
- FavoriteFeature
- Features
type: string
- name: $expand
in: query
description: Expand related entities
schema:
uniqueItems: true
type: array
items:
enum:
- *
- Friends
- BestFriend
- Trips
type: string
responses:
200:
description: Retrieved entities
content:
application/json:
schema:
title: Collection of NewComePeople
type: object
properties:
value:
type: array
items:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
default:
$ref: '#/components/responses/error'
callbacks: { }
post:
tags:
- name: NewComePeople
summary: Add new entity to NewComePeople
requestBody:
description: New entity
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
required: true
responses:
201:
description: Created entity
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
default:
$ref: '#/components/responses/error'
callbacks: { }
/NewComePeople('{UserName}'):
get:
tags:
- name: NewComePeople
summary: Get entity from NewComePeople by key
parameters:
- name: UserName
in: path
description: key: UserName
required: true
schema:
type: string
- name: $select
in: query
description: Select properties to be returned
schema:
uniqueItems: true
type: array
items:
enum:
- UserName
- FirstName
- LastName
- MiddleName
- Gender
- Age
- Emails
- AddressInfo
- HomeAddress
- FavoriteFeature
- Features
type: string
- name: $expand
in: query
description: Expand related entities
schema:
uniqueItems: true
type: array
items:
enum:
- *
- Friends
- BestFriend
- Trips
type: string
responses:
200:
description: Retrieved entity
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
default:
$ref: '#/components/responses/error'
callbacks: { }
patch:
tags:
- name: NewComePeople
summary: Update entity in NewComePeople
parameters:
- name: UserName
in: path
description: key: UserName
required: true
schema:
type: string
requestBody:
description: New property values
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
required: true
responses:
204:
description: Success
default:
$ref: '#/components/responses/error'
callbacks: { }
delete:
tags:
- name: NewComePeople
summary: Delete entity from NewComePeople
parameters:
- name: UserName
in: path
description: key: UserName
required: true
schema:
type: string
- name: If-Match
in: header
description: ETag
schema:
type: string
responses:
204:
description: Success
default:
$ref: '#/components/responses/error'
callbacks: { }
/NewComePeople('{UserName}')/GetFavoriteAirline(person={person}):
get:
tags:
- name: person
summary: Invoke function GetFavoriteAirline
parameters:
- name: person
in: path
required: true
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
responses:
200:
description: Success
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airline'
default:
$ref: '#/components/responses/error'
callbacks: { }
/NewComePeople('{UserName}')/GetFriendsTrips(person={person},userName={userName}):
get:
summary: Invoke function GetFriendsTrips
parameters:
- name: person
in: path
required: true
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
- name: userName
in: path
required: true
schema:
type: string
responses:
200:
description: Success
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Trip'
default:
$ref: '#/components/responses/error'
callbacks: { }
/NewComePeople('{UserName}')/UpdatePersonLastName(person={person},lastName={lastName}):
get:
summary: Invoke function UpdatePersonLastName
parameters:
- name: person
in: path
required: true
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
- name: lastName
in: path
required: true
schema:
type: string
responses:
200:
description: Success
content:
application/json:
schema:
type: boolean
default: false
default:
$ref: '#/components/responses/error'
callbacks: { }
/NewComePeople('{UserName}')/ShareTrip:
post:
summary: Invoke action ShareTrip
parameters:
- name: personInstance
in: path
required: true
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
- name: userName
in: path
required: true
schema:
type: string
- name: tripId
in: path
required: true
schema:
maximum: 2147483647
minimum: -2147483648
type: integer
format: int32
responses:
204:
description: Success
default:
$ref: '#/components/responses/error'
callbacks: { }
/Me:
get:
tags:
- name: Me
summary: Get Me
parameters:
- name: $select
in: query
description: Select properties to be returned
schema:
uniqueItems: true
type: array
items:
enum:
- UserName
- FirstName
- LastName
- MiddleName
- Gender
- Age
- Emails
- AddressInfo
- HomeAddress
- FavoriteFeature
- Features
type: string
- name: $expand
in: query
description: Expand related entities
schema:
uniqueItems: true
type: array
items:
enum:
- *
- Friends
- BestFriend
- Trips
type: string
responses:
200:
description: Retrieved entity
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
default:
$ref: '#/components/responses/error'
callbacks: { }
patch:
tags:
- name: Me
summary: Update Me
requestBody:
description: New property values
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
required: true
responses:
204:
description: Success
default:
$ref: '#/components/responses/error'
callbacks: { }
/Me/GetFavoriteAirline(person={person}):
get:
tags:
- name: person
summary: Invoke function GetFavoriteAirline
parameters:
- name: person
in: path
required: true
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
responses:
200:
description: Success
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airline'
default:
$ref: '#/components/responses/error'
callbacks: { }
/Me/GetFriendsTrips(person={person},userName={userName}):
get:
summary: Invoke function GetFriendsTrips
parameters:
- name: person
in: path
required: true
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
- name: userName
in: path
required: true
schema:
type: string
responses:
200:
description: Success
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Trip'
default:
$ref: '#/components/responses/error'
callbacks: { }
/Me/UpdatePersonLastName(person={person},lastName={lastName}):
get:
summary: Invoke function UpdatePersonLastName
parameters:
- name: person
in: path
required: true
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
- name: lastName
in: path
required: true
schema:
type: string
responses:
200:
description: Success
content:
application/json:
schema:
type: boolean
default: false
default:
$ref: '#/components/responses/error'
callbacks: { }
/Me/ShareTrip:
post:
summary: Invoke action ShareTrip
parameters:
- name: personInstance
in: path
required: true
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
- name: userName
in: path
required: true
schema:
type: string
- name: tripId
in: path
required: true
schema:
maximum: 2147483647
minimum: -2147483648
type: integer
format: int32
responses:
204:
description: Success
default:
$ref: '#/components/responses/error'
callbacks: { }
/GetPersonWithMostFriends():
get:
summary: Invoke function GetPersonWithMostFriends
responses:
200:
description: Success
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
default:
$ref: '#/components/responses/error'
callbacks: { }
/GetNearestAirport(lat={lat},lon={lon}):
get:
summary: Invoke function GetNearestAirport
parameters:
- name: lat
in: path
required: true
schema:
oneOf:
- type: number
- type: string
- enum:
- -INF
- INF
- NaN
format: double
- name: lon
in: path
required: true
schema:
oneOf:
- type: number
- type: string
- enum:
- -INF
- INF
- NaN
format: double
responses:
200:
description: Success
content:
application/json:
schema:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airport'
default:
$ref: '#/components/responses/error'
callbacks: { }
/ResetDataSource:
post:
summary: Invoke action ResetDataSource
responses:
204:
description: Success
default:
$ref: '#/components/responses/error'
callbacks: { }
components:
schemas:
Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person:
title: Person
type: object
properties:
UserName:
type: string
FirstName:
type: string
LastName:
type: string
nullable: true
MiddleName:
type: string
nullable: true
Gender:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.PersonGender'
Age:
oneOf:
- type: integer
- type: string
format: int64
nullable: true
Emails:
type: array
items:
type: string
nullable: true
AddressInfo:
type: array
items:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Location'
HomeAddress:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Location'
FavoriteFeature:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Feature'
Features:
type: array
items:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Feature'
Friends:
type: array
items:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
BestFriend:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
Trips:
type: array
items:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Trip'
Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airline:
title: Airline
type: object
properties:
AirlineCode:
type: string
Name:
type: string
nullable: true
Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airport:
title: Airport
type: object
properties:
Name:
type: string
nullable: true
IcaoCode:
type: string
IataCode:
type: string
nullable: true
Location:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.AirportLocation'
Microsoft.OData.Service.Sample.TrippinInMemory.Models.Location:
title: Location
type: object
properties:
Address:
type: string
nullable: true
City:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.City'
Microsoft.OData.Service.Sample.TrippinInMemory.Models.City:
title: City
type: object
properties:
Name:
type: string
nullable: true
CountryRegion:
type: string
nullable: true
Region:
type: string
nullable: true
Microsoft.OData.Service.Sample.TrippinInMemory.Models.AirportLocation:
allOf:
- $ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Location'
- title: AirportLocation
type: object
properties:
Loc:
$ref: https://raw.githubusercontent.com/oasis-tcs/odata-openapi/master/examples/odata-definitions.json#/definitions/Edm.GeographyPoint
Microsoft.OData.Service.Sample.TrippinInMemory.Models.EventLocation:
allOf:
- $ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Location'
- title: EventLocation
type: object
properties:
BuildingInfo:
type: string
nullable: true
Microsoft.OData.Service.Sample.TrippinInMemory.Models.Trip:
title: Trip
type: object
properties:
TripId:
maximum: 2147483647
minimum: -2147483648
type: integer
format: int32
ShareId:
pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$
type: string
format: uuid
Name:
type: string
nullable: true
Budget:
oneOf:
- type: number
- type: string
- enum:
- -INF
- INF
- NaN
format: float
Description:
type: string
nullable: true
Tags:
type: array
items:
type: string
nullable: true
StartsAt:
pattern: ^[0-9]{4,}-(0[1-9]|1[012])-(0[1-9]|[12][0-9]|3[01])T([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]([.][0-9]{1,12})?(Z|[+-][0-9][0-9]:[0-9][0-9])$
type: string
format: date-time
EndsAt:
pattern: ^[0-9]{4,}-(0[1-9]|1[012])-(0[1-9]|[12][0-9]|3[01])T([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]([.][0-9]{1,12})?(Z|[+-][0-9][0-9]:[0-9][0-9])$
type: string
format: date-time
PlanItems:
type: array
items:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.PlanItem'
Microsoft.OData.Service.Sample.TrippinInMemory.Models.PlanItem:
title: PlanItem
type: object
properties:
PlanItemId:
maximum: 2147483647
minimum: -2147483648
type: integer
format: int32
ConfirmationCode:
type: string
nullable: true
StartsAt:
pattern: ^[0-9]{4,}-(0[1-9]|1[012])-(0[1-9]|[12][0-9]|3[01])T([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]([.][0-9]{1,12})?(Z|[+-][0-9][0-9]:[0-9][0-9])$
type: string
format: date-time
EndsAt:
pattern: ^[0-9]{4,}-(0[1-9]|1[012])-(0[1-9]|[12][0-9]|3[01])T([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]([.][0-9]{1,12})?(Z|[+-][0-9][0-9]:[0-9][0-9])$
type: string
format: date-time
Duration:
pattern: ^-?P([0-9]+D)?(T([0-9]+H)?([0-9]+M)?([0-9]+([.][0-9]+)?S)?)?$
type: string
format: duration
Microsoft.OData.Service.Sample.TrippinInMemory.Models.Event:
allOf:
- $ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.PlanItem'
- title: Event
type: object
properties:
OccursAt:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.EventLocation'
Description:
type: string
nullable: true
Microsoft.OData.Service.Sample.TrippinInMemory.Models.PublicTransportation:
allOf:
- $ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.PlanItem'
- title: PublicTransportation
type: object
properties:
SeatNumber:
type: string
nullable: true
Microsoft.OData.Service.Sample.TrippinInMemory.Models.Flight:
allOf:
- $ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.PublicTransportation'
- title: Flight
type: object
properties:
FlightNumber:
type: string
nullable: true
Airline:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airline'
From:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airport'
To:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Airport'
Microsoft.OData.Service.Sample.TrippinInMemory.Models.Employee:
allOf:
- $ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
- title: Employee
type: object
properties:
Cost:
oneOf:
- type: integer
- type: string
format: int64
Peers:
type: array
items:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
Microsoft.OData.Service.Sample.TrippinInMemory.Models.Manager:
allOf:
- $ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
- title: Manager
type: object
properties:
Budget:
oneOf:
- type: integer
- type: string
format: int64
BossOffice:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Location'
DirectReports:
type: array
items:
$ref: '#/components/schemas/Microsoft.OData.Service.Sample.TrippinInMemory.Models.Person'
Microsoft.OData.Service.Sample.TrippinInMemory.Models.PersonGender:
title: PersonGender
enum:
- Male
- Female
- Unknow
type: string
Microsoft.OData.Service.Sample.TrippinInMemory.Models.Feature:
title: Feature
enum:
- Feature1
- Feature2
- Feature3
- Feature4
type: string
odata.error:
required:
- error
type: object
properties:
error:
$ref: '#/components/schemas/odata.error.main'
odata.error.main:
required:
- code
- message
type: object
properties:
code:
type: string
message:
type: string
target:
type: string
details:
type: array
items:
$ref: '#/components/schemas/odata.error.detail'
innererror:
type: object
description: The structure of this object is service-specific
odata.error.detail:
required:
- code
- message
type: object
properties:
code:
type: string
message:
type: string
target:
type: string
responses:
error:
description: error
content:
application/json:
schema:
$ref: '#/components/schemas/odata.error'
parameters:
top:
name: $top
in: query
description: Show only the first n items
schema:
minimum: 0
type: integer
example: 50
skip:
name: $skip
in: query
description: Skip the first n items
schema:
minimum: 0
type: integer
count:
name: $count
in: query
description: Include count of items
schema:
type: boolean
filter:
name: $filter
in: query
description: Filter items by property values
schema:
type: string
search:
name: $search
in: query
description: Search items by search phrases
schema:
type: string
tags:
- name: People
- name: Airlines
- name: Airports
- name: NewComePeople
- name: Me