Skip to content

Commit d92bdf4

Browse files
committed
update
1 parent d5c9ff6 commit d92bdf4

File tree

3 files changed

+27
-21
lines changed

3 files changed

+27
-21
lines changed

docs/api/components/schemas.yaml

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -384,7 +384,7 @@ Role:
384384
items:
385385
type: string
386386
readOnly: true
387-
$ref: "#/CollectionAccessConfig"
387+
$ref: '#/CollectionAccessConfig'
388388
title: Role
389389
User-session-information:
390390
type: object
@@ -407,6 +407,7 @@ User-session-information:
407407
description: A map of the channels in the default collection that the user is in along with the sequence number the user was granted access. This does not include inherited channels through roles.
408408
type: object
409409
additionalProperties:
410+
x-additionalPropertiesName: channelName
410411
type: number
411412
minimum: 1
412413
description: The sequence number the user was granted access.
@@ -2116,13 +2117,13 @@ Startup-config:
21162117
21172118
By default, this will only be accessible to the localhost.
21182119
type: string
2119-
default: "127.0.0.1:4985"
2120+
default: '127.0.0.1:4985'
21202121
admin_interface_authentication:
21212122
description: Whether the admin API requires authentication
21222123
type: boolean
21232124
default: true
21242125
compress_responses:
2125-
description: "If false, disables compression of HTTP responses"
2126+
description: 'If false, disables compression of HTTP responses'
21262127
type: boolean
21272128
default: true
21282129
cors:
@@ -3162,7 +3163,7 @@ IndexInitStatus:
31623163
"error": The index creation operation has failed.
31633164
settings:
31643165
allOf:
3165-
- $ref: "#/IndexSettings"
3166+
- $ref: '#/IndexSettings'
31663167
required:
31673168
- status
31683169
- start_time
@@ -3180,11 +3181,18 @@ CORS:
31803181
type: array
31813182
items:
31823183
type: string
3184+
example:
3185+
- Accept-Encoding
3186+
- Authorization
3187+
- Content-Type
3188+
- If-Match
31833189
login_origin:
31843190
description: |-
3185-
List of allowed origins to apply to public /{db}/_session API.
3191+
List of allowed origins to apply to public `/{db}/_session` API.
31863192
31873193
To use cors on `/{db}/_sesssion`, the domain must be present in both `login_origin` and `origin`.
3194+
3195+
If configured, `Authorization` must be included in headers.
31883196
type: array
31893197
items:
31903198
type: string
@@ -3195,7 +3203,7 @@ CORS:
31953203
default: 0
31963204
origin:
31973205
description: |-
3198-
List of allowed origins, use `['*']` to allow access from everywhere.
3206+
List of allowed origins for the public API.
31993207
type: array
32003208
items:
32013209
type: string

docs/api/paths/admin/db-_session.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ post:
3232
description: Time until the session expires. Uses default value of 24 hours if left blank. This value must be greater or equal to 1.
3333
type: integer
3434
responses:
35-
"200":
35+
'200':
3636
description: Session created successfully. Returned body is dependant on if using Public or Admin APIs.
3737
content:
3838
application/json:
@@ -52,11 +52,11 @@ post:
5252
Example:
5353
value:
5454
session_id: c5af80a039db4ed9d2b6865576b6999935282689
55-
expires: "2022-01-21T15:24:44Z"
55+
expires: '2022-01-21T15:24:44Z'
5656
cookie_name: SyncGatewaySession
5757
"401":
5858
$ref: ../../components/responses.yaml#/Unauthorized
59-
"404":
59+
'404':
6060
$ref: ../../components/responses.yaml#/Not-found
6161
tags:
6262
- Session

docs/api/paths/public/db-_session.yaml

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -28,21 +28,19 @@ post:
2828
If `Origin` header is passed to this endpoint, the `Origin` header must match both the `cors.login_origin` and `cors.origin` configuration options.
2929
requestBody:
3030
description: The body can be used to override the credentials of the authenticating user, or blank if getting a user session for the authenticating user.
31+
required: false
3132
content:
3233
application/json:
3334
schema:
34-
oneOf:
35-
- type: "null"
36-
title: "Empty Body"
37-
- type: object
38-
title: "User Credentials"
39-
properties:
40-
name:
41-
description: User name to generate the session for.
42-
type: string
43-
password:
44-
description: Password of the user to generate the session for.
45-
type: string
35+
type: object
36+
title: "User Credentials"
37+
properties:
38+
name:
39+
description: User name to generate the session for. Omit this value to use the authenticating user's credentials.
40+
type: string
41+
password:
42+
description: Password of the user to generate the session for. Omit this value to use the authenticating user's credentials.
43+
type: string
4644
responses:
4745
"200":
4846
$ref: ../../components/responses.yaml#/User-session-information

0 commit comments

Comments
 (0)