diff options
author | 6543 | 2021-08-12 14:43:08 +0200 |
---|---|---|
committer | GitHub | 2021-08-12 14:43:08 +0200 |
commit | 2289580bb7ef8dfa4124c2b3bfb89897dbb35f46 (patch) | |
tree | e68aae604bb3d738b44156504a1415adaf042c68 /CONTRIBUTING.md | |
parent | ca13e1d56c561f72cf8ad251fe61b1898abfec51 (diff) |
[API] generalize list header (#16551)
* Add info about list endpoints to CONTRIBUTING.md
* Let all list endpoints return X-Total-Count header
* Add TODOs for GetCombinedCommitStatusByRef
* Fix models/issue_stopwatch.go
* Rrefactor models.ListDeployKeys
* Introduce helper func and use them for SetLinkHeader related func
Diffstat (limited to 'CONTRIBUTING.md')
-rw-r--r-- | CONTRIBUTING.md | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index eb515f268..026536868 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -207,6 +207,10 @@ In general, HTTP methods are chosen as follows: An endpoint which changes/edits an object expects all fields to be optional (except ones to identify the object, which are required). +### Endpoints returning lists should + * support pagination (`page` & `limit` options in query) + * set `X-Total-Count` header via **SetTotalCountHeader** ([example](https://github.com/go-gitea/gitea/blob/7aae98cc5d4113f1e9918b7ee7dd09f67c189e3e/routers/api/v1/repo/issue.go#L444)) + ## Developer Certificate of Origin (DCO) @@ -231,8 +235,8 @@ on, finishing, and issuing releases. The overall goal is to make a minor release every three or four months, which breaks down into two or three months of general development followed by one month of testing and polishing known as the release freeze. All the feature pull requests should be -merged before feature freeze. And, during the frozen period, a corresponding -release branch is open for fixes backported from main branch. Release candidates +merged before feature freeze. And, during the frozen period, a corresponding +release branch is open for fixes backported from main branch. Release candidates are made during this period for user testing to obtain a final version that is maintained in this branch. A release is maintained by issuing patch releases to only correct critical problems |