Class: PlatformAPI::SmsNumber

Inherits:
Object
  • Object
show all
Defined in:
lib/platform-api/client.rb

Overview

SMS numbers are used for recovery on accounts with two-factor authentication enabled.

Instance Method Summary collapse

Constructor Details

#initialize(client) ⇒ SmsNumber

Returns a new instance of SmsNumber.



2290
2291
2292
# File 'lib/platform-api/client.rb', line 2290

def initialize(client)
  @client = client
end

Instance Method Details

#confirm(account_email_or_account_id_or_account_self) ⇒ Object

Confirm an SMS number change with a confirmation code

Parameters:

  • account_email_or_account_id_or_account_self:

    unique email address of account or unique identifier of an account or Implicit reference to currently authorized user



2311
2312
2313
# File 'lib/platform-api/client.rb', line 2311

def confirm()
  @client.sms_number.confirm()
end

#recover(account_email_or_account_id_or_account_self) ⇒ Object

Recover an account using an SMS recovery code

Parameters:

  • account_email_or_account_id_or_account_self:

    unique email address of account or unique identifier of an account or Implicit reference to currently authorized user



2304
2305
2306
# File 'lib/platform-api/client.rb', line 2304

def recover()
  @client.sms_number.recover()
end

#sms_number(account_email_or_account_id_or_account_self) ⇒ Object

Recover an account using an SMS recovery code

Parameters:

  • account_email_or_account_id_or_account_self:

    unique email address of account or unique identifier of an account or Implicit reference to currently authorized user



2297
2298
2299
# File 'lib/platform-api/client.rb', line 2297

def sms_number()
  @client.sms_number.sms_number()
end