woob.capabilities.account

class woob.capabilities.account.Account(id=None, url=None)

Bases: woob.capabilities.base.BaseObject

Describe an account and its properties.

Variables
  • login – (str) Login

  • password – (str) Password

  • properties – (dict) List of key/value properties

exception woob.capabilities.account.AccountRegisterError

Bases: woob.capabilities.base.UserError

Raised when there is an error during registration.

class woob.capabilities.account.CapAccount

Bases: woob.capabilities.base.Capability

Capability for websites when you can create and manage accounts.

Variables

ACCOUNT_REGISTER_PROPERTIES – This class constant may be a list of woob.tools.value.Value objects. If the value remains None, woob considers that register_account() isn’t supported.

ACCOUNT_REGISTER_PROPERTIES = None
confirm_account(mail)

From an email go to the confirm link.

get_account()

Get the current account.

get_account_status()

Get status of the current account.

Returns

a list of fields

static register_account(account)

Register an account on website

This is a static method, it would be called even if the backend is instancied.

Parameters

account (Account) – describe the account to create

Raises

AccountRegisterError

update_account(account)

Update the current account.

class woob.capabilities.account.StatusField(key, label, value, flags=0, url=None)

Bases: woob.capabilities.base.BaseObject

Field of an account staeobjectus.

Variables
  • key – (str) Key

  • label – (str) Label

  • value – (str) Value

  • flags – (int, int) Flags

FIELD_HTML = 2
FIELD_TEXT = 1