Skip to content

Latest commit

 

History

History
282 lines (245 loc) · 5.6 KB

Atc.Rest.Options.md

File metadata and controls

282 lines (245 loc) · 5.6 KB

Atc.Rest.Options


AssemblyPairOptions

public class AssemblyPairOptions

Properties

ApiAssembly

ApiAssembly

DomainAssembly

DomainAssembly

Methods

ToString

string ToString()

AuthorizationOptions

Copy and fill out the AzureAd section into the project User Secrets.

Code usage:

{
"Authorization": {
/*
This will be used to set the Authority on the JWT bearer options
- 'https://login.microsoftonline.com' (For Azure AD)
- 'https://adfs1.some.organization.com' (For on-prem ADFS)
*/
"Instance": "https://login.microsoftonline.com",
"ClientId": "[Application ID of the Azure AD App Registration]",
/*
You need specify the TenantId only if you want to accept access tokens from a single tenant
(line-of-business app).
Otherwise, you can leave them set to common.
This can be:
- A GUID (Tenant ID = Directory ID)
- 'common' (any organization and personal accounts)
- 'organizations' (any organization)
- 'consumers' (Microsoft personal accounts)
- 'adfs' (For on-prem ADFS)
*/
"TenantId": "common",
"Audience": "[App Identifier URI of the Azure AD App Registration]"
"Issuer": "[The token iss claim also specified as the access_token_issuer from the OpenID configuration]"
"ValidAudiences": ["A", "collection", "of", "app", "identifier", "URIs"]
}
}
public class AuthorizationOptions

Static Fields

ConfigurationSectionName

string ConfigurationSectionName

Properties

Audience

Audience

ClientId

ClientId

Instance

Instance

Issuer

Issuer

TenantId

TenantId

ValidAudiences

ValidAudiences

ValidIssuers

ValidIssuers

Methods

IsSecurityEnabled

bool IsSecurityEnabled()

ConfigureApiBehaviorOptions

public class ConfigureApiBehaviorOptions : IConfigureOptions<ApiBehaviorOptions>

Methods

Configure

void Configure(ApiBehaviorOptions options)

RequestResponseLoggerOptions

public class RequestResponseLoggerOptions

Properties

DefaultLogLevel

DefaultLogLevel

Summary: Gets or sets the default log level for the logger.

IncludeRequestHeaderParameters

IncludeRequestHeaderParameters

Summary: Gets or sets a value indicating whether request header parameters should be included in logs.

IncludeRequestQueryParameters

IncludeRequestQueryParameters

Summary: Gets or sets a value indicating whether request query parameters should be included in logs.

IncludeResponseBody

IncludeResponseBody

Summary: Gets or sets a value indicating whether the response body should be logged.

Remarks: Logging the response body can be useful for debugging responses but may increase the size of log files.

IncludeResponseHeaderParameters

IncludeResponseHeaderParameters

Summary: Gets or sets a value indicating whether response header parameters should be included in logs.

SkipSignalrRequests

SkipSignalrRequests

Summary: Gets or sets a value indicating whether SignalR requests should be exempt from logging.

Remarks: Skipping SignalR requests can reduce noise in logs from real-time communications.

SkipSwaggerRequests

SkipSwaggerRequests

Summary: Gets or sets a value indicating whether Swagger requests should be exempt from logging.

Remarks: Skipping Swagger requests can reduce noise in logs from automated or development-time API exploration.

Methods

ToString

string ToString()

RestApiOptions

public class RestApiOptions

Properties

AllowAnonymousAccessForDevelopment

AllowAnonymousAccessForDevelopment

AssemblyPairs

AssemblyPairs

Authorization

Authorization

EnableRequestResponseLogger

EnableRequestResponseLogger

ErrorHandlingExceptionFilter

ErrorHandlingExceptionFilter

JsonSerializerCasingStyle

JsonSerializerCasingStyle

RequestResponseLoggerOptions

RequestResponseLoggerOptions

UseApplicationInsights

UseApplicationInsights

UseAutoRegistrateServices

UseAutoRegistrateServices

UseEnumAsStringInSerialization

UseEnumAsStringInSerialization

UseHttpContextAccessor

UseHttpContextAccessor

UseJsonSerializerOptionsIgnoreNullValues

UseJsonSerializerOptionsIgnoreNullValues

UseRequireHttpsPermanent

UseRequireHttpsPermanent

UseValidateServiceRegistrations

UseValidateServiceRegistrations

Methods

AddAssemblyPairs

void AddAssemblyPairs(Assembly apiAssembly, Assembly domainAssembly)

RestApiOptionsErrorHandlingExceptionFilter

public class RestApiOptionsErrorHandlingExceptionFilter

Properties

Enable

Enable

IncludeExceptionDetails

IncludeExceptionDetails

UseProblemDetailsAsResponseBody

UseProblemDetailsAsResponseBody

Generated by MarkdownCodeDoc version 1.2