@rest_initialiser(cluster_init_check=True, version_check=True)
def execute(self, opts):
    cmds = [opts.create_scope, opts.drop_scope, opts.list_scopes, opts.create_collection, opts.drop_collection, opts.list_collections]
    cmd_total = sum(((cmd is not None) for cmd in cmds))
    args = '--create-scope, --drop-scope, --list-scopes, --create-collection, --drop-collection, or --list-collections'
    if (cmd_total == 0):
        _exit_if_errors([f'Must specify one of the following: {args}'])
    elif (cmd_total != 1):
        _exit_if_errors([f'Only one of the following may be specified: {args}'])
    if ((opts.max_ttl is not None) and (opts.create_collection is None)):
        _exit_if_errors(['--max-ttl can only be set with --create-collection'])
    if opts.create_scope:
        self._create_scope(opts)
    if opts.drop_scope:
        self._drop_scope(opts)
    if opts.list_scopes:
        self._list_scopes(opts)
    if opts.create_collection:
        self._create_collection(opts)
    if opts.drop_collection:
        self._drop_collection(opts)
    if (opts.list_collections is not None):
        self._list_collections(opts)
@rest_initialiser(cluster_init_check=True, version_check=True)
def execute(self, opts):
    cmds = [opts.create_scope, opts.drop_scope, opts.list_scopes, opts.create_collection, opts.drop_collection, opts.list_collections]
    cmd_total = sum(((cmd is not None) for cmd in cmds))
    args = '--create-scope, --drop-scope, --list-scopes, --create-collection, --drop-collection, or --list-collections'
    if (cmd_total == 0):
        _exit_if_errors([f'Must specify one of the following: {args}'])
    elif (cmd_total != 1):
        _exit_if_errors([f'Only one of the following may be specified: {args}'])
    if ((opts.max_ttl is not None) and (opts.create_collection is None)):
        _exit_if_errors(['--max-ttl can only be set with --create-collection'])
    if opts.create_scope:
        self._create_scope(opts)
    if opts.drop_scope:
        self._drop_scope(opts)
    if opts.list_scopes:
        self._list_scopes(opts)
    if opts.create_collection:
        self._create_collection(opts)
    if opts.drop_collection:
        self._drop_collection(opts)
    if (opts.list_collections is not None):
        self._list_collections(opts)