Tailored Intelligence - CrowdStrike/falconpy GitHub Wiki
| Operation ID | Description | ||||
|---|---|---|---|---|---|
|
Get event body for the provided event ID | ||||
|
Get events entities for specified ids. | ||||
|
Get events ids that match the provided filter criteria. | ||||
|
Get rules entities for specified ids. | ||||
|
Get rules ids that match the provided filter criteria. | ||||
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.
Get event body for the provided event ID.
get_event_body
| Method | Route |
|---|---|
/ti/events/entities/events-full-body/v2 |
- Produces: application/octet-stream
| Name | Service | Uber | Type | Data type | Description |
|---|---|---|---|---|---|
| id |
|
|
query | string or list of strings | Return the event body for event ID. |
| parameters |
|
|
query | dictionary | Full query string parameters payload in JSON format. |
from falconpy import TailoredIntelligence
falcon = TailoredIntelligence(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
save_file = "some_file.ext"
response = falcon.get_event_body(id="string")
open(save_file, 'wb').write(response)from falconpy import TailoredIntelligence
falcon = TailoredIntelligence(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
save_file = "some_file.ext"
response = falcon.GetEventsBody(id="string")
open(save_file, 'wb').write(response)from falconpy import APIHarnessV2
falcon = APIHarnessV2(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
save_file = "some_file.ext"
response = falcon.command("GetEventsBody", id="string")
open(save_file, 'wb').write(response)Back to Table of Contents
Get events entities for specified ids.
get_event_entities
| Method | Route |
|---|---|
/ti/events/entities/events/GET/v2 |
- Consumes: application/json
- Produces: application/json
| Name | Service | Uber | Type | Data type | Description |
|---|---|---|---|---|---|
| ids |
|
|
body | string or list of strings | Return the event entities for specified ID. |
| body |
|
|
body | dictionary | Full body payload in JSON format. Not required when using the ids keyword. |
from falconpy import TailoredIntelligence
falcon = TailoredIntelligence(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_event_entities(ids=id_list)
print(response)from falconpy import TailoredIntelligence
falcon = TailoredIntelligence(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
id_list = 'ID1,ID2,ID3' # Can also pass a list here: ['ID1', 'ID2', 'ID3']
response = falcon.GetEventsEntities(ids=id_list)
print(response)from falconpy import APIHarnessV2
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("GetEventsEntities", ids=id_list)
print(response)Back to Table of Contents
Get events ids that match the provided filter criteria.
query_events
| Method | Route |
|---|---|
/ti/events/queries/events/v2 |
- Produces: application/json
| Name | Service | Uber | Type | Data type | Description |
|---|---|---|---|---|---|
| filter |
|
|
query | string | FQL query specifying the filter parameters. Wildcard character '*' means to not filter on anything. |
| limit |
|
|
query | integer | The maximum number of IDs to return in this response. Use with the offset parameter to manage pagination of results. |
| offset |
|
|
query | integer | 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 phrase_prefix query criteria |
| sort |
|
|
query | string | Sort results using a FQL formatted string.
|
from falconpy import TailoredIntelligence
falcon = TailoredIntelligence(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
response = falcon.query_events(offset="string",
limit=integer,
sort="string",
filter="string",
q="string"
)
print(response)from falconpy import TailoredIntelligence
falcon = TailoredIntelligence(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
response = falcon.QueryEvents(offset="string",
limit=integer,
sort="string",
filter="string",
q="string"
)
print(response)from falconpy import APIHarnessV2
falcon = APIHarnessV2(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
response = falcon.command("QueryEvents",
offset="string",
limit=integer,
sort="string",
filter="string",
q="string"
)
print(response)Back to Table of Contents
Get rules entities for specified ids.
get_rule_entities
| Method | Route |
|---|---|
/ti/rules/entities/rules/GET/v2 |
- Consumes: application/json
- Produces: application/json
| Name | Service | Uber | Type | Data type | Description |
|---|---|---|---|---|---|
| ids |
|
|
body | string or list of strings | Return the rule entities for specified ID. |
| body |
|
|
body | dictionary | Full body payload in JSON format. Not required when using the ids keyword. |
from falconpy import TailoredIntelligence
falcon = TailoredIntelligence(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_rule_entities(ids=id_list)
print(response)from falconpy import TailoredIntelligence
falcon = TailoredIntelligence(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
id_list = 'ID1,ID2,ID3' # Can also pass a list here: ['ID1', 'ID2', 'ID3']
response = falcon.GetRulesEntities(ids=id_list)
print(response)from falconpy import APIHarnessV2
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("GetRulesEntities", ids=id_list)
print(response)Back to Table of Contents
Get rules ids that match the provided filter criteria.
query_rules
| Method | Route |
|---|---|
/ti/rules/queries/rules/v2 |
- Produces: application/json
| Name | Service | Uber | Type | Data type | Description |
|---|---|---|---|---|---|
| filter |
|
|
query | string | FQL query specifying the filter parameters. Wildcard character '*' means to not filter on anything. |
| limit |
|
|
query | integer | The maximum number of IDs to return in this response. Use with the offset parameter to manage pagination of results. |
| offset |
|
|
query | integer | 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 phrase_prefix query criteria |
| sort |
|
|
query | string | Sort results using a FQL formatted string.
|
from falconpy import TailoredIntelligence
falcon = TailoredIntelligence(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
response = falcon.query_rules(offset="string",
limit=integer,
sort="string",
filter="string",
q="string"
)
print(response)from falconpy import TailoredIntelligence
falcon = TailoredIntelligence(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
response = falcon.QueryRules(offset="string",
limit=integer,
sort="string",
filter="string",
q="string"
)
print(response)from falconpy import APIHarnessV2
falcon = APIHarnessV2(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
response = falcon.command("QueryRules",
offset="string",
limit=integer,
sort="string",
filter="string",
q="string"
)
print(response)Back to Table of Contents
