Skip to main content
Skip table of contents

Method deleteFaxReports

This method is used to delete multiple fax job’s report data. The length of time report data can be stored in the Retarus infrastructure can be individually configured for each time the Webservice is accessed. The default value is 3 days. Once this period elapses, the report data is automatically deleted.

If you sent the fax job requests via a high availability URL, you have to send a delete request to both included data centers. Else, it will be likely that the job was not processed in the data center you referenced and hence cannot be deleted there. Please do not send a delete request directly to an HA URL but use the specific ones for the data centers.

Input parameter: DeleteReportsRequest

Output parameter: DeleteReportsResponse

DeleteReportsRequest

Field name

Data type

Required

Multiple possible

jobId

String

Yes

Yes

jobId
Job ID for the job whose report is to be deleted

DeleteReportsResponse

Field name

Data type

Required

Multiple possible

jobId

String

Yes

No

deleted

Boolean

Yes

No

reason

String

No

No

jobId
Job ID for which the deletion of report data has been requested

deleted
true is displayed when the deletion has successfully occurred, otherwise false is displayed

reason
Missing if deletion was successful, otherwise one of the following reason messages is returned:

  • NOT_FOUND: No report exists for the given job id.

  • INTERNAL_ERROR: Unspecified server-side error.

Java Sample Code

JAVA
DeleteReportsRequest deleteReportsRequest = this.objectFactory.createDeleteReportsRequest();

// Authentication:
deleteReportsRequest.setUsername(_USERNAME_);
deleteReportsRequest.setPassword(_PASSWORD_);

// Specify jobs:
List<String> jobIdList = deleteReportsRequest.getJobId();
for (String jobId : requestedJobIds) {
    jobIdList.add(jobId)
}

// Fire request:
DeleteReportsResponse deleteReportsResponse = this.servicePort.deleteFaxReports(deleteReportsRequest);

for (DeleteReportResponseEx deleteReportResponse : deleteReportsResponse.getDeletedReports()) {
    if (deleteReportResponse.isDeleted()) {
        log.info("Succeeded in deleting report for job id " + deleteReportResponse.getJobId() + ".")
    } else {
        log.warn("Failed to delete report for job id " + deleteReportResponse.getJobId() + ". Reason: " + deleteReportResponse.getReason())
    }
}

Request XML

XML
<ns2:DeleteReportsRequest xmlns:ns2="http://retarus.com/fax4ba/faxws/3/0">
	<username>faxws@example.com</username>
	<password>faxws</password>
	<jobId>FJHAL0RNBW0AZ82ZX5FCET</jobId>
</ns2:DeleteReportsRequest>

Response XML

XML
<ns2:DeleteReportsResponse xmlns:ns2="http://retarus.com/fax4ba/faxws/3/0">
  <deletedReports>
    <jobId>FJJNK48UL80F3IPAU5V5L0</jobId>
    <deleted>true</deleted>
  </deletedReports>
  <deletedReports>
    <jobId>FJJNK48UMN0F3IPAU5C3J2</jobId>
    <deleted>false</deleted>
    <reason>NOT_FOUND</reason>
  </deletedReports>
</ns2:DeleteReportsResponse>

Exceptions

TemporaryFailure
appears when the request currently cannot be processed due to an internal Webservice error.

WrongUserPassword
appears when the request contains invalid authentication data.

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.