diff options
author | Achilleas Pipinellis <axil@gitlab.com> | 2017-10-19 18:19:12 +0300 |
---|---|---|
committer | Achilleas Pipinellis <axil@gitlab.com> | 2017-10-19 18:19:12 +0300 |
commit | ed339b69019533fae6d2bfee5a5e1c17a12e2402 (patch) | |
tree | 6d7369a085d8384a1a17717dc4f01c0cabfcc668 /doc | |
parent | 16998e2e13a83a07be9d78f210e7f629e7330dd4 (diff) | |
parent | efbb9cfb7b6ebc8a0c724d103c6e1063e049f205 (diff) |
Merge branch 'sh-document-plus-encoding-api' into 'master'
Document converting `+` to `%2B` in an API query parameter
See merge request gitlab-org/gitlab-ce!14948
Diffstat (limited to 'doc')
-rw-r--r-- | doc/api/README.md | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/doc/api/README.md b/doc/api/README.md index 3145c9b676f..de0fe79b3d6 100644 --- a/doc/api/README.md +++ b/doc/api/README.md @@ -455,6 +455,23 @@ Content-Type: application/json } ``` +## Encoding `+` in ISO 8601 dates + +If you need to include a `+` in a query parameter, you may need to use `%2B` instead due +a [W3 recommendation]((http://www.w3.org/Addressing/URL/4_URI_Recommentations.html) that +causes a `+` to be interpreted as a space. For example, in an ISO 8601 date, you may want to pass +a time in Mountain Standard Time, such as: + +``` +2017-10-17T23:11:13.000+05:30 +``` + +The correct encoding for the query parameter would be: + +``` +2017-10-17T23:11:13.000%2B05:30 +``` + ## Clients There are many unofficial GitLab API Clients for most of the popular |