Module: Whatsapp::BusinessPhoneNumber
- Defined in:
- lib/ruby/whatsapp/business_phone_number.rb,
lib/ruby/whatsapp/business_phone_number/account.rb,
lib/ruby/whatsapp/business_phone_number/profile.rb,
lib/ruby/whatsapp/business_phone_number/register.rb,
lib/ruby/whatsapp/business_phone_number/response.rb,
lib/ruby/whatsapp/business_phone_number/transport.rb,
lib/ruby/whatsapp/business_phone_number/deregister.rb,
lib/ruby/whatsapp/business_phone_number/account/get.rb,
lib/ruby/whatsapp/business_phone_number/profile/get.rb,
lib/ruby/whatsapp/business_phone_number/verify_code.rb,
lib/ruby/whatsapp/business_phone_number/request_code.rb,
lib/ruby/whatsapp/business_phone_number/account/update.rb,
lib/ruby/whatsapp/business_phone_number/profile/update.rb,
lib/ruby/whatsapp/business_phone_number/account/details.rb,
lib/ruby/whatsapp/business_phone_number/profile/details.rb,
lib/ruby/whatsapp/business_phone_number/account/transport.rb,
lib/ruby/whatsapp/business_phone_number/profile/verticals.rb
Overview
Onboards and deboards a business phone number with Cloud API: requesting and verifying a phone number's verification code, then registering or deregistering it.
This is the switch that makes a phone number usable — or not — with Cloud API in
the first place. It is a different concern from SubscribedApp, which
turns webhook delivery on and off for a whole WhatsApp Business Account: this
module is per phone number and is a prerequisite for messaging itself, not just
for notifications. The onboarding actions address phone_id, like
Media and Messages.
The full flow, in order: RequestCode -> VerifyCode -> Register, with Deregister as the reverse switch.
Profile reads and updates the public card a WhatsApp user sees before they reply.
It addresses phone_id like the onboarding actions above, so it shares their transport.
Account is the one exception to the phone_id rule: it reads and updates the
WhatsApp Business Account a number belongs to, so it addresses waba_id and
carries its own transport.
See lib/ruby/whatsapp/business_phone_number/CLAUDE.md,
docs/business_phone_number/README.md, and docs/business_phone_number/profile.md.
Source: https://developers.facebook.com/documentation/business-messaging/whatsapp/business-phone-numbers/registration
Defined Under Namespace
Modules: Account, Profile, Transport Classes: Deregister, Error, Register, RequestCode, Response, VerifyCode