Patch Connection
Partial update of a connection resource. Only provided fields will be updated.
Path Parameters
The name or ID of the resource
Body
The request body resource with fields to update
Toggle Port Forwarding
- enabled - Enable to perform port forwarding for this connection
- disabled - Disable port forwarding for this connection
enabled, disabled Toggle Ad Hoc Executions
- enabled - Enable to run ad-hoc executions for this connection
- disabled - Disable ad-hoc executions for this connection
enabled, disabled Toggle Ad Hoc Runbooks Executions
- enabled - Enable to run runbooks for this connection
- disabled - Disable runbooks execution for this connection
enabled, disabled Toggle Introspection Schema
- enabled - Enable the instrospection schema in the webapp
- disabled - Disable the instrospection schema in the webapp
enabled, disabled The agent associated with this connection
"1837453e-01fc-46f3-9e4c-dcf22d395393"
Attributes associated with this connection
Is the shell command that is going to be executed when interacting with this connection. This value is required if the connection is going to be used from the Webapp.
Tags to identify the connection
- keys must contain between 1 and 64 alphanumeric characters, it may include (-), (_), (/), or (.) characters and it must not end with (-), (/) or (-).
- values must contain between 1 and 256 alphanumeric characters, it may include space, (-), (_), (/), (+), (@), (:), (=) or (.) characters.
The guard rail association id rules
The jira issue templates ids associated to the connection
"B19BBA55-8646-4D94-A40A-C3AFE2F4BAFD"
MandatoryMetadataFields are fields that must be present in the metadata for this connection for every session.
MCPOAuthFlowID adopts a completed MCP OAuth login into a durable grant for this connection. Write-only, and only meaningful for the "mcpproxy" subtype. See Connection.MCPOAuthFlowID for the full rationale.
PATCH needs it for the same reason POST and PUT do, and more urgently: re-authorizing an EXISTING connection is the only way to replace a credential the provider has expired, and the edit screen speaks PATCH. Without this the browser could obtain a fresh token but never hand over the flow that owns its refresh token, so every re-authorization would freeze another token destined to expire exactly like the last one.
"7c8a1234-5678-9abc-def0-123456789abc"
Redact Types is a list of info types that will used to redact the output of the connection. Possible values are described in the DLP documentation: https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference
Reviewers is a list of groups that will review the connection before the user could execute it
Secrets are environment variables that are going to be exposed in the runtime of the connection:
- { envvar:[env-key]: [base64-val] } - Expose the value as environment variable
- { filesystem:[env-key]: [base64-val] } - Expose the value as a temporary file path creating the value in the filesystem
The value could also represent an integration with a external provider:
- { envvar:[env-key]: _aws:[secret-name]:[secret-key] } - Obtain the value dynamically in the AWS secrets manager and expose as environment variable
- { envvar:[env-key]: _envjson:[json-env-name]:[json-env-key] } - Obtain the value dynamically from a JSON env in the agent runtime. Example: MYENV={"KEY": "val"}
Sub Type is the underline implementation of the connection:
- postgres - Implements Postgres protocol
- mysql - Implements MySQL protocol
- mongodb - Implements MongoDB Wire Protocol
- mssql - Implements Microsoft SQL Server Protocol
- oracledb - Implements Oracle Database Protocol
- tcp - Forwards a TCP connection
- ssh - Forwards a SSH connection
- httpproxy - Forwards a HTTP connection
- dynamodb - AWS DynamoDB experimental integration
- cloudwatch - AWS CloudWatch experimental integration
"postgres"
DEPRECATED: Tags to classify the connection
Type represents the main type of the connection:
- database - Database protocols
- application - Custom applications
- custom - Shell applications
database, application, custom "database"
Response
OK
Toggle Port Forwarding
- enabled - Enable to perform port forwarding for this connection
- disabled - Disable port forwarding for this connection
enabled, disabled Toggle Ad Hoc Executions
- enabled - Enable to run ad-hoc executions for this connection
- disabled - Disable ad-hoc executions for this connection
enabled, disabled Toggle Ad Hoc Runbooks Executions
- enabled - Enable to run runbooks for this connection
- disabled - Disable runbooks execution for this connection
enabled, disabled Toggle Introspection Schema
- enabled - Enable the instrospection schema in the webapp
- disabled - Disable the instrospection schema in the webapp
enabled, disabled The agent associated with this connection
"1837453e-01fc-46f3-9e4c-dcf22d395393"
Name of the connection. This attribute is immutable when updating it
"pgdemo"
Type represents the main type of the connection:
- database - Database protocols
- application - Custom applications
- custom - Shell applications
database, application, custom "database"
Maximum duration in seconds for JIT access sessions on this connection
3600
Attributes associated with this connection. Includes Hoop-managed attributes (e.g. the active protection profile attribute); omitting a managed name on update detaches the connection from it.
Is the shell command that is going to be executed when interacting with this connection. This value is required if the connection is going to be used from the Webapp.
Tags to identify the connection
- keys must contain between 1 and 64 alphanumeric characters, it may include (-), (_), (/), or (.) characters and it must not end with (-), (/) or (-).
- values must contain between 1 and 256 alphanumeric characters, it may include space, (-), (_), (/), (+), (@), (:), (=) or (.) characters.
Default databases returns the configured value of the attribute secrets->'DB'
EffectiveFeatures reports which features will actually act on this connection, resolving attribute-based associations as well as direct ones.
Null means "unknown", never "nothing is active" — the two must not be confused by a caller deciding whether to warn a user. It is null on the list endpoint, which does not resolve it, and on the detail endpoint when resolution failed (the gateway logs the failure).
Deliberately not omitempty: an absent key and an explicit null are different contracts, and the one documented here is null.
Groups that can force approve reviews for this connection
The guard rail association id rules
Unique ID of the resource
"5364ec99-653b-41ba-8165-67236e894990"
The jira issue templates ids associated to the connection
"B19BBA55-8646-4D94-A40A-C3AFE2F4BAFD"
JitAccessDurationSec is the fixed access duration in seconds enforced by a JIT access request rule. When set, the user cannot choose a custom duration and must request access for this exact window.
1800
Hoop-managed attributes associated with this connection (e.g. the active protection profile attribute). Computed on reads; manage the association through the attributes field.
Managed By is a read only field that indicates who is managing this resource. When this attribute is set, this resource is considered immutable
""
MandatoryMetadataFields are fields that must be present in the metadata for this connection for every session.
MCPOAuthFlowID adopts a completed MCP OAuth login into a durable grant for this connection. Write-only, and only meaningful for the "mcpproxy" subtype.
The login runs before the connection exists, so the token it obtained is keyed by the flow rather than by connection. Passing the flow id here at save time joins the two: the gateway stores the refresh token against this connection and renews the access token at every session open, instead of relying on the frozen HEADER_AUTHORIZATION value alone, which stops working when the provider's token expires.
Write-only is enforced by ToOpenApi, which never populates this field —
not by a struct tag. swag reads readonly and has no writeonly
counterpart (field_parser.go only consults readOnlyTag), so the tag that
used to sit here was inert and the published spec advertised the field
as readable. The omitempty keeps it out of every response body.
"7c8a1234-5678-9abc-def0-123456789abc"
MCPOAuthGranted reports that a durable MCP OAuth grant exists for this connection, so its credential is renewed from a refresh token at every session open rather than frozen at the value it was authorized with.
The edit screen cannot infer this from the env vars. A brokered OAuth login and a pasted token both end up as one HEADER_AUTHORIZATION, and MCP_AUTH collapses "oauth" to "static" because that is all the agent needs to know (see services.MCPOAuthGrantSubType). Without this field the form has to guess which mode the admin chose, guesses "static", and an OAuth connection reopens offering to replace a token it should be offering to re-authorize.
Presence only — no token, no expiry, nothing the grant holds.
true
MCPOAuthWarning reports that the connection was saved but the MCP OAuth login named by mcp_oauth_flow_id was not attached to it. Present only on the create/update response that produced it.
The save succeeded and the connection still works on its frozen HEADER_AUTHORIZATION, so this is not an error status. What it is not is silent: without a grant the credential is never renewed, the connection stops working the moment the provider expires that token, and the admin needs to hear it at save time rather than from a failing session days later.
"the oauth login authorized https://a.example/mcp but the connection points at https://b.example/mcp"
Minimum number of review approvals required to execute this connection
2
When this option is enabled it will allow managing the redact types through the attribute redact_types
Redact Types is a list of info types that will used to redact the output of the connection. Possible values are described in the DLP documentation: https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference
Resource to which this connection belongs to, it'll be created if it doesn't exist
"pgdemo"
Reviewers is a list of groups that will review the connection before the user could execute it
Secrets are environment variables that are going to be exposed in the runtime of the connection:
- { envvar:[env-key]: [base64-val] } - Expose the value as environment variable
- { filesystem:[env-key]: [base64-val] } - Expose the value as a temporary file path creating the value in the filesystem
The value could also represent an integration with a external provider:
- { envvar:[env-key]: _aws:[secret-name]:[secret-key] } - Obtain the value dynamically in the AWS secrets manager and expose as environment variable
- { envvar:[env-key]: _envjson:[json-env-name]:[json-env-key] } - Obtain the value dynamically from a JSON env in the agent runtime. Example: MYENV={"KEY": "val"}
SecretsUpdatedAt is the timestamp of the last replacement of any inline secret value for this connection. Null when no inline secret has been modified since the write-only secrets feature was introduced. References to external providers (AWS Secrets Manager, Vault, IAM RDS) do not affect this field.
"2025-01-15T10:30:00Z"
Status is a read only field that informs if the connection is available for interaction
- online - The agent is connected and alive
- offline - The agent is not connected
online, offline Sub Type is the underline implementation of the connection:
- postgres - Implements Postgres protocol
- mysql - Implements MySQL protocol
- mongodb - Implements MongoDB Wire Protocol
- mssql - Implements Microsoft SQL Server Protocol
- oracledb - Implements Oracle Database Protocol
- tcp - Forwards a TCP connection
- ssh - Forwards a SSH connection
- httpproxy - Forwards a HTTP connection
- dynamodb - AWS DynamoDB experimental integration
- cloudwatch - AWS CloudWatch experimental integration
"postgres"
DEPRECATED: Tags to classify the connection