The channel policy to delete.
Parameters:
-
channel_name
(__string)
–
The name of the channel associated with this channel policy.
Raises:
Source code in docs_src/capo_mediatailor/_services/media_tailor.py
| def delete_channel_policy(
self,
channel_name: "capo_mediatailor.types.__string.__string",
*,
config_overrides: Optional[MediaTailorClientConfig] = None,
) -> "capo_mediatailor.types.delete_channel_policy_response.DeleteChannelPolicyResponse":
"""<p>The channel policy to delete.</p>
Args:
channel_name: <p>The name of the channel associated with this channel policy.</p>
Raises:
capo_mediatailor.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
def _handler(
req: "OperationRequest[capo_mediatailor.types.delete_channel_policy_request.DeleteChannelPolicyRequest]",
) -> OperationResponse[
"capo_mediatailor.types.delete_channel_policy_response.DeleteChannelPolicyResponse"
]:
import capo_mediatailor._operations.media_tailor.delete_channel_policy
output, http_response = (
capo_mediatailor._operations.media_tailor.delete_channel_policy.delete_channel_policy(
req.options, req.input
)
)
return OperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("DeleteChannelPolicy")
)
input_: capo_mediatailor.types.delete_channel_policy_request.DeleteChannelPolicyRequest = {
"channel_name": channel_name
}
response = execute_pipeline(
OperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
response.response.close()
return response.output
|