129 lines
2.6 KiB
YAML
129 lines
2.6 KiB
YAML
swagger: "2.0"
|
|
info:
|
|
title: oc-peers
|
|
description: |
|
|
Manage OpenCloud peers
|
|
version: 1.0.0
|
|
termsOfService: http://cloud.o-forge.io/
|
|
contact:
|
|
email: admin@o-cloud.io
|
|
license:
|
|
name: MIT
|
|
url: https://opensource.org/license/mit
|
|
basePath: /oc/
|
|
paths:
|
|
/peer/:
|
|
get:
|
|
tags:
|
|
- peer
|
|
description: |-
|
|
find all peer
|
|
<br>
|
|
operationId: PeerController.GetAll
|
|
responses:
|
|
"200":
|
|
description: '{peer} models.peer'
|
|
/peer/{id}:
|
|
get:
|
|
tags:
|
|
- peer
|
|
description: |-
|
|
find peer by peerid
|
|
<br>
|
|
operationId: PeerController.Get
|
|
parameters:
|
|
- in: path
|
|
name: id
|
|
description: the peer id you want to get
|
|
required: true
|
|
type: string
|
|
responses:
|
|
"200":
|
|
description: '{peer} models.peer'
|
|
put:
|
|
tags:
|
|
- peer
|
|
description: |-
|
|
create peers
|
|
<br>
|
|
operationId: PeerController.Update
|
|
parameters:
|
|
- in: path
|
|
name: id
|
|
description: the peer id you want to get
|
|
required: true
|
|
type: string
|
|
- in: body
|
|
name: body
|
|
description: The peer content
|
|
required: true
|
|
schema:
|
|
$ref: '#/definitions/models.peer'
|
|
responses:
|
|
"200":
|
|
description: ""
|
|
schema:
|
|
$ref: '#/definitions/models.peer'
|
|
/peer/search/{search}:
|
|
get:
|
|
tags:
|
|
- peer
|
|
description: |-
|
|
search workspace
|
|
<br>
|
|
operationId: PeerController.Search
|
|
parameters:
|
|
- in: path
|
|
name: search
|
|
description: the word search you want to get
|
|
required: true
|
|
type: string
|
|
responses:
|
|
"200":
|
|
description: '{workspace} models.workspace'
|
|
/status/:
|
|
post:
|
|
tags:
|
|
- status
|
|
description: |-
|
|
get peer status if it's alive
|
|
<br>
|
|
operationId: StatusController.Status
|
|
parameters:
|
|
- in: body
|
|
name: body
|
|
description: of
|
|
schema:
|
|
$ref: '#/definitions/list'
|
|
responses:
|
|
"200":
|
|
description: '{status} models.status'
|
|
/version/:
|
|
get:
|
|
tags:
|
|
- version
|
|
description: |-
|
|
get version
|
|
<br>
|
|
operationId: VersionController.GetAll
|
|
responses:
|
|
"200":
|
|
description: ""
|
|
definitions:
|
|
list:
|
|
title: list
|
|
type: object
|
|
models.peer:
|
|
title: peer
|
|
type: object
|
|
tags:
|
|
- name: status
|
|
description: |
|
|
Operations about workflow
|
|
- name: peer
|
|
description: |
|
|
Operations about workflow
|
|
- name: version
|
|
description: |
|
|
VersionController operations for Version
|