> You are reading the Docusign Developer Documentation. For clean Markdown of any page, append .md to the page URL.
>
> Documentation indexes by section:
> - APIs and SDKs: https://docusign.docs.buildwithfern.com/docs/llms.txt
> - Platform 101: https://docusign.docs.buildwithfern.com/platform/llms.txt
> - Extension Apps: https://docusign.docs.buildwithfern.com/extension-apps/llms.txt
> - Docusign CLI: https://docusign.docs.buildwithfern.com/docusign-cli/llms.txt
>
> Authentication (OAuth, JWT Grant, M2M): https://docusign.docs.buildwithfern.com/platform/auth
> Webhooks and Connect: https://docusign.docs.buildwithfern.com/platform/webhooks
>
> OpenAPI specifications: https://docusign.docs.buildwithfern.com/openapi.json
> MCP server: https://docusign.docs.buildwithfern.com/_mcp/server

# Update request logging settings

PUT https://demo.docusign.net/restapi/v2/diagnostics/settings
Content-Type: application/json

Enables or disables API request logging for troubleshooting.

When enabled (`apiRequestLogging` is set to true), REST API requests and responses for the user are added to a log. A log can have up to 50 requests/responses and the current number of log entries can be determined by getting the settings. Logging is automatically disabled when the log limit of 50 is reached.

You can call [ML:GetRequestLog] or [ML:GetRequestLogs] to download the log files (individually or as a zip file). Call [ML:DeleteRequestLogs] to clear the log by deleting current entries.

Private information, such as passwords and integrator key information, which is normally located in the call header is omitted from the request/response log.

###### Note: API request logging only captures requests from the authenticated user. Any call that does not authenticate the user and resolve a userId isn't logged. Meaning that login_information, NewAccounts, or other distributor-credential calls are not logged.


Reference: https://developers.docusign.com/docs/esign-rest-api/v2/reference/diagnostics/requestlogs/updatesettings

## Authentication

- `Authorization` header (required) — OAuth 2.0 access token (JWT or auth-code grant). Sent as Authorization: Bearer \<token>.

## Servers

- `https://demo.docusign.net/restapi` (Demo, default)
- `https://www.docusign.net/restapi` (Production)

## Request

### Body (application/json)

This endpoint expects a diagnosticsSettingsInformation.

- `apiRequestLogging` (string, optional) — When set to **true**, enables API request logging for the user.
- `apiRequestLogMaxEntries` (string, optional) — Specifies the maximum number of API requests to log.
- `apiRequestLogRemainingEntries` (string, optional) — Indicates the remaining number of API requests that can be logged.

## Response

### 200

Successful response.

- `apiRequestLogging` (string, optional) — When set to **true**, enables API request logging for the user.
- `apiRequestLogMaxEntries` (string, optional) — Specifies the maximum number of API requests to log.
- `apiRequestLogRemainingEntries` (string, optional) — Indicates the remaining number of API requests that can be logged.

## Errors

### 400 Bad Request Error

Error encountered.

- `errorCode` (string, optional) — An error code associated with the error.
- `message` (string, optional) — A short error message.

## Examples

**Request**

```json
{}
```

**Response**

```json
{
  "apiRequestLogging": "string",
  "apiRequestLogMaxEntries": "string",
  "apiRequestLogRemainingEntries": "string"
}
```