Search files
POST
/v1/workspaces/{workspace_id}/fs/_/grep
const url = 'https://app.everruns.com/api/v1/workspaces/example/fs/_/grep';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"path_pattern":"example","pattern":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://app.everruns.com/api/v1/workspaces/example/fs/_/grep \ --header 'Content-Type: application/json' \ --data '{ "path_pattern": "example", "pattern": "example" }'Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters ” workspace_id
required
string
Workspace ID (wsp_<32-hex>)
Request Body required
Section titled “Request Body required ” Media type application/json
object
path_pattern
string | null
pattern
required
string
Example generated
{ "path_pattern": "example", "pattern": "example"}Responses
Section titled “ Responses ”Search results
Media type application/json
Response wrapper for list endpoints.
All list endpoints return responses wrapped in a data field.
object
data
required
Array of items returned by the list operation.
Array<object>
Grep result for a file
object
matches
required
Array<object>
Grep match result
object
line
required
string
line_number
required
integer
path
required
string
path
required
string
Example generated
{ "data": [ { "matches": [ { "line": "example", "line_number": 1, "path": "example" } ], "path": "example" } ]}Invalid regex pattern
Internal server error