Merge remote-tracking branch 'refs/remotes/origin/simplify-client' into simplify-client

This commit is contained in:
Dominik Schröter 2025-02-07 16:42:36 +01:00
commit 4d8e4ff17a

View file

@ -1,5 +1,17 @@
package main
// GetDocumentsApiResponse is the response payload for /documents endpoint.
// But we are only interested in a subset of the fields.
type GetDocumentsApiResponse struct {
Count int `json:"count"`
// Next interface{} `json:"next"`
// Previous interface{} `json:"previous"`
All []int `json:"all"`
Results []GetDocumentApiResponseResult `json:"results"`
}
// GetDocumentApiResponseResult is a part of the response payload for /documents endpoint.
// But we are only interested in a subset of the fields.
type GetDocumentApiResponseResult struct {
ID int `json:"id"`
Correspondent int `json:"correspondent"`
@ -26,16 +38,6 @@ type GetDocumentApiResponseResult struct {
// } `json:"__search_hit__"`
}
// GetTagsApiResponse is the response payload for /tags endpoint.
// But we are only interested in a subset of the fields.
type GetDocumentsApiResponse struct {
Count int `json:"count"`
// Next interface{} `json:"next"`
// Previous interface{} `json:"previous"`
All []int `json:"all"`
Results []GetDocumentApiResponseResult `json:"results"`
}
// GetDocumentApiResponse is the response payload for /documents/{id} endpoint.
// But we are only interested in a subset of the fields.
type GetDocumentApiResponse struct {