Displaying customer's tariff on-demand in your app
Once a customer connects their tariff, you can use Connect to display their tariff on demand within your app. This article also explains how to enable the customer to update or remove the tariff connection.
Create Connect token
Set location_id
to customer’s location when creating the connect-token:
Display tariff status summary
Start connect session using the token you just created. Connect will return a relevant page, depending on the status if the tariff connection. This may be:
Your customer can navigate through these pages and select from a list of available actions presented on each page.
Create Connect token
Set location_id
to customer’s location when creating the connect-token:
Display tariff status summary
Start connect session using the token you just created. Connect will return a relevant page, depending on the status if the tariff connection. This may be:
Your customer can navigate through these pages and select from a list of available actions presented on each page.
Create a Connect token
You will be starting a new session with Connect, so you must create a new Connect token. Go to create-connect-token API endpoint and include the following parameters in your request:
-
Set
location_id
to where you want to display the tariff summary. -
Set
callback_uri
to any page that can accept callbacks.
Run Connect-headless flow
Run Connect. When you specify location_id
when creating the connect_token,
the relevant summary or pending page will be returned.