Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Perform a DELETE method REST call against an endpoint.

If no body is returned, an empty string will be present in FDR_RESPONSE_STRING.

All response headers are returned as plugin outputs, with the output name being the header name. See Capturing Response Headers in the REST Plugin for details on how to capture headers. (@Since 7.0.0.1)

Inputs

Input Name

Input Code

Required

Description

REST URL

FDR_REQUEST_URL

Yes

URL to the desired REST Service

This input supports FlexDeploy property replacement. i.e. you can use ${{PROP1}} in the input value.

Query String

FDR_QUERY_STRING

No

Query String to be used. Use Groovy if desired to use FlexDeploy variables in the query string.

'a=b&c=d&e='+FD_TEMP_DIR+'&f=g'

or, if not using Groovy, simply

a=b&c=d

Spaces will not be trimmed from the string.

The query string input allows FlexDeploy property replacement to be used

Username

FDR_USER

No

The username for authentication

Password

FDR_PASSWORD

No

The password for authentication

Preemptive Authentication


FDR_PREEMPTIVE_AUTH

No

Use preemptive Basic authentication (provide authentication before being asked)

if false, non-preemptive Universal authentication is used.

Request Media Type

FDR_REQUEST_MEDIA_TYPE

No

The media type to request from the server

Ignore SSL Errors

FDR_IGNORE_SSL_ERRORS

No

 If checked, SSL errors will be ignored. Otherwise they will cause the operation to fail.

Response Action

FDR_RESPONSE_ACTION

Yes

What action should be taken upon completion of this request? Possible options are:

  • ReturnAsOutput - Save the response body and response code to the outputs described below

  • SaveToTemp - Save the response body to a response file in the temp directory. 

    • File name will be 'response.json', 'response.xml', or 'response.txt' depending on the response type.

  • SaveToArtifacts - Save the response body to a response file in the artifacts directory. Be sure to check 'produces artifacts' if intending to save the file to artifacts.

    • File name will be 'response.json', 'response.xml', or 'response.txt' depending on the response type.

Headers

FDR_HEADERS

No

Headers to send with the request. Formatted as key=value. One key/value pair per line.  For example:

  • my-custom-header=abc123

  • x-client-secret=${{FD_CLIENT_SECRET}}

The headers input also allows FlexDeploy property replacement to be used as seen in the x-client-secret header above

Validation Script

FDR_VALIDATION_SCRIPT

No

Groovy validation script to be run against the response body. This input expects a groovy script as plain text, meaning you should not enable the groovy script flag on the plugin input itself. 

Available variables:

  • PAYLOAD - accessed as a Json object or a simple string if the return type is not Json

  • RESPONSE_CODE - integer response code

Returning true indicates that the response was considered successful. False indicates that the response should be considered unsuccessful.

Example script:

PAYLOAD.myField && PAYLOAD.myField.equals('myValue')

Validation Action

FDR_VALIDATION_ACTION

No

What action should be taken if the Groovy Validation Script fails?  Valid options are:

  • JustLog - Simply log the failed result and continue as if successful.

  • GenerateTestResults - Generate a simple test results file. The results will not show up in the test results tab unless this is used in a test workflow

  • FailExecution - Throw an error and fail this plugin execution

Connect Timeout

FDR_CONNECT_TIMEOUT

No

Time to wait to allow a connection to be established. Setting to 0 will wait forever.

Read Timeout

FDR_READ_TIMEOUT

No

Time to wait for a response after establishing a connection. Setting to 0 will wait forever.

...