Refactor du projet réduire le nombre de packages et sous-dossiers #200
1 changed files with 12 additions and 9 deletions
21
response.go
21
response.go
|
@ -19,14 +19,14 @@ func (R *APIResponse) SetStatusCode(code int) {
|
|||
R.statusCode = code
|
||||
}
|
||||
|
||||
type V1BucketsGET struct {
|
||||
type ListBucketsResponse struct {
|
||||
APIResponse
|
||||
Data struct {
|
||||
Buckets map[string]string
|
||||
}
|
||||
}
|
||||
|
||||
type V1BucketGET struct {
|
||||
type ReadBucketResponse struct {
|
||||
APIResponse
|
||||
Data struct {
|
||||
Keys []string
|
||||
|
@ -38,7 +38,7 @@ type DataDocument struct {
|
|||
Size int64
|
||||
}
|
||||
|
||||
type V1DocumentsPOST struct {
|
||||
type CreateDocumentsResponse struct {
|
||||
APIResponse
|
||||
Data struct {
|
||||
Bucket string
|
||||
|
@ -46,8 +46,7 @@ type V1DocumentsPOST struct {
|
|||
}
|
||||
}
|
||||
|
||||
// Deprecated: Use V1DocumentsPOST instead
|
||||
type V1DocumentPOST struct {
|
||||
type CreateDocumentResponse struct {
|
||||
APIResponse
|
||||
Data struct {
|
||||
Bucket string
|
||||
|
@ -55,11 +54,11 @@ type V1DocumentPOST struct {
|
|||
}
|
||||
}
|
||||
|
||||
type V1DocumentDELETE struct {
|
||||
type DeleteDocumentResponse struct {
|
||||
APIResponse
|
||||
}
|
||||
|
||||
type V1DocumentKeyPUT struct {
|
||||
type UpdateDocumentKeyResponse struct {
|
||||
APIResponse
|
||||
Data struct {
|
||||
Bucket string
|
||||
|
@ -67,20 +66,21 @@ type V1DocumentKeyPUT struct {
|
|||
}
|
||||
}
|
||||
|
||||
type V1SeedPOST struct {
|
||||
type ExecuteSeedResponse struct {
|
||||
APIResponse
|
||||
Data struct {
|
||||
Buckets []string
|
||||
}
|
||||
}
|
||||
|
||||
type V1SpecGET struct {
|
||||
type ReadSpecResponse struct {
|
||||
APIResponse
|
||||
Data struct {
|
||||
Spec string
|
||||
}
|
||||
}
|
||||
|
||||
// Deprecated: Use ListBucketsResponse instead
|
||||
type HandleAdminDocumentsUploadResponse struct {
|
||||
APIResponse
|
||||
Data struct {
|
||||
|
@ -88,6 +88,7 @@ type HandleAdminDocumentsUploadResponse struct {
|
|||
}
|
||||
}
|
||||
|
||||
// Deprecated: Use ListBucketsResponse instead
|
||||
type HandleDocumentationResponse struct {
|
||||
APIResponse
|
||||
Data struct {
|
||||
|
@ -95,11 +96,13 @@ type HandleDocumentationResponse struct {
|
|||
}
|
||||
}
|
||||
|
||||
// Deprecated: Use CreateDocumentResponse instead
|
||||
type UploadDocumentAPIResponse struct {
|
||||
APIResponse
|
||||
Data UploadDocumentResponseData
|
||||
}
|
||||
|
||||
// Deprecated: Use DataDocument instead
|
||||
type UploadDocumentResponseData struct {
|
||||
Bucket string
|
||||
Object string
|
||||
|
|
Loading…
Reference in a new issue