Skip to main content

Arguments

phoneNumber : String

A phone number to find accounts associated with.

portfolioNumber : String

A portfolio number to find accounts associated with.

Returns

[AccountType]

The account object can be one of several attached to a Portfolio (which usually has an AccountUser which is used to authenticate access to the Portfolio's accounts). Typically a person has a single account attached to a portfolio and properties on the same account will appear on the same bill. Where separate bills are desired, multiple accounts are created and added to the same portfolio of accounts.

Allowed Viewers

Customer Partner User Third party

Required Permissions

Can search for accounts

Query Complexity

1

Examples

The example data in the variables and responses below are autogenerated values designed to resemble real inputs. They do not represent actual customer data, and in some cases may require additional validation.

Query

query Accounts( $phoneNumber: String, $portfolioNumber: String ) { accounts( phoneNumber: $phoneNumber, portfolioNumber: $portfolioNumber ) { accountType activeHardshipAgreements { ...HardshipAgreementTypeFragment } activeReferralSchemes { ...ReferralSchemeTypesFragment } address { ...RichAddressTypeFragment } annualStatements { ...AnnualStatementConnectionTypeConnectionFragment } applications { ...AccountApplicationConnectionTypeConnectionFragment } assistanceAgreements { ...AssistanceAgreementTypeFragment } balance bill { ...BillInterfaceFragment } billingAddress billingAddressLine1 billingAddressLine2 billingAddressLine3 billingAddressLine4 billingAddressLine5 billingAddressPostcode billingCountryCode billingDeliveryPointIdentifier billingEmail billingName billingOptions { ...BillingOptionsTypeFragment } billingPostcode billingSubName billingTriggerConfiguration { ...BillingTriggerConfigurationFragment } bills { ...BillConnectionTypeConnectionFragment } brand business { ...BusinessTypeFragment } campaigns { ...AccountCampaignTypeFragment } canBeWithdrawn canChangePayments canInputMeterReadingsViaIvr canModifyPayments { ...CanModifyPaymentsTypeFragment } canRenewTariff canRequestRefund commsDeliveryPreference complaints { ...ComplaintConnectionTypeConnectionFragment } consents { ...ConsentTypeFragment } contributionAgreements { ...ContributionAgreementTypeFragment } cotReadingWindowDays createdAt currentEstimatedSsd customerAssets { ...CustomerAssetTypeFragment } debtCollectionProceedings { ...DebtCollectionProceedingTypeFragment } directDebitInstructions { ...DirectDebitInstructionConnectionTypeConnectionFragment } documentAccessibility earliestPossibleSsd electricityAgreements { ...ElectricityAgreementTypeFragment } eligibilityForWarmHomeDiscount { ...WarmHomeDiscountEligibilityFragment } events { ...AccountEventConnectionTypeConnectionFragment } fileAttachments { ...AccountFileAttachmentFragment } gasAgreements { ...GasAgreementTypeFragment } greenAccomplishments { ...GreenAccomplishmentsTypeFragment } hasActiveCollectionsProceedings hasActiveDunningProcess id isInBlockingMigration isInHardship latestPossibleSsd ledgers { ...LedgerTypeFragment } marketSupplyAgreements { ...AgreementConnectionFragment } maximumRefund { ...MaximumRefundTypeFragment } metadata { ...MetadataFragment } notes { ...AccountNoteTypeFragment } number operationsTeam { ...OperationsTeamTypeFragment } overdueBalance paginatedFileAttachments { ...AccountFileAttachmentConnectionTypeConnectionFragment } paginatedPaymentForecast { ...PaymentForecastConnectionTypeConnectionFragment } paymentAdequacy { ...PaymentAdequacyTypeFragment } paymentMethods { ...PaymentInstructionConnectionTypeConnectionFragment } paymentPlans { ...PaymentPlanConnectionTypeConnectionFragment } payments { ...AccountPaymentConnectionTypeConnectionFragment } paymentSchedules { ...PaymentScheduleConnectionTypeConnectionFragment } portfolio { ...PortfolioTypeFragment } preferredLanguageForComms projectedBalance properties { ...PropertyTypeFragment } provisionalTransactions { ...ProvisionalTransactionConnectionTypeConnectionFragment } recommendedBalanceAdjustment references { ...AccountReferenceTypeFragment } referrals { ...ReferralConnectionTypeConnectionFragment } referralsCreated refundApproval { ...RefundApprovalTypeFragment } reminders { ...AccountReminderConnectionTypeConnectionFragment } repayments { ...AccountRepaymentConnectionTypeConnectionFragment } requestRefundEligibility { ...RequestRefundEligibilityTypeFragment } rewards { ...RewardTypeFragment } shouldReviewPayments smets2Interest smets2RefusalReason splitBillingAddress status trackerTariffDailyPricing { ...TrackerTariffDailyPricingFragment } transactions { ...TransactionConnectionTypeConnectionFragment } urn users { ...AccountUserTypeFragment } warmHomeDiscount { ...WarmHomeDiscountFragment } } }

Variables

{ "phoneNumber": "foot-security-may-moment-chance", "portfolioNumber": "P-2D076B6C" }

Response

{ "data": { "accounts": [ { "accountType": "BUSINESS", "activeHardshipAgreements": [HardshipAgreementType], "activeReferralSchemes": ReferralSchemeTypes, "address": RichAddressType, "annualStatements": AnnualStatementConnectionTypeConnection, "applications": AccountApplicationConnectionTypeConnection, "assistanceAgreements": [AssistanceAgreementType], "balance": 94, "bill": BillInterface, "billingAddress": "for-foreign-attention-woman-look", "billingAddressLine1": "tree-until-wide-spring-understand", "billingAddressLine2": "two-soon-care-model-offer", "billingAddressLine3": "yeah-six-reflect-second-gun", "billingAddressLine4": "walk-poor-I-let-woman", "billingAddressLine5": "mother-cold-chance-reach-none", "billingAddressPostcode": "trade-continue-in-road-anyone", "billingCountryCode": "between-nation-entire-blood-energy", "billingDeliveryPointIdentifier": "94844540", "billingEmail": "number-political-talk-some-design", "billingName": "study-memory-it-opportunity-tonight", "billingOptions": BillingOptionsType, "billingPostcode": "main-space-detail-customer-management", "billingSubName": "together-dog-laugh-happen-tree", "billingTriggerConfiguration": BillingTriggerConfiguration, "bills": BillConnectionTypeConnection, "brand": "country-lot-authority-subject-wish", "business": BusinessType, "campaigns": [AccountCampaignType], "canBeWithdrawn": true, "canChangePayments": true, "canInputMeterReadingsViaIvr": true, "canModifyPayments": CanModifyPaymentsType, "canRenewTariff": true, "canRequestRefund": true, "commsDeliveryPreference": "EMAIL", "complaints": ComplaintConnectionTypeConnection, "consents": [ConsentType], "contributionAgreements": [ContributionAgreementType], "cotReadingWindowDays": 53, "createdAt": "1981-05-24T11:12:58.191360+00:00", "currentEstimatedSsd": "2012-04-03", "customerAssets": [CustomerAssetType], "debtCollectionProceedings": [DebtCollectionProceedingType], "directDebitInstructions": DirectDebitInstructionConnectionTypeConnection, "documentAccessibility": "LARGE_PRINT", "earliestPossibleSsd": "2013-08-03", "electricityAgreements": [ElectricityAgreementType], "eligibilityForWarmHomeDiscount": WarmHomeDiscountEligibility, "events": AccountEventConnectionTypeConnection, "fileAttachments": [AccountFileAttachment], "gasAgreements": [GasAgreementType], "greenAccomplishments": GreenAccomplishmentsType, "hasActiveCollectionsProceedings": true, "hasActiveDunningProcess": true, "id": "79026002", "isInBlockingMigration": true, "isInHardship": true, "latestPossibleSsd": "2019-07-28", "ledgers": [LedgerType], "marketSupplyAgreements": AgreementConnection, "maximumRefund": MaximumRefundType, "metadata": [Metadata], "notes": [AccountNoteType], "number": "baby-past-member-official-international", "operationsTeam": OperationsTeamType, "overdueBalance": 46, "paginatedFileAttachments": AccountFileAttachmentConnectionTypeConnection, "paginatedPaymentForecast": PaymentForecastConnectionTypeConnection, "paymentAdequacy": PaymentAdequacyType, "paymentMethods": PaymentInstructionConnectionTypeConnection, "paymentPlans": PaymentPlanConnectionTypeConnection, "payments": AccountPaymentConnectionTypeConnection, "paymentSchedules": PaymentScheduleConnectionTypeConnection, "portfolio": PortfolioType, "preferredLanguageForComms": "surface-learn-couple-federal-reality", "projectedBalance": 1, "properties": [PropertyType], "provisionalTransactions": ProvisionalTransactionConnectionTypeConnection, "recommendedBalanceAdjustment": 70, "references": [AccountReferenceType], "referrals": ReferralConnectionTypeConnection, "referralsCreated": 16, "refundApproval": RefundApprovalType, "reminders": AccountReminderConnectionTypeConnection, "repayments": AccountRepaymentConnectionTypeConnection, "requestRefundEligibility": RequestRefundEligibilityType, "rewards": [RewardType], "shouldReviewPayments": true, "smets2Interest": "PRIORITY", "smets2RefusalReason": "SMETS2_INTEREST_REASON_DO_NOT_OWN_HOME", "splitBillingAddress": "state-mention-yes-firm-since", "status": "PENDING", "trackerTariffDailyPricing": TrackerTariffDailyPricing, "transactions": TransactionConnectionTypeConnection, "urn": "population-year-executive-in-vote", "users": [AccountUserType], "warmHomeDiscount": WarmHomeDiscount } ] } }