Esempio n. 1
0
        public void ShouldSetProperApiVersion()
        {
            var client = new LookupsClient("XXXXXX", "XXXXXXX");

            Assert.AreEqual("v1", client.ApiVersion);

        }
    static void Main(string[] args)
    {
        // Find your Account Sid and Auth Token at twilio.com/console
        const string accountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
        const string authToken = "your_auth_token";
        var lookupsClient = new LookupsClient(accountSid, authToken);

        var phoneNumber = lookupsClient.GetPhoneNumber("+4402077651182", false);

        Console.WriteLine(phoneNumber.NationalFormat);
    }
    static void Main(string[] args)
    {
        // Find your Account Sid and Auth Token at twilio.com/console
        const string accountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
        const string authToken = "your_auth_token";
        var lookupsClient = new LookupsClient(accountSid, authToken);

        var phoneNumber = lookupsClient.GetPhoneNumber("(510) 867-5309", "US", false);

        Console.WriteLine(phoneNumber.PhoneNumber);
    }
    static void Main(string[] args)
    {
        // Find your Account Sid and Auth Token at twilio.com/user/account
        const string accountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
        const string authToken = "your_auth_token";
        var lookupsClient = new LookupsClient(accountSid, authToken);

        // Look up a phone number in local format
        var phoneNumber = lookupsClient.GetPhoneNumber("(510) 867-5309", "US", true);
        Console.WriteLine(phoneNumber.Carrier.Type);
        Console.WriteLine(phoneNumber.Carrier.Name);
    }
Esempio n. 5
0
        public void ShouldSetProperBaseUrl()
        {
            var client = new LookupsClient("XXXXXX", "XXXXXXX");

            Assert.AreEqual("https://lookups.twilio.com/", client.BaseUrl);
        }