Skip to content

MtaTlsStrategy

Defines a TLS security strategy for outbound connections.

This object can be configured from the WebUI under Settings › MTA › Outbound › TLS Strategies

Type: String · read-only

Short identifier for the TLS strategy

Type: Boolean · default: false

Whether to allow connections to servers with invalid TLS certificates

Type: MtaRequiredOrOptional · default: "optional"

Whether DANE is required, optional, or disabled

Type: String?

A short description of the TLS strategy, which can be used to identify it in the list of strategies

Type: MtaRequiredOrOptional · default: "optional"

Whether MTA-STS is required, optional, or disabled

Type: MtaRequiredOrOptional · default: "optional"

Whether TLS support is required, optional, or disabled

Type: Duration · default: "5m"

Maximum time to wait for the MTA-STS policy lookup to complete

Type: Duration · default: "3m"

Maximum time to wait for the TLS handshake to complete

The MtaTlsStrategy object is available via the urn:stalwart:jmap capability.

This is a standard Foo/get method as defined in RFC 8620, Section 5.1.

This method requires the sysMtaTlsStrategyGet permission.

Terminal window
curl -X POST https://mail.example.com/api \
-H 'Authorization: Bearer $TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"methodCalls": [
[
"x:MtaTlsStrategy/get",
{
"ids": [
"id1"
]
},
"c1"
]
],
"using": [
"urn:ietf:params:jmap:core",
"urn:stalwart:jmap"
]
}'

This is a standard Foo/set method as defined in RFC 8620, Section 5.3.

Supports create, update, and destroy operations in a single call.

This operation requires the sysMtaTlsStrategyCreate permission.

Terminal window
curl -X POST https://mail.example.com/api \
-H 'Authorization: Bearer $TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"methodCalls": [
[
"x:MtaTlsStrategy/set",
{
"create": {
"new1": {}
}
},
"c1"
]
],
"using": [
"urn:ietf:params:jmap:core",
"urn:stalwart:jmap"
]
}'

This operation requires the sysMtaTlsStrategyUpdate permission.

Terminal window
curl -X POST https://mail.example.com/api \
-H 'Authorization: Bearer $TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"methodCalls": [
[
"x:MtaTlsStrategy/set",
{
"update": {
"id1": {
"description": "updated value"
}
}
},
"c1"
]
],
"using": [
"urn:ietf:params:jmap:core",
"urn:stalwart:jmap"
]
}'

This operation requires the sysMtaTlsStrategyDestroy permission.

Terminal window
curl -X POST https://mail.example.com/api \
-H 'Authorization: Bearer $TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"methodCalls": [
[
"x:MtaTlsStrategy/set",
{
"destroy": [
"id1"
]
},
"c1"
]
],
"using": [
"urn:ietf:params:jmap:core",
"urn:stalwart:jmap"
]
}'

This is a standard Foo/query method as defined in RFC 8620, Section 5.5.

This method requires the sysMtaTlsStrategyQuery permission.

Terminal window
curl -X POST https://mail.example.com/api \
-H 'Authorization: Bearer $TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"methodCalls": [
[
"x:MtaTlsStrategy/query",
{
"filter": {
"name": "example"
}
},
"c1"
]
],
"using": [
"urn:ietf:params:jmap:core",
"urn:stalwart:jmap"
]
}'

The x:MtaTlsStrategy/query filter argument accepts the following conditions (combinable with AnyOf / AllOf / Not per RFC 8620):

ConditionKind
nametext

stalwart-cli wraps the same JMAP calls. See the CLI reference for installation, authentication, and general usage.

Terminal window
stalwart-cli get MtaTlsStrategy id1
Terminal window
stalwart-cli create MtaTlsStrategy
Terminal window
stalwart-cli query MtaTlsStrategy
stalwart-cli query MtaTlsStrategy --where name=example
Terminal window
stalwart-cli update MtaTlsStrategy id1 --field description='updated value'
Terminal window
stalwart-cli delete MtaTlsStrategy --ids id1
ValueLabel
optionalOptional
requireRequired
disableDisabled