Skip to content

Commit

Permalink
Update scopes documentation (#6231)
Browse files Browse the repository at this point in the history
  • Loading branch information
torcolvin authored and bbrks committed Mar 28, 2024
1 parent 034ecb6 commit 50c9b75
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions docs/api/components/schemas.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1090,7 +1090,7 @@ CollectionConfig:
sync:
description: The Javascript function that newly created documents in this collection are ran through.
type: string
example: 'function(doc){channel(doc.channels);}'
example: 'function(doc){channel("collection name");}'
import_filter:
description: |-
This is the function that all imported documents in this collection are ran through in order to filter out what to import and what not to import. This allows you to control what is made available to Couchbase Mobile clients. If it is not set, then no documents are filtered when imported.
Expand Down Expand Up @@ -1165,7 +1165,9 @@ Database:
description: The name of the database.
type: string
sync:
description: The Javascript function that newly created documents are ran through for the _default scope and collection.
description: The Javascript function that newly created documents are ran through for the default scope and collection.

If `scopes` parameter is set, this is ignored.
type: string
default: 'function(doc){channel(doc.channels);}'
users:
Expand Down Expand Up @@ -1203,9 +1205,11 @@ Database:
default: 16
import_filter:
description: |-
This is the function that all imported documents in the _default scope and collection are ran through in order to filter out what to import and what not to import. This allows you to control what is made available to Couchbase Mobile clients. If it is not set, then no documents are filtered when imported.
This is the function that all imported documents in the default scope and collection are ran through in order to filter out what to import and what not to import. This allows you to control what is made available to Couchbase Mobile clients. If it is not set, then no documents are filtered when imported.
`import_docs` must be true to make this field applicable.
If `scopes` parameter is set, this is ignored.
type: string
example: 'function(doc) { if (doc.type != ''mobile'') { return false; } return true; }'
import_backup_old_rev:
Expand Down

0 comments on commit 50c9b75

Please sign in to comment.