mirror of
https://github.com/thousandeyes/thousandeyes-sdk-python.git
synced 2025-12-06 07:55:31 +00:00
Some checks failed
Python CI / build (push) Has been cancelled
Co-authored-by: API Team <api-team@thousandeyes.com>
2.8 KiB
2.8 KiB
ApiRequest
Properties
| Name | Type | Description | Notes |
|---|---|---|---|
| assertions | **List[ApiRequestAssertion]** | List of assertion objects. | [optional] |
| auth_type | ApiRequestAuthType | [optional] | |
| bearer_token | str | The bearer token if `authType = bearer-token`. | [optional] |
| body | str | POST/PUT request body. Must be in JSON format. | [optional] |
| client_authentication | ApiClientAuthentication | [optional] | |
| client_id | str | The application ID used when `authType` is set to "oauth2". | [optional] |
| client_secret | str | The private client secret used when `authType` is set to "oauth2". | [optional] |
| collect_api_response | bool | Set to `true` if API response body should be collected and saved. Set to `false` if API response body should not be saved. | [optional] [default to True] |
| headers | **List[ApiRequestHeader]** | Array of API Request Header objects. | [optional] |
| method | ApiRequestMethod | [optional] | |
| name | str | API step name, must be unique. | |
| password | str | The password if `authType = basic`. | [optional] |
| scope | str | Application-specific scope values for the access token when `authType` is "oauth2". | [optional] |
| token_url | str | The endpoint used to request the access token when `authType` is "oauth2". | [optional] |
| url | str | Request url. Supports variables in the format `{{variableName}}`. | |
| username | str | The username if `authType = basic`. | [optional] |
| variables | **List[ApiRequestVariable]** | Array of API post request variable objects. | [optional] |
| wait_time_ms | int | Post request delay before executing the next API requests, in milliseconds. | [optional] |
Example
from thousandeyes_sdk.instant_tests.models.api_request import ApiRequest
# TODO update the JSON string below
json = "{}"
# create an instance of ApiRequest from a JSON string
api_request_instance = ApiRequest.from_json(json)
# print the JSON string representation of the object
print(ApiRequest.to_json())
# convert the object into a dict
api_request_dict = api_request_instance.to_dict()
# create an instance of ApiRequest from a dict
api_request_from_dict = ApiRequest.from_dict(api_request_dict)