different base_url #139
-
In _service_class.py, class ServiceClass has hardcoded base_url: str = "https://api.crowdstrike.com" in the constructor object; but should happen that some tennant has https://api.us-2.crowdstrike.com. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
The following init function definition defines the default base_url value (which is https://api.crowdstrike.com) when an instance of a Service Class is created. def __init__(self: object, access_token: str = None, auth_object: object = None, creds: dict = None,
base_url: str = "https://api.crowdstrike.com", ssl_verify: bool = True) -> object: This is to allow users to create an instance of a Service Class without having to specify a base_url value. from falconpy.cloud_connect_aws import Cloud_Connect_AWS as FalconAWS
falcon = FalconAWS(creds={"client_id": client_id,
"client_secret": client_secret})
result = falcon.QueryAWSAccounts() In order to specify a different base_url, you will need to pass that value when you create the instance of the class. from falconpy.cloud_connect_aws import Cloud_Connect_AWS as FalconAWS
falcon = FalconAWS(creds={"client_id": client_id,
"client_secret": client_secret
},
base_url="https://api.us-2.crowdstrike.com")
result = falcon.QueryAWSAccounts() Are you having issues when creating an instance of a Service Class using a different base_url value? |
Beta Was this translation helpful? Give feedback.
-
Nice! Thx! |
Beta Was this translation helpful? Give feedback.
The following init function definition defines the default base_url value (which is https://api.crowdstrike.com) when an instance of a Service Class is created.
This is to allow users to create an instance of a Service Class without having to specify a base_url value.
In order to spec…