Search for a pattern inside file contents (grep)
import requests
url = "https://api.13-215-85-171.sslip.io/v1/machines/{id}/files/find"
payload = {
"path": "<string>",
"pattern": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)curl --request POST \
--url https://api.13-215-85-171.sslip.io/v1/machines/{id}/files/find \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"path": "<string>",
"pattern": "<string>"
}
'[
{
"file": "<string>",
"line": 123,
"content": "<string>"
}
]Files
Search for a pattern inside file contents (grep)
POST
/
v1
/
machines
/
{id}
/
files
/
find
Search for a pattern inside file contents (grep)
import requests
url = "https://api.13-215-85-171.sslip.io/v1/machines/{id}/files/find"
payload = {
"path": "<string>",
"pattern": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)curl --request POST \
--url https://api.13-215-85-171.sslip.io/v1/machines/{id}/files/find \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"path": "<string>",
"pattern": "<string>"
}
'[
{
"file": "<string>",
"line": 123,
"content": "<string>"
}
]Authorizations
API key passed as Bearer token
Path Parameters
Machine ID (e.g. mch_a1b2c3d4)
Body
application/json