Small enhancements due to requests

This commit is contained in:
Nico Kroll 2025-08-05 14:23:49 +02:00
parent 8cd8199417
commit 00243eb3b5
3 changed files with 58 additions and 1 deletions

View File

@ -19,6 +19,7 @@ https://www.astera.com/de/type/blog/api-design-best-practices
https://www.citusdata.com/blog/2016/03/30/five-ways-to-paginate/
https://stackoverflow.blog/2021/10/06/best-practices-for-authentication-and-authorization-for-rest-apis/
https://www.akamai.com/blog/security/rest-api-security-best-practices
https://jakarta.ee/specifications/data/1.0/
# Examples

View File

@ -1287,6 +1287,54 @@ paths:
$ref: "#/components/responses/GenericError"
security:
- SessionScheme: []
/Documents/{Guid}/custommethods/AcceptOffer:
post:
tags:
- "Documents"
description: "Accepts an offer. Dependant on the implementation, it could be that the offer is after the operation an order."
parameters:
- $ref: "#/components/parameters/GuidPathParameter"
- $ref: "#/components/parameters/_HashValueParameter"
- name: "Comment"
in: "query"
required: false
schema:
type: "string"
default: null
example: "Thanks you!"
responses:
200:
description: "successful operation"
401:
$ref: "#/components/responses/SessionOfOnlineUserOrHigherRequired"
default:
$ref: "#/components/responses/GenericError"
security:
- SessionScheme: []
/Documents/{Guid}/custommethods/RejectOffer:
post:
tags:
- "Documents"
description: "Rejects an offer. Dependant on the implementation, the offer keeps beeing open for further responses or gets historic."
parameters:
- $ref: "#/components/parameters/GuidPathParameter"
- $ref: "#/components/parameters/_HashValueParameter"
- name: "Comment"
in: "query"
required: false
schema:
type: "string"
default: null
example: "The price is higher than excepted. Can you make another offer?"
responses:
200:
description: "successful operation"
401:
$ref: "#/components/responses/SessionOfOnlineUserOrHigherRequired"
default:
$ref: "#/components/responses/GenericError"
security:
- SessionScheme: []
/DocumentPositions:
get:
tags:

View File

@ -1,7 +1,7 @@
openapi: 3.0.0
info:
title: "TyrePro-API, TPMS"
version: "Version 6"
version: "Version 7"
servers:
- url: "https://musterreifen.com/api/tpms"
description: "Development server"
@ -1353,6 +1353,12 @@ components:
type: "integer"
CustomerName1:
type: "string"
StorageDesignation:
type: "string"
StoragePlaceDesignation:
type: "string"
RemoteStorageReference:
type: "string"
Documents:
type: "array"
items:
@ -1458,6 +1464,8 @@ components:
type: "string"
GuidStorageLocation:
type: "string"
RemoteStorageReference:
type: "string"
CommentExternal:
type: "string"
CommentInternal: