Skip to content

Commit

Permalink
adding more attribute to message object (#283)
Browse files Browse the repository at this point in the history
* adding more attribute to message object

* fix

* version update

* Update version.txt
  • Loading branch information
narayana-plivo authored Sep 6, 2024
1 parent d5873d0 commit 429dea1
Show file tree
Hide file tree
Showing 8 changed files with 110 additions and 29 deletions.
7 changes: 5 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
# Change Log
## [5.44.3](https://github.com/plivo/plivo-java/tree/v5.44.3) (2024-09-06)
**Feature - Adding more attribute on mdr object**
- Added `message_sent_time`, `message_updated_time` and `error-message` on get and list Message API

## [5.44.2](https://github.com/plivo/plivo-java/tree/v5.44.2) (2024-09-06)
**Feature - Adding support for brand_name and app_hash in Create,Get and List Session**
- Added new request param `brand_name`, `code_length` and `app_hash` in create Session API
Expand All @@ -7,8 +11,7 @@
## [5.44.1](https://github.com/plivo/plivo-java/tree/v5.44.1) (2024-09-03)
**Feature - Adding new element for Audio Stream XML**
- Added `keepCallAlive` element in Audio Stream XML


-
## [5.44.0](https://github.com/plivo/plivo-java/tree/v5.44.0) (2024-07-11)
**Feature - Adding locale support for Create, Get and List Session API**
- Added new request param `locale` in create Session API
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ The Plivo Java SDK makes it simpler to integrate communications into your Java a

### To Install Stable release

You can use this SDK by adding it as a dependency in your dependency management tool. Alternatively, you can use the [JAR file](https://search.maven.org/remotecontent?filepath=com/plivo/plivo-java/5.44.2/plivo-java-5.44.2.jar).
You can use this SDK by adding it as a dependency in your dependency management tool. Alternatively, you can use the [JAR file](https://search.maven.org/remotecontent?filepath=com/plivo/plivo-java/5.44.3/plivo-java-5.44.3.jar).


If you are using Maven, use the following XML to include the Plivo SDK as a dependency.
Expand All @@ -19,13 +19,13 @@ If you are using Maven, use the following XML to include the Plivo SDK as a depe
<dependency>
<groupId>com.plivo</groupId>
<artifactId>plivo-java</artifactId>
<version>5.44.2</version>
<version>5.44.3</version>
</dependency>
```

If you are using Gradle, use the following line in your dependencies.
```
compile 'com.plivo:plivo-java:5.44.2'
compile 'com.plivo:plivo-java:5.44.3'
```

### To Install Beta release
Expand Down
2 changes: 1 addition & 1 deletion pom.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Written manually.

version=5.44.2
version=5.44.3
groupId=com.plivo
artifactId=plivo-java

2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>com.plivo</groupId>
<artifactId>plivo-java</artifactId>
<version>5.44.2</version>
<version>5.43.3</version>
<name>plivo-java</name>
<description>A Java SDK to make voice calls &amp; send SMS using Plivo and to generate Plivo XML</description>
<licenses>
Expand Down
15 changes: 15 additions & 0 deletions src/main/java/com/plivo/api/models/message/Message.java
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@ public class Message extends BaseResource {
private String conversationOrigin;
private String conversationExpirationTimestamp;
private String log;
private String errorMessage;
private String messageSentTime;
private String messageUpdatedTime;

public static MessageCreator creator(String source, String destination) {
return new MessageCreator(source, destination);
Expand Down Expand Up @@ -179,7 +182,19 @@ public String getConversationExpirationTimestamp() {
public String getLog() {
return log;
}

public String getErrorMessage(){
return errorMessage;
}

public String getMessageSentTime(){
return messageSentTime;
}

public String getMessageUpdatedTime(){
return messageUpdatedTime;
}

@Override
public String getId() {
return getMessageUuid();
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/com/plivo/api/version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
5.44.2
5.44.3
5 changes: 4 additions & 1 deletion src/test/resources/com/plivo/api/messageGetResponse.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,8 @@
"dlt_template_category": "service_implicit",
"conversation_id": "9876",
"conversation_origin": "utility",
"conversation_expiration_timestamp": "2023-08-03 23:02:00+05:30"
"conversation_expiration_timestamp": "2023-08-03 23:02:00+05:30",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
}
100 changes: 80 additions & 20 deletions src/test/resources/com/plivo/api/messageListResponse.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,10 @@
"dlt_template_category": "service_explicit",
"conversation_id": "1234",
"conversation_origin": "service",
"conversation_expiration_timestamp": "2023-08-03 23:02:00+05:30"
"conversation_expiration_timestamp": "2023-08-03 23:02:00+05:30",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": null,
Expand All @@ -49,7 +52,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": null,
Expand All @@ -71,7 +77,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": null,
Expand All @@ -93,7 +102,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": null,
Expand All @@ -115,7 +127,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": null,
Expand All @@ -137,7 +152,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": null,
Expand All @@ -159,7 +177,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": null,
Expand All @@ -181,7 +202,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": "000",
Expand All @@ -203,7 +227,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": null,
Expand All @@ -225,7 +252,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": "000",
Expand All @@ -247,7 +277,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": null,
Expand All @@ -269,7 +302,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": "000",
Expand All @@ -291,7 +327,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": null,
Expand All @@ -313,7 +352,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": "000",
Expand All @@ -335,7 +377,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": null,
Expand All @@ -357,7 +402,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": "000",
Expand All @@ -379,7 +427,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": "000",
Expand All @@ -401,7 +452,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": "000",
Expand All @@ -423,7 +477,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
},
{
"error_code": "000",
Expand All @@ -445,7 +502,10 @@
"dlt_template_category": "",
"conversation_id": "",
"conversation_origin": "",
"conversation_expiration_timestamp": ""
"conversation_expiration_timestamp": "",
"message_sent_time": "2024-08-21 18:28:49.244057+05:30",
"message_updated_time": "2024-08-21 18:28:51.94772+05:30",
"error_message": ""
}
]
}

0 comments on commit 429dea1

Please sign in to comment.