Create or update a SMB/CIFS repository (location)

Use this API to create a new location to crawl files located on a server reached through SMB/CIFS.

Requirement: OpenSearchServer v1.5

The URLs and HTTP methods used by this API are different from other OSS APIs, please give this document a careful read.

Call parameters

URL: /services/rest/crawler/file/repository/inject/smb/{index_name}/{result_type}?path={path}&ignoreHiddenFile={ignoreHiddenFile}&includeSubDirectory={includeSubDirectory}&enabled={enabled}&delay={delay}

Method: PUT

URL parameters:

  • index_name (required): The name of the index.
  • result_type (required): The type of returned result (json or xml).
  • path: The path to connect to the server and folder.
  • ignoreHiddenFile: Whether hidden files should be ignored during crawling (true or false).
  • includeSubDirectory: Whether sub-directories should be crawled (true or false).
  • enabled: Whether this new location should be eligible for crawling (true or false).
  • delay: delay between each file access in ms (defaults to 0).
  • username: user name to connect to the server.
  • password: password to connect to the server.
  • domain: domain to connect to the server.
  • host: host to connect to the server.

Success response

The new location has been created or updated.

HTTP code:

Content (json):


Error response

The request failed. The reason is provided in the content.

HTTP code:

View/edit on GitHub

comments powered by Disqus