Skip to content

Commit e9153c8

Browse files
Documentation update and migration to openapi-codegen
1 parent 427f7b2 commit e9153c8

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+1546
-1211
lines changed

README.md

Lines changed: 29 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,45 @@
11
# TelstraMessaging
22

3+
Telstra Messaging API
4+
- API version: 2.2.6
5+
- Build date: 2018-06-20T14:25:51.755551+10:00[Australia/Melbourne]
6+
7+
8+
9+
10+
311
## Requirements
412

5-
Building the API client library requires [Maven](https://maven.apache.org/) to be installed.
13+
Building the API client library requires:
14+
1. Java 1.7+
15+
2. Maven/Gradle
616

717
## Installation
818

919
To install the API client library to your local Maven repository, simply execute:
1020

1121
```shell
12-
mvn install
22+
mvn clean install
1323
```
1424

1525
To deploy it to a remote Maven repository instead, configure the settings of the repository and execute:
1626

1727
```shell
18-
mvn deploy
28+
mvn clean deploy
1929
```
2030

21-
Refer to the [official documentation](https://maven.apache.org/plugins/maven-deploy-plugin/usage.html) for more information.
31+
Refer to the [OSSRH Guide](http://central.sonatype.org/pages/ossrh-guide.html) for more information.
2232

2333
### Maven users
2434

2535
Add this dependency to your project's POM:
2636

2737
```xml
2838
<dependency>
29-
<groupId>Telstra</groupId>
30-
<artifactId>TelstraMessaging</artifactId>
31-
<version>1.0.0</version>
32-
<scope>compile</scope>
39+
<groupId>Telstra</groupId>
40+
<artifactId>TelstraMessaging</artifactId>
41+
<version>1.0.0</version>
42+
<scope>compile</scope>
3343
</dependency>
3444
```
3545

@@ -45,12 +55,13 @@ compile "Telstra:TelstraMessaging:1.0.0"
4555

4656
At first generate the JAR by executing:
4757

48-
mvn package
58+
```shell
59+
```
4960

5061
Then manually install the following JARs:
5162

52-
* target/TelstraMessaging-1.0.0.jar
53-
* target/lib/*.jar
63+
* `target/TelstraMessaging-1.0.0.jar`
64+
* `target/lib/*.jar`
5465

5566
## Getting Started
5667

@@ -71,9 +82,9 @@ public class AuthenticationApiExample {
7182
public static void main(String[] args) {
7283

7384
AuthenticationApi apiInstance = new AuthenticationApi();
74-
String clientId = "clientId_example"; // String |
75-
String clientSecret = "clientSecret_example"; // String |
76-
String grantType = "client_credentials"; // String |
85+
String clientId = "null"; // String |
86+
String clientSecret = "null"; // String |
87+
String grantType = "\"client_credentials\""; // String |
7788
try {
7889
OAuthResponse result = apiInstance.authToken(clientId, clientSecret, grantType);
7990
System.out.println(result);
@@ -92,9 +103,10 @@ All URIs are relative to *https://tapi.telstra.com/v2*
92103

93104
Class | Method | HTTP request | Description
94105
------------ | ------------- | ------------- | -------------
95-
*AuthenticationApi* | [**authToken**](docs/AuthenticationApi.md#authToken) | **POST** /oauth/token | Generate authentication token
106+
*AuthenticationApi* | [**authToken**](docs/AuthenticationApi.md#authToken) | **POST** /oauth/token | Generate OAuth2 token
96107
*MessagingApi* | [**getMMSStatus**](docs/MessagingApi.md#getMMSStatus) | **GET** /messages/mms/{messageid}/status | Get MMS Status
97108
*MessagingApi* | [**getSMSStatus**](docs/MessagingApi.md#getSMSStatus) | **GET** /messages/sms/{messageId}/status | Get SMS Status
109+
*MessagingApi* | [**retrieveMMSResponses**](docs/MessagingApi.md#retrieveMMSResponses) | **GET** /messages/mms | Retrieve MMS Responses
98110
*MessagingApi* | [**retrieveSMSResponses**](docs/MessagingApi.md#retrieveSMSResponses) | **GET** /messages/sms | Retrieve SMS Responses
99111
*MessagingApi* | [**sendMMS**](docs/MessagingApi.md#sendMMS) | **POST** /messages/mms | Send MMS
100112
*MessagingApi* | [**sendSMS**](docs/MessagingApi.md#sendSMS) | **POST** /messages/sms | Send SMS
@@ -106,15 +118,11 @@ Class | Method | HTTP request | Description
106118
## Documentation for Models
107119

108120
- [DeleteNumberRequest](docs/DeleteNumberRequest.md)
109-
- [ErrorError](docs/ErrorError.md)
110-
- [ErrorErrorError](docs/ErrorErrorError.md)
111121
- [GetSubscriptionResponse](docs/GetSubscriptionResponse.md)
112122
- [InboundPollResponse](docs/InboundPollResponse.md)
113123
- [MMSContent](docs/MMSContent.md)
114124
- [Message](docs/Message.md)
115125
- [MessageSentResponse](docs/MessageSentResponse.md)
116-
- [MessageType](docs/MessageType.md)
117-
- [OAuthRequest](docs/OAuthRequest.md)
118126
- [OAuthResponse](docs/OAuthResponse.md)
119127
- [OutboundPollResponse](docs/OutboundPollResponse.md)
120128
- [ProvisionNumberRequest](docs/ProvisionNumberRequest.md)
@@ -124,14 +132,14 @@ Class | Method | HTTP request | Description
124132
- [Status](docs/Status.md)
125133

126134

127-
## Documentation for Authorization
135+
## Documentation for Authorisation
128136

129137
Authentication schemes defined for the API:
130138
### auth
131139

132140
- **Type**: OAuth
133141
- **Flow**: application
134-
- **Authorization URL**:
142+
- **Authorisation URL**:
135143
- **Scopes**:
136144
- NSMS: NSMS
137145

build.gradle

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,10 +94,11 @@ if(hasProperty('target') && target == 'android') {
9494
}
9595

9696
dependencies {
97-
compile 'io.swagger:swagger-annotations:1.5.15'
97+
compile 'io.swagger:swagger-annotations:1.5.17'
9898
compile 'com.squareup.okhttp:okhttp:2.7.5'
9999
compile 'com.squareup.okhttp:logging-interceptor:2.7.5'
100100
compile 'com.google.code.gson:gson:2.8.1'
101-
compile 'joda-time:joda-time:2.9.9'
101+
compile 'io.gsonfire:gson-fire:1.8.0'
102+
compile 'org.threeten:threetenbp:1.3.5'
102103
testCompile 'junit:junit:4.12'
103104
}

build.sbt

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,12 @@ lazy val root = (project in file(".")).
99
publishArtifact in (Compile, packageDoc) := false,
1010
resolvers += Resolver.mavenLocal,
1111
libraryDependencies ++= Seq(
12-
"io.swagger" % "swagger-annotations" % "1.5.15",
12+
"io.swagger" % "swagger-annotations" % "1.5.17",
1313
"com.squareup.okhttp" % "okhttp" % "2.7.5",
1414
"com.squareup.okhttp" % "logging-interceptor" % "2.7.5",
1515
"com.google.code.gson" % "gson" % "2.8.1",
16-
"joda-time" % "joda-time" % "2.9.9" % "compile",
16+
"org.threeten" % "threetenbp" % "1.3.5" % "compile",
17+
"io.gsonfire" % "gson-fire" % "1.8.0" % "compile",
1718
"junit" % "junit" % "4.12" % "test",
1819
"com.novocode" % "junit-interface" % "0.10" % "test"
1920
)

docs/AuthenticationApi.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,16 @@ All URIs are relative to *https://tapi.telstra.com/v2*
44

55
Method | HTTP request | Description
66
------------- | ------------- | -------------
7-
[**authToken**](AuthenticationApi.md#authToken) | **POST** /oauth/token | Generate authentication token
7+
[**authToken**](AuthenticationApi.md#authToken) | **POST** /oauth/token | Generate OAuth2 token
88

99

1010
<a name="authToken"></a>
1111
# **authToken**
1212
> OAuthResponse authToken(clientId, clientSecret, grantType)
1313
14-
Generate authentication token
14+
Generate OAuth2 token
1515

16-
Generate authentication token
16+
To generate an OAuth2 Authentication token, pass through your &#x60;Client key&#x60; and &#x60;Client secret&#x60; that you received when you registered for the **API Free Trial** Product. The grant_type should be left as &#x60;client_credentials&#x60; and the scope as &#x60;NSMS&#x60;. The token will expire in one hour.
1717

1818
### Example
1919
```java
@@ -23,9 +23,9 @@ Generate authentication token
2323

2424

2525
AuthenticationApi apiInstance = new AuthenticationApi();
26-
String clientId = "clientId_example"; // String |
27-
String clientSecret = "clientSecret_example"; // String |
28-
String grantType = "client_credentials"; // String |
26+
String clientId = "null"; // String |
27+
String clientSecret = "null"; // String |
28+
String grantType = "\"client_credentials\""; // String |
2929
try {
3030
OAuthResponse result = apiInstance.authToken(clientId, clientSecret, grantType);
3131
System.out.println(result);
@@ -39,9 +39,9 @@ try {
3939

4040
Name | Type | Description | Notes
4141
------------- | ------------- | ------------- | -------------
42-
**clientId** | **String**| |
43-
**clientSecret** | **String**| |
44-
**grantType** | **String**| | [default to client_credentials]
42+
**clientId** | **String**| | [default to null]
43+
**clientSecret** | **String**| | [default to null]
44+
**grantType** | **String**| | [default to &quot;client_credentials&quot;]
4545

4646
### Return type
4747

docs/InboundPollResponse.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@
55
Name | Type | Description | Notes
66
------------ | ------------- | ------------- | -------------
77
**status** | **String** | message status | [optional]
8-
**destinationAddress** | **String** | The phone number (recipient) that the message was sent to(in E.164 format). | [optional]
9-
**senderAddress** | **String** | The phone number (sender) that the message was sent from (in E.164 format). | [optional]
8+
**destinationAddress** | **String** | The phone number (recipient) that the message was sent to (in E.164 format). | [optional]
9+
**senderAddress** | **String** | The phone number (sender) that the message was sent from (in E.164 format). | [optional]
1010
**message** | **String** | Text of the message that was sent | [optional]
1111
**messageId** | **String** | Message Id | [optional]
1212
**sentTimestamp** | **String** | The date and time when the message was sent by recipient. | [optional]

docs/MMSContent.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
## Properties
55
Name | Type | Description | Notes
66
------------ | ------------- | ------------- | -------------
7-
**type** | **String** | The following types are supported audio/amr audio/aac audio/mp3 audio/mpeg3 audio/mpeg audio/mpg audio/wav audio/3gpp audio/mp4 image/gif image/jpeg image/jpg image/png image/bmp video/mpeg4 video/mp4 video/mpeg video/3gpp video/3gp video/h263 text/plain text/x-vCard text/x-vCalendar |
7+
**type** | **String** | The following types are supported audio/amr audio/aac audio/mp3 audio/mpeg3 audio/mpeg audio/mpg audio/wav audio/3gpp audio/mp4 image/gif image/jpeg image/jpg image/png image/bmp video/mpeg4 video/mp4 video/mpeg video/3gpp video/3gp video/h263 text/plain text/x-vCard text/x-vCalendar\&quot; |
88
**filename** | **String** | The file name to be associated with the content. Some devices will display this file name with a placeholder for the content. |
99
**payload** | **String** | |
1010

docs/Message.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@
44
## Properties
55
Name | Type | Description | Notes
66
------------ | ------------- | ------------- | -------------
7-
**to** | **String** | |
8-
**deliveryStatus** | **String** | |
9-
**messageId** | **String** | |
10-
**messageStatusURL** | **String** | | [optional]
7+
**to** | **String** | Just a copy of the number the message is sent to. |
8+
**deliveryStatus** | **String** | Gives an indication if the message has been accepted for delivery. The description field contains information on why a message may have been rejected. |
9+
**messageId** | **String** | For an accepted message, ths will be a unique reference that can be used to check the messages status. Please refer to the Delivery Notification section. Note that &#x60;messageId&#x60; will be different for each number that the message was sent to. |
10+
**messageStatusURL** | **String** | For an accepted message, ths will be the URL that can be used to check the messages status. Please refer to the Delivery Notification section. | [optional]
1111

1212

1313

docs/MessageSentResponse.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@
44
## Properties
55
Name | Type | Description | Notes
66
------------ | ------------- | ------------- | -------------
7-
**messages** | [**List&lt;Message&gt;**](Message.md) | |
8-
**messageType** | **String** | |
9-
**numberSegments** | **Integer** | |
10-
**numberNationalDestinations** | **Integer** | | [optional]
11-
**numberInternationalDestinations** | **Integer** | | [optional]
7+
**messages** | [**List&lt;Message&gt;**](Message.md) | An array of messages. |
8+
**messageType** | **String** | This returns whether the message sent was a SMS or MMS. |
9+
**numberSegments** | **Integer** | For SMS messages only, the value indicates the number of 160 character message segments sent. |
10+
**numberNationalDestinations** | **Integer** | This returns the number of domestic Australian messages sent. | [optional]
11+
**numberInternationalDestinations** | **Integer** | This returns the number of international messages sent | [optional]
1212

1313

1414

0 commit comments

Comments
 (0)