mirror of
https://github.com/adidas/api-guidelines.git
synced 2025-10-25 15:19:19 +00:00
Add OAS2 structure to the snippet
This commit is contained in:
@@ -1,64 +1,74 @@
|
|||||||
HalLinkObject:
|
swagger: "2.0"
|
||||||
title: HAL Link Object
|
info:
|
||||||
type: object
|
|
||||||
properties:
|
|
||||||
href:
|
|
||||||
type: string
|
|
||||||
templated:
|
|
||||||
type: boolean
|
|
||||||
type:
|
|
||||||
type: string
|
|
||||||
deprecation:
|
|
||||||
type: string
|
|
||||||
name:
|
|
||||||
type: string
|
|
||||||
profile:
|
|
||||||
type: string
|
|
||||||
title:
|
|
||||||
type: string
|
|
||||||
hreflang:
|
|
||||||
type: string
|
|
||||||
required:
|
|
||||||
- href
|
|
||||||
HalCuriesLink:
|
|
||||||
title: HAL Curies Link
|
|
||||||
allOf:
|
|
||||||
- type: object
|
|
||||||
properties:
|
|
||||||
templated:
|
|
||||||
enum:
|
|
||||||
- true
|
|
||||||
required:
|
|
||||||
- templated
|
|
||||||
- $ref: '#/definitions/HalLinkObject'
|
|
||||||
HAL:
|
|
||||||
title: HAL
|
title: HAL
|
||||||
description: >-
|
description: HAL snippet for OAS2
|
||||||
JSON Hypertext Application Language. Definition of [HAL message
|
version: 1.0.0
|
||||||
format](https://tools.ietf.org/html/draft-kelly-json-hal-08)
|
host: api.example.com
|
||||||
type: object
|
basePath: /v1
|
||||||
properties:
|
schemes:
|
||||||
_links:
|
- https
|
||||||
type: object
|
paths: {}
|
||||||
additionalProperties:
|
definitions:
|
||||||
allOf:
|
HalLinkObject:
|
||||||
- $ref: '#/definitions/HalLinkObject'
|
title: HAL Link Object
|
||||||
- type: array
|
type: object
|
||||||
items:
|
properties:
|
||||||
$ref: '#/definitions/HalLinkObject'
|
href:
|
||||||
properties:
|
type: string
|
||||||
curies:
|
templated:
|
||||||
|
type: boolean
|
||||||
|
type:
|
||||||
|
type: string
|
||||||
|
deprecation:
|
||||||
|
type: string
|
||||||
|
name:
|
||||||
|
type: string
|
||||||
|
profile:
|
||||||
|
type: string
|
||||||
|
title:
|
||||||
|
type: string
|
||||||
|
hreflang:
|
||||||
|
type: string
|
||||||
|
required:
|
||||||
|
- href
|
||||||
|
HalCuriesLink:
|
||||||
|
title: HAL Curies Link
|
||||||
|
allOf:
|
||||||
|
- type: object
|
||||||
|
properties:
|
||||||
|
templated:
|
||||||
|
enum:
|
||||||
|
- true
|
||||||
|
required:
|
||||||
|
- templated
|
||||||
|
- $ref: '#/definitions/HalLinkObject'
|
||||||
|
HAL:
|
||||||
|
title: HAL
|
||||||
|
description: >-
|
||||||
|
JSON Hypertext Application Language. Definition of [HAL message
|
||||||
|
format](https://tools.ietf.org/html/draft-kelly-json-hal-08)
|
||||||
|
type: object
|
||||||
|
properties:
|
||||||
|
_links:
|
||||||
|
type: object
|
||||||
|
additionalProperties:
|
||||||
allOf:
|
allOf:
|
||||||
- $ref: '#/definitions/HalCuriesLink'
|
- $ref: '#/definitions/HalLinkObject'
|
||||||
- type: array
|
- type: array
|
||||||
items:
|
items:
|
||||||
$ref: >-
|
$ref: '#/definitions/HalLinkObject'
|
||||||
'#/definitions/HalCuriesLink'
|
properties:
|
||||||
_embedded:
|
curies:
|
||||||
type: object
|
allOf:
|
||||||
additionalProperties:
|
- $ref: '#/definitions/HalCuriesLink'
|
||||||
allOf:
|
- type: array
|
||||||
- $ref: '#/definitions/HAL'
|
items:
|
||||||
- type: array
|
$ref: '#/definitions/HalCuriesLink'
|
||||||
items:
|
_embedded:
|
||||||
$ref: '#/definitions/HAL'
|
type: object
|
||||||
|
additionalProperties:
|
||||||
|
allOf:
|
||||||
|
- $ref: '#/definitions/HAL'
|
||||||
|
- type: array
|
||||||
|
items:
|
||||||
|
$ref: '#/definitions/HAL'
|
||||||
Reference in New Issue
Block a user