mirror of
https://github.com/LukeHagar/developer.sailpoint.com.git
synced 2025-12-08 12:27:47 +00:00
update layout for method examples
This commit is contained in:
@@ -53,21 +53,24 @@ Code | Description | Data Type | Response headers |
|
||||
|
||||
```python
|
||||
import sailpoint.beta
|
||||
from sailpoint.beta.api.org_config_api import OrgConfigApi
|
||||
from sailpoint.beta.api_client import ApiClient
|
||||
from sailpoint.beta.models.org_config import OrgConfig
|
||||
from sailpoint.beta.rest import ApiException
|
||||
from pprint import pprint
|
||||
from sailpoint.configuration import Configuration
|
||||
configuration = Configuration()
|
||||
|
||||
with ApiClient(configuration) as api_client:
|
||||
|
||||
try:
|
||||
# Get Org configuration settings
|
||||
|
||||
api_response = api_instance.get_org_config()
|
||||
|
||||
results =OrgConfigApi(api_client).get_org_config()
|
||||
# Below is a request that includes all optional parameters
|
||||
# api_response = api_instance.get_org_config()
|
||||
# results = OrgConfigApi(api_client).get_org_config()
|
||||
print("The response of OrgConfigApi->get_org_config:\n")
|
||||
pprint(api_response)
|
||||
except Exception as e:
|
||||
pprint(results)
|
||||
except Exception as e:
|
||||
print("Exception when calling OrgConfigApi->get_org_config: %s\n" % e)
|
||||
```
|
||||
|
||||
@@ -105,20 +108,23 @@ Code | Description | Data Type | Response headers |
|
||||
|
||||
```python
|
||||
import sailpoint.beta
|
||||
from sailpoint.beta.rest import ApiException
|
||||
from sailpoint.beta.api.org_config_api import OrgConfigApi
|
||||
from sailpoint.beta.api_client import ApiClient
|
||||
from pprint import pprint
|
||||
from sailpoint.configuration import Configuration
|
||||
configuration = Configuration()
|
||||
|
||||
with ApiClient(configuration) as api_client:
|
||||
|
||||
try:
|
||||
# Get list of time zones
|
||||
|
||||
api_response = api_instance.get_valid_time_zones()
|
||||
|
||||
results =OrgConfigApi(api_client).get_valid_time_zones()
|
||||
# Below is a request that includes all optional parameters
|
||||
# api_response = api_instance.get_valid_time_zones()
|
||||
# results = OrgConfigApi(api_client).get_valid_time_zones()
|
||||
print("The response of OrgConfigApi->get_valid_time_zones:\n")
|
||||
pprint(api_response)
|
||||
except Exception as e:
|
||||
pprint(results)
|
||||
except Exception as e:
|
||||
print("Exception when calling OrgConfigApi->get_valid_time_zones: %s\n" % e)
|
||||
```
|
||||
|
||||
@@ -160,11 +166,15 @@ Code | Description | Data Type | Response headers |
|
||||
|
||||
```python
|
||||
import sailpoint.beta
|
||||
from sailpoint.beta.api.org_config_api import OrgConfigApi
|
||||
from sailpoint.beta.api_client import ApiClient
|
||||
from sailpoint.beta.models.json_patch_operation import JsonPatchOperation
|
||||
from sailpoint.beta.models.org_config import OrgConfig
|
||||
from sailpoint.beta.rest import ApiException
|
||||
from pprint import pprint
|
||||
from sailpoint.configuration import Configuration
|
||||
configuration = Configuration()
|
||||
|
||||
with ApiClient(configuration) as api_client:
|
||||
[{op=replace, path=/timeZone, value=America/Toronto}] # List[JsonPatchOperation] | A list of schema attribute update operations according to the [JSON Patch](https://tools.ietf.org/html/rfc6902) standard.
|
||||
json_patch_operation = {
|
||||
"op" : "replace",
|
||||
@@ -175,14 +185,14 @@ from pprint import pprint
|
||||
|
||||
try:
|
||||
# Patch an Org configuration property
|
||||
Result = json_patch_operation.from_json(json_patch_operation)
|
||||
api_response = api_instance.patch_org_config(Result)
|
||||
|
||||
new_json_patch_operation = JsonPatchOperation()
|
||||
new_json_patch_operation.from_json(json_patch_operation)
|
||||
results =OrgConfigApi(api_client).patch_org_config(new_json_patch_operation)
|
||||
# Below is a request that includes all optional parameters
|
||||
# api_response = api_instance.patch_org_config(Result)
|
||||
# results = OrgConfigApi(api_client).patch_org_config(new_json_patch_operation)
|
||||
print("The response of OrgConfigApi->patch_org_config:\n")
|
||||
pprint(api_response)
|
||||
except Exception as e:
|
||||
pprint(results)
|
||||
except Exception as e:
|
||||
print("Exception when calling OrgConfigApi->patch_org_config: %s\n" % e)
|
||||
```
|
||||
|
||||
|
||||
Reference in New Issue
Block a user