Skip to content

Commit

Permalink
Documentation update and migration to openapi-codegen
Browse files Browse the repository at this point in the history
  • Loading branch information
developersteve committed Jun 20, 2018
1 parent fc9ce3f commit 2311903
Show file tree
Hide file tree
Showing 29 changed files with 301 additions and 240 deletions.
9 changes: 3 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
TelstraMessaging - JavaScript client for Telstra_Messaging

- API version: 2.2.6
- Package version: 1.0.4
- Package version: 1.0.4.1

## Installation

Expand Down Expand Up @@ -92,13 +92,9 @@ Please follow the [installation](#installation) instruction and execute the foll
var TelstraMessaging = require('Telstra_Messaging');

var api = new TelstraMessaging.AuthenticationApi()

var clientId = "clientId_example"; // {String}

var clientSecret = "clientSecret_example"; // {String}

var grantType = "client_credentials"; // {String}

var grantType = "'client_credentials'"; // {String}

var callback = function(error, data, response) {
if (error) {
Expand All @@ -120,6 +116,7 @@ Class | Method | HTTP request | Description
*TelstraMessaging.AuthenticationApi* | [**authToken**](docs/AuthenticationApi.md#authToken) | **POST** /oauth/token | Generate OAuth2 token
*TelstraMessaging.MessagingApi* | [**getMMSStatus**](docs/MessagingApi.md#getMMSStatus) | **GET** /messages/mms/{messageid}/status | Get MMS Status
*TelstraMessaging.MessagingApi* | [**getSMSStatus**](docs/MessagingApi.md#getSMSStatus) | **GET** /messages/sms/{messageId}/status | Get SMS Status
*TelstraMessaging.MessagingApi* | [**retrieveMMSResponses**](docs/MessagingApi.md#retrieveMMSResponses) | **GET** /messages/mms | Retrieve MMS Responses
*TelstraMessaging.MessagingApi* | [**retrieveSMSResponses**](docs/MessagingApi.md#retrieveSMSResponses) | **GET** /messages/sms | Retrieve SMS Responses
*TelstraMessaging.MessagingApi* | [**sendMMS**](docs/MessagingApi.md#sendMMS) | **POST** /messages/mms | Send MMS
*TelstraMessaging.MessagingApi* | [**sendSMS**](docs/MessagingApi.md#sendSMS) | **POST** /messages/sms | Send SMS
Expand Down
11 changes: 3 additions & 8 deletions docs/AuthenticationApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,21 +13,16 @@ Method | HTTP request | Description
Generate OAuth2 token

To generate an OAuth2 Authentication token, pass through your `Client key` and `Client secret` that you received when you registered for the "API Free Trial" Product. The grant_type should be left as `client_credentials` and the scope as `NSMS`. The token will expire in one hour. <pre><code class=\"language-sh\"> #!/bin/bash # Obtain these keys from the Telstra Developer Portal CLIENT_KEY=\"your client key\" CLIENT_SECRET=\"your client secret\" curl -X POST -H 'Content-Type: application/x-www-form-urlencoded' \\ -d 'grant_type=client_credentials&client_id=$CLIENT_KEY&client_secret=CLIENT_SECRET&scope=NSMS' \\ 'https://tapi.telstra.com/v2/oauth/token' </code></pre>
To generate an OAuth2 Authentication token, pass through your `Client key` and `Client secret` that you received when you registered for the **API Free Trial** Product. The grant_type should be left as `client_credentials` and the scope as `NSMS`. The token will expire in one hour.

### Example
```javascript
var TelstraMessaging = require('Telstra_Messaging');

var apiInstance = new TelstraMessaging.AuthenticationApi();

var clientId = "clientId_example"; // String |

var clientSecret = "clientSecret_example"; // String |

var grantType = "client_credentials"; // String |


var grantType = "'client_credentials'"; // String |
var callback = function(error, data, response) {
if (error) {
console.error(error);
Expand All @@ -44,7 +39,7 @@ Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**clientId** | **String**| |
**clientSecret** | **String**| |
**grantType** | **String**| | [default to client_credentials]
**grantType** | **String**| | [default to 'client_credentials']

### Return type

Expand Down
4 changes: 2 additions & 2 deletions docs/InboundPollResponse.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**status** | **String** | message status | [optional]
**destinationAddress** | **String** | The phone number (recipient) that the message was sent to(in E.164 format). | [optional]
**senderAddress** | **String** | The phone number (sender) that the message was sent from (in E.164 format). | [optional]
**destinationAddress** | **String** | The phone number (recipient) that the message was sent to (in E.164 format). | [optional]
**senderAddress** | **String** | The phone number (sender) that the message was sent from (in E.164 format). | [optional]
**message** | **String** | Text of the message that was sent | [optional]
**messageId** | **String** | Message Id | [optional]
**sentTimestamp** | **String** | The date and time when the message was sent by recipient. | [optional]
Expand Down
2 changes: 1 addition & 1 deletion docs/MMSContent.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**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 |
**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\" |
**filename** | **String** | The file name to be associated with the content. Some devices will display this file name with a placeholder for the content. |
**payload** | **String** | |

Expand Down
Loading

0 comments on commit 2311903

Please sign in to comment.