MCPcopy Create free account
hub / github.com/algolia/cli / Pause

Method Pause

api/crawler/client.go:246–256  ·  view source on GitHub ↗

Pause pauses a Crawler. It returns the Task ID if successful.

(crawlerID string)

Source from the content-addressed store, hash-verified

244// Pause pauses a Crawler.
245// It returns the Task ID if successful.
246func (c *Client) Pause(crawlerID string) (string, error) {
247 var res TaskIDResponse
248 path := fmt.Sprintf("crawlers/%s/pause", crawlerID)
249
250 err := c.request(&res, http.MethodPost, path, nil, nil)
251 if err != nil {
252 return "", err
253 }
254
255 return res.TaskID, nil
256}
257
258// Reindex reindexes a Crawler.
259// It returns the Task ID if successful.

Callers

nothing calls this directly

Calls 1

requestMethod · 0.95

Tested by

no test coverage detected