Download as txt, pdf, or txt
Download as txt, pdf, or txt
You are on page 1of 3

as per meeting discusion

using RestSharp;

var options = new RestClientOptions("https://api.gupshup.io/sm/api/v1/msg");


var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("accept", "application/json");
request.AddHeader("Content-Type", "application/x-www-form-urlencoded");
var response = await client.PostAsync(request);

Console.WriteLine("{0}", response.Content);

using RestSharp;

var options = new


RestClientOptions("http://enterprise.smsgupshup.com/GatewayAPI/rest");
var client = new RestClient(options);
var request = new RestRequest("");
var response = await client.GetAsync(request);

Console.WriteLine("{0}", response.Content);

tBoTA8iHKgtU1PewHtxb95XlzY_Rb0QSpnBQh5qu

+917394998854
+14155238886
+15735945636

whole-section

var accountSid = "AC0b63871d40d3721e7556ec50a10a642e";


var authToken = "[AuthToken]";
TwilioClient.Init(accountSid, authToken);

var messageOptions = new CreateMessageOptions(


new PhoneNumber("whatsapp:+917394998854"));
messageOptions.From = new PhoneNumber("whatsapp:+14155238886");
messageOptions.Body = "Your appointment is coming up on July 21 at 3PM";

var message = MessageResource.Create(messageOptions);


Console.WriteLine(message.Body);
which is join sandbox

//const string accountSid = "AC0b63871d40d3721e7556ec50a10a642e";


//const string authToken = "a8e7287306aa2c159d9c58db9f9f2c8e";

//TwilioClient.Init(accountSid, authToken);

//var message = MessageResource.Create(


// body: "Hello there!",
// from: new Twilio.Types.PhoneNumber("whatsapp:+14155238886"),
// to: new Twilio.Types.PhoneNumber("whatsapp:+917394998854")
//);

//Console.WriteLine(message.Sid);

//var url = "https://api.ultramsg.com/instance58146/messages/chat";


//var client = new RestClient(url);

//var request = new RestRequest(url, Method.Post);


//request.AddHeader("content-type", "application/x-www-form-
urlencoded");
//request.AddParameter("token", "qld56epyyjm5rp7v");
//request.AddParameter("to", "+917394998854");
//request.AddParameter("body", "MAdhuri patel");

//RestResponse response = client.Execute(request);


//var output = response.Content;
//Console.WriteLine(output);
//string instanceId = "instance950"; // your instanceId
//string token = "yourtoken"; //instance Token
//string mobile = "14155552671";
//string message = "WhatsApp API on UltraMsg.com works good";
//var url = "https://api.ultramsg.com/" + instanceId +
"/messages/chat";
//var client = new RestClient(url);
//var request = new RestRequest(url, Method.Post);
//request.AddHeader("content-type", "application/x-www-form-
urlencoded");
//request.AddParameter("token", token);
//request.AddParameter("to", mobile);
//request.AddParameter("body", message);

//RestResponse response = await client.ExecuteAsync(request);


//var output = response.Content;
//Console.WriteLine(output);

//string accountSid =
Environment.GetEnvironmentVariable("ACfbe44785bf8d16ced92fa3af7f941a9e");
//string authToken =
Environment.GetEnvironmentVariable("b63ac55ed0e9b13d5fa946fb3ba772f0");

//TwilioClient.Init(accountSid, authToken);

//var message = MessageResource.Create(


// body: "Hello there!",
// from: new Twilio.Types.PhoneNumber("whatsapp:+14155238886"),
// to: new Twilio.Types.PhoneNumber("whatsapp:+917394998854")
//);

//Console.WriteLine(message.Sid);

Today's task status


------------------
Worked on Whatsapp chatbot
1.Implemented Twilio token for send and receive data on whatsapp from
free trial we can send msg only registerd moble number on twilio from twilio
number.
2.second we have implemented Ultramsg API sussessfully msg send and received.
3.discuss from birinder sir.

Implemented Ultramsg whatsapp chat API for send and receive data on whatsapp.

You might also like