1
---
2
-title: "Automatic Credential Masking for Composio-Managed Connections"
3
-description: "Access and refresh tokens for connections on Composio-managed auth configs are now always masked in API responses, regardless of project-level masking. Connections on your own auth config are unchanged."
4
-date: "2026-04-21"
2
+title: "Credential Redaction for Composio-Managed Auth Configs and Connections"
3
+description: "Composio-managed auth configs and their connections now redact sensitive fields in API responses. Customer-owned auth configs continue to mask secrets; previously plaintext client_secret and developer_token values are now masked as well."
4
+date: "2026-04-22"
5
---
6
7
-For connections created through a Composio-managed auth config, access tokens, refresh tokens, and the `Authorization` header are now always masked in `connected-accounts` API responses — regardless of your project's `mask_secret_keys_in_connected_account` setting.
7
+Two related security changes are rolling out together:
8
+
9
+1. **Connections on Composio-managed auth configs** now always redact `access_token`, `refresh_token`, and the `Authorization` header in `connected-accounts` responses — independent of your project's `mask_secret_keys_in_connected_account` flag.
10
+2. **Auth-config GET responses** now redact (for Composio-managed) or mask (for customer-owned) every sensitive credential field — including `client_secret` and `developer_token`, which were previously returned in plaintext under some paths.
11
+
12
+Auth-config credential redaction is **not controlled by `mask_secret_keys_in_connected_account`**. That flag only applies to runtime connected-account credentials (access tokens, refresh tokens, and the like). Auth-config credentials are developer-owned static fields — `client_id`, `client_secret`, `developer_token`, etc. — and are always redacted or masked regardless of the project flag.
13
14
**Most integrations need no changes.**
15
11
-- Tool execution through the SDK, Tool Router, and MCP is unchanged. Composio handles authentication server-side, so your agents never needed to read these tokens directly.
12
-- Connections on your own auth config are unchanged. Token visibility continues to follow your project's masking setting.
16
+- Tool execution through the SDK, Tool Router, and MCP is unchanged. Composio uses the unredacted values server-side.
17
+- Connections on customer-owned auth configs continue to follow your project's `mask_secret_keys_in_connected_account` setting for runtime tokens.
18
19
### What is a Composio-managed auth config?
20
16
-When you connect a user through a toolkit's default integration — for example, Gmail or Slack without registering your own OAuth application — the connection runs through an OAuth application that Composio owns and operates on behalf of every team using that default. The access and refresh tokens the provider issues are bound to Composio's shared OAuth client.
21
+When you connect a user through a toolkit's default integration — for example, Gmail or Slack without registering your own OAuth application — Composio uses an OAuth application it owns and shares across every team on that default. Tokens the provider issues are bound to that shared Composio-owned client.
22
18
-You can identify a Composio-managed connection by the `auth_config.is_composio_managed: true` field on the connected-account resource.
19
-
20
-### Why this change
23
+You can identify a Composio-managed auth config or connection by `is_composio_managed: true` on the auth-config or connected-account resource.
24
22
-A single OAuth application backs every team on a default integration, and the tokens we return are bound to it. If a provider throttles, restricts, or suspends that app in response to misuse of one of its tokens, the integration becomes unavailable for every team on the default at once. Masking the tokens keeps that exposure out of API responses; Composio still uses them server-side, so tool execution is unchanged.
25
+### 1. Connected-account tokens
26
24
-### Example
27
+Access tokens, refresh tokens, and all header and query-parameter values are now replaced with the literal string `"REDACTED"` for Composio-managed connections. No prefix, no suffix — nothing that reveals the underlying value.
28
26
-Before, with project masking disabled on a Composio-managed Gmail connection:
29
+Before, with `mask_secret_keys_in_connected_account: false` on a Composio-managed Gmail connection:
30
31
```json
32
{
35
"access_token": "ya29.a0ARrdaM9...full token...",
36
"refresh_token": "1//04...full token..."
37
}
38
+ },
39
+ "data": {
40
+ "headers": {
41
+ "Authorization": "Bearer ya29.a0ARrdaM9...full token..."
42
+ }
43
}
44
}
45
```
50
{
51
"state": {
52
"val": {
45
- "access_token": "ya29...",
46
- "refresh_token": "1//0..."
53
+ "access_token": "REDACTED",
54
+ "refresh_token": "REDACTED"
55
+ }
56
+ },
57
+ "data": {
58
+ "headers": {
59
+ "Authorization": "REDACTED"
60
}
61
}
62
}
63
```
64
52
-The same applies to `data`, `params`, and `headers.Authorization` wherever these values would otherwise appear.
65
+Connections on customer-owned auth configs are unaffected — token visibility follows your existing `mask_secret_keys_in_connected_account` setting (`xxxx...` truncation when enabled, raw passthrough when disabled).
66
+
67
+### 2. Auth-config credentials
68
+
69
+`GET /api/v3/auth_configs` and `GET /api/v3/auth_configs/{id}` now redact or mask every sensitive credential field.
70
+
71
+**Composio-managed auth configs** — every field below is replaced with `"REDACTED"`:
72
+
73
+- `client_id`, `client_secret`, `consumer_key`, `consumer_secret`, `code_verifier`
74
+- `bot_token`, `bearer_token`, `verification_token`, `generic_id`, `developer_token`
75
+
76
+**Customer-owned auth configs** — `client_id` and `consumer_key` still pass through in full (you own them and need them to debug OAuth flows). The following fields are now masked as `<first-4>...<last-4>`:
77
+
78
+- `client_secret`, `consumer_secret`, `code_verifier`
79
+- `bot_token`, `bearer_token`, `verification_token`, `generic_id`, `developer_token`
80
+
81
+Values shorter than 8 characters collapse to `"REDACTED"` to avoid partial leaks.
82
+
83
+**Previously returned in plaintext:**
84
+
85
+- `client_secret` on customer-owned auth configs.
86
+- `developer_token` (Google Ads) and other default-scheme fields (`bot_token`, `bearer_token`, `verification_token`, `generic_id`) on Composio-managed auth configs.
87
+
88
+If you were reading these values out of the GET response, switch to storing them alongside the code that uploaded them (see the migration section below).
89
+
90
+### Why this change
91
+
92
+A single OAuth application backs every team on a Composio-managed default integration, and the tokens and client secrets bound to it are shared. If a provider throttles, restricts, or suspends that app in response to misuse of one of its credentials, the integration becomes unavailable for every team on the default at once. Redacting the values keeps them out of API responses; Composio still uses them server-side, so tool execution is unchanged.
93
+
94
+For customer-owned auth configs, masking a freshly re-read `client_secret` or `developer_token` limits the blast radius of a compromised project API key without breaking your ability to identify which credential was uploaded.
95
96
### Affected endpoints
97
98
+Connected accounts:
99
+
100
- [`GET /api/v3/connected_accounts/{id}`](/reference/api-reference/connected-accounts/getConnectedAccountsByNanoid)
101
- [`GET /api/v3/connected_accounts`](/reference/api-reference/connected-accounts/getConnectedAccounts)
102
- [`POST /api/v3/connected_accounts`](/reference/api-reference/connected-accounts/postConnectedAccounts)
103
+- Webhook payloads that include connection credentials
104
+
105
+Auth configs:
106
+
107
+- [`GET /api/v3/auth_configs/{id}`](/reference/api-reference/auth-configs/getAuthConfigsByNanoid)
108
+- [`GET /api/v3/auth_configs`](/reference/api-reference/auth-configs/getAuthConfigs)
109
60
-### If you need raw tokens
110
+### If you need raw values
111
62
-To keep reading `access_token` or `refresh_token` from API responses, connect through your own auth config. Tokens issued against an OAuth application you own are returned in full (subject to your project's masking setting).
112
+**Connected-account tokens.** Connect through a customer-owned auth config, and optionally set `mask_secret_keys_in_connected_account: false` on your project.
113
114
1. Register an OAuth application with the provider — for Gmail, start in the [Google Cloud Console](https://console.cloud.google.com/apis/credentials).
115
2. [Create a custom auth config](/reference/api-reference/auth-configs/postAuthConfigs) using those credentials.
116
3. Create new connections against that auth config.
117
+
118
+**Auth-config secrets** (`client_secret`, `developer_token`, etc.). Keep these alongside the code that created the auth config — for example, in your own secret manager at upload time. The auth-config GET endpoints will only return masked or redacted values going forward.
119
+
120
+**Temporary per-project exception.** If this change blocks an active production integration and you cannot complete the migration above immediately, contact support. We can toggle off forced redaction for Composio-managed connections on your project for a limited migration window, after which the project reverts to the default redacted behavior.
121
+
122
+<Callout type="info">
123
+If your integration relies on reading `access_token`, `refresh_token`, `client_secret`, or `developer_token` from Composio API responses, you will need to act. All other integrations continue to work as before.
124
+</Callout>