Package com.adyen.model.management
Class TestOutput
- java.lang.Object
-
- com.adyen.model.management.TestOutput
-
public class TestOutput extends Object
TestOutput
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classTestOutput.CustomTypeAdapterFactory
-
Field Summary
Fields Modifier and Type Field Description static HashSet<String>openapiFieldsstatic HashSet<String>openapiRequiredFieldsstatic StringSERIALIZED_NAME_MERCHANT_IDstatic StringSERIALIZED_NAME_OUTPUTstatic StringSERIALIZED_NAME_REQUEST_SENTstatic StringSERIALIZED_NAME_RESPONSE_CODEstatic StringSERIALIZED_NAME_RESPONSE_TIMEstatic StringSERIALIZED_NAME_STATUS
-
Constructor Summary
Constructors Constructor Description TestOutput()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object o)static TestOutputfromJson(String jsonString)Create an instance of TestOutput given an JSON stringStringgetMerchantId()Unique identifier of the merchant account that the notification is about.StringgetOutput()The response your server returned for the test webhook.StringgetRequestSent()The [body of the notification webhook](https://docs.adyen.com/development-resources/webhooks/understand-notifications#notification-structure) that was sent to your server.StringgetResponseCode()The HTTP response code for your server's response to the test webhook.StringgetResponseTime()The time between sending the test webhook and receiving the response from your server.StringgetStatus()The status of the test request.inthashCode()TestOutputmerchantId(String merchantId)TestOutputoutput(String output)TestOutputrequestSent(String requestSent)TestOutputresponseCode(String responseCode)TestOutputresponseTime(String responseTime)voidsetMerchantId(String merchantId)voidsetOutput(String output)voidsetRequestSent(String requestSent)voidsetResponseCode(String responseCode)voidsetResponseTime(String responseTime)voidsetStatus(String status)TestOutputstatus(String status)StringtoJson()Convert an instance of TestOutput to an JSON stringStringtoString()static voidvalidateJsonObject(com.google.gson.JsonObject jsonObj)Validates the JSON Object and throws an exception if issues found
-
-
-
Field Detail
-
SERIALIZED_NAME_MERCHANT_ID
public static final String SERIALIZED_NAME_MERCHANT_ID
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_OUTPUT
public static final String SERIALIZED_NAME_OUTPUT
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_REQUEST_SENT
public static final String SERIALIZED_NAME_REQUEST_SENT
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_RESPONSE_CODE
public static final String SERIALIZED_NAME_RESPONSE_CODE
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_RESPONSE_TIME
public static final String SERIALIZED_NAME_RESPONSE_TIME
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_STATUS
public static final String SERIALIZED_NAME_STATUS
- See Also:
- Constant Field Values
-
-
Method Detail
-
merchantId
public TestOutput merchantId(String merchantId)
-
getMerchantId
public String getMerchantId()
Unique identifier of the merchant account that the notification is about.- Returns:
- merchantId
-
setMerchantId
public void setMerchantId(String merchantId)
-
output
public TestOutput output(String output)
-
getOutput
public String getOutput()
The response your server returned for the test webhook. Your server must respond with **[accepted]** for the test webhook to be successful (`data.status`: **success**). Find out more about [accepting notifications](https://docs.adyen.com/development-resources/webhooks#accept-notifications) You can use the value of this field together with the [`responseCode`](https://docs.adyen.com/api-explorer/#/ManagementService/v1/post/merchants/{merchantId}/webhooks/{id}/test__resParam_data-responseCode) value to troubleshoot unsuccessful test webhooks.- Returns:
- output
-
setOutput
public void setOutput(String output)
-
requestSent
public TestOutput requestSent(String requestSent)
-
getRequestSent
public String getRequestSent()
The [body of the notification webhook](https://docs.adyen.com/development-resources/webhooks/understand-notifications#notification-structure) that was sent to your server.- Returns:
- requestSent
-
setRequestSent
public void setRequestSent(String requestSent)
-
responseCode
public TestOutput responseCode(String responseCode)
-
getResponseCode
public String getResponseCode()
The HTTP response code for your server's response to the test webhook. You can use the value of this field together with the the [`output`](https://docs.adyen.com/api-explorer/#/ManagementService/v1/post/merchants/{merchantId}/webhooks/{id}/test__resParam_data-output) field value to troubleshoot failed test webhooks.- Returns:
- responseCode
-
setResponseCode
public void setResponseCode(String responseCode)
-
responseTime
public TestOutput responseTime(String responseTime)
-
getResponseTime
public String getResponseTime()
The time between sending the test webhook and receiving the response from your server. You can use it as an indication of how long your server takes to process a webhook notification. Measured in milliseconds, for example **304 ms**.- Returns:
- responseTime
-
setResponseTime
public void setResponseTime(String responseTime)
-
status
public TestOutput status(String status)
-
getStatus
public String getStatus()
The status of the test request. Possible values are: * **success**, if `data.output`: **[accepted]** and `data.responseCode`: **200**. * **failed**, in all other cases. You can use the value of the [`output`](https://docs.adyen.com/api-explorer/#/ManagementService/v1/post/merchants/{merchantId}/webhooks/{id}/test__resParam_data-output) field together with the [`responseCode`](https://docs.adyen.com/api-explorer/#/ManagementService/v1/post/merchants/{merchantId}/webhooks/{id}/test__resParam_data-responseCode) value to troubleshoot failed test webhooks.- Returns:
- status
-
setStatus
public void setStatus(String status)
-
validateJsonObject
public static void validateJsonObject(com.google.gson.JsonObject jsonObj) throws IOExceptionValidates the JSON Object and throws an exception if issues found- Parameters:
jsonObj- JSON Object- Throws:
IOException- if the JSON Object is invalid with respect to TestOutput
-
fromJson
public static TestOutput fromJson(String jsonString) throws IOException
Create an instance of TestOutput given an JSON string- Parameters:
jsonString- JSON string- Returns:
- An instance of TestOutput
- Throws:
IOException- if the JSON string is invalid with respect to TestOutput
-
toJson
public String toJson()
Convert an instance of TestOutput to an JSON string- Returns:
- JSON string
-
-