messagebird
Advanced tools
Comparing version 3.5.0 to 3.6.0
@@ -278,2 +278,13 @@ /** | ||
httpRequest({ method: 'POST', path: '/messages', params: params }, callback); | ||
}, | ||
/** | ||
* Delete a text message | ||
* | ||
* @param {String} id | ||
* @param {Function} callback | ||
* @return {void} | ||
*/ | ||
delete: function (id, callback) { | ||
httpRequest({ method: 'DELETE', path: '/messages/' + id }, callback); | ||
} | ||
@@ -406,2 +417,13 @@ }, | ||
httpRequest({ method: 'POST', path: '/voicemessages', params: params }, callback); | ||
}, | ||
/** | ||
* Delete a voice message | ||
* | ||
* @param {String} id | ||
* @param {Function} callback | ||
* @return {void} | ||
*/ | ||
delete: function (id, callback) { | ||
httpRequest({ method: 'DELETE', path: '/voicemessages/' + id }, callback); | ||
} | ||
@@ -1420,2 +1442,26 @@ }, | ||
/** | ||
* Delete recordings. | ||
* | ||
* @param {String} callId | ||
* @param {String} legId | ||
* @param {String} recId | ||
* @param {Function} callback | ||
* @return void | ||
*/ | ||
delete: function (callId, legId, recId, callback) { | ||
httpRequest( | ||
{ | ||
hostname: VOICE_ENDPOINT, | ||
method: 'DELETE', | ||
path: `/calls/${callId}/legs/${legId}/recordings/${recId}`, | ||
}, | ||
callback, | ||
); | ||
}, | ||
/** | ||
* Download an existing recording. | ||
@@ -1422,0 +1468,0 @@ * |
{ | ||
"name": "messagebird", | ||
"version": "3.5.0", | ||
"version": "3.6.0", | ||
"description": "A node.js wrapper for the MessageBird REST API", | ||
@@ -38,5 +38,6 @@ "main": "lib/messagebird.js", | ||
"devDependencies": { | ||
"dtslint": "^0.9.3", | ||
"nock": "^11.3.2" | ||
"dtslint": "^4.0.7", | ||
"nock": "^11.3.2", | ||
"typescript": "^4.2.2" | ||
} | ||
} |
MessageBird REST API for Node.js | ||
================================ | ||
[![Build Status](https://travis-ci.org/messagebird/messagebird-nodejs.svg?branch=master)](https://travis-ci.org/messagebird/messagebird-nodejs) | ||
This repository contains the open source Node.js client for MessageBird's REST API. | ||
Documentation can be found at: https://developers.messagebird.com | ||
Documentation can be found at: [https://developers.messagebird.com](https://developers.messagebird.com) | ||
Requirements | ||
@@ -15,3 +16,2 @@ ------------ | ||
Installation | ||
@@ -22,3 +22,2 @@ ------------ | ||
Usage | ||
@@ -77,7 +76,10 @@ ----- | ||
``` | ||
Notes | ||
------------- | ||
Messaging and Voice API use different pagination semantics: | ||
**Messaging API** uses limit and offset params for list methods (where applicable) | ||
````javascript | ||
@@ -92,4 +94,6 @@ // list conversations | ||
}); | ||
```` | ||
```` | ||
**Voice API** uses page and perPage params for list methods (where applicable) | ||
````javascript | ||
@@ -105,2 +109,3 @@ // list Call Flows | ||
```` | ||
Verifying Signatures | ||
@@ -111,3 +116,3 @@ ------------- | ||
``` | ||
```javascript | ||
var Signature = require('messagebird/lib/signature'); | ||
@@ -136,2 +141,3 @@ | ||
``` | ||
Documentation | ||
@@ -143,5 +149,5 @@ ------------- | ||
License | ||
------- | ||
The MessageBird REST API for Node.js is licensed under [The BSD 2-Clause License](http://opensource.org/licenses/BSD-2-Clause). Copyright (c) 2014, MessageBird |
@@ -49,2 +49,3 @@ // TypeScript Version: 3.0 | ||
list(filter: FilterParameters, callback: CallbackFn<Message[]>): void; | ||
delete(id: string, callback: CallbackFn): void; | ||
}; | ||
@@ -71,2 +72,3 @@ callflows: { | ||
): void; | ||
delete(id: string, callback: CallbackFn): void; | ||
}; | ||
@@ -311,2 +313,6 @@ verify: { | ||
/** | ||
* Deletes a recording | ||
*/ | ||
delete(callId: string, legId: string, recordingId: string, callback: CallbackFn): void; | ||
/** | ||
* Downloads a recording | ||
@@ -313,0 +319,0 @@ */ |
@@ -11,8 +11,4 @@ { | ||
"strict": true, | ||
"noImplicitAny": true, | ||
"strictNullChecks": true, | ||
"strictFunctionTypes": true, | ||
"strictBindCallApply": true, | ||
"strictPropertyInitialization": true, | ||
"noImplicitThis": true, | ||
"alwaysStrict": true, | ||
@@ -19,0 +15,0 @@ |
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
186200
5677
146
3
62