Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const request = require('request');
- const options = {
- url: 'https://ln....api.infobip.com/sms/2/text/single',
- json: {
- from: 'Infobip',
- to: '5573991626817',
- text: 'Teste'
- },
- headers: {
- 'Authorization': 'App ca8c0e09e3ad4058f5b462e...',
- 'Content-Type': 'application/json',
- 'Accept': 'application/json'
- }
- }
- request.post(options,(err, response) => {
- if (err){
- return console.log(err)
- }
- console.log(`Status code: ${response.statusCode}. Message: ${response.body}`);
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement