public class CMAWebhook extends CMAResource
setName(String), setUrl(String),
addTopic(CMAWebhookTopic).| Constructor and Description |
|---|
CMAWebhook() |
| Modifier and Type | Method and Description |
|---|---|
CMAWebhook |
addHeader(String key,
String value)
Adds a custom http header to the call done by this webhook.
|
CMAWebhook |
addTopic(CMAWebhookTopic topic)
Add a topic this webhook should be triggered on.
|
List<CMAWebhookHeader> |
getHeaders() |
String |
getName() |
List<CMAWebhookTopic> |
getTopics() |
String |
getUrl() |
String |
getUser() |
CMAWebhook |
setBasicAuthorization(String user,
String password)
Set authorization parameter for basic HTTP authorization on the url to be called by this
webhook.
|
CMAWebhook |
setName(String name)
Set the name of this webhook.
|
CMAWebhook |
setUrl(String url)
Sets the url to be called when this webhook is triggered.
|
getResourceId, getSpaceId, getSys, getVersion, setId, setSyspublic CMAWebhook setName(String name)
name - to identify this webhookpublic CMAWebhook setUrl(String url)
url - complete, existing url to be usedpublic CMAWebhook addTopic(CMAWebhookTopic topic)
topic - a valid enum value for the trigger reason.public CMAWebhook addHeader(String key, String value)
key - HTTP header key to be used (aka 'X-My-Header-Name')value - HTTP header value to be used (aka 'this-is-my-name')public CMAWebhook setBasicAuthorization(String user, String password)
user - username to be usedpassword - password to be used (cannot be retrieved, only updated!)public String getName()
public String getUrl()
public List<CMAWebhookTopic> getTopics()
public List<CMAWebhookHeader> getHeaders()
public String getUser()
Copyright © 2016 Contentful, GmbH.. All Rights Reserved.