1. Onboarding Methods — Direct Integration
Glow Platform
  • Welcome to Glow Data Service!
  • Getting Started
  • Glow Portals
  • Introducing the Glow System
  • API Authentication
  • Smart Meter Onboarding
    • Introducing Smart Meter Onboarding
    • Smart Meter Eligibility Check
    • Terms and Conditions APIs and Management
    • Onboarding Methods — Direct Integration
      • EUI/Postcode Check
      • AVS Check
    • Onboarding Methods — Hosted Integration
      • Glow IDV SDK
        • Introducing the Glow SDK
        • Supported Verification Methods
        • Implementation Guide — Web
        • Implementation Guide — Mobile
        • Verifiable Credentials
        • Verification Result Screen
        • Consent Capture & Onboarding
    • Onboarding Methods — No Integration
      • Invitation Functionality
      • Agent Verification Portal
  • Data Retrieval
    • Retrieving Time Series Data from Onboarded Users
  • Consent Management and Offboarding
    • Consent Management
    • Offboarding
  • Glow CADs & Fulfilment
    • Glow CAD Fulfilment
  • API Reference
    • Smart Meter Elgibility
      • eligibility
        • smets-ihd-cad
          • Check MPxN has CAD/PPMID
        • checksmetsihd
          • postcode
            • Match EUI IHD with postcode
          • Match EUI IHD with MPxN
        • checksmetsmpxn
          • Check MPXN is eligible in DCC.
    • Content System
      • content
        • {contentId}
          • get a content object
          • Update an existing content object
        • Find all the content objects of an application
        • Add a content object
      • languagecontent
        • {languageContentId}
          • get a language content object by ID
          • Update an existing language content object
        • Find all the language content objects of an application
        • Add a language content object
      • termsconditions
        • {tcId}
          • get a terms and conditions object by ID
        • current
          • Find the terms and conditions that are in force.
        • Find all the terms and conditions of an application
        • Add terms and conditions
      • termsconditionsuser
        • {tcUserId}
          • get a specified terms and conditions user obj
        • Find all the responses to terms and conditions documents.
        • Add a user's response to Terms & Conditions document
      • supportdetails
        • {supportDetailsId}
          • get a support details object
        • Find all the support detail objects of an application
        • Add a support details object
      • faq
        • {faqId}
          • get a FAQ object
        • Find all the FAQ objects of an application
        • Add a faq object
      • prompttype
        • {promptTypeId}
          • get a Prompt Type object
        • Find all the prompt type objects of an application
        • Add a Prompt Type object
      • prompt
        • {promptId}
          • get a Prompt object
        • Find all the prompt objects of an application
        • Add a Prompt object
      • promptuser
        • {promptUserId}
          • get a Prompt User object
        • Find all the prompt user objects of an application
        • Add a Prompt User object
      • useraction
        • {userActionId}
          • get a User Action object
        • Find all the user action objects of an application
        • Add a User Action object
      • useractiontype
        • {userActionTypeId}
          • get a User Action Type object
        • Find all the user action type objects of an application
        • Add a User Action Type object
    • User System
      • register
        • User self registers
      • account
        • {accountId}
          • status
            • Find the status of a specified account. If the account is using an external directory service, this call will confirm whether the user is authenticated against it. This call requires administrative application level credentials.
          • mobileapptoken
            • Add mobile app token to a user
            • Remove a mobile app token to a user
          • Find specific account of an application.
          • Updates the account's metadata.
          • Delete account
        • status
          • With a given JWT token a user can have their account status verfied. If their account is created under an external directory service, this call will establish whether a user's token to the external service is still valid.
        • email
          • Change a user's email
        • name
          • Change a user's name
        • changepassword
          • Change a user's password
        • Find all accounts of an application
        • Add an account to an existing user
      • user
        • {userId}
          • username
            • Change a user's username
          • Find specific user that has an account in an application.
          • Delete specific user. This will delete all the accounts of a user. Please refer to delete account API. This API requires specific permissions.
        • verify
          • Generate a user verification token
          • Verify a user verification token
        • resetpassword
          • Generate a token that can be used by user to reset their password.
          • A user resets their password
        • verification
          • status
            • mpxns
              • renewal
                • Renew consent for a number of meterpoints
              • revocation
                • Revoke consent for a number of meterpoints
            • mpxn
              • {mpxn}
                • renewal
                  • Get meter point consent renewals
                  • Renew meter point consent
                • revocation
                  • Get meter point consent revocations
                  • Revoke meter point consent
            • API to retrieve user's meter points' consent and verification
        • Find specific user that has an account in an application from the username.
        • Create a user
      • accountprofile
        • {profileName}
          • Find specific group of application
        • Find all the profiles of an account
        • Create an account profile under a given profileName.
      • accountsession
        • get the session of an account
        • Update an account session.
      • auth
        • token
          • {tokenId}
            • Deletes a token, specified by its tokenId.
          • Returns all the tokens that are active and valid for a specified user.
        • newToken
          • Generate a new token for an account.
        • deleteToken
          • delete a token
        • oauth
          • access
            • Exchange the Authorization Code for an Access Token.
          • Check and validate an Oauth Access token.
          • Authenticate a user and generate an OAuth 2.0 Authorization Code Grant.
        • Checks whether a user token is valid.
        • authenticate an account
    • Virtual Entity System
      • vesys
        • appstats
          • find statistics on the number of Virtual Entities per application
      • virtualentity
        • {id}
          • resources
            • Find the resources of that belong to Virtual Entity with ID
          • attribute
            • Find a Virtual Entity's metadata by ID
            • Add/Update a Virtual Entity's metadata
            • delete metadata from the Virtual Entity
          • Find Virtual Entity by ID
          • Update a Virtual Entity
          • Delete a Virtual Entity
        • Add a new Virtual Entity
        • Find all Virtual Entities
      • vetype
        • {id}
          • resources
            • Find all resources that belong to a user that satisfy the Resource Types in the Virtual Entity Type definition.
          • Find Virtual Entity Type by ID
          • Update a Virtual Entity Type
        • Add a new Virtual Entity Type
        • Find all Virtual Entity Types
    • Webhook System
      • webhook
        • {webhookId}
          • Find webhook by ID
        • error
          • {errorId}
            • Find a particular webhook error
          • Find all the webhooks that have failed
        • Find all webhooks of an application (or user)
    • Resource System
      • resource
        • {id}
          • readings
            • Get resource readings
          • current
            • Get the current resource reading.
          • first-time
            • Get the UTC time of the first available reading
          • last-time
            • Get the UTC time of the most recent available reading
          • meterread
            • Get the cumulative value reported on a metering device. (Not supported for all resource types).
          • tariff
            • Get the latest tariff that is being applied to a resource.
          • tariff-list
            • Get the tariff history that is being applied to a cost resource.
          • catchup
            • Trigger a request to retrieve the latest available readings from the DCC.
          • glowbinary
            • API that returns the resource's raw data in the Glow Binary format.
          • Find resource by ID
        • count
          • Count the number of resources per resourceType
        • Add a new resource
        • Find all resources per user or application
      • resourcetype
        • {id}
          • resource
            • Find resources of a specific resource type that belong to a user
          • appresource
            • Find resources of a specific resource type that an application has access to
          • Find resourceType by ID
        • Add a new resource type.
        • Find all resource types
    • Notification System
      • alerttype
        • {alertTypeId}
          • Find alert type by ID
          • Updates the alert type's metadata.
        • Find all alert types of an application
        • Create an alert type
      • alert
        • {alertId}
          • Get an alert by Id
        • user
          • Get the alerts sent to a user
        • Send an alert
      • template
        • {templateId}
          • Find template type by ID
          • Updates the teplate's metadata.
        • {alertTypeId}
          • {channelType}
            • {cultureCode}
              • Find template by alertTypeId, channeType and cultureCode
              • Create template by alertTypeId, channeType and cultureCode
        • Find all templates of an application
        • Create a template
      • notification
        • {notificationId}
          • log
            • Get the logs of a particular notification
          • Get a notification by Id
    • DFS
      • dfs
        • termsconditions
          • The current version of terms and conditions that is pertinent to DFS for a particular application.
        • user
          • Get all the users that have opted in the DFS functionality
          • User opts in to DFS functionality for a particular MPxN. The mpxn field is only required if a user has more than one MPxN.
          • User opts out of DFS functionality
        • event
          • {dfsEventId}
            • user
              • Get all the users that have participated in a particular DFS event
          • user
            • participation
              • API to indicate User participating in particular DFS event
            • Get all the events a user has signed up for
    • Device Management System
      • devicetype
        • {id}
          • Find Device Type by ID
        • Add a new Device Type
        • Find all device types
      • device
        • {id}
          • status
            • This call can be used to see whether a gateway device is sending packets to the Glow Platform (i.e. via WiFi).
          • Find device by ID
        • resource
          • {resourceId}
            • Find the device that sources a specified resource.
        • meter-point
          • {meterPointNumber}
            • inventory
              • Get the DCC inventory of a meter point
            • resources
              • Get the resources associated to a meter point
        • smart-meter
          • {eui}
            • inventory
              • Get the DCC inventory of a meter point by providing an EUI.
        • status
          • This call can be used to see whether a gateway device is sending packets to the Glow Platform (i.e. via WiFi).
        • Get a user's devices
        • Add a new device
      • discover
        • {hardwareId}
          • Find device by ID
  1. Onboarding Methods — Direct Integration

AVS Check

Introduction#

This verification method compares an address registered to a bank card to that registered against a smart meter that an end user is attempting to grant consent for. Address verification, or AVS checks, are commonly used to verify that a payment card is registered at a particular address.

Definitions#

TermDescription
MobileAppThe third party app
ServerAppThe third party backend serving information to the MobileApp
End UserThe person user the MobileApp
Glow UserThe user entity in the Glow Platform that represent the End User
Stripe CustomerThe customer record in Stripe that represents the End User
StripeThe chosen external payment provider
Glow userIdThe UUID of the Glow User

Implementation#

The below implementation guide uses Stripe as an external payment provider. In Stripe, we do not want to run a payment authorisation for the person that is being verified, so one of the routes to invoke AVS is the tokenisation of a payment card.
The tokenisation information can include a first line of address and postcode, along with the card number, expiration date and CV2 numbers. The idea is to match 3 addresses; the billing address the end user provides, the billing address registered against the card details and the address stored in the DCC Inventory. During the AVS check Stripe will advice whether the billing address provided is associated to the credit card (see event payloads below). If that passes, we proceed to comparing the address to the one in the DCC Inventory.

Requirements#

The end user needs to input their MPxN and bank card information (including the address information). Stripe webhooks will need to be configured to send events to the GlowAPI as well as any support needed by the ServerApp or MobileApp.
In the sections below we will first explore the 4 main process flows that can be used to implement Smart Meter Onboarding via AVS. This will be followed by the respective API definitions, and finally we will conclude with examples on Stripe structures.

Process Description#

There are 4 different process flows available for onboarding a smart meter with the AVS Address Verification method. These flows differ with regards to 2 parameters; firstly whether the Glow userId is known at the time the Stripe Customer gets created, and secondly whether the Glow User is being created simultaneously with the smart meter onboard.
In the table below each process flow is outlined along with the Stripe webhooks and the Glow APIs that will need to be used in each case. To demonstrate the differences between the process flows we define:
Preexisting Stripe Customer - The Stripe Customer was created without setting the Glow userId to the description. This would mean that the Server App would need to update the customer record on Stripe prior to proceeding with the smart meter registration. In these scenarios, the Stripe Update Customer API can be used and the webhook that needs to be set up is the customer.updated .
Preexisting Glow User - The Glow User was created prior to the smart meter onboard.
Please note that for the third party integration you can switch between using the Glow API 1 and 2. However it is highly advisable that only one Stripe webhook related to the customer is used (either customer.created or customer.updated ).
CaseProcess Flow DescriptionPreexisting Stripe CustomerPreexisting Glow UserStripe Webhooks to configureGlow API to use
1Stripe Customer and Glow User are registered at the same time the meter is onboarded. (API 1)falsefalse- customer.created
- payment_method.attached
API 1
2Glow User and Stripe Customer (Stripe Customer is tied to Glow User at creation) preexist at the time the smart meter is onboarded. (API 2)falsetrue- customer.created
- payment_method.attached
API 2
3Stripe Customer preexists and was created without assigning a Glow userId to description. Glow User is registered at the same time the meter is onboarded. (API 1)truefalse- customer.updated
- payment_method.attached
API 1
4Stripe Customer preexists and was created without assigning a Glow userId to description. Glow User also preexists at the time the smart meter is onboarded. (API 2)truetrue- customer.updated
- payment_method.attached
API 2

Process Flow 1#

Stripe Customer and Glow User is registered at the same time the meter is onboarded. (API 1)

Process Flow 2#

Glow User and Stripe Customer (Stripe Customer is tied to Glow User at creation) preexist at the time the smart meter is onboarded. (API 2)

Process Flow 3#

Stripe Customer preexists and was created without assigning a Glow userId to description. Glow User is registered at the same time the meter is onboarded. (API 1)

Process Flow 4#

Stripe Customer preexists and was created without assigning a Glow userId to description. Glow User also preexists at the time the smart meter is onboarded. (API 2)

APIs for Smart Meter Onboarding via AVS Address Verification#

Register user and onboard smart meter and verify via AVS Address Verification#

Onboard smart meter and verify via AVS Address Verification for existing userId#

Responses#

Synchronous response#

All responses will contain a prenotification ID. This can be used to query the status of a given smart meter onboard. Further information to be provided.

Asynchronous response#

The Glow API will be notified by the payment provider asynchronously. It will onboard the smart meter if the AVS succeeds and matches the DCC address, or report an error if it fails. Notifying the Server App on the success/failure of these events will happen via Webhooks. The below 2 events will be generated. For information on how to setup webhooks, please refer to the document entitled GlowPlatformDccCallbackNotes_v13.md .
These events are generated as an asynchronous response to the APIs used for Smart meter onboarding via AVS Address Verification.

On Success#

EventPayloadDescriptionJSON payload
smart-meter-avs-onboard.success- MPXN
- userId
-applicationId
These events are generated as a successful asynchronous response to the AVS. This means that the system will register the smart meters against the user.{
"applicationId": "b0f1b774-a586-4f72-9edd-27ead8aa7a8d",
"eventType": "smart-meter-avs-onboard.success",
"data": {
"userId": "0f580541-7139-43d3-826f-a63655b73c89",
"mpxn": "1111111122228"
}
}

On Failure#

EventPayloadDescriptionJSON payload
smart-meter-avs-onboard.failure-- MPXN
- userId
- applicationId
These events are generated as an unsuccessful asynchronous response to the AVS. This means that the system will register the smart meters against the user. The error codes with details are provided in the SmarterMeterOnboardingViaAVS(Stripe) documentation.{
"applicationId": "b0f1b774-a586-4f72-9edd-27ead8aa7a8d",
"eventType": "smart-meter-avs-onboard.success",
"data": {
"userId": "0f580541-7139-43d3-826f-a63655b73c89",
"mpxn": "1111111122228",
"errorCode":"ERROR_CODE"
"errorDetails": {} }
}
The AVS Failure ErrorCodes are the following:
ErrorCodeDescription
AVS_BAD_PAYMENT_METHODPayment method not attached to cusotmer, it was rejected for some reason by stripe
MPXN_NO_DCC_ADDRESSMPXN has no address in the DCC.
AVS_FAILSAVS fails (billing address provided does not match card billing address)
AVS_MPXN_ADDRESS_MISMATCHDCC address does not match incoming billing address

Setting up webhooks in Stripe#

https://docs.stripe.com/webhooks#register-webhook
The event types of interest are the following:
customer.created OR customer.updated
payment_method.attached
The endpoint to set up the webhooks to is:

Examples of Webhook responses from Stripe#

Event: customer.created#

{
  "object": {
    "id": "cus_NsJ5YtQ7qPzfUX",
    "object": "customer",
    "address": null,
    "balance": 0,
    "created": 1683807587,
    "currency": null,
    "default_source": null,
    "delinquent": false,
    "description": "2f828329-55cd-456b-9123-05d07fa9e1cc",
    "discount": null,
    "email": null,
    "invoice_prefix": "55CA31B0",
    "invoice_settings": {
      "custom_fields": null,
      "default_payment_method": null,
      "footer": null,
      "rendering_options": null
    },
    "livemode": false,
    "metadata": {
    },
    "name": null,
    "phone": null,
    "preferred_locales": [
    ],
    "shipping": null,
    "tax_exempt": "none",
    "test_clock": null
  }
}

Event: customer.updated#

{
  "object": {
    "id": "cus_NsJ5YtQ7qPzfUX",
    "object": "customer",
    "address": null,
    "balance": 0,
    "created": 1683807587,
    "currency": null,
    "default_source": null,
    "delinquent": false,
    "description": "2f828329-55cd-456b-9123-05d07fa9e1cc",
    "discount": null,
    "email": null,
    "invoice_prefix": "55CA31B0",
    "invoice_settings": {
      "custom_fields": null,
      "default_payment_method": null,
      "footer": null,
      "rendering_options": null
    },
    "livemode": false,
    "metadata": {
    },
    "name": null,
    "phone": null,
    "preferred_locales": [
    ],
    "shipping": null,
    "tax_exempt": "none",
    "test_clock": null
  }
}

Event: payment_method.attached#

Successful card postcode check#

All 3 should pass
{
          "address_line1_check": "pass",
          "address_postal_code_check": "pass",
          "cvc_check": "pass"
        },
{
  "id": "evt_1N6Xd9DOZzcVYvZSFp1IUJp8",
  "object": "event",
  "api_version": "2022-11-15",
  "created": 1683804354,
  "data": {
    "object": {
      "id": "pm_************************",
      "object": "payment_method",
      "billing_details": {
        "address": {
          "city": "London",
          "country": null,
          "line1": "Street Name",
          "line2": "123A",
          "postal_code": "A00 A00",
          "state": null
        },
        "email": null,
        "name": "Justin Testing",
        "phone": null
      },
      "card": {
        "brand": "visa",
        "checks": {
          "address_line1_check": "pass",
          "address_postal_code_check": "pass",
          "cvc_check": "pass"
        },
        "country": "US",
        "exp_month": 7,
        "exp_year": 2026,
        "fingerprint": "************",
        "funding": "credit",
        "generated_from": null,
        "last4": "4242",
        "networks": {
          "available": [
            "visa"
          ],
          "preferred": null
        },
        "three_d_secure_usage": {
          "supported": true
        },
        "wallet": null
      },
      "created": 1683804354,
      "customer": "cus_NsHWPrRrruAkIu",
      "livemode": false,
      "metadata": {},
      "type": "card"
    }
  },
  "livemode": false,
  "pending_webhooks": 1,
  "request": {
    "id": "req_eTST0K7NYyHA4K",
    "idempotency_key": "6014083d-da1e-4c22-86f5-804dff000156"
  },
  "type": "payment_method.attached"
}

Failed card check#

Here the billing address provided by the user does not match the billing address of the card, resulting to the Stripe event indicating that "address_postal_code_check" is false.
{
  "id": "evt_1N6XhmDOZzcVYvZSlRxgTdED",
  "object": "event",
  "api_version": "2022-11-15",
  "created": 1683804642,
  "data": {
    "object": {
      "id": "pm_************************",",
      "object": "payment_method",
      "billing_details": {
        "address": {
          "city": "London",
          "country": null,
          "line1": "Street Name",
          "line2": "123A",
          "postal_code": "A00 A00",
          "state": null
        },
        "email": null,
        "name": "Justin Testing",
        "phone": null
      },
      "card": {
        "brand": "visa",
        "checks": {
          "address_line1_check": "pass",
          "address_postal_code_check": "fail",
          "cvc_check": "pass"
        },
        "country": "US",
        "exp_month": 2,
        "exp_year": 2044,
        "fingerprint": "************",
        "funding": "credit",
        "generated_from": null,
        "last4": "0036",
        "networks": {
          "available": [
            "visa"
          ],
          "preferred": null
        },
        "three_d_secure_usage": {
          "supported": true
        },
        "wallet": null
      },
      "created": 1683804641,
      "customer": "cus_NsHWPrRrruAkIu",
      "livemode": false,
      "metadata": {},
      "type": "card"
    }
  },
  "livemode": false,
  "pending_webhooks": 3,
  "request": {
    "id": "req_35g2UeX1asmS90",
    "idempotency_key": "4be614bc-ac44-4117-83cb-c2de310c2ff0"
  },
  "type": "payment_method.attached"
}

Testing with Stripe#

Please set up tests with the following cards:
https://stripe.com/docs/testing?locale=en-GB#fraud-prevention
- Postal code check fails
- Line1 check fails
- Address checks fail
- Address unavailable
Our current understanding is that if you pass in a test address it should come through to the events. So as a billing address try to pass the DCC address with a card that would go though.
If this does not work you could explore this:
https://stripe.com/docs/testing?locale=en-GB#webhooks

Other Material#

What the customer looks like in Stripe#

Customer object needs to be created for each user, the userId can be attached as the description.
{
    "id": "cus_NsJ5YtQ7qPzfUX",
    "object": "customer",
    "address": null,
    "balance": 0,
    "created": 1683807587,
    "currency": null,
    "default_source": null,
    "delinquent": false,
    "description": "2f828329-55cd-456b-9123-05d07fa9e1cc",
    "discount": null,
    "email": null,
    "invoice_prefix": "55CA31B0",
    "invoice_settings": {
        "custom_fields": null,
        "default_payment_method": null,
        "footer": null,
        "rendering_options": null
    },
    "livemode": false,
    "metadata": {},
    "name": null,
    "phone": null,
    "preferred_locales": [],
    "shipping": null,
    "tax_exempt": "none",
    "test_clock": null
}
Modified at 2026-08-14 16:19:44
Previous
EUI/Postcode Check
Next
Introducing the Glow SDK
Built with