Class HttpInterceptor
Provides the ability to intercept requests made by HttpService
Inheritance
System.Object
HttpInterceptor
Implements
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Onbox.Core.V8.Http
Assembly: Onbox.Core.dll
Syntax
public class HttpInterceptor : IHttpInterceptor
Methods
| Improve this Doc View SourceAfterSending(HttpResponseMessage)
Right all responses are processed, this method will be called. You have the ability to modify the response before they are serialized.
You can use this to log incoming messages, process errors and so on.
Declaration
public void AfterSending(HttpResponseMessage response)
Parameters
Type | Name | Description |
---|---|---|
System.Net.Http.HttpResponseMessage | response |
BeforeSending(HttpRequestMessage)
Right before all requests are sent, this method will be called.
You have the ability to modify the request like adding authentication tokens, identification, data modifiers and so on.
Declaration
public void BeforeSending(HttpRequestMessage request)
Parameters
Type | Name | Description |
---|---|---|
System.Net.Http.HttpRequestMessage | request |