Interface IServiceOAuthAuthenticatorEndpoint
Namespace: Terrasoft.Core.ServiceModel
Assembly: Terrasoft.Core.ServiceModel.dll
Syntax
[CoreServiceRoute("/ServiceModel/")]
[CoreServiceRoute("/0/ServiceModel/")]
[ServiceContract(Name = "ServiceOAuthAuthenticatorEndpoint", Namespace = "http://Terrasoft.WebApp.ServiceModel")]
public interface IServiceOAuthAuthenticatorEndpoint
Methods
AuthorizationCodeRedirectHandler(String, String)
Handle and process authorization code.
Declaration
[OperationContract]
[WebGet(UriTemplate = "AuthorizationCodeRedirectHandler?state={state}&code={code}", ResponseFormat = WebMessageFormat.Json)]
Task AuthorizationCodeRedirectHandler(string code, string state)
Parameters
Type | Name | Description |
---|---|---|
System.String | code | |
System.String | state |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task |
GetAuthorizationGrantUrl(String)
Returns authorization grant url.
Declaration
[OperationContract]
[WebGet(UriTemplate = "GetAuthorizationGrantUrl/{appId}", ResponseFormat = WebMessageFormat.Json)]
string GetAuthorizationGrantUrl(string appId)
Parameters
Type | Name | Description |
---|---|---|
System.String | appId | Application id. |
Returns
Type | Description |
---|---|
System.String | Authorization grant url. |
GetOAuthClientSecret(String)
Returns OAuth client secret key.
Declaration
[OperationContract]
[WebGet(UriTemplate = "GetOAuthClientSecret/{appId}", ResponseFormat = WebMessageFormat.Json)]
string GetOAuthClientSecret(string appId)
Parameters
Type | Name | Description |
---|---|---|
System.String | appId | Application id. |
Returns
Type | Description |
---|---|
System.String | Client secret key. |
RemoveOAuthApplication(String)
Removes OAuth application.
Declaration
[OperationContract]
[WebInvoke(Method = "POST", UriTemplate = "RemoveOAuthApplication/{applicationId}", BodyStyle = WebMessageBodyStyle.Bare, ResponseFormat = WebMessageFormat.Json)]
void RemoveOAuthApplication(string applicationId)
Parameters
Type | Name | Description |
---|---|---|
System.String | applicationId | Application id. |
RemoveOAuthUser(RemoveOAuthAppUserService)
Removes token by OAuthAppUser.
Data contract.Declaration
[OperationContract]
[WebInvoke(Method = "POST", UriTemplate = "RemoveOAuthUser", BodyStyle = WebMessageBodyStyle.Bare, ResponseFormat = WebMessageFormat.Json)]
Task RemoveOAuthUser(RemoveOAuthAppUserService contract)
Parameters
Type | Name | Description |
---|---|---|
RemoveOAuthAppUserService | contract |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task |