-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #24 from plugoinc/feat/hubclientinfo
HubClientInfo module Interfaces
- Loading branch information
Showing
7 changed files
with
134 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
description: ClientInfo Response | ||
content: | ||
application/json: | ||
schema: | ||
allOf: | ||
- $ref: ./BaseResponse.yaml | ||
- properties: | ||
data: | ||
$ref: ../schemas/ClientInfo.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
description: List of ClientInfo objects | ||
|
||
headers: | ||
Link: | ||
$ref: ../headers/Link.yaml | ||
X-Total-Count: | ||
$ref: ../headers/X-Total-Count.yaml | ||
X-Limit: | ||
$ref: ../headers/X-Limit.yaml | ||
content: | ||
application/json: | ||
schema: | ||
allOf: | ||
- $ref: ./BaseResponse.yaml | ||
- properties: | ||
data: | ||
type: array | ||
items: | ||
$ref: ../schemas/ClientInfo.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
type: object | ||
required: | ||
- party_id | ||
- country_code | ||
- role | ||
- status | ||
- last_updated | ||
properties: | ||
party_id: | ||
$ref: ./PartyID.yaml | ||
country_code: | ||
$ref: ./CountryCode.yaml | ||
role: | ||
$ref: ./Role.yaml | ||
status: | ||
$ref: ./ConnectionStatus.yaml | ||
last_updated: | ||
$ref: ./DateTime.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
summary: ConnectionStatus enum | ||
type: string | ||
enum: | ||
- CONNECTED | ||
- OFFLINE | ||
- PLANNED | ||
- SUSPENDED |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
get: | ||
tags: | ||
- HubClientInfo | ||
summary: "Receiver: {clientinfo_endpoint_url}/{country_code}/{party_id}" | ||
description: | | ||
Retrieve a ClientInfo object as it is stored in the connected clients system. | ||
operationId: getClientInfo | ||
security: | ||
- tokenAuth: [] | ||
parameters: | ||
- $ref: ../components/parameters/countryCode.yaml | ||
- $ref: ../components/parameters/partyId.yaml | ||
responses: | ||
"200": | ||
description: OK | ||
$ref: ../components/responses/ClientInfoResponse.yaml | ||
"401": | ||
description: Unauthorized | ||
$ref: ../components/responses/Unauthorized.yaml | ||
"404": | ||
description: Not Found | ||
$ref: ../components/responses/NotFound.yaml | ||
|
||
put: | ||
tags: | ||
- HubClientInfo | ||
summary: "Receiver: {clientinfo_endpoint_url}/{country_code}/{party_id}" | ||
description: | | ||
New or updated ClientInfo objects are pushed from the Hub to a connected client. | ||
operationId: putClientInfo | ||
security: | ||
- tokenAuth: [] | ||
parameters: | ||
- $ref: ../components/parameters/countryCode.yaml | ||
- $ref: ../components/parameters/partyId.yaml | ||
requestBody: | ||
content: | ||
application/json: | ||
schema: | ||
$ref: ../components/schemas/ClientInfo.yaml | ||
|
||
responses: | ||
"200": | ||
description: Updated | ||
$ref: ../components/responses/ClientInfoResponse.yaml | ||
"201": | ||
description: Created | ||
$ref: ../components/responses/ClientInfoResponse.yaml | ||
"400": | ||
description: Bad Request | ||
$ref: ../components/responses/BadRequest.yaml | ||
"401": | ||
description: Unauthorized | ||
$ref: ../components/responses/Unauthorized.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
get: | ||
tags: | ||
- HubClientInfo | ||
summary: "Sender: {locations_endpoint_url}" | ||
description: | | ||
Get the list of known ClientInfo objects, last updated between the {date_from} and {date_to} paginated) | ||
operationId: getHubClientInfos | ||
security: | ||
- tokenAuth: [] | ||
|
||
parameters: | ||
- $ref: ../components/parameters/collectionDateFrom.yaml | ||
- $ref: ../components/parameters/collectionDateTo.yaml | ||
- $ref: ../components/parameters/collectionOffset.yaml | ||
- $ref: ../components/parameters/collectionLimit.yaml | ||
responses: | ||
"200": | ||
$ref: ../components/responses/ClientInfosResponse.yaml | ||
"400": | ||
$ref: ../components/responses/BadRequest.yaml | ||
"401": | ||
$ref: ../components/responses/Unauthorized.yaml |