:doc:`Batch <../../batch>` / Client / terminate_service_job

*********************
terminate_service_job
*********************



.. py:method:: Batch.Client.terminate_service_job(**kwargs)

  

  Terminates a service job in a job queue.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/batch-2016-08-10/TerminateServiceJob>`_  


  **Request Syntax**
  ::

    response = client.terminate_service_job(
        jobId='string',
        reason='string'
    )
    
  :type jobId: string
  :param jobId: **[REQUIRED]** 

    The service job ID of the service job to terminate.

    

  
  :type reason: string
  :param reason: **[REQUIRED]** 

    A message to attach to the service job that explains the reason for canceling it. This message is returned by ``DescribeServiceJob`` operations on the service job.

    

  
  
  :rtype: dict
  :returns: 
    
    **Response Syntax**

    
    ::

      {}
      
    **Response Structure**

    

    - *(dict) --* 
  
  **Exceptions**
  
  *   :py:class:`Batch.Client.exceptions.ClientException`

  
  *   :py:class:`Batch.Client.exceptions.ServerException`

  