|
3 | 3 | NodeJs Client library for Bandwidth Numbers API |
4 | 4 |
|
5 | 5 | ## Developer Docs |
6 | | -* [[Bandwidth API Developer Docs](https://dev.bandwidth.com) |
| 6 | +* [Bandwidth API Developer Docs](https://dev.bandwidth.com) |
7 | 7 |
|
8 | 8 | ## Other Node SDKs |
9 | 9 | * Messaging: https://github.com/Bandwidth/node-messaging |
@@ -150,6 +150,42 @@ Each entity has a get, list, create, update and delete method if appropriate. |
150 | 150 | All properties are camel-cased for Javascript readability, and are converted on the fly to the proper |
151 | 151 | case by the internals of the API when converted to XML. |
152 | 152 |
|
| 153 | +## Account |
| 154 | +### Get Move Tns Orders |
| 155 | + |
| 156 | +```js |
| 157 | +var orders = numbers.Account.getMoveTnsOrders(function(err, res){ |
| 158 | + if (err){ |
| 159 | + console.log(err) |
| 160 | + }; |
| 161 | + console.log(res); |
| 162 | +}); |
| 163 | +``` |
| 164 | + |
| 165 | +### Create Move Tns Order |
| 166 | + |
| 167 | +```js |
| 168 | +numbers = ["19195551234", "19195554321"] |
| 169 | +data = { |
| 170 | + CustomerOrderId: "abc123", |
| 171 | + SiteId: "12345", // DESTINATION sub-account (site) |
| 172 | + SipPeerId: "54321" // DESTINATION location (sip-peer) (optional - if not inclided, tn(s) will provision to default sip-peer) |
| 173 | +} |
| 174 | +data.telephoneNumbers = [numbers.map(number => {return {telephoneNumber: number}})]; |
| 175 | +numbers.account.moveTns(client, data, callback); |
| 176 | +``` |
| 177 | + |
| 178 | +### Get Move Tns Order Information |
| 179 | + |
| 180 | +```js |
| 181 | +numbers.account.getMoveTnsOrder(client, 'my-order-id-12345', callback); |
| 182 | +``` |
| 183 | + |
| 184 | +### Get Move Tns Order History |
| 185 | + |
| 186 | +```js |
| 187 | +numbers.account.getMoveTnsOrderHistory(client, 'my-order-id-12345', callback); |
| 188 | +``` |
153 | 189 |
|
154 | 190 | ## Applications |
155 | 191 | ### Create Voice Application |
|
0 commit comments