MtaQueueQuota
MtaQueueQuota
Section titled “MtaQueueQuota”Defines a quota rule for message queues.
This object can be configured from the WebUI under Settings › MTA › Rates & Quotas › Queue Quotas
Fields
Section titled “Fields”enable
Section titled “enable”Type:
Boolean· default:trueWhether to enable this quota
description
Section titled “description”Type:
String?· read-onlyShort description for the quota
Type:
MtaQueueQuotaKey[]· min items: 1Optional list of context variables that determine where this quota should be applied
Type:
Expression· requiredEnable the imposition of concurrency and rate limits only when a specific condition is met
Available variables:
MtaQueueHostVariable.
messages
Section titled “messages”Type:
UnsignedInt?· min: 1Maximum number of messages in the queue that this quota will allow
Type:
Size?Maximum total size of messages in the queue that this quota will allow
JMAP API
Section titled “JMAP API”The MtaQueueQuota object is available via the urn:stalwart:jmap capability.
x:MtaQueueQuota/get
Section titled “x:MtaQueueQuota/get”This is a standard Foo/get method as defined in RFC 8620, Section 5.1.
This method requires the sysMtaQueueQuotaGet permission.
curl -X POST https://mail.example.com/api \ -H 'Authorization: Bearer $TOKEN' \ -H 'Content-Type: application/json' \ -d '{ "methodCalls": [ [ "x:MtaQueueQuota/get", { "ids": [ "id1" ] }, "c1" ] ], "using": [ "urn:ietf:params:jmap:core", "urn:stalwart:jmap" ] }'x:MtaQueueQuota/set
Section titled “x:MtaQueueQuota/set”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.
Create
Section titled “Create”This operation requires the sysMtaQueueQuotaCreate permission.
curl -X POST https://mail.example.com/api \ -H 'Authorization: Bearer $TOKEN' \ -H 'Content-Type: application/json' \ -d '{ "methodCalls": [ [ "x:MtaQueueQuota/set", { "create": { "new1": { "key": {}, "match": { "else": "Example", "match": {} } } } }, "c1" ] ], "using": [ "urn:ietf:params:jmap:core", "urn:stalwart:jmap" ] }'Update
Section titled “Update”This operation requires the sysMtaQueueQuotaUpdate permission.
curl -X POST https://mail.example.com/api \ -H 'Authorization: Bearer $TOKEN' \ -H 'Content-Type: application/json' \ -d '{ "methodCalls": [ [ "x:MtaQueueQuota/set", { "update": { "id1": { "enable": true } } }, "c1" ] ], "using": [ "urn:ietf:params:jmap:core", "urn:stalwart:jmap" ] }'Destroy
Section titled “Destroy”This operation requires the sysMtaQueueQuotaDestroy permission.
curl -X POST https://mail.example.com/api \ -H 'Authorization: Bearer $TOKEN' \ -H 'Content-Type: application/json' \ -d '{ "methodCalls": [ [ "x:MtaQueueQuota/set", { "destroy": [ "id1" ] }, "c1" ] ], "using": [ "urn:ietf:params:jmap:core", "urn:stalwart:jmap" ] }'x:MtaQueueQuota/query
Section titled “x:MtaQueueQuota/query”This is a standard Foo/query method as defined in RFC 8620, Section 5.5.
This method requires the sysMtaQueueQuotaQuery permission.
curl -X POST https://mail.example.com/api \ -H 'Authorization: Bearer $TOKEN' \ -H 'Content-Type: application/json' \ -d '{ "methodCalls": [ [ "x:MtaQueueQuota/query", { "filter": {} }, "c1" ] ], "using": [ "urn:ietf:params:jmap:core", "urn:stalwart:jmap" ] }'stalwart-cli wraps the same JMAP calls. See the CLI reference for installation, authentication, and general usage.
stalwart-cli get MtaQueueQuota id1Create
Section titled “Create”stalwart-cli create MtaQueueQuota \ --field 'key={}' \ --field 'match={"else":"Example","match":{}}'stalwart-cli query MtaQueueQuotaUpdate
Section titled “Update”stalwart-cli update MtaQueueQuota id1 --field enable=trueDelete
Section titled “Delete”stalwart-cli delete MtaQueueQuota --ids id1Nested types
Section titled “Nested types”Expression
Section titled “Expression”A conditional expression with match rules and a default value.
Type:
ExpressionMatch[]List of conditions and their corresponding results
Type:
String· requiredElse condition
ExpressionMatch
Section titled “ExpressionMatch”A single condition-result pair in an expression.
Type:
String· requiredIf condition
Type:
String· requiredThen clause
MtaQueueQuotaKey
Section titled “MtaQueueQuotaKey”| Value | Label |
|---|---|
sender | Sender |
senderDomain | Sender Domain |
rcpt | Recipient |
rcptDomain | Recipient Domain |
Expression references
Section titled “Expression references”The following expression contexts are used by fields on this page:
MtaQueueHostVariable(Variables)