Bird Verify

Preview में

वह verification API जिसमें store करने के लिए कुछ नहीं।

यहां सेटअप करें:
Cursor

Email, SMS, या WhatsApp पर एक one-time code भेजें, फिर उसे recipient के आधार पर check करें, दोनों calls के बीच रखने के लिए कोई verification id नहीं। Channel क्रम, sender, और code नियम हर देश के लिए configuration हैं, rebuild नहीं। हर दूसरे Bird channel जैसा ही auth और idempotency, क्योंकि इन सबको एक ही team ने बनाया है। Voice आगे रोल आउट हो रहा है।

verify.ts
200 · pending
import { BirdClient } from "@messagebird/sdk";

const bird = new BirdClient({ apiKey: process.env.BIRD_API_KEY! });

// Send the code, then check it by recipient.
await bird.verify.verifications.create({
  to: { phone_number: "+15551234567" },
}).safe();

const { data } = await bird.verify.verifications.check({
  to:   { phone_number: "+15551234567" },
  code: userInput,
}).safe();

Install से verified user तक दो calls

एक code भेजें, फिर उसे check करें, उसी भाषा में जो आप पहले से इस्तेमाल करते हैं।

Create-or-retry code भेजता है; check उसे recipient के आधार पर confirm करता है। दो calls, और दोनों के बीच पिरोने के लिए कोई verification id नहीं।

1
2
3
4
5
6
7
8
9
10
11
12
import { BirdClient } from "@messagebird/sdk";

const bird = new BirdClient({ apiKey: process.env.BIRD_API_KEY! });

await bird.verify.verifications.create({
  to: { phone_number: "+15551234567" },
}).safe();

const { data } = await bird.verify.verifications.check({
  to:   { phone_number: "+15551234567" },
  code: "482917",
}).safe();

दस चीजें जो आप नहीं बनाते जब verification ही API हो।

ठोस primitives, नामित और configurable। कोई गोलमोल बात नहीं।

  1. 01

    एक ही call में create या retry।

    वही recipient दोबारा post करें और हम live session फिर से शुरू कर देते हैं और cooldown बीतते ही दोबारा भेज देते हैं। कोई अलग resend endpoint नहीं, कोई duplicate verifications नहीं।

  2. 02

    Target के आधार पर check करें। कुछ भी store न करें।

    Recipient और code submit करें; हम configuration-और-recipient जोड़ी से session resolve कर लेते हैं। Send और check के बीच persist करने के लिए कोई verification id नहीं होती।

  3. 03

    Launch पर Email, SMS, और WhatsApp।

    आप जो recipient देते हैं वही channel चुनता है: एक email address email से verify होता है, एक phone number SMS या WhatsApp से। Channels बदलना एक-field का बदलाव है, नया integration नहीं। Voice आगे रोल आउट हो रहा है, और channels के बीच automatic fallback रास्ते में है।

  4. 04

    Per-country channel क्रम, config के रूप में।

    Channel क्रम, sender, और कौन-से channels चालू हैं, हर देश के लिए, एक first-class configuration resource के रूप में सेट करें, न कि support ticket के जरिए।

  5. 05

    वे codes जो आप कभी नहीं देखते।

    एक cryptographic random source से generate किए गए, केवल HMAC के रूप में store किए गए, constant time में तुलना किए गए। Plaintext code कभी आपके stack या हमारे logs को नहीं छूता।

  6. 06

    Configurable code, TTL, attempts।

    छह-अंकों का default, 4–10 configurable; एक 10-मिनट का window; 5 attempts; एक 60-second resend cooldown, हर configuration के लिए सेट। Code length को हर request के लिए भी override किया जा सकता है।

  7. 07

    हर code session खत्म होने तक valid रहता है।

    एक देर से आया message और एक ताजा दोबारा भेजा गया code दोनों verify करते हैं, क्योंकि जब नया code जाता है तब हम पुराने code को invalidate नहीं करते।

  8. 08

    गलत code एक 200 है, exception नहीं।

    Check एक boolean result के साथ जवाब देता है — इस code ने verify किया या नहीं, हां या नहीं — और एक reason जो न होने पर विस्तार देता है: invalid, expired, already verified, या attempts खत्म। आप एक field पर branch करते हैं, कभी किसी thrown error पर नहीं।

  9. 09

    Rate limits और quotas built in।

    Per-recipient send caps, एक per-verification guess limit, और एक per-workspace daily quota, हर एक Retry-After के साथ एक 429, ताकि brute force आपसे पहले खत्म हो जाए।

  10. 10

    बाकी Bird जैसा ही contract।

    Bearer auth, एक idempotency key, typed vrf_ ids, एक error envelope। जो handler आपने email के लिए लिखा वह verification के लिए पहले से फिट बैठता है।

Send और check के बीच कुछ भी store न करें।

ज्यादातर verification APIs आपको एक id देती हैं जिसे persist करना, look up करना, और उसके खिलाफ code submit करना होता है। Bird recipient से session resolve कर लेता है, इसलिए आपकी तरफ कोई per-verification state नहीं होती।

ज्यादातर verification APIs

Create एक id return करता है जिसे आप store करते हैं, फिर उसके खिलाफ code check करने के लिए verification को look up करते हैं।

id-keyed.ts
const { id } = await api.verifications.create({
  to: "+15551234567",
});
// persist id somewhere, then later…
await api.verifications.check({ id, code });

Bird Verify

Recipient के आधार पर check करें। दोनों calls के बीच पिरोने के लिए कुछ नहीं।

by-target.ts
await bird.verify.verifications.create({
  to: { phone_number: "+15551234567" },
}).safe();
// no id to store; check by the same recipient
await bird.verify.verifications.check({
  to: { phone_number: "+15551234567" }, code,
}).safe();

Per-country routing configuration है।

Channel क्रम, sender, और कौन-से channels चालू हैं यह हर देश के लिए सेट करें — एक बाजार में WhatsApp-first, दूसरे में SMS-only। यह एक first-class config resource है, जो हर verification के plan में resolve होता है। देखें channel orchestration

per-country.ts
200
await bird.verify.verifications.configurations.countries.upsert(
  "vfc_login",
  "BR",
  { channels: [
    { channel: "whatsapp", state: "enabled" },
    { channel: "sms", state: "enabled" },
  ] },
).safe();

Verification एक product निर्णय भी है: वही API two-factor authentication और passwordless login को शक्ति देता है। पहले किसी number को validate कर रहे हैं? इसे Lookup के साथ जोड़ें। Silent network authentication और TOTP authenticator apps roadmap पर हैं।

हम Verify क्यों बनाते हैं

क्योंकि जो code किसी user को अंदर आने देता है उसे अपनी खुद की database table की जरूरत नहीं होनी चाहिए।

OTP वह channel है जहां जो code नहीं पहुंचता वह signup है जो नहीं होता। Bird पहले से email और SMS को scale पर चलाता है, इसलिए Verify वही delivery है और साथ में code generation, session, per-country channel plan, और rate limits, दो endpoints के पीछे जो आपकी तरफ कुछ store नहीं करते और हर दूसरे Bird channel जैसे ही आकार में जवाब देते हैं।

verify.ts
200 · pending
import { BirdClient } from "@messagebird/sdk";

const bird = new BirdClient({ apiKey: process.env.BIRD_API_KEY! });

// Send the code, then check it by recipient.
await bird.verify.verifications.create({
  to: { phone_number: "+15551234567" },
}).safe();

const { data } = await bird.verify.verifications.check({
  to:   { phone_number: "+15551234567" },
  code: userInput,
}).safe();

यदि आपने SMS integrate किया है, तो आपने Verify integrate कर लिया है।

वही auth model, वही idempotency contract, वही error envelope। फर्क बस इतना है कि Verify code generate करता है, channel चुनता है, और rate limits चलाता है — ताकि आपको न करना पड़े।

Verify

एक call code भेजती है; एक call उसे recipient के आधार पर check करती है। Code, session और limits हमारे जिम्मे हैं।

verify.ts
await bird.verify.verifications.create({
  to: { phone_number: "+15551234567" },
});

SMS

Raw send, जब आप code generation और retry policy खुद संभालना चाहते हैं।

notify.ts
await bird.sms.send({
  from:     "Bird",
  to:       "+15551234567",
  text:     `Your code is ${code}.`,
  category: "authentication",
});

Verify API FAQ

मैं अपने ऐप में verification कैसे जोड़ूं?+
दो calls: किसी recipient के लिए एक verification बनाएं, फिर वे जो code दर्ज करते हैं उसे check करें। Check recipient के आधार पर होता है, इसलिए दोनों के बीच store करने के लिए कोई verification id नहीं होती — configuration id (एक constant) और address ही आपके लिए काफी हैं।
मैं किन channels पर verify कर सकता हूं?+
आज Email, SMS और WhatsApp। Voice एक अतिरिक्त channel के रूप में रोल आउट हो रहा है, और channel क्रम, sender, और कौन-से channels चालू हैं यह हर देश के हिसाब से configurable है — बिना किसी code बदलाव के।
क्या मुझे verification id store करनी पड़ती है?+
नहीं। दोबारा भेजना वही create call है (create-or-retry), और checking recipient address के आधार पर होती है, इसलिए किसी verification को आपकी तरफ किसी per-request state की जरूरत नहीं। यदि आप बाद में status पढ़ना चाहें तो एक id return होती है, पर वह optional है।
जब कोई गलत code दर्ज करता है तो क्या होता है?+
Check एक result के साथ 200 return करता है — जब तक attempts बचे हैं तब तक invalid, उनके खत्म हो जाने पर failed, या window बीत जाने पर expired। गलत code एक सामान्य परिणाम है जिस पर आप branch करते हैं, HTTP error नहीं।
Codes कैसे generate और store किए जाते हैं?+
Codes एक cryptographic random source से generate होते हैं और केवल HMAC-SHA256 hash के रूप में store होते हैं, जिनकी तुलना constant time में की जाती है। Plaintext code कभी return नहीं होता और कभी आपके stack या हमारे logs में नहीं लिखा जाता। Length (4–10 digits), TTL, और attempt limits configurable हैं।
इसकी कीमत कितनी है?+
Verify preview में है और अभी सार्वजनिक price list पर नहीं है। संपर्क करें और हम आपके channels और volume के लिए pricing समझा देंगे।
मेरे users को code किसकी ओर से दिखता है?+
Authifly, Bird की verification brand। यह हर code पर वह पहचान है जो आपके users को मिलती है: email otp@verify.authifly.com से या आपके अपने verified domain से आती है, और SMS तथा WhatsApp Authifly-branded हैं। authifly.com एक सार्वजनिक page है जो recipients को आश्वस्त करता है कि Authifly किसी व्यवसाय की ओर से वैध one-time codes भेजती है। Bird वह platform है जिस पर आप build करते हैं; Authifly वह है जो recipient को दिखती है।

वह sender जो आपके users को दिखता है: Authifly

आपके end users को उनके codes Authifly से मिलते हैं, जो Bird की verification brand है। साझा senders पर OTP email otp@verify.authifly.com से आता है और SMS संदेश में Authifly का नाम होता है, ताकि codes एक सुसंगत पहचान के तहत आएं जिसे चलाना आपको नहीं पड़ता। यदि किसी recipient को अप्रत्याशित code मिलता है, तो authifly.com उन्हें आश्वस्त करता है कि Authifly किसी व्यवसाय की ओर से वैध one-time codes भेजती है। Authifly का संचालन Bird B.V. करती है।

authifly.com पर जाएं

आपके बाकी messaging जैसी ही platform पर verification।

Verify preview में है। आज ही एक build शुरू करें, या हमसे उन channels, volume, और pricing के बारे में बात करें जिनकी आपको जरूरत है।

एक चैनल से शुरुआत करें।
तैयार होने पर बाकी जोड़ें।

एक test API key तुरंत आपकी है। जब आप payment method जोड़ते हैं और sender verify करते हैं, तब production अनलॉक हो जाता है।

Claude Code, Cursor या Codex इस्तेमाल कर रहे हैं? एक setup prompt कॉपी करें और आपका agent आपके लिए Bird CLI और skills इंस्टॉल कर देगा। अपना चुनें:

Cursor