2025-01-23 09:19:10 +01:00
|
|
|
openapi: 3.0.3
|
|
|
|
info:
|
|
|
|
title: swisssign-challenge - dlmw
|
|
|
|
description: |-
|
|
|
|
This is the documentation for the SwissSign Challenge API.
|
|
|
|
termsOfService: ""
|
|
|
|
contact:
|
|
|
|
email: dylan@dlmw.ch
|
|
|
|
license:
|
|
|
|
name: GNU General Public License Version 3
|
|
|
|
url: https://www.gnu.org/licenses/gpl-3.0.txt
|
|
|
|
version: 0.0.1
|
|
|
|
externalDocs:
|
|
|
|
description: ""
|
|
|
|
url: ""
|
|
|
|
servers:
|
|
|
|
- url: ""
|
|
|
|
tags:
|
|
|
|
- name: hello
|
|
|
|
description: ""
|
|
|
|
|
|
|
|
paths:
|
|
|
|
/hello:
|
|
|
|
get:
|
|
|
|
tags:
|
|
|
|
- hello
|
|
|
|
summary: Get a hello from me
|
|
|
|
operationId: getHello
|
|
|
|
responses:
|
|
|
|
200:
|
|
|
|
description: "Hello"
|
|
|
|
content:
|
|
|
|
application/json:
|
|
|
|
schema:
|
|
|
|
$ref: "#/components/schemas/HelloResponse"
|
2025-01-30 17:42:36 +01:00
|
|
|
/token:
|
|
|
|
post:
|
|
|
|
tags:
|
|
|
|
- session
|
|
|
|
summary: Create a bearer token
|
|
|
|
operationId: createToken
|
|
|
|
requestBody:
|
|
|
|
content:
|
|
|
|
application/json:
|
|
|
|
schema:
|
|
|
|
$ref: "#/components/schemas/CreateSessionRequest"
|
|
|
|
responses:
|
|
|
|
200:
|
|
|
|
description: "New token was generated"
|
|
|
|
content:
|
|
|
|
application/json:
|
|
|
|
schema:
|
|
|
|
$ref: "#/components/schemas/CreateSessionResponse"
|
2025-01-23 09:19:10 +01:00
|
|
|
|
|
|
|
components:
|
|
|
|
schemas:
|
|
|
|
HelloResponse:
|
|
|
|
type: object
|
|
|
|
properties:
|
|
|
|
value:
|
|
|
|
type: string
|
|
|
|
|
2025-01-30 17:42:36 +01:00
|
|
|
CreateSessionRequest:
|
|
|
|
type: object
|
|
|
|
required:
|
|
|
|
- username
|
|
|
|
- password
|
|
|
|
properties:
|
|
|
|
username:
|
|
|
|
type: string
|
|
|
|
password:
|
|
|
|
type: string
|
|
|
|
|
|
|
|
CreateSessionResponse:
|
|
|
|
type: object
|
|
|
|
required:
|
|
|
|
- token
|
|
|
|
properties:
|
|
|
|
token:
|
|
|
|
type: string
|
|
|
|
|
2025-01-23 09:19:10 +01:00
|
|
|
ErrorResponse:
|
|
|
|
type: object
|
|
|
|
required:
|
|
|
|
- message
|
|
|
|
- code
|
|
|
|
properties:
|
|
|
|
message:
|
|
|
|
type: string
|
|
|
|
description: Human-readable error message
|
|
|
|
code:
|
|
|
|
type: integer
|
|
|
|
description: Machine-readable error code
|
|
|
|
details:
|
|
|
|
type: object
|
|
|
|
description: Additional error details when available
|