Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add update message in OboMessageService #797

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -306,6 +306,7 @@ public List<String> getAttachmentTypes() {
* @return a {@link V4Message} object containing the details of the sent message
* @see <a href="https://developers.symphony.com/restapi/reference#update-message-v4">Create Update v4</a>
*/
@Override
@API(status = API.Status.EXPERIMENTAL)
public V4Message update(@Nonnull V4Message messageToUpdate, @Nonnull Message content) {
return this.update(messageToUpdate.getStream().getStreamId(), messageToUpdate.getMessageId(), content);
Expand All @@ -320,6 +321,7 @@ public V4Message update(@Nonnull V4Message messageToUpdate, @Nonnull Message con
* @return a {@link V4Message} object containing the details of the sent message
* @see <a href="https://developers.symphony.com/restapi/reference#update-message-v4">Create Update v4</a>
*/
@Override
@API(status = API.Status.EXPERIMENTAL)
public V4Message update(@Nonnull String streamId, @Nonnull String messageId, @Nonnull Message content) {
return this.executeAndRetry("update", messagesApi.getApiClient().getBasePath(), () -> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,27 @@ public interface OboMessageService {
*/
V4Message send(@Nonnull String streamId, @Nonnull Message message);

/**
* Update an existing message. The existing message must be a valid social message, that has not been deleted.
*
* @param messageToUpdate the message to be updated
* @param content the update content (attachments are not supported yet)
* @return a {@link V4Message} object containing the details of the sent message
* @see <a href="https://developers.symphony.com/restapi/reference#update-message-v4">Create Update v4</a>
*/
V4Message update(@Nonnull V4Message messageToUpdate, @Nonnull Message content);

/**
* Update an existing message. The existing message must be a valid social message, that has not been deleted.
*
* @param streamId the ID of the stream where the message to be updated comes from
* @param messageId the ID of the message to be updated
* @param content the update content (attachments are not supported yet)
* @return a {@link V4Message} object containing the details of the sent message
* @see <a href="https://developers.symphony.com/restapi/reference#update-message-v4">Create Update v4</a>
*/
V4Message update(@Nonnull String streamId, @Nonnull String messageId, @Nonnull Message content);

/**
* Suppresses a users message based on the messageID pass in parameter.
*
Expand Down