communicationApi documentation (1.0.0)

Download OpenAPI specification:Download

Documentation and interface contract for the communication API, the API responsible for sending emails.

Mails

sendMail

Send an email.

header Parameters
X-Correlation-ID
string

Correlation identifier

Request Body schema: application/json
id
string

Technical and unique id generated automatically that identifies a mail object.

sendingDate
string <date-time>

Sending date filled in automatically at the time of sending (Timestamp in ISO 8601 format)

receiversId
Array of strings

The technical ids of the recipients.

publicationId
string

Technical id of a listing.

reservationId
string

Technical id of a booking.

productType
string
Enum: "TRIP" "HOST"

Product type (Trip, host ...).

organizationId
string

Technical id of an organization.

establishmentId
string

Technical id of an establishment.

category
string
Enum: "PROFILE_COMPLETION_REQUEST" "ORGANIZATION_CREATION_REQUEST" "ESTABLISHMENT_CREATION_REQUEST" "ORGANIZATION_INFO_COMPLETION_REQUEST" "ESTABLISHMENT_INFO_COMPLETION_REQUEST" "USER_ACCOUNT_ACTIVATION_CONFIRMATION" "ORGANIZATION_ACTIVATION_CONFIRMATION" "ESTABLISHMENT_ACTIVATION_CONFIRMATION" "TRIP_DRAFT_PUBLICATION_REQUEST" "TRIP_PUBLICATION_NOTIFICATION" "TRIP_RESPONSIBLE_DESIGNATION_NOTIFICATION" "PARTNER_TRIP_BOOKING_NOTIFICATION" "CLIENT_TRIP_BOOKING_NOTIFICATION" "PARTNER_BOOKING_CANCELLATION_NOTIFICATION" "CLIENT_BOOKING_CANCELLATION_NOTIFICATION" "PARTNER_PAYMENT_NOTIFICATION" "CLIENT_PAYMENT_NOTIFICATION" "TRIP_REMINDER_NOTIFICATION"

Mail category.

Responses

Request samples

Content type
application/json
{
  • "id": "string",
  • "sendingDate": "2019-08-24T14:15:22Z",
  • "receiversId": [
    ],
  • "publicationId": "string",
  • "reservationId": "string",
  • "productType": "TRIP",
  • "organizationId": "string",
  • "establishmentId": "string",
  • "category": "PROFILE_COMPLETION_REQUEST"
}

Response samples

Content type
application/json
{
  • "id": "string",
  • "sendingDate": "2019-08-24T14:15:22Z",
  • "receiversId": [
    ],
  • "publicationId": "string",
  • "reservationId": "string",
  • "productType": "TRIP",
  • "organizationId": "string",
  • "establishmentId": "string",
  • "category": "PROFILE_COMPLETION_REQUEST",
  • "links": [
    ]
}

Contact message

sendContactMessage

Contact us.

header Parameters
X-Correlation-ID
string

Correlation identifier

Request Body schema: application/json
id
string

Technical and unique id generated automatically that identifies a contact object.

conversationId
string

Technical id assigned to the first message in order to link other messages in case of a reply.

sendingDate
string <date-time>

Sending date filled in automatically at the time of sending (Timestamp in ISO 8601 format)

receiverId
string

The technical id of the recipient.

transmitterId
string

The technical id of the sender if connected.

name
string

Name of the client who wants to contact us.

mail
string

Client's email address.

object
string

The subject of the message.

message
string

Client's message.

required
any

Responses

Request samples

Content type
application/json
{
  • "id": "string",
  • "conversationId": "string",
  • "sendingDate": "2019-08-24T14:15:22Z",
  • "receiverId": "string",
  • "transmitterId": "string",
  • "name": "string",
  • "mail": "string",
  • "object": "string",
  • "message": "string",
  • "required": null
}

Response samples

Content type
application/json
{
  • "id": "string",
  • "conversationId": "string",
  • "sendingDate": "2019-08-24T14:15:22Z",
  • "receiverId": "string",
  • "transmitterId": "string",
  • "name": "string",
  • "mail": "string",
  • "object": "string",
  • "message": "string",
  • "required": null,
  • "links": [
    ]
}

listContactMessage

List contact messages.

path Parameters
contact_id
required
string

Technical id of the contact message.

query Parameters
currentPage
integer >= 0

Current page number. Do not send this attribute on the first call.

sizePage
integer >= 3

Number of elements per page.

header Parameters
X-Correlation-ID
string

Correlation identifier

Responses

Response samples

Content type
application/json
{
  • "totalElements": 0,
  • "totalPages": 0,
  • "currentPage": 0,
  • "content": [
    ]
}

getContactMessage

Get a contact message.

path Parameters
contact_id
required
string

Technical id of the contact message.

header Parameters
X-Correlation-ID
string

Correlation identifier

Responses

Response samples

Content type
application/json
{
  • "id": "string",
  • "conversationId": "string",
  • "sendingDate": "2019-08-24T14:15:22Z",
  • "receiverId": "string",
  • "transmitterId": "string",
  • "name": "string",
  • "mail": "string",
  • "object": "string",
  • "message": "string",
  • "required": null,
  • "links": [
    ]
}

Conversation

addConversation

Create a conversation.

header Parameters
X-Correlation-ID
string

Correlation identifier

Request Body schema: application/json
id
string <uuid>
tripPublicationId
required
string
tripReference
required
string
establishmentId
required
string
customerId
required
string
assignedAgentId
string or null

The id of the agent currently responsible for the conversation.

participants
Array of strings

List of IDs of users involved (client + agents).

object (message)

Represents a message exchanged in a conversation.

status
string
Enum: "OPEN" "CLOSED" "ARCHIVED"

Status of the conversation (open, closed, archived)

Responses

Request samples

Content type
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "tripPublicationId": "string",
  • "tripReference": "string",
  • "establishmentId": "string",
  • "customerId": "string",
  • "assignedAgentId": "string",
  • "participants": [
    ],
  • "lastMessage": {
    },
  • "status": "OPEN"
}

Response samples

Content type
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "tripPublicationId": "string",
  • "tripReference": "string",
  • "establishmentId": "string",
  • "customerId": "string",
  • "assignedAgentId": "string",
  • "participants": [
    ],
  • "lastMessage": {
    },
  • "status": "OPEN",
  • "links": [
    ]
}

listConversation

List conversations.

query Parameters
establishmentId
string

Technical id of the establishment concerned by the conversation.

customerId
string

Id of the user who created the conversation.

assignedAgentId
string

Id of the agent managing the conversation.

currentPage
integer >= 0

Current page number. Do not send this attribute on the first call.

sizePage
integer >= 3

Number of elements per page.

header Parameters
X-Correlation-ID
string

Correlation identifier

Responses

Response samples

Content type
application/json
{
  • "totalElements": 0,
  • "totalPages": 0,
  • "currentPage": 0,
  • "content": [
    ]
}

getConversation

Retrieve a conversation.

path Parameters
conversation-id
required
string

Technical id of the conversation.

header Parameters
X-Correlation-ID
string

Correlation identifier

Responses

Response samples

Content type
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "tripPublicationId": "string",
  • "tripReference": "string",
  • "establishmentId": "string",
  • "customerId": "string",
  • "assignedAgentId": "string",
  • "participants": [
    ],
  • "lastMessage": {
    },
  • "status": "OPEN",
  • "links": [
    ]
}

putConversation

Update a conversation.

path Parameters
conversation-id
required
string

Technical id of the conversation.

header Parameters
X-Correlation-ID
string

Correlation identifier

Request Body schema: application/json
id
string <uuid>
tripPublicationId
required
string
tripReference
required
string
establishmentId
required
string
customerId
required
string
assignedAgentId
string or null

The id of the agent currently responsible for the conversation.

participants
Array of strings

List of IDs of users involved (client + agents).

object (message)

Represents a message exchanged in a conversation.

status
string
Enum: "OPEN" "CLOSED" "ARCHIVED"

Status of the conversation (open, closed, archived)

Responses

Request samples

Content type
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "tripPublicationId": "string",
  • "tripReference": "string",
  • "establishmentId": "string",
  • "customerId": "string",
  • "assignedAgentId": "string",
  • "participants": [
    ],
  • "lastMessage": {
    },
  • "status": "OPEN"
}

Response samples

Content type
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "tripPublicationId": "string",
  • "tripReference": "string",
  • "establishmentId": "string",
  • "customerId": "string",
  • "assignedAgentId": "string",
  • "participants": [
    ],
  • "lastMessage": {
    },
  • "status": "OPEN",
  • "links": [
    ]
}

assignConversation

Update the agent assigned to a conversation.

path Parameters
conversation-id
required
string

Technical id of the conversation.

query Parameters
assignedAgentId
required
string

Identifier of the agent assigned to the conversation.

header Parameters
X-Correlation-ID
string

Correlation identifier

Responses

Response samples

Content type
application/json
{
  • "name": "string",
  • "debug_id": "string",
  • "message": "string",
  • "information_link": "string",
  • "details": [
    ],
  • "links": [
    ]
}

listMessages

Retrieve the messages of a conversation.

path Parameters
conversation-id
required
string

Technical id of the conversation.

query Parameters
currentPage
integer >= 0

Current page number. Do not send this attribute on the first call.

sizePage
integer >= 3

Number of elements per page.

header Parameters
X-Correlation-ID
string

Correlation identifier

Responses

Response samples

Content type
application/json
{
  • "totalElements": 0,
  • "totalPages": 0,
  • "currentPage": 0,
  • "content": [
    ]
}