C# Class Microsoft.AspNet.WebHooks.WebHookReceiverConfig

Provides a default IWebHookReceiverConfig implementation which manages IWebHookReceiver configuration using application settings. The name of the application setting is 'MS_WebHookReceiverSecret_<name>' where 'name' is the name of the receiver, for example github. The value is a comma-separated list of secrets, using an ID to differentiate between them. For example, 'secret0, id1=secret1, id2=secret2'. The corresponding WebHook URI is of the form 'https://<host>/api/webhooks/incoming/custom/{id}'.
Inheritance: IWebHookReceiverConfig
Exibir arquivo Open project: aspnet/WebHooks Class Usage Examples

Public Methods

Method Description
GetReceiverConfigAsync ( string name, string id ) : Task
WebHookReceiverConfig ( SettingsDictionary settings, ILogger logger ) : System

Initializes a new instance of the WebHookReceiverConfig which will use the application settings set in the given settings.

Private Methods

Method Description
AddKey ( string>.IDictionary config, ILogger logger, string receiver, string id, string value ) : void
GetConfigKey ( string receiver, string id ) : string
ReadSettings ( SettingsDictionary settings, ILogger logger ) : string>.IDictionary

Method Details

GetReceiverConfigAsync() public method

public GetReceiverConfigAsync ( string name, string id ) : Task
name string
id string
return Task

WebHookReceiverConfig() public method

Initializes a new instance of the WebHookReceiverConfig which will use the application settings set in the given settings.
public WebHookReceiverConfig ( SettingsDictionary settings, ILogger logger ) : System
settings SettingsDictionary The to use for reading configuration.
logger ILogger The to use.
return System