Scheduled Reports - CrowdStrike/falconpy GitHub Wiki
| Operation ID | Description | ||||
|---|---|---|---|---|---|
|
Launch scheduled report executions for the provided ID(s). | ||||
|
Retrieve scheduled reports for the provided report IDs. | ||||
|
Find all report IDs matching the query with filter | ||||
WARNING
client_idandclient_secretare keyword arguments that contain your CrowdStrike API credentials. Please note that all examples below do not hard code these values. (These values are ingested as strings.)CrowdStrike does not recommend hard coding API credentials or customer identifiers within source code.
Launch scheduled report executions for the provided ID(s).
launch
| Method | Route |
|---|---|
/reports/entities/scheduled-reports/execution/v1 |
- Consumes: application/json
- Produces: application/json
| Name | Service | Uber | Type | Data type | Description |
|---|---|---|---|---|---|
| ids |
|
|
query | string or list of strings | The report ID(s) to launch. |
| body |
|
|
query | list of dictionaries | Full body payload in JSON format. |
from falconpy import ScheduledReports
# Do not hardcode API credentials!
falcon = ScheduledReports(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
id_list = 'ID1,ID2,ID3' # Can also pass a list here: ['ID1', 'ID2', 'ID3']
response = falcon.launch(ids=id_list)
print(response)from falconpy import ScheduledReports
# Do not hardcode API credentials!
falcon = ScheduledReports(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
id_list = 'ID1,ID2,ID3' # Can also pass a list here: ['ID1', 'ID2', 'ID3']
response = falcon.scheduled_reports_launch(ids=id_list)
print(response)from falconpy import APIHarnessV2
# Do not hardcode API credentials!
falcon = APIHarnessV2(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
# To send multiple retries, pass a list of dictionaries, each holding one ID
BODY = [
{
"id": "ID1"
},
{
"id": "ID2"
},
{
"id": "ID3"
}
]
response = falcon.command("scheduled_reports_launch", body=BODY)
print(response)Retrieve scheduled reports for the provided report IDs.
get_reports
| Method | Route |
|---|---|
/reports/entities/scheduled-reports/v1 |
- Consumes: application/json
- Produces: application/json
| Name | Service | Uber | Type | Data type | Description |
|---|---|---|---|---|---|
| ids |
|
|
query | string or list of strings | The scheduled_report id to get details about. |
| parameters |
|
|
query | dictionary | Full query string parameters payload in JSON format. |
from falconpy import ScheduledReports
# Do not hardcode API credentials!
falcon = ScheduledReports(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
id_list = 'ID1,ID2,ID3' # Can also pass a list here: ['ID1', 'ID2', 'ID3']
response = falcon.get_reports(ids=id_list)
print(response)from falconpy import ScheduledReports
# Do not hardcode API credentials!
falcon = ScheduledReports(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
id_list = 'ID1,ID2,ID3' # Can also pass a list here: ['ID1', 'ID2', 'ID3']
response = falcon.scheduled_reports_get(ids=id_list)
print(response)from falconpy import APIHarnessV2
# Do not hardcode API credentials!
falcon = APIHarnessV2(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
id_list = 'ID1,ID2,ID3' # Can also pass a list here: ['ID1', 'ID2', 'ID3']
response = falcon.command("scheduled_reports_get", ids=id_list)
print(response)Find all report IDs matching the query with filter
query_reports
| Method | Route |
|---|---|
/reports/queries/scheduled-reports/v1 |
- Consumes: application/json
- Produces: application/json
| Name | Service | Uber | Type | Data type | Description |
|---|---|---|---|---|---|
| filter |
|
|
query | string |
FQL query specifying the filter parameters. Filter term criteria:
|
| limit |
|
|
query | integer | Number of ids to return. |
| offset |
|
|
query | string | Starting index of overall result set from which to return ids. |
| parameters |
|
|
query | dictionary | Full query string parameters payload in JSON format. |
| q |
|
|
query | string | Match query criteria, which includes all the filter string fields. |
| sort |
|
|
query | string | Possible order by fields:
|
from falconpy import ScheduledReports
# Do not hardcode API credentials!
falcon = ScheduledReports(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
response = falcon.query_reports(sort="string",
filter="string",
q="string",
offset="string",
limit=integer
)
print(response)from falconpy import ScheduledReports
# Do not hardcode API credentials!
falcon = ScheduledReports(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
response = falcon.scheduled_reports_query(sort="string",
filter="string",
q="string",
offset="string",
limit=integer
)
print(response)from falconpy import APIHarnessV2
# Do not hardcode API credentials!
falcon = APIHarnessV2(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
response = falcon.command("scheduled_reports_query",
sort="string",
filter="string",
q="string",
offset="string",
limit=integer
)
print(response)
