File tree Expand file tree Collapse file tree 1 file changed +8
-8
lines changed
Expand file tree Collapse file tree 1 file changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -21,7 +21,7 @@ npm install @bandwidth/messaging
2121
2222### Initialize
2323
24- ```
24+ ``` js
2525import { Client , ApiController , MessageRequest } from ' @bandwidth/messaging' ;
2626const client = new Client ({
2727 basicAuthUserName: " username" ,
@@ -33,19 +33,19 @@ const accountId = "12345";
3333```
3434
3535### Send A Text Message
36- ```
37- var applicationId = "3-a-b-c";
38- var toPhoneNumber = "+15554443333";
39- var fromPhoneNumber = "+15553334444";
40- var text = "Hello world";
41- var body = {
36+ ``` js
37+ const applicationId = " 3-a-b-c" ;
38+ const toPhoneNumber = " +15554443333" ;
39+ const fromPhoneNumber = " +15553334444" ;
40+ const text = " Hello world" ;
41+ const body = {
4242 applicationId: applicationId,
4343 to: [toPhoneNumber],
4444 from: fromPhoneNumber,
4545 text: text
4646};
4747
48- var createMessageResponse = await controller.createMessage(accountId, body);
48+ const createMessageResponse = await controller .createMessage (accountId, body);
4949console .log (createMessageResponse .result .id );
5050```
5151
You can’t perform that action at this time.
0 commit comments