Get the API account details like balance of credits.
        :return: An Account object.
355904
def account(self):
        
        resp = self._call(endpoint='account')
        return Account(resp['credits'], resp['jobs_completed'], resp['jobs_processing'])
265131
def fetch(self):
        
        params = values.of({})

        payload = self._version.fetch(
            'GET',
            self._uri,
            params=params,
        )

        return AssignedAddOnInstance(
            self._version,
            payload,
            account_sid=self._solution['account_sid'],
            resource_sid=self._solution['resource_sid'],
            sid=self._solution['sid'],
        )
432756
def params(self):
        
        params = {}
        params["access_token"] = self.access_token
        params["account_id"] = self.account_id
        return params
1048269
def user_info(self):
        
        account_uri = self.uri.split('/api/v1')[0] + '/account'
        req = self.request(account_uri)
        account_info = req.get()
        user_data = HTMLParser(account_info.content)
        return user_data
144446
def accounts(self):
        
        if self._accounts is None:
            self._accounts = AccountList(self)
        return self._accounts
134153
def info(gandi):
    
    output_keys = ['handle', 'credit', 'prepaid']

    account = gandi.account.all()
    account['prepaid_info'] = gandi.contact.balance().get('prepaid', {})
    output_account(gandi, account, output_keys)
    return account
412169
def get_balance(self):
        
        if not SMSGLOBAL_CHECK_BALANCE_COUNTRY:
            raise Exception('SMSGLOBAL_CHECK_BALANCE_COUNTRY setting must be set to check balance.')
        
        params = {
          'user' : self.get_username(),
          'password' : self.get_password(),
          'country' : SMSGLOBAL_CHECK_BALANCE_COUNTRY,
        }
        
        req = urllib2.Request(SMSGLOBAL_API_URL_CHECKBALANCE, urllib.urlencode(params))
        response = urllib2.urlopen(req).read()

        # CREDITS:8658.44;COUNTRY:AU;SMS:3764.54;
        if response.startswith('ERROR'):
            raise Exception('Error retrieving balance: %s' % response.replace('ERROR:', ''))
        
        return dict([(p.split(':')[0].lower(), p.split(':')[1]) for p in response.split(';') if len(p) > 0])
20915
def get_balance(self, account: SEPAAccount):
        

        with self._get_dialog() as dialog:
            hksal = self._find_highest_supported_command(HKSAL5, HKSAL6, HKSAL7)

            seg = hksal(
                account=hksal._fields['account'].type.from_sepa_account(account),
                all_accounts=False,
            )

            response = dialog.send(seg)

            for resp in response.response_segments(seg, 'HISAL'):
                return resp.balance_booked.as_mt940_Balance()
556570
def credits(params = {})
      request_params = params.merge(access_params)
      request = Requests::Credit::List.new(request_params)
      request.call!
    end
277071
def fetch(self):
        
        params = values.of({})

        payload = self._version.fetch(
            'GET',
            self._uri,
            params=params,
        )

        return FeedbackInstance(
            self._version,
            payload,
            account_sid=self._solution['account_sid'],
            call_sid=self._solution['call_sid'],
        )
495779
def get_account_info(self):
        
        headers = self._manager.get_account_headers()
        return (headers.get("x-account-container-count"),
                headers.get("x-account-bytes-used"))
802391
def GetAccounts(alias=None):
		""""""
		if alias is not None:  payload = {'AccountAlias': alias}
		else:  payload = {}
		r = clc.v1.API.Call('post','Account/GetAccounts',payload)
		if int(r['StatusCode']) == 0:  
			# Assume first response is always the original account.  Not sure if this is reliable
			if not clc.ALIAS:  clc.ALIAS = r['Accounts'][0]['AccountAlias']
			if not clc.LOCATION:  clc.LOCATION = r['Accounts'][0]['Location']

			return(r['Accounts'])
596018
def get_account(self, name, **kwargs):
        
        if len(name.split(".")) == 3:
            return self.get_objects([name])[0]
        else:
            return self.get_account_by_name(name, **kwargs)
516979
def namedb_get_account_balance(account):
    
    # NOTE: this is only possible because Python does not overflow :P
    balance = account['credit_value'] - account['debit_value']
    if balance < 0:
        log.fatal("Balance of {} is {} (credits = {}, debits = {})".format(account['address'], balance, account['credit_value'], account['debit_value']))
        traceback.print_stack()
        os.abort()

    return balance
985570
def get_balance(self):
        
        
        response = util.call_api("merchant/{0}/balance".format(self.identifier), self.build_basic_request(),
                                 base_url=self.service_url)
        json_response = json.loads(response)
        self.parse_error(json_response)
        return json_response.get('balance')
219434
def get_account_details(self, account):
        
        _form = mechanize.HTMLForm(self.SEARCH_MEMBERS_URL, method="POST")
        _form.new_control('text', 'username', {'value': account})
        _form.new_control('text', '_', {'value': ''})

        try:
            r = self.post_url(self.SEARCH_MEMBERS_URL, form=_form)
        except AuthRequiredException:
            self._auth()
            r = self.post_url(self.SEARCH_MEMBERS_URL, form=_form)

        if r:
            # single quoted json parameters are not valid so convert
            # them into double quoted parameters
            _decoded = json.loads(r.replace("'", '"'))
            # we have a double array result so retrieve only what's
            # essential
            if _decoded[0]:
                return _decoded[0][0]

        raise InvalidAccountException
964478
def get_account_details(self, account):
        
        result = self.get_user(account.username)
        if result is None:
            result = {}
        return result