Get Authentication Token

Create a Verification Service

This will check whether the user-provided token is correct.

URL

justOTP is the #1 mobile marketing platform for businesses. The platform empowers businesses to conduct scheduling, send real-time alerts, promote events, execute marketing campaigns, and provide customer service, ultimately driving higher revenue and adoption for millions of products and services.

Http Method

Nothing. The justOTP Agency Program is completely free of charge. You will earn money for every referral who signs up for justOTP as a paid customer.

Request Parameters

Nothing. The justOTP Agency Program is completely free of charge. You will earn money for every referral who signs up for justOTP as a paid customer.

Sample Request

Nothing. The justOTP Agency Program is completely free of charge. You will earn money for every referral who signs up for justOTP as a paid customer.

Sample Response

Nothing. The justOTP Agency Program is completely free of charge. You will earn money for every referral who signs up for justOTP as a paid customer.

Sample Code

// Download the helper library from https://www.twilio.com/docs/node/install
                        // Your Account Sid and Auth Token from twilio.com/console
                        // DANGER! This is insecure. See http://twil.io/secure
                        const accountSid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
                        const authToken = 'your_auth_token';
                        const client = require('twilio')(accountSid, authToken);
                        
                        client.verify.services('VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX')
                                     .verifications
                                     .create({to: '+15017122661', channel: 'sms'})
                                     .then(verification => console.log(verification.status));

C#

// Install the C# / .NET helper library from twilio.com/docs/csharp/install
                        
                        using System;
                        using Twilio;
                        using Twilio.Rest.Verify.V2.Service;
                        
                        
                        class Program
                        {
                            static void Main(string[] args)
                            {
                                // Find your Account Sid and Token at twilio.com/console
                                // DANGER! This is insecure. See http://twil.io/secure
                                const string accountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
                                const string authToken = "your_auth_token";
                        
                                TwilioClient.Init(accountSid, authToken);
                        
                                var verification = VerificationResource.Create(
                                    to: "+15017122661",
                                    channel: "sms",
                                    pathServiceSid: "VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
                                );
                        
                                Console.WriteLine(verification.Status);
                            }
                        }

PHP

<?php
                        
                        // Update the path below to your autoload.php,
                        // see https://getcomposer.org/doc/01-basic-usage.md
                        require_once '/path/to/vendor/autoload.php';
                        
                        use Twilio\Rest\Client;
                        
                        // Find your Account Sid and Auth Token at twilio.com/console
                        // DANGER! This is insecure. See http://twil.io/secure
                        $sid    = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
                        $token  = "your_auth_token";
                        $twilio = new Client($sid, $token);
                        
                        $verification = $twilio->verify->v2->services("VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX")
                                                           ->verifications
                                                           ->create("+15017122661", "sms");
                        
                        print($verification->status);

# Download the helper library from https://www.twilio.com/docs/ruby/install
                        require 'rubygems'
                        require 'twilio-ruby'
                        
                        # Your Account Sid and Auth Token from twilio.com/console
                        # DANGER! This is insecure. See http://twil.io/secure
                        account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
                        auth_token = 'your_auth_token'
                        @client = Twilio::REST::Client.new(account_sid, auth_token)
                        
                        verification = @client.verify
                                              .services('VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX')
                                              .verifications
                                              .create(to: '+15017122661', channel: 'sms')
                        
                        puts verification.status

# Download the helper library from https://www.twilio.com/docs/python/install
                        from twilio.rest import Client
                        
                        
                        # Your Account Sid and Auth Token from twilio.com/console
                        # DANGER! This is insecure. See http://twil.io/secure
                        account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
                        auth_token = 'your_auth_token'
                        client = Client(account_sid, auth_token)
                        
                        verification = client.verify \
                                             .services('VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
                                             .verifications \
                                             .create(to='+15017122661', channel='sms')
                        
                        print(verification.status)

// Install the Java helper library from twilio.com/docs/java/install
                        
                        import com.twilio.Twilio;
                        import com.twilio.rest.verify.v2.service.Verification;
                        
                        public class Example {
                            // Find your Account Sid and Token at twilio.com/console
                            // DANGER! This is insecure. See http://twil.io/secure
                            public static final String ACCOUNT_SID = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
                            public static final String AUTH_TOKEN = "your_auth_token";
                        
                            public static void main(String[] args) {
                                Twilio.init(ACCOUNT_SID, AUTH_TOKEN);
                                Verification verification = Verification.creator(
                                        "VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
                                        "+15017122661",
                                        "sms")
                                    .create();
                        
                                System.out.println(verification.getStatus());
                            }
                        }

curl -X POST "https://verify.twilio.com/v2/Services/VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Verifications" \
                        --data-urlencode "To=+15017122661" \
                        --data-urlencode "Channel=sms" \
                        -u ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token