メニュー

Rate this page:

Thanks for rating this page!

We are always striving to improve our documentation quality, and your feedback is valuable to us. How could this documentation serve you better?

Verify API (Beta)

Twilio's new Verify API is currently available as a Public Beta product. Some features are not yet implemented and others may be changed before the product is declared as Generally Available. Public Beta products are not covered by a Twilio SLA.

As part of Twilio's account security offerings, the Twilio Verify API makes it simple to add phone verification to your web application. It supports codes sent via voice and SMS.

ベースURL

このドキュメントで参照されるベースURLは次の通りです。

https://verify.twilio.com/v2/

TwilioのREST APIはHTTPS経由で提供されます。 データのプライバシーを確保するため、暗号化されていないHTTPはサポートされません。

認証

HTTP requests to the REST API are protected with HTTP Basic authentication. To learn more about how Twilio handles authentication, please refer to our security documentation. In short, you will use your Twilio account SID as the username and your auth token as the password for HTTP Basic authentication.

curl -XPOST https://verify.twilio.com/v2/Services \
    -d FriendlyName=MyServiceName \
    -u '[YOUR ACCOUNT SID]:[YOUR AUTH TOKEN]'

You can find your account SID and auth token in your console.

Phone Verification Workflow

There are 3 steps to completing a phone verification:

1. First, Create a Verification Service

A Verification Service is the set of common configurations used to create and check verifications. This includes features like:

  • Friendly Name (used in the Verification message templates)
  • Code Length
  • ...and more

You can also create and configure Verification Services in the Twilio Console.

2. Using your Service SID from Step 1, 検証トークンを送信する

This will send a token to the end user through the specified channel (e.g. SMS).

3. Check the Verification Token

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

Check out the linked docs to try it for yourself!

We're actively looking to improve our new Verify API and its documentation. If you have any thoughts, comments, questions, or feedback, rate this page and leave us a note. We really do read these!

Rate this page:

ヘルプが必要ですか?

We all do sometimes; code is hard. Get help now from our support team, or lean on the wisdom of the crowd browsing the Twilio tag on Stack Overflow.