MCPcopy Create free account
hub / github.com/omkarcloud/botasaurus / getReadme

Function getReadme

js/botasaurus-server-js/src/server.ts:20–32  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

18}
19const validScraperTypes = new Set([ScraperType.REQUEST, ScraperType.BROWSER, ScraperType.TASK]);
20function getReadme(): string {
21 try {
22 const readmeFile = getReadmePath();
23
24 const text = fs.readFileSync(readmeFile, 'utf-8');
25 return text;
26 } catch (error) {
27 if (isNoentError(error)) {
28 return '';
29 }
30 throw error;
31 }
32}
33
34export function getScraperErrorMessage(validScraperNames: string[], scraperName: string | null, validNamesString: string) {
35 if (validScraperNames.length === 0) {

Callers 2

getConfigMethod · 0.85
configureMethod · 0.85

Calls 2

getReadmePathFunction · 0.90
isNoentErrorFunction · 0.90

Tested by

no test coverage detected