Messages API (v9.1)
Download OpenAPI specification:Download
Get a list of messages
Allows to retrieve a list of messages (GET only) according to certain criteria.
query Parameters
RecipientId | string Profile Id from eGuichet |
SearchTerm | string Term searched in messages |
SenderOrigin | string Filters messages by |
IsImportant | boolean Filters messages by |
IsFollowed | boolean Filters messages by |
IsRead | boolean Messages read have a not null |
IsConfirmed | boolean Messages confirmed have a not null |
ThreadId | integer <int32> Filters messages by |
LastInThread | boolean When enabled, only retrieve the last message in each thread |
CreationTaskId | string <uuid> Filters messages by |
MinMessageStamp | string <date-time> Messages with a later or equal |
MaxMessageStamp | string <date-time> Messages with an earlier or equal |
MinCreationStamp | string <date-time> Messages with a later or equal |
MaxCreationStamp | string <date-time> Messages with an earlier or equal |
RecipientIsOrgAdmin | boolean Indicate if the recipient is admin of its organization |
object Filters by metadata key-value. It is possible to use the following synthax multiple time for the same metadataName. Usage : Other : using Swagger : use the following example format with Swagger : | |
object Filters by date of access by prestation. The Usage : Swagger : use the following example format with Swagger : | |
PageNumber | integer <int32> [ 1 .. 2147483647 ] Page number |
PageSize | integer <int32> [ -1 .. 2147483647 ] Number of messages per page. Using value |
OrderBy | string Sorting option. Usage (no square brackets !) : |
Responses
Response samples
- 200
- 422
[- {
- "id": 0,
- "creationTaskId": "eb059d3e-6d17-4c26-b5d1-961c5d82bc0c",
- "creationStamp": "2019-08-24T14:15:22Z",
- "threadId": 0,
- "title": "string",
- "body": "string",
- "messageStamp": "2019-08-24T14:15:22Z",
- "recipientId": "string",
- "senderOrigin": "string",
- "senderDisplayName": "string",
- "isImportant": true,
- "isFollowed": true,
- "isReplyable": true,
- "hasAttachment": true,
- "readStamp": "2019-08-24T14:15:22Z",
- "confirmStamp": "2019-08-24T14:15:22Z",
- "metadata": [
- {
- "id": 0,
- "name": "string",
- "value": "string"
}
]
}
]
Get a list of messages
Allows to retrieve a list of messages (GET only) according to certain criteria.
query Parameters
RecipientId | string Profile Id from eGuichet |
SearchTerm | string Term searched in messages |
SenderOrigin | string Filters messages by |
IsImportant | boolean Filters messages by |
IsFollowed | boolean Filters messages by |
IsRead | boolean Messages read have a not null |
IsConfirmed | boolean Messages confirmed have a not null |
ThreadId | integer <int32> Filters messages by |
LastInThread | boolean When enabled, only retrieve the last message in each thread |
CreationTaskId | string <uuid> Filters messages by |
MinMessageStamp | string <date-time> Messages with a later or equal |
MaxMessageStamp | string <date-time> Messages with an earlier or equal |
MinCreationStamp | string <date-time> Messages with a later or equal |
MaxCreationStamp | string <date-time> Messages with an earlier or equal |
RecipientIsOrgAdmin | boolean Indicate if the recipient is admin of its organization |
object Filters by metadata key-value. It is possible to use the following synthax multiple time for the same metadataName. Usage : Other : using Swagger : use the following example format with Swagger : | |
object Filters by date of access by prestation. The Usage : Swagger : use the following example format with Swagger : | |
PageNumber | integer <int32> [ 1 .. 2147483647 ] Page number |
PageSize | integer <int32> [ -1 .. 2147483647 ] Number of messages per page. Using value |
OrderBy | string Sorting option. Usage (no square brackets !) : |
Responses
Response samples
- 200
- 422
[- {
- "id": 0,
- "creationTaskId": "eb059d3e-6d17-4c26-b5d1-961c5d82bc0c",
- "creationStamp": "2019-08-24T14:15:22Z",
- "threadId": 0,
- "title": "string",
- "body": "string",
- "messageStamp": "2019-08-24T14:15:22Z",
- "recipientId": "string",
- "senderOrigin": "string",
- "senderDisplayName": "string",
- "isImportant": true,
- "isFollowed": true,
- "isReplyable": true,
- "hasAttachment": true,
- "readStamp": "2019-08-24T14:15:22Z",
- "confirmStamp": "2019-08-24T14:15:22Z",
- "metadata": [
- {
- "id": 0,
- "name": "string",
- "value": "string"
}
]
}
]
Create a new message
Allows to create a new message.
Request Body schema: application/json
Message to create
creationTaskId | string or null <uuid> Guid identifying messages created in the same operation.
Default value : |
threadId | integer <int32> ID of the thread containing the message.
Default value : the new message |
title required | string non-empty Title of the message |
body required | string non-empty Body content of the message |
messageStamp | string or null <date-time> Official date of the message
Default value : |
recipientId required | string [ 1 .. 50 ] characters Recipient's Profile ID (from eGuichet) |
senderOrigin | string or null <= 128 characters Source of the message.
Default value : |
senderDisplayName required | string [ 1 .. 128 ] characters Name of the sender, used for display. |
isImportant | boolean Indicates if the message is important (requiring a confirmation).
Default value : |
isFollowed | boolean Indicates if the message is followed by its recipient.
Default value : |
isReplyable | boolean Indicates if the message is replyable.
Default value : |
hasAttachment | boolean Indicates if the message has at least one attachment.
Default value : |
Array of objects or null (MetadataForCreationDto) List of the metadata linked to the message.
Default value : |
Responses
Request samples
- Payload
{- "creationTaskId": "eb059d3e-6d17-4c26-b5d1-961c5d82bc0c",
- "threadId": 0,
- "title": "string",
- "body": "string",
- "messageStamp": "2019-08-24T14:15:22Z",
- "recipientId": "string",
- "senderOrigin": "string",
- "senderDisplayName": "string",
- "isImportant": true,
- "isFollowed": true,
- "isReplyable": true,
- "hasAttachment": true,
- "metadata": [
- {
- "name": "string",
- "value": "string"
}
]
}
Response samples
- 201
- 400
- 422
{- "id": 0,
- "creationTaskId": "eb059d3e-6d17-4c26-b5d1-961c5d82bc0c",
- "creationStamp": "2019-08-24T14:15:22Z",
- "threadId": 0,
- "title": "string",
- "body": "string",
- "messageStamp": "2019-08-24T14:15:22Z",
- "recipientId": "string",
- "senderOrigin": "string",
- "senderDisplayName": "string",
- "isImportant": true,
- "isFollowed": true,
- "isReplyable": true,
- "hasAttachment": true,
- "readStamp": "2019-08-24T14:15:22Z",
- "confirmStamp": "2019-08-24T14:15:22Z",
- "metadata": [
- {
- "id": 0,
- "name": "string",
- "value": "string"
}
]
}
Delete messages by criteria
Allows to delete existing messages by criteria and all their metadata. Also deletes every messages in the same thread.
query Parameters
RecipientId required | string Profile Id from eGuichet |
Responses
Response samples
- 422
{- "type": "string",
- "title": "string",
- "status": 0,
- "detail": "string",
- "traceId": "729bb1bf-882d-483b-89d3-5855dc5af3aa",
- "property1": null,
- "property2": null
}
Get a single message
Allows to retrieve a specific message identified by its Id
.
path Parameters
messageId required | integer <int32> Message |
Responses
Response samples
- 200
- 404
- 422
{- "id": 0,
- "creationTaskId": "eb059d3e-6d17-4c26-b5d1-961c5d82bc0c",
- "creationStamp": "2019-08-24T14:15:22Z",
- "threadId": 0,
- "title": "string",
- "body": "string",
- "messageStamp": "2019-08-24T14:15:22Z",
- "recipientId": "string",
- "senderOrigin": "string",
- "senderDisplayName": "string",
- "isImportant": true,
- "isFollowed": true,
- "isReplyable": true,
- "hasAttachment": true,
- "readStamp": "2019-08-24T14:15:22Z",
- "confirmStamp": "2019-08-24T14:15:22Z",
- "metadata": [
- {
- "id": 0,
- "name": "string",
- "value": "string"
}
]
}
Delete a message and all its metadata
Allows to delete an existing message and all its metadata. Also deletes every messages in the same thread.
path Parameters
messageId required | integer <int32> Message |
Responses
Response samples
- 404
- 422
{- "type": "string",
- "title": "string",
- "status": 0,
- "detail": "string",
- "traceId": "729bb1bf-882d-483b-89d3-5855dc5af3aa",
- "property1": null,
- "property2": null
}
Update a message
Allows to update certain properties of an existing message. When a message is marked as read, messages in the same thread also are.
path Parameters
messageId required | integer <int32> Message |
Request Body schema: application/json
Updated properties
isFollowed | boolean Indicates if the message is followed by its recipient |
hasAttachment | boolean Indicates if the message has at least one attachment |
readStamp | string or null <date-time> Date of reading. |
confirmStamp | string or null <date-time> Date of confirmation. A confirm date can only be set when the message is important and is read. |
Responses
Request samples
- Payload
{- "isFollowed": true,
- "hasAttachment": true,
- "readStamp": "2019-08-24T14:15:22Z",
- "confirmStamp": "2019-08-24T14:15:22Z"
}
Response samples
- 200
- 400
- 404
- 422
{- "id": 0,
- "creationTaskId": "eb059d3e-6d17-4c26-b5d1-961c5d82bc0c",
- "creationStamp": "2019-08-24T14:15:22Z",
- "threadId": 0,
- "title": "string",
- "body": "string",
- "messageStamp": "2019-08-24T14:15:22Z",
- "recipientId": "string",
- "senderOrigin": "string",
- "senderDisplayName": "string",
- "isImportant": true,
- "isFollowed": true,
- "isReplyable": true,
- "hasAttachment": true,
- "readStamp": "2019-08-24T14:15:22Z",
- "confirmStamp": "2019-08-24T14:15:22Z",
- "metadata": [
- {
- "id": 0,
- "name": "string",
- "value": "string"
}
]
}
Get all metadata for a message
Allows to retrieve the list of metadata for a specific message.
path Parameters
messageId required | integer <int32> Message |
query Parameters
PageNumber | integer <int32> [ 1 .. 2147483647 ] Page number |
PageSize | integer <int32> [ -1 .. 2147483647 ] Number of messages per page. Using value |
OrderBy | string Sorting option. Usage (no square brackets !) : |
Responses
Response samples
- 200
- 404
- 422
[- {
- "id": 0,
- "name": "string",
- "value": "string"
}
]
Get a single metadata for a specific message
Allows to retrieve a specific metadata for a specific message, identified respectively by Name
and Id
.
path Parameters
messageId required | integer <int32> Message |
name required | string Metadata Name (case insensitive) |
Responses
Response samples
- 200
- 404
- 422
{- "id": 0,
- "name": "string",
- "value": "string"
}
Get the recipients of the messages created in the last X seconds
Allows to retrieve the list of recipients of the messages created in the last X seconds
query Parameters
timeOffsetInSeconds required | integer <int32> Time offset in seconds that will be substracted from current time |
Responses
Response samples
- 200
- 422
[- "string"
]
id | integer <int32> Unique ID of the message |
creationTaskId | string or null <uuid> Guid identifying messages created in the same operation |
creationStamp | string <date-time> Date of message creation by the API |
threadId | integer <int32> ID of the thread containing the message |
title | string Title of the message |
body | string Body content of the message |
messageStamp | string <date-time> Official date of the message |
recipientId | string Recipient's Profile ID (from eGuichet) |
senderOrigin | string or null Source of the message |
senderDisplayName | string Name of the sender, used for display |
isImportant | boolean Indicates if the message is important (requiring a confirmation) |
isFollowed | boolean Indicates if the message is followed by its recipient |
isReplyable | boolean Indicates if the message is replyable |
hasAttachment | boolean Indicates if the message has at least one attachment |
readStamp | string or null <date-time> Date of reading |
confirmStamp | string or null <date-time> Date of confirmation |
Array of objects or null (MetadataDto) List of the metadata linked to the message |
{- "id": 0,
- "creationTaskId": "eb059d3e-6d17-4c26-b5d1-961c5d82bc0c",
- "creationStamp": "2019-08-24T14:15:22Z",
- "threadId": 0,
- "title": "string",
- "body": "string",
- "messageStamp": "2019-08-24T14:15:22Z",
- "recipientId": "string",
- "senderOrigin": "string",
- "senderDisplayName": "string",
- "isImportant": true,
- "isFollowed": true,
- "isReplyable": true,
- "hasAttachment": true,
- "readStamp": "2019-08-24T14:15:22Z",
- "confirmStamp": "2019-08-24T14:15:22Z",
- "metadata": [
- {
- "id": 0,
- "name": "string",
- "value": "string"
}
]
}
creationTaskId | string or null <uuid> Guid identifying messages created in the same operation.
Default value : |
threadId | integer <int32> ID of the thread containing the message.
Default value : the new message |
title required | string non-empty Title of the message |
body required | string non-empty Body content of the message |
messageStamp | string or null <date-time> Official date of the message
Default value : |
recipientId required | string [ 1 .. 50 ] characters Recipient's Profile ID (from eGuichet) |
senderOrigin | string or null <= 128 characters Source of the message.
Default value : |
senderDisplayName required | string [ 1 .. 128 ] characters Name of the sender, used for display. |
isImportant | boolean Indicates if the message is important (requiring a confirmation).
Default value : |
isFollowed | boolean Indicates if the message is followed by its recipient.
Default value : |
isReplyable | boolean Indicates if the message is replyable.
Default value : |
hasAttachment | boolean Indicates if the message has at least one attachment.
Default value : |
Array of objects or null (MetadataForCreationDto) List of the metadata linked to the message.
Default value : |
{- "creationTaskId": "eb059d3e-6d17-4c26-b5d1-961c5d82bc0c",
- "threadId": 0,
- "title": "string",
- "body": "string",
- "messageStamp": "2019-08-24T14:15:22Z",
- "recipientId": "string",
- "senderOrigin": "string",
- "senderDisplayName": "string",
- "isImportant": true,
- "isFollowed": true,
- "isReplyable": true,
- "hasAttachment": true,
- "metadata": [
- {
- "name": "string",
- "value": "string"
}
]
}
isFollowed | boolean Indicates if the message is followed by its recipient |
hasAttachment | boolean Indicates if the message has at least one attachment |
readStamp | string or null <date-time> Date of reading. |
confirmStamp | string or null <date-time> Date of confirmation. A confirm date can only be set when the message is important and is read. |
{- "isFollowed": true,
- "hasAttachment": true,
- "readStamp": "2019-08-24T14:15:22Z",
- "confirmStamp": "2019-08-24T14:15:22Z"
}
id | integer <int32> Unique ID of the metadata |
name | string Unique metadata name per message |
value | string Value of the metadata |
{- "id": 0,
- "name": "string",
- "value": "string"
}
type | string or null URI that identifies the problem detail type |
title | string or null A short human-readable summary about the problem |
status | integer or null <int32> HTTP Status Code |
detail | string or null A human-readable explanation about the problem |
traceId | string <uuid> Guid to trace the error in the log files |
property name* additional property | any |
{- "type": "string",
- "title": "string",
- "status": 0,
- "detail": "string",
- "traceId": "729bb1bf-882d-483b-89d3-5855dc5af3aa",
- "property1": null,
- "property2": null
}