/// <summary>
        /// Stops the canary to prevent all future runs. If the canary is currently running, Synthetics
        /// stops waiting for the current run of the specified canary to complete. The run that
        /// is in progress completes on its own, publishes metrics, and uploads artifacts, but
        /// it is not recorded in Synthetics as a completed run.
        ///
        ///
        /// <para>
        /// You can use <code>StartCanary</code> to start it running again with the canary’s current
        /// schedule at any point in the future.
        /// </para>
        /// </summary>
        /// <param name="request">Container for the necessary parameters to execute the StopCanary service method.</param>
        /// <param name="cancellationToken">
        ///     A cancellation token that can be used by other objects or threads to receive notice of cancellation.
        /// </param>
        ///
        /// <returns>The response from the StopCanary service method, as returned by Synthetics.</returns>
        /// <exception cref="Amazon.Synthetics.Model.ConflictException">
        /// A conflicting operation is already in progress.
        /// </exception>
        /// <exception cref="Amazon.Synthetics.Model.InternalServerException">
        /// An unknown internal error occurred.
        /// </exception>
        /// <exception cref="Amazon.Synthetics.Model.ResourceNotFoundException">
        /// One of the specified resources was not found.
        /// </exception>
        /// <exception cref="Amazon.Synthetics.Model.ValidationException">
        /// A parameter could not be validated.
        /// </exception>
        /// <seealso href="http://docs.aws.amazon.com/goto/WebAPI/synthetics-2017-10-11/StopCanary">REST API Reference for StopCanary Operation</seealso>
        public virtual Task <StopCanaryResponse> StopCanaryAsync(StopCanaryRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken))
        {
            var options = new InvokeOptions();

            options.RequestMarshaller    = StopCanaryRequestMarshaller.Instance;
            options.ResponseUnmarshaller = StopCanaryResponseUnmarshaller.Instance;

            return(InvokeAsync <StopCanaryResponse>(request, options, cancellationToken));
        }
        internal virtual StopCanaryResponse StopCanary(StopCanaryRequest request)
        {
            var options = new InvokeOptions();

            options.RequestMarshaller    = StopCanaryRequestMarshaller.Instance;
            options.ResponseUnmarshaller = StopCanaryResponseUnmarshaller.Instance;

            return(Invoke <StopCanaryResponse>(request, options));
        }