Package com.onfido.models
Class Webhook.Request
- java.lang.Object
-
- com.onfido.models.Webhook.Request
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Webhook.Requestenabled(Boolean enabled)Determines if the webhook should be active.Webhook.Requestenvironment(String... environment)The environment to be usedWebhook.Requestenvironment(List<String> environment)The environment to be usedWebhook.Requestevents(String... events)The events that should be published to the webhook.Webhook.Requestevents(List<String> events)The events that should be published to the webhook.BooleangetEnabled()Determines if the webhook should be active.String[]getEnvironment()The environment to be usedString[]getEvents()The events that should be published to the webhook.StringgetUrl()The url to listen to notifications (must be HTTPS)StringtoJson()StringtoString()Webhook.Requesturl(String url)The url to listen to notifications (must be HTTPS)
-
-
-
Method Detail
-
toJson
public String toJson()
-
url
public Webhook.Request url(String url)
The url to listen to notifications (must be HTTPS)- Parameters:
url- The url to listen to notifications (must be HTTPS)- Returns:
- The Webhook request object.
-
enabled
public Webhook.Request enabled(Boolean enabled)
Determines if the webhook should be active. If omitted, will be set to true by default- Parameters:
enabled- Determines if the webhook should be active. If omitted, will be set to true by default- Returns:
- The Webhook request object.
-
events
public Webhook.Request events(List<String> events)
The events that should be published to the webhook. If omitted, all events will be subscribed by default. You can read about the supported events- Parameters:
events- The events that should be published to the webhook. If omitted, all events will be subscribed by default. You can read about the supported events- Returns:
- The Webhook request object.
-
events
public Webhook.Request events(String... events)
The events that should be published to the webhook. If omitted, all events will be subscribed by default. You can read about the supported events- Parameters:
events- The events that should be published to the webhook. If omitted, all events will be subscribed by default. You can read about the supported events- Returns:
- The Webhook request object
-
environment
public Webhook.Request environment(List<String> environment)
The environment to be used- Parameters:
environment- The environment to be used- Returns:
- The Webhook request object.
-
environment
public Webhook.Request environment(String... environment)
The environment to be used- Parameters:
environment- The environment to be used- Returns:
- The Webhook request object
-
getUrl
public String getUrl()
The url to listen to notifications (must be HTTPS)- Returns:
- The url to listen to notifications (must be HTTPS)
-
getEnabled
public Boolean getEnabled()
Determines if the webhook should be active. If omitted, will be set to true by default- Returns:
- Determines if the webhook should be active. If omitted, will be set to true by default
-
getEvents
public String[] getEvents()
The events that should be published to the webhook. If omitted, all events will be subscribed by default. You can read about the supported events- Returns:
- The events that should be published to the webhook. If omitted, all events will be subscribed by default. You can read about the supported events
-
getEnvironment
public String[] getEnvironment()
The environment to be used- Returns:
- The environment to be used
-
-