Skip to main content
FoveusOptions controls how the Foveus SDK identifies your service, captures telemetry, sends data, protects sensitive values, and tunes performance. Most applications should configure these options from appsettings.json.
Then add a Foveus section to your configuration.
You do not need to construct FoveusOptions manually for most services.

Core options

API key

ApiKey is required.
Test keys are created automatically during onboarding. Live keys are created manually from Settings.

ServiceName

ServiceName identifies the service producing telemetry. If you do not set it, Foveus uses your project assembly name.
Override this when your assembly name is not the name your team wants to see in Foveus.

Environment

Environment describes where your service is running. If you do not set it, Foveus uses the current app environment.

Mode

Mode controls the Foveus data boundary. Foveus defaults to Test mode. Set Mode only when sending live telemetry.
Use a live key with Live mode. Do not use a live key in local development.

Capture profiles

CaptureProfile lets you quickly tune capture behavior. Example:
Use Debug carefully. It can capture more context than you usually want in production.

Transport options

Transport options control how the SDK batches and sends telemetry to Foveus. Example:

Data capture options

Data capture options control what context the SDK captures. Example:

Request body capture

Request body capture helps you understand what the client sent.
Request body capture is useful for debugging API behavior, but you should still avoid sending sensitive data.

Response body capture

Response body capture helps you inspect business outcomes and provider responses.
Response bodies often contain sensitive data. Enable this intentionally and review redaction settings first.

Context sampling

ContextSamplingRate controls how often successful context snapshots are captured.
A value of 0.01 means 1%. Increase it when debugging. Lower it for high-volume services.

Path filtering

Use path filters to reduce noise.
Use this for endpoints such as:
Use IncludedPathPrefixes when you want allow-list behavior.

Privacy options

Privacy options control what Foveus masks or avoids storing. Example:
Redaction is a safety layer, not a reason to intentionally send secrets. Avoid capturing sensitive data whenever possible.

Performance options

Performance options help tune the SDK for high-volume services. Example:
Use HighThroughput profile for busy services where low overhead matters.

Debugging options

Debugging options help you troubleshoot SDK behavior. Example:
Use debug logging temporarily. Turn it off when you are done troubleshooting.

Outcome semantics options

Outcome semantics help Foveus understand whether an execution succeeded, failed, or returned a business-level failure. Use outcome semantics when HTTP status alone is not enough. For example, a provider may return HTTP 200 with a response body that means the operation failed. Outcome semantics can help Foveus classify that execution correctly.

Local development

Normal production service

High-volume service

Sensitive API

Options-based configuration

You can also configure Foveus directly in code.
Use this when configuration values are computed in code. For most services, prefer appsettings.json or environment variables.

Troubleshooting

I changed an option but behavior did not change

Check that:
  • the Foveus section is correctly named
  • the app is loading the expected configuration file
  • environment variables are not overriding your values
  • the service was restarted after config changes
  • the option name matches the SDK property name

Response body context is missing

Check that:
  • CaptureResponseBodies is enabled
  • the response body size is within MaxBodyCaptureSizeBytes
  • the response content type is supported
  • the path is not excluded
  • sampling did not skip the context snapshot
  • redaction did not remove the value

Too much telemetry is being sent

Use one or more of:
  • CaptureProfile: "HighThroughput"
  • lower ContextSamplingRate
  • ExcludedPathPrefixes
  • CaptureRequestBodies: false
  • CaptureResponseBodies: false

Next steps