Skip to content

EmailSubmission

Capability: urn:ietf:params:jmap:submission

Arguments

PropertyTypeRequiredDescription
accountIdAccountIdYesThe account to fetch EmailSubmission objects from.
idsarray?NoSubmission ids to fetch. If null, returns all.
propertiesarray?NoEmailSubmission properties to return. Defaults to all properties.

Response

PropertyTypeRequiredDescription
accountIdAccountIdYesThe account the EmailSubmission objects belong to.
statestringYesCurrent EmailSubmission state, used in subsequent /changes calls.
listEmailSubmission[]YesThe requested EmailSubmission objects.
notFoundarray?NoIds that were not found.

Capability: urn:ietf:params:jmap:submission

Arguments

PropertyTypeRequiredDescription
accountIdAccountIdYesThe account to create, update, or destroy EmailSubmission objects in.
ifInStatestring?NoOptimistic concurrency guard on EmailSubmission state.
createobject?NoMap of creation id to EmailSubmissionCreate objects.
updateobject?NoMap of submission id to patch objects (RFC 8620 §5.3 patch).
destroyarray?NoIds of EmailSubmission objects to destroy.
onSuccessUpdateEmailobject?NoMap of submission id (or creation id reference) to Email patch applied on successful send.
onSuccessDestroyEmailarray?NoList of submission ids (or creation id references) whose associated Emails should be destroyed on successful send.

Response

PropertyTypeRequiredDescription
accountIdAccountIdYesThe account the set operation was performed on.
oldStatestring?YesThe EmailSubmission state before this call, or null if no prior state existed.
newStatestringYesThe EmailSubmission state after this call.
createdobject?NoMap of creation id to the created EmailSubmission object.
updatedobject?NoMap of id to the updated EmailSubmission object (or null if unchanged properties were not returned).
destroyedarray?NoIds of EmailSubmission objects that were successfully destroyed.
notCreatedobject?NoMap of creation id to SetError for each failed create.
notUpdatedobject?NoMap of id to SetError for each failed update.
notDestroyedobject?NoMap of id to SetError for each failed destroy.

Capability: urn:ietf:params:jmap:submission

Arguments

PropertyTypeRequiredDescription
accountIdAccountIdYesThe account to query EmailSubmission objects in.
filterobject?NoConditions to filter EmailSubmission objects.
sortarray?NoList of Comparator objects specifying the sort order.
positioninteger?NoZero-based index of the first result to return.
anchorIdNoId of an item to anchor the result window on.
anchorOffsetinteger?NoOffset relative to the anchor.
limitinteger?NoMaximum number of ids to return.
calculateTotalboolean?NoIf true, return the total count of results.

Response

PropertyTypeRequiredDescription
accountIdAccountIdYesThe account the query was run against.
queryStatestringYesServer state string for this query result.
canCalculateChangesbooleanYesWhether the server can calculate query changes.
positionintegerYesZero-based index of the first result in ids.
idsId[]YesThe EmailSubmission ids in the requested window.
totalinteger?NoTotal number of results (if calculateTotal was true).
limitinteger?NoThe limit applied to this query.

Capability: urn:ietf:params:jmap:submission

Arguments

PropertyTypeRequiredDescription
accountIdAccountIdYesThe account to get EmailSubmission query changes for.
filterobject?NoMust match the filter used in the original query.
sortarray?NoMust match the sort used in the original query.
sinceQueryStatestringYesThe queryState to get changes since.
maxChangesinteger?NoMaximum number of changes to return.
upToIdIdNoStop reporting changes after this id.
calculateTotalboolean?NoIf true, return the new total count of query results.

Response

PropertyTypeRequiredDescription
accountIdAccountIdYesThe account the query changes are for.
oldQueryStatestringYesThe sinceQueryState value passed in the request.
newQueryStatestringYesThe current query state after these changes.
totalinteger?NoNew total number of results (if calculateTotal was true).
removedId[]YesIds removed from the query results.
addedobject[]YesItems added to the query results with their new index.

Capability: urn:ietf:params:jmap:submission

Arguments

PropertyTypeRequiredDescription
accountIdAccountIdYesThe account to get EmailSubmission changes for.
sinceStatestringYesThe state to get changes since.
maxChangesinteger?NoMaximum number of changes to return.

Response

PropertyTypeRequiredDescription
accountIdAccountIdYesThe account these changes are for.
oldStatestringYesThe sinceState value passed in the request.
newStatestringYesThe current EmailSubmission state after these changes.
hasMoreChangesbooleanYesIf true, more changes exist beyond maxChanges; make another call with newState as sinceState.
createdId[]YesEmailSubmission ids created since sinceState.
updatedId[]YesEmailSubmission ids updated since sinceState.
destroyedId[]YesEmailSubmission ids destroyed since sinceState.