@hello-bill/node 2.1.4 → 2.2.0-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/dist/express/index.d.cts +2 -2
- package/dist/express/index.d.ts +2 -2
- package/dist/hono/index.d.cts +2 -2
- package/dist/hono/index.d.ts +2 -2
- package/dist/{index-DnEk4Y5R.d.ts → index-D425PJZo.d.ts} +1 -1
- package/dist/{index-C_gIXrzG.d.cts → index-DIV4FzH6.d.cts} +1 -1
- package/dist/index.d.cts +4 -4
- package/dist/index.d.ts +4 -4
- package/dist/koa/index.d.cts +2 -2
- package/dist/koa/index.d.ts +2 -2
- package/dist/next/index.d.cts +2 -2
- package/dist/next/index.d.ts +2 -2
- package/dist/types/index.d.cts +2 -2
- package/dist/types/index.d.ts +2 -2
- package/dist/types/index.js.map +1 -1
- package/dist/types/index.mjs.map +1 -1
- package/dist/webhook/index.d.cts +2 -2
- package/dist/webhook/index.d.ts +2 -2
- package/dist/{webhooks-DePW-Bjp.d.cts → webhooks-DKDXYTkz.d.cts} +22 -6
- package/dist/{webhooks-DePW-Bjp.d.ts → webhooks-DKDXYTkz.d.ts} +22 -6
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 2.2.0-beta.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- fcc42e2: v19: customer.title (required enum mr|mrs|miss|ms|mx|dr|other) + other_title; customer/occupant full_legal_name; energy credit-check address history (customer.credit_check.previous_addresses) gated by the new requires_credit_check_addresses product flag; new embed credit-check-addresses screen; PATCH /partner/sessions/:id; conditional first_name/full_legal_name validation; AnyVan removals disabled in sandbox.
|
|
8
|
+
|
|
3
9
|
## 2.1.0-beta.0
|
|
4
10
|
|
|
5
11
|
### Minor Changes
|
package/dist/express/index.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as CreateHellobillHandlerOptions } from '../index-
|
|
2
|
-
import '../webhooks-
|
|
1
|
+
import { C as CreateHellobillHandlerOptions } from '../index-DIV4FzH6.cjs';
|
|
2
|
+
import '../webhooks-DKDXYTkz.cjs';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Express adapter for the framework-agnostic SDK core.
|
package/dist/express/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as CreateHellobillHandlerOptions } from '../index-
|
|
2
|
-
import '../webhooks-
|
|
1
|
+
import { C as CreateHellobillHandlerOptions } from '../index-D425PJZo.js';
|
|
2
|
+
import '../webhooks-DKDXYTkz.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Express adapter for the framework-agnostic SDK core.
|
package/dist/hono/index.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as CreateHellobillHandlerOptions } from '../index-
|
|
2
|
-
import '../webhooks-
|
|
1
|
+
import { C as CreateHellobillHandlerOptions } from '../index-DIV4FzH6.cjs';
|
|
2
|
+
import '../webhooks-DKDXYTkz.cjs';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Hono adapter for the framework-agnostic SDK core.
|
package/dist/hono/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as CreateHellobillHandlerOptions } from '../index-
|
|
2
|
-
import '../webhooks-
|
|
1
|
+
import { C as CreateHellobillHandlerOptions } from '../index-D425PJZo.js';
|
|
2
|
+
import '../webhooks-DKDXYTkz.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Hono adapter for the framework-agnostic SDK core.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { aS as WebhookEvent, aF as SessionEmbedOpened, aE as SessionDetailsConfirmed, aH as SessionProductsSelected, aG as SessionLoaSigned, aB as SessionAccountCreated, aD as SessionAppInstalled, aC as SessionAppDeferred, aM as SubscriptionChanged, aJ as SetupStatusChanged, a8 as MoveOutNotificationSent, a7 as MoveOutNotificationFailed, m as BankDetailsCollected, S as SessionPayload } from './webhooks-DKDXYTkz.js';
|
|
2
2
|
|
|
3
3
|
interface TokenStorage {
|
|
4
4
|
get(clientId: string): Promise<{
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { aS as WebhookEvent, aF as SessionEmbedOpened, aE as SessionDetailsConfirmed, aH as SessionProductsSelected, aG as SessionLoaSigned, aB as SessionAccountCreated, aD as SessionAppInstalled, aC as SessionAppDeferred, aM as SubscriptionChanged, aJ as SetupStatusChanged, a8 as MoveOutNotificationSent, a7 as MoveOutNotificationFailed, m as BankDetailsCollected, S as SessionPayload } from './webhooks-DKDXYTkz.cjs';
|
|
2
2
|
|
|
3
3
|
interface TokenStorage {
|
|
4
4
|
get(clientId: string): Promise<{
|
package/dist/index.d.cts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { T as TokenStorage, L as Logger } from './index-
|
|
2
|
-
export { C as CreateHellobillHandlerOptions, H as HellobillHandlerSet, a as HellobillRequest, b as HellobillResponse, I as InMemoryTokenStorage, c as InMemoryWebhookDedupeStore, d as TokenManager, e as TokenManagerOptions, U as UnknownWebhookEventError, V as VerifyWebhookOptions, W as WebhookDedupeStore, f as WebhookHandlerContext, g as WebhookHandlerOptions, h as WebhookHandlers, i as WebhookVerificationError, j as createHellobillHandler, k as createWebhookHandler, v as verifyWebhook, l as verifyWebhookSignature } from './index-
|
|
3
|
-
import { R as RequestId, S as SessionPayload, a as SessionResponse, b as SessionGetResponse, P as ProductsQuery, c as ProductsResponse, d as PropertyDetailResponse, L as LoaListResponse, C as CreateCustomerInput, e as CustomerCreateResponse, f as CustomerId, g as CustomerStatusResponse, B as BankDetailsRequest, h as BankDetailsResponse } from './webhooks-
|
|
4
|
-
export { A as Address, i as AddressObject, j as AddressesObject, k as ApiVersion, l as AppDeeplinks, m as BankDetailsCollected, n as BankDetailsConsent, o as BankDetailsObject, p as BankDetailsStatus, q as BillType, r as BreakdownCoverProduct, s as BroadbandProduct, t as BuildingStyle, u as BuildingType, v as CacheStatus, w as ClientMode, x as Consent, y as ContextEntry, z as CouncilTaxProduct, D as CreditCheckAddress, E as CreditCheckObject, F as Customer, G as CustomerType, H as DataCompleteness, I as DiscoveryStatus, J as Email, K as EnergyProduct, M as Environment, N as EpcRating, O as
|
|
1
|
+
import { T as TokenStorage, L as Logger } from './index-DIV4FzH6.cjs';
|
|
2
|
+
export { C as CreateHellobillHandlerOptions, H as HellobillHandlerSet, a as HellobillRequest, b as HellobillResponse, I as InMemoryTokenStorage, c as InMemoryWebhookDedupeStore, d as TokenManager, e as TokenManagerOptions, U as UnknownWebhookEventError, V as VerifyWebhookOptions, W as WebhookDedupeStore, f as WebhookHandlerContext, g as WebhookHandlerOptions, h as WebhookHandlers, i as WebhookVerificationError, j as createHellobillHandler, k as createWebhookHandler, v as verifyWebhook, l as verifyWebhookSignature } from './index-DIV4FzH6.cjs';
|
|
3
|
+
import { R as RequestId, S as SessionPayload, a as SessionResponse, b as SessionGetResponse, P as ProductsQuery, c as ProductsResponse, d as PropertyDetailResponse, L as LoaListResponse, C as CreateCustomerInput, e as CustomerCreateResponse, f as CustomerId, g as CustomerStatusResponse, B as BankDetailsRequest, h as BankDetailsResponse } from './webhooks-DKDXYTkz.cjs';
|
|
4
|
+
export { A as Address, i as AddressObject, j as AddressesObject, k as ApiVersion, l as AppDeeplinks, m as BankDetailsCollected, n as BankDetailsConsent, o as BankDetailsObject, p as BankDetailsStatus, q as BillType, r as BreakdownCoverProduct, s as BroadbandProduct, t as BuildingStyle, u as BuildingType, v as CacheStatus, w as ClientMode, x as Consent, y as ContextEntry, z as CouncilTaxProduct, D as CreditCheckAddress, E as CreditCheckObject, F as Customer, G as CustomerType, H as DataCompleteness, I as DiscoveryStatus, J as Email, K as EnergyProduct, M as Environment, N as EpcRating, O as FeatureFlags, Q as FinalRead, T as FuelType, U as HeatingType, V as HomeInsuranceProduct, W as IdempotencyKey, X as IsoDate, Y as IsoDateTime, Z as LoASignature, _ as LoaId, $ as LoaRecord, a0 as LocationRole, a1 as MaskedSortCode, a2 as Meters, a3 as MobileProduct, a4 as MoveIn, a5 as MoveObject, a6 as MoveOut, a7 as MoveOutNotificationFailed, a8 as MoveOutNotificationSent, a9 as MoveOutNotifyFlags, aa as MoveOutReason, ab as MoveOutStatus, ac as NearbyPoi, ad as OccupantObject, ae as OccupantType, af as OnboardingInfo, ag as OverallStatus, ah as Paginated, ai as Person, aj as PhoneNumber, ak as Postcode, al as Product, am as ProductBase, an as ProductCategory, ao as ProductConfidence, ap as ProductId, aq as ProductSetup, ar as PropertyDetailObject, as as PropertyLocation, at as PropertyObject, au as PropertyType, av as PropertyTypeCode, aw as PropertyTypeSubcode, ax as ProvidedFieldPath, ay as SESSION_IDEMPOTENCY_TTL_MS, az as SavingsSummaryResponse, aA as SelectedProduct, aB as SessionAccountCreated, aC as SessionAppDeferred, aD as SessionAppInstalled, aE as SessionDetailsConfirmed, aF as SessionEmbedOpened, aG as SessionLoaSigned, aH as SessionProductsSelected, aI as SetupStatus, aJ as SetupStatusChanged, aK as SignatureImage, aL as StoredBankDetails, aM as SubscriptionChanged, aN as SubscriptionStatus, aO as Title, aP as TvLicenceProduct, aQ as Url, aR as WaterProduct, aS as WebhookEvent, aT as WebhookEventBase, aU as WebhookEventId, aV as WebhookEventType } from './webhooks-DKDXYTkz.cjs';
|
|
5
5
|
import { ErrorEnvelope } from './types/index.cjs';
|
|
6
6
|
export { AnyvanSlot, AnyvanSlotsResponse, ErrorCode, ErrorType, RETRYABLE_HTTP_STATUSES } from './types/index.cjs';
|
|
7
7
|
|
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { T as TokenStorage, L as Logger } from './index-
|
|
2
|
-
export { C as CreateHellobillHandlerOptions, H as HellobillHandlerSet, a as HellobillRequest, b as HellobillResponse, I as InMemoryTokenStorage, c as InMemoryWebhookDedupeStore, d as TokenManager, e as TokenManagerOptions, U as UnknownWebhookEventError, V as VerifyWebhookOptions, W as WebhookDedupeStore, f as WebhookHandlerContext, g as WebhookHandlerOptions, h as WebhookHandlers, i as WebhookVerificationError, j as createHellobillHandler, k as createWebhookHandler, v as verifyWebhook, l as verifyWebhookSignature } from './index-
|
|
3
|
-
import { R as RequestId, S as SessionPayload, a as SessionResponse, b as SessionGetResponse, P as ProductsQuery, c as ProductsResponse, d as PropertyDetailResponse, L as LoaListResponse, C as CreateCustomerInput, e as CustomerCreateResponse, f as CustomerId, g as CustomerStatusResponse, B as BankDetailsRequest, h as BankDetailsResponse } from './webhooks-
|
|
4
|
-
export { A as Address, i as AddressObject, j as AddressesObject, k as ApiVersion, l as AppDeeplinks, m as BankDetailsCollected, n as BankDetailsConsent, o as BankDetailsObject, p as BankDetailsStatus, q as BillType, r as BreakdownCoverProduct, s as BroadbandProduct, t as BuildingStyle, u as BuildingType, v as CacheStatus, w as ClientMode, x as Consent, y as ContextEntry, z as CouncilTaxProduct, D as CreditCheckAddress, E as CreditCheckObject, F as Customer, G as CustomerType, H as DataCompleteness, I as DiscoveryStatus, J as Email, K as EnergyProduct, M as Environment, N as EpcRating, O as
|
|
1
|
+
import { T as TokenStorage, L as Logger } from './index-D425PJZo.js';
|
|
2
|
+
export { C as CreateHellobillHandlerOptions, H as HellobillHandlerSet, a as HellobillRequest, b as HellobillResponse, I as InMemoryTokenStorage, c as InMemoryWebhookDedupeStore, d as TokenManager, e as TokenManagerOptions, U as UnknownWebhookEventError, V as VerifyWebhookOptions, W as WebhookDedupeStore, f as WebhookHandlerContext, g as WebhookHandlerOptions, h as WebhookHandlers, i as WebhookVerificationError, j as createHellobillHandler, k as createWebhookHandler, v as verifyWebhook, l as verifyWebhookSignature } from './index-D425PJZo.js';
|
|
3
|
+
import { R as RequestId, S as SessionPayload, a as SessionResponse, b as SessionGetResponse, P as ProductsQuery, c as ProductsResponse, d as PropertyDetailResponse, L as LoaListResponse, C as CreateCustomerInput, e as CustomerCreateResponse, f as CustomerId, g as CustomerStatusResponse, B as BankDetailsRequest, h as BankDetailsResponse } from './webhooks-DKDXYTkz.js';
|
|
4
|
+
export { A as Address, i as AddressObject, j as AddressesObject, k as ApiVersion, l as AppDeeplinks, m as BankDetailsCollected, n as BankDetailsConsent, o as BankDetailsObject, p as BankDetailsStatus, q as BillType, r as BreakdownCoverProduct, s as BroadbandProduct, t as BuildingStyle, u as BuildingType, v as CacheStatus, w as ClientMode, x as Consent, y as ContextEntry, z as CouncilTaxProduct, D as CreditCheckAddress, E as CreditCheckObject, F as Customer, G as CustomerType, H as DataCompleteness, I as DiscoveryStatus, J as Email, K as EnergyProduct, M as Environment, N as EpcRating, O as FeatureFlags, Q as FinalRead, T as FuelType, U as HeatingType, V as HomeInsuranceProduct, W as IdempotencyKey, X as IsoDate, Y as IsoDateTime, Z as LoASignature, _ as LoaId, $ as LoaRecord, a0 as LocationRole, a1 as MaskedSortCode, a2 as Meters, a3 as MobileProduct, a4 as MoveIn, a5 as MoveObject, a6 as MoveOut, a7 as MoveOutNotificationFailed, a8 as MoveOutNotificationSent, a9 as MoveOutNotifyFlags, aa as MoveOutReason, ab as MoveOutStatus, ac as NearbyPoi, ad as OccupantObject, ae as OccupantType, af as OnboardingInfo, ag as OverallStatus, ah as Paginated, ai as Person, aj as PhoneNumber, ak as Postcode, al as Product, am as ProductBase, an as ProductCategory, ao as ProductConfidence, ap as ProductId, aq as ProductSetup, ar as PropertyDetailObject, as as PropertyLocation, at as PropertyObject, au as PropertyType, av as PropertyTypeCode, aw as PropertyTypeSubcode, ax as ProvidedFieldPath, ay as SESSION_IDEMPOTENCY_TTL_MS, az as SavingsSummaryResponse, aA as SelectedProduct, aB as SessionAccountCreated, aC as SessionAppDeferred, aD as SessionAppInstalled, aE as SessionDetailsConfirmed, aF as SessionEmbedOpened, aG as SessionLoaSigned, aH as SessionProductsSelected, aI as SetupStatus, aJ as SetupStatusChanged, aK as SignatureImage, aL as StoredBankDetails, aM as SubscriptionChanged, aN as SubscriptionStatus, aO as Title, aP as TvLicenceProduct, aQ as Url, aR as WaterProduct, aS as WebhookEvent, aT as WebhookEventBase, aU as WebhookEventId, aV as WebhookEventType } from './webhooks-DKDXYTkz.js';
|
|
5
5
|
import { ErrorEnvelope } from './types/index.js';
|
|
6
6
|
export { AnyvanSlot, AnyvanSlotsResponse, ErrorCode, ErrorType, RETRYABLE_HTTP_STATUSES } from './types/index.js';
|
|
7
7
|
|
package/dist/koa/index.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as CreateHellobillHandlerOptions } from '../index-
|
|
2
|
-
import '../webhooks-
|
|
1
|
+
import { C as CreateHellobillHandlerOptions } from '../index-DIV4FzH6.cjs';
|
|
2
|
+
import '../webhooks-DKDXYTkz.cjs';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Koa adapter for the framework-agnostic SDK core.
|
package/dist/koa/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as CreateHellobillHandlerOptions } from '../index-
|
|
2
|
-
import '../webhooks-
|
|
1
|
+
import { C as CreateHellobillHandlerOptions } from '../index-D425PJZo.js';
|
|
2
|
+
import '../webhooks-DKDXYTkz.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Koa adapter for the framework-agnostic SDK core.
|
package/dist/next/index.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as CreateHellobillHandlerOptions } from '../index-
|
|
2
|
-
import '../webhooks-
|
|
1
|
+
import { C as CreateHellobillHandlerOptions } from '../index-DIV4FzH6.cjs';
|
|
2
|
+
import '../webhooks-DKDXYTkz.cjs';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Next.js App Router adapter for the framework-agnostic SDK core.
|
package/dist/next/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as CreateHellobillHandlerOptions } from '../index-
|
|
2
|
-
import '../webhooks-
|
|
1
|
+
import { C as CreateHellobillHandlerOptions } from '../index-D425PJZo.js';
|
|
2
|
+
import '../webhooks-DKDXYTkz.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Next.js App Router adapter for the framework-agnostic SDK core.
|
package/dist/types/index.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { A as Address, i as AddressObject, j as AddressesObject, k as ApiVersion, l as AppDeeplinks, m as BankDetailsCollected, n as BankDetailsConsent, o as BankDetailsObject, B as BankDetailsRequest, h as BankDetailsResponse, p as BankDetailsStatus, q as BillType, r as BreakdownCoverProduct, s as BroadbandProduct, t as BuildingStyle, u as BuildingType, v as CacheStatus, w as ClientMode, x as Consent, y as ContextEntry, z as CouncilTaxProduct, C as CreateCustomerInput, D as CreditCheckAddress, E as CreditCheckObject, F as Customer, e as CustomerCreateResponse, f as CustomerId, g as CustomerStatusResponse, G as CustomerType, H as DataCompleteness, I as DiscoveryStatus, J as Email, K as EnergyProduct, M as Environment, N as EpcRating, O as
|
|
1
|
+
import { Y as IsoDateTime, R as RequestId } from '../webhooks-DKDXYTkz.cjs';
|
|
2
|
+
export { A as Address, i as AddressObject, j as AddressesObject, k as ApiVersion, l as AppDeeplinks, m as BankDetailsCollected, n as BankDetailsConsent, o as BankDetailsObject, B as BankDetailsRequest, h as BankDetailsResponse, p as BankDetailsStatus, q as BillType, r as BreakdownCoverProduct, s as BroadbandProduct, t as BuildingStyle, u as BuildingType, v as CacheStatus, w as ClientMode, x as Consent, y as ContextEntry, z as CouncilTaxProduct, C as CreateCustomerInput, D as CreditCheckAddress, E as CreditCheckObject, F as Customer, e as CustomerCreateResponse, f as CustomerId, g as CustomerStatusResponse, G as CustomerType, H as DataCompleteness, I as DiscoveryStatus, J as Email, K as EnergyProduct, M as Environment, N as EpcRating, O as FeatureFlags, Q as FinalRead, T as FuelType, U as HeatingType, V as HomeInsuranceProduct, W as IdempotencyKey, X as IsoDate, Z as LoASignature, _ as LoaId, L as LoaListResponse, $ as LoaRecord, a0 as LocationRole, a1 as MaskedSortCode, a2 as Meters, a3 as MobileProduct, a4 as MoveIn, a5 as MoveObject, a6 as MoveOut, a7 as MoveOutNotificationFailed, a8 as MoveOutNotificationSent, a9 as MoveOutNotifyFlags, aa as MoveOutReason, ab as MoveOutStatus, ac as NearbyPoi, ad as OccupantObject, ae as OccupantType, af as OnboardingInfo, ag as OverallStatus, ah as Paginated, ai as Person, aj as PhoneNumber, ak as Postcode, al as Product, am as ProductBase, an as ProductCategory, ao as ProductConfidence, ap as ProductId, aq as ProductSetup, P as ProductsQuery, c as ProductsResponse, ar as PropertyDetailObject, d as PropertyDetailResponse, as as PropertyLocation, at as PropertyObject, au as PropertyType, av as PropertyTypeCode, aw as PropertyTypeSubcode, ax as ProvidedFieldPath, ay as SESSION_IDEMPOTENCY_TTL_MS, az as SavingsSummaryResponse, aA as SelectedProduct, aB as SessionAccountCreated, aC as SessionAppDeferred, aD as SessionAppInstalled, aE as SessionDetailsConfirmed, aF as SessionEmbedOpened, b as SessionGetResponse, aG as SessionLoaSigned, S as SessionPayload, aH as SessionProductsSelected, a as SessionResponse, aI as SetupStatus, aJ as SetupStatusChanged, aK as SignatureImage, aL as StoredBankDetails, aM as SubscriptionChanged, aN as SubscriptionStatus, aO as Title, aP as TvLicenceProduct, aQ as Url, aR as WaterProduct, aS as WebhookEvent, aT as WebhookEventBase, aU as WebhookEventId, aV as WebhookEventType } from '../webhooks-DKDXYTkz.cjs';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* AnyVan move slot types.
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { A as Address, i as AddressObject, j as AddressesObject, k as ApiVersion, l as AppDeeplinks, m as BankDetailsCollected, n as BankDetailsConsent, o as BankDetailsObject, B as BankDetailsRequest, h as BankDetailsResponse, p as BankDetailsStatus, q as BillType, r as BreakdownCoverProduct, s as BroadbandProduct, t as BuildingStyle, u as BuildingType, v as CacheStatus, w as ClientMode, x as Consent, y as ContextEntry, z as CouncilTaxProduct, C as CreateCustomerInput, D as CreditCheckAddress, E as CreditCheckObject, F as Customer, e as CustomerCreateResponse, f as CustomerId, g as CustomerStatusResponse, G as CustomerType, H as DataCompleteness, I as DiscoveryStatus, J as Email, K as EnergyProduct, M as Environment, N as EpcRating, O as
|
|
1
|
+
import { Y as IsoDateTime, R as RequestId } from '../webhooks-DKDXYTkz.js';
|
|
2
|
+
export { A as Address, i as AddressObject, j as AddressesObject, k as ApiVersion, l as AppDeeplinks, m as BankDetailsCollected, n as BankDetailsConsent, o as BankDetailsObject, B as BankDetailsRequest, h as BankDetailsResponse, p as BankDetailsStatus, q as BillType, r as BreakdownCoverProduct, s as BroadbandProduct, t as BuildingStyle, u as BuildingType, v as CacheStatus, w as ClientMode, x as Consent, y as ContextEntry, z as CouncilTaxProduct, C as CreateCustomerInput, D as CreditCheckAddress, E as CreditCheckObject, F as Customer, e as CustomerCreateResponse, f as CustomerId, g as CustomerStatusResponse, G as CustomerType, H as DataCompleteness, I as DiscoveryStatus, J as Email, K as EnergyProduct, M as Environment, N as EpcRating, O as FeatureFlags, Q as FinalRead, T as FuelType, U as HeatingType, V as HomeInsuranceProduct, W as IdempotencyKey, X as IsoDate, Z as LoASignature, _ as LoaId, L as LoaListResponse, $ as LoaRecord, a0 as LocationRole, a1 as MaskedSortCode, a2 as Meters, a3 as MobileProduct, a4 as MoveIn, a5 as MoveObject, a6 as MoveOut, a7 as MoveOutNotificationFailed, a8 as MoveOutNotificationSent, a9 as MoveOutNotifyFlags, aa as MoveOutReason, ab as MoveOutStatus, ac as NearbyPoi, ad as OccupantObject, ae as OccupantType, af as OnboardingInfo, ag as OverallStatus, ah as Paginated, ai as Person, aj as PhoneNumber, ak as Postcode, al as Product, am as ProductBase, an as ProductCategory, ao as ProductConfidence, ap as ProductId, aq as ProductSetup, P as ProductsQuery, c as ProductsResponse, ar as PropertyDetailObject, d as PropertyDetailResponse, as as PropertyLocation, at as PropertyObject, au as PropertyType, av as PropertyTypeCode, aw as PropertyTypeSubcode, ax as ProvidedFieldPath, ay as SESSION_IDEMPOTENCY_TTL_MS, az as SavingsSummaryResponse, aA as SelectedProduct, aB as SessionAccountCreated, aC as SessionAppDeferred, aD as SessionAppInstalled, aE as SessionDetailsConfirmed, aF as SessionEmbedOpened, b as SessionGetResponse, aG as SessionLoaSigned, S as SessionPayload, aH as SessionProductsSelected, a as SessionResponse, aI as SetupStatus, aJ as SetupStatusChanged, aK as SignatureImage, aL as StoredBankDetails, aM as SubscriptionChanged, aN as SubscriptionStatus, aO as Title, aP as TvLicenceProduct, aQ as Url, aR as WaterProduct, aS as WebhookEvent, aT as WebhookEventBase, aU as WebhookEventId, aV as WebhookEventType } from '../webhooks-DKDXYTkz.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* AnyVan move slot types.
|
package/dist/types/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/types/session.ts","../../src/types/errors.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"sources":["../../src/types/session.ts","../../src/types/errors.ts"],"names":[],"mappings":";;;AAyGO,IAAM,0BAAA,GAA6B,EAAA,GAAK,EAAA,GAAK,EAAA,GAAK;;;ACzBlD,IAAM,uBAAA,uBAA8B,GAAA,CAAY,CAAC,KAAK,GAAA,EAAK,GAAA,EAAK,GAAA,EAAK,GAAG,CAAC","file":"index.js","sourcesContent":["/**\n * Session lifecycle types.\n * POST /partner/sessions creates a session and returns a short-lived session_token\n * that the embed presents to the frontend-facing endpoints.\n */\n\nimport type {\n AddressObject,\n Consent,\n ContextEntry,\n Customer,\n IsoDateTime,\n Meters,\n MoveIn,\n MoveOut,\n ProvidedFieldPath,\n OccupantObject,\n PropertyObject,\n} from './common.js';\n\nexport interface AddressesObject {\n /** The property the customer is moving INTO. Where utilities are set up. */\n current: PropertyObject;\n /** The property the customer is moving OUT of, if applicable. */\n previous?: PropertyObject;\n}\n\nexport interface MoveObject {\n in: MoveIn;\n out?: MoveOut;\n}\n\n/**\n * Canonical snake_case shape the SDK sends to POST /partner/sessions.\n * `buildSessionPayload(req)` on the server is responsible for assembling this\n * from whatever shape the partner's host page provides.\n */\nexport interface SessionPayload {\n /** Partner-controlled correlation. Echoed back on webhooks as `data.referral_id`. */\n referral_id?: string;\n customer: Customer;\n occupants?: OccupantObject[];\n addresses: AddressesObject;\n move: MoveObject;\n meters?: Meters;\n consent: Consent;\n context?: ContextEntry[];\n}\n\n/**\n * Per-session toggles that gate embed pages and filter product categories.\n * Snake_case end-to-end; the embed reads the `feature_flags` envelope as-is.\n */\nexport interface FeatureFlags {\n /** When false, the embed hides the Direct Debit page. */\n direct_debit: boolean;\n /** When false, the embed hides the Letter of Authority signing page. */\n loa_signing: boolean;\n /** When false, the API filters out removal-services products. */\n allow_removal_services: boolean;\n /** When false, the API filters out electoral-roll products. */\n allow_electoral_roll: boolean;\n}\n\n/** Response from POST /partner/sessions. */\nexport interface SessionResponse {\n session_id: string;\n /** Short-lived JWT (300s) the embed presents to the SDK-mounted endpoints. */\n session_token: string;\n embed_base_url: string;\n /** Initial discovery status. Embed polls /products until complete. */\n discovery_status: 'running' | 'complete';\n estimated_ready_seconds?: number;\n /** Dot-notation paths of fields HelloBill received. Drives adaptive UI. */\n provided_fields: ProvidedFieldPath[];\n /** ISO 8601. Session resource expires after 90 days. */\n expires_at: IsoDateTime;\n /** Optional for back-compat with fixtures and pre-feature_flags payloads. */\n feature_flags?: FeatureFlags;\n}\n\n/**\n * Response from GET /partner/sessions/:id.\n *\n * Per spec §3.7, the endpoint echoes back the full SessionPayload the partner\n * originally sent to POST /partner/sessions, extended with server-assigned fields.\n * This is distinct from SessionResponse (POST projection) which carries session_token\n * and embed_base_url but not the original payload fields.\n */\nexport interface SessionGetResponse extends SessionPayload {\n /** Stable server-assigned session identifier. */\n session_id: string;\n /** ISO 8601 timestamp when the session was created. */\n created_at: IsoDateTime;\n /** ISO 8601 session expiry (90 days from creation). */\n expires_at: IsoDateTime;\n /** Lifecycle status of the session. */\n status: 'created' | 'customer_created' | 'expired';\n}\n\n/**\n * Idempotency window for POST /sessions: 24h on\n * email + addresses.current.postcode + addresses.current.address_line_1.\n * `move.out` is NOT part of the key — partners cannot retroactively change shape.\n */\nexport const SESSION_IDEMPOTENCY_TTL_MS = 24 * 60 * 60 * 1000;\n","/**\n * Spec error envelope.\n * Returned with non-2xx responses from the Partner API and surfaced verbatim by the SDK.\n */\n\nimport type { RequestId } from './common.js';\n\n/**\n * Error codes follow `<category>.<specific>` naming and match the v15 §12 catalog.\n */\nexport type ErrorCode =\n // validation.*\n | 'validation.missing_required_field'\n | 'validation.invalid_field_value'\n | 'validation.invalid_enum_value'\n // consent.*\n | 'consent.required'\n // product.*\n | 'product.id_expired'\n // loa.*\n | 'loa.coverage_missing'\n | 'loa.coverage_excess'\n | 'loa.session_mismatch'\n | 'loa.template_changed'\n | 'loa.selection_changed'\n // signature_image.*\n | 'signature_image.invalid'\n | 'signature_image.too_large'\n | 'signature_image.dimensions_invalid'\n // address.*\n | 'address.line_too_long'\n | 'address.postcode_invalid'\n // move_out.*\n | 'move_out.requires_previous_property'\n | 'move_out.invalid_date'\n // final_read.*\n | 'final_read.implausible'\n // customer.*\n | 'customer.address_invalid'\n | 'customer.not_found'\n // bank_details.*\n | 'bank_details.invalid_sort_code'\n | 'bank_details.invalid_account_number'\n | 'bank_details.modulus_check_failed'\n | 'bank_details.session_locked'\n // auth.*\n | 'auth.invalid_credentials'\n | 'auth.token_expired'\n | 'auth.token_malformed'\n | 'auth.insufficient_scope'\n // session.*\n | 'session.not_found'\n // rate.*\n | 'rate.limited'\n // internal.*\n | 'internal.error'\n // discovery.*\n | 'discovery.unavailable';\n\nexport type ErrorType =\n | 'authentication_error'\n | 'validation_error'\n | 'rate_limit_error'\n | 'api_error';\n\nexport interface ErrorEnvelope {\n error: {\n type: ErrorType;\n code: ErrorCode;\n message: string;\n /** Path of the offending field (e.g. \"addresses.current.postcode\"). */\n param?: string;\n /** For validation.missing_required_field — dot-notation list of missing fields. */\n missing_fields?: string[];\n /** Echo of `X-HelloBill-Request-Id` for support correlation. */\n request_id: RequestId;\n };\n}\n\n/** HTTP statuses the SDK retries automatically with exponential backoff. */\nexport const RETRYABLE_HTTP_STATUSES = new Set<number>([429, 500, 502, 503, 504]);\n"]}
|
package/dist/types/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/types/session.ts","../../src/types/errors.ts"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"sources":["../../src/types/session.ts","../../src/types/errors.ts"],"names":[],"mappings":";AAyGO,IAAM,0BAAA,GAA6B,EAAA,GAAK,EAAA,GAAK,EAAA,GAAK;;;ACzBlD,IAAM,uBAAA,uBAA8B,GAAA,CAAY,CAAC,KAAK,GAAA,EAAK,GAAA,EAAK,GAAA,EAAK,GAAG,CAAC","file":"index.mjs","sourcesContent":["/**\n * Session lifecycle types.\n * POST /partner/sessions creates a session and returns a short-lived session_token\n * that the embed presents to the frontend-facing endpoints.\n */\n\nimport type {\n AddressObject,\n Consent,\n ContextEntry,\n Customer,\n IsoDateTime,\n Meters,\n MoveIn,\n MoveOut,\n ProvidedFieldPath,\n OccupantObject,\n PropertyObject,\n} from './common.js';\n\nexport interface AddressesObject {\n /** The property the customer is moving INTO. Where utilities are set up. */\n current: PropertyObject;\n /** The property the customer is moving OUT of, if applicable. */\n previous?: PropertyObject;\n}\n\nexport interface MoveObject {\n in: MoveIn;\n out?: MoveOut;\n}\n\n/**\n * Canonical snake_case shape the SDK sends to POST /partner/sessions.\n * `buildSessionPayload(req)` on the server is responsible for assembling this\n * from whatever shape the partner's host page provides.\n */\nexport interface SessionPayload {\n /** Partner-controlled correlation. Echoed back on webhooks as `data.referral_id`. */\n referral_id?: string;\n customer: Customer;\n occupants?: OccupantObject[];\n addresses: AddressesObject;\n move: MoveObject;\n meters?: Meters;\n consent: Consent;\n context?: ContextEntry[];\n}\n\n/**\n * Per-session toggles that gate embed pages and filter product categories.\n * Snake_case end-to-end; the embed reads the `feature_flags` envelope as-is.\n */\nexport interface FeatureFlags {\n /** When false, the embed hides the Direct Debit page. */\n direct_debit: boolean;\n /** When false, the embed hides the Letter of Authority signing page. */\n loa_signing: boolean;\n /** When false, the API filters out removal-services products. */\n allow_removal_services: boolean;\n /** When false, the API filters out electoral-roll products. */\n allow_electoral_roll: boolean;\n}\n\n/** Response from POST /partner/sessions. */\nexport interface SessionResponse {\n session_id: string;\n /** Short-lived JWT (300s) the embed presents to the SDK-mounted endpoints. */\n session_token: string;\n embed_base_url: string;\n /** Initial discovery status. Embed polls /products until complete. */\n discovery_status: 'running' | 'complete';\n estimated_ready_seconds?: number;\n /** Dot-notation paths of fields HelloBill received. Drives adaptive UI. */\n provided_fields: ProvidedFieldPath[];\n /** ISO 8601. Session resource expires after 90 days. */\n expires_at: IsoDateTime;\n /** Optional for back-compat with fixtures and pre-feature_flags payloads. */\n feature_flags?: FeatureFlags;\n}\n\n/**\n * Response from GET /partner/sessions/:id.\n *\n * Per spec §3.7, the endpoint echoes back the full SessionPayload the partner\n * originally sent to POST /partner/sessions, extended with server-assigned fields.\n * This is distinct from SessionResponse (POST projection) which carries session_token\n * and embed_base_url but not the original payload fields.\n */\nexport interface SessionGetResponse extends SessionPayload {\n /** Stable server-assigned session identifier. */\n session_id: string;\n /** ISO 8601 timestamp when the session was created. */\n created_at: IsoDateTime;\n /** ISO 8601 session expiry (90 days from creation). */\n expires_at: IsoDateTime;\n /** Lifecycle status of the session. */\n status: 'created' | 'customer_created' | 'expired';\n}\n\n/**\n * Idempotency window for POST /sessions: 24h on\n * email + addresses.current.postcode + addresses.current.address_line_1.\n * `move.out` is NOT part of the key — partners cannot retroactively change shape.\n */\nexport const SESSION_IDEMPOTENCY_TTL_MS = 24 * 60 * 60 * 1000;\n","/**\n * Spec error envelope.\n * Returned with non-2xx responses from the Partner API and surfaced verbatim by the SDK.\n */\n\nimport type { RequestId } from './common.js';\n\n/**\n * Error codes follow `<category>.<specific>` naming and match the v15 §12 catalog.\n */\nexport type ErrorCode =\n // validation.*\n | 'validation.missing_required_field'\n | 'validation.invalid_field_value'\n | 'validation.invalid_enum_value'\n // consent.*\n | 'consent.required'\n // product.*\n | 'product.id_expired'\n // loa.*\n | 'loa.coverage_missing'\n | 'loa.coverage_excess'\n | 'loa.session_mismatch'\n | 'loa.template_changed'\n | 'loa.selection_changed'\n // signature_image.*\n | 'signature_image.invalid'\n | 'signature_image.too_large'\n | 'signature_image.dimensions_invalid'\n // address.*\n | 'address.line_too_long'\n | 'address.postcode_invalid'\n // move_out.*\n | 'move_out.requires_previous_property'\n | 'move_out.invalid_date'\n // final_read.*\n | 'final_read.implausible'\n // customer.*\n | 'customer.address_invalid'\n | 'customer.not_found'\n // bank_details.*\n | 'bank_details.invalid_sort_code'\n | 'bank_details.invalid_account_number'\n | 'bank_details.modulus_check_failed'\n | 'bank_details.session_locked'\n // auth.*\n | 'auth.invalid_credentials'\n | 'auth.token_expired'\n | 'auth.token_malformed'\n | 'auth.insufficient_scope'\n // session.*\n | 'session.not_found'\n // rate.*\n | 'rate.limited'\n // internal.*\n | 'internal.error'\n // discovery.*\n | 'discovery.unavailable';\n\nexport type ErrorType =\n | 'authentication_error'\n | 'validation_error'\n | 'rate_limit_error'\n | 'api_error';\n\nexport interface ErrorEnvelope {\n error: {\n type: ErrorType;\n code: ErrorCode;\n message: string;\n /** Path of the offending field (e.g. \"addresses.current.postcode\"). */\n param?: string;\n /** For validation.missing_required_field — dot-notation list of missing fields. */\n missing_fields?: string[];\n /** Echo of `X-HelloBill-Request-Id` for support correlation. */\n request_id: RequestId;\n };\n}\n\n/** HTTP statuses the SDK retries automatically with exponential backoff. */\nexport const RETRYABLE_HTTP_STATUSES = new Set<number>([429, 500, 502, 503, 504]);\n"]}
|
package/dist/webhook/index.d.cts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { c as InMemoryWebhookDedupeStore, U as UnknownWebhookEventError, V as VerifyWebhookOptions, W as WebhookDedupeStore, f as WebhookHandlerContext, g as WebhookHandlerOptions, h as WebhookHandlers, i as WebhookVerificationError, k as createWebhookHandler, v as verifyWebhook, l as verifyWebhookSignature } from '../index-
|
|
2
|
-
import '../webhooks-
|
|
1
|
+
export { c as InMemoryWebhookDedupeStore, U as UnknownWebhookEventError, V as VerifyWebhookOptions, W as WebhookDedupeStore, f as WebhookHandlerContext, g as WebhookHandlerOptions, h as WebhookHandlers, i as WebhookVerificationError, k as createWebhookHandler, v as verifyWebhook, l as verifyWebhookSignature } from '../index-DIV4FzH6.cjs';
|
|
2
|
+
import '../webhooks-DKDXYTkz.cjs';
|
package/dist/webhook/index.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { c as InMemoryWebhookDedupeStore, U as UnknownWebhookEventError, V as VerifyWebhookOptions, W as WebhookDedupeStore, f as WebhookHandlerContext, g as WebhookHandlerOptions, h as WebhookHandlers, i as WebhookVerificationError, k as createWebhookHandler, v as verifyWebhook, l as verifyWebhookSignature } from '../index-
|
|
2
|
-
import '../webhooks-
|
|
1
|
+
export { c as InMemoryWebhookDedupeStore, U as UnknownWebhookEventError, V as VerifyWebhookOptions, W as WebhookDedupeStore, f as WebhookHandlerContext, g as WebhookHandlerOptions, h as WebhookHandlers, i as WebhookVerificationError, k as createWebhookHandler, v as verifyWebhook, l as verifyWebhookSignature } from '../index-D425PJZo.js';
|
|
2
|
+
import '../webhooks-DKDXYTkz.js';
|
|
@@ -257,6 +257,20 @@ interface SessionPayload {
|
|
|
257
257
|
consent: Consent;
|
|
258
258
|
context?: ContextEntry[];
|
|
259
259
|
}
|
|
260
|
+
/**
|
|
261
|
+
* Per-session toggles that gate embed pages and filter product categories.
|
|
262
|
+
* Snake_case end-to-end; the embed reads the `feature_flags` envelope as-is.
|
|
263
|
+
*/
|
|
264
|
+
interface FeatureFlags {
|
|
265
|
+
/** When false, the embed hides the Direct Debit page. */
|
|
266
|
+
direct_debit: boolean;
|
|
267
|
+
/** When false, the embed hides the Letter of Authority signing page. */
|
|
268
|
+
loa_signing: boolean;
|
|
269
|
+
/** When false, the API filters out removal-services products. */
|
|
270
|
+
allow_removal_services: boolean;
|
|
271
|
+
/** When false, the API filters out electoral-roll products. */
|
|
272
|
+
allow_electoral_roll: boolean;
|
|
273
|
+
}
|
|
260
274
|
/** Response from POST /partner/sessions. */
|
|
261
275
|
interface SessionResponse {
|
|
262
276
|
session_id: string;
|
|
@@ -270,6 +284,8 @@ interface SessionResponse {
|
|
|
270
284
|
provided_fields: ProvidedFieldPath[];
|
|
271
285
|
/** ISO 8601. Session resource expires after 90 days. */
|
|
272
286
|
expires_at: IsoDateTime;
|
|
287
|
+
/** Optional for back-compat with fixtures and pre-feature_flags payloads. */
|
|
288
|
+
feature_flags?: FeatureFlags;
|
|
273
289
|
}
|
|
274
290
|
/**
|
|
275
291
|
* Response from GET /partner/sessions/:id.
|
|
@@ -325,9 +341,9 @@ interface ProductBase {
|
|
|
325
341
|
interface EnergyProduct extends ProductBase {
|
|
326
342
|
category: 'energy';
|
|
327
343
|
details: {
|
|
328
|
-
unit_rate_pence_per_kwh: number;
|
|
344
|
+
unit_rate_pence_per_kwh: number | null;
|
|
329
345
|
unit_rate_pence_per_kwh_gas?: number;
|
|
330
|
-
standing_charge_pence_per_day: number;
|
|
346
|
+
standing_charge_pence_per_day: number | null;
|
|
331
347
|
standing_charge_pence_per_day_gas?: number;
|
|
332
348
|
estimated_annual_usage_kwh?: number;
|
|
333
349
|
estimated_annual_usage_kwh_gas?: number;
|
|
@@ -345,12 +361,12 @@ interface WaterProduct extends ProductBase {
|
|
|
345
361
|
metered: boolean;
|
|
346
362
|
estimated_litres_per_day?: number;
|
|
347
363
|
unit_rate_gbp_per_m3?: number;
|
|
348
|
-
standing_charge_gbp_per_year: number;
|
|
364
|
+
standing_charge_gbp_per_year: number | null;
|
|
349
365
|
rateable_value_pence?: number;
|
|
350
366
|
sewerage_annual_pence?: number;
|
|
351
367
|
surface_water_drainage_pence?: number;
|
|
352
|
-
effective_tariff_year: string;
|
|
353
|
-
region: string;
|
|
368
|
+
effective_tariff_year: string | null;
|
|
369
|
+
region: string | null;
|
|
354
370
|
};
|
|
355
371
|
}
|
|
356
372
|
interface BroadbandProduct extends ProductBase {
|
|
@@ -764,4 +780,4 @@ type BankDetailsCollected = WebhookEventBase<'bank_details.collected', {
|
|
|
764
780
|
type WebhookEvent = SessionEmbedOpened | SessionDetailsConfirmed | SessionProductsSelected | SessionLoaSigned | SessionAccountCreated | SessionAppInstalled | SessionAppDeferred | SubscriptionChanged | SetupStatusChanged | MoveOutNotificationSent | MoveOutNotificationFailed | BankDetailsCollected;
|
|
765
781
|
type WebhookEventType = WebhookEvent['event'];
|
|
766
782
|
|
|
767
|
-
export { type
|
|
783
|
+
export { type LoaRecord as $, type Address as A, type BankDetailsRequest as B, type CreateCustomerInput as C, type CreditCheckAddress as D, type CreditCheckObject as E, type Customer as F, type CustomerType as G, type DataCompleteness as H, type DiscoveryStatus as I, type Email as J, type EnergyProduct as K, type LoaListResponse as L, type Environment as M, type EpcRating as N, type FeatureFlags as O, type ProductsQuery as P, type FinalRead as Q, type RequestId as R, type SessionPayload as S, type FuelType as T, type HeatingType as U, type HomeInsuranceProduct as V, type IdempotencyKey as W, type IsoDate as X, type IsoDateTime as Y, type LoASignature as Z, type LoaId as _, type SessionResponse as a, type LocationRole as a0, type MaskedSortCode as a1, type Meters as a2, type MobileProduct as a3, type MoveIn as a4, type MoveObject as a5, type MoveOut as a6, type MoveOutNotificationFailed as a7, type MoveOutNotificationSent as a8, type MoveOutNotifyFlags as a9, type SelectedProduct as aA, type SessionAccountCreated as aB, type SessionAppDeferred as aC, type SessionAppInstalled as aD, type SessionDetailsConfirmed as aE, type SessionEmbedOpened as aF, type SessionLoaSigned as aG, type SessionProductsSelected as aH, type SetupStatus as aI, type SetupStatusChanged as aJ, type SignatureImage as aK, type StoredBankDetails as aL, type SubscriptionChanged as aM, type SubscriptionStatus as aN, type Title as aO, type TvLicenceProduct as aP, type Url as aQ, type WaterProduct as aR, type WebhookEvent as aS, type WebhookEventBase as aT, type WebhookEventId as aU, type WebhookEventType as aV, type MoveOutReason as aa, type MoveOutStatus as ab, type NearbyPoi as ac, type OccupantObject as ad, type OccupantType as ae, type OnboardingInfo as af, type OverallStatus as ag, type Paginated as ah, type Person as ai, type PhoneNumber as aj, type Postcode as ak, type Product as al, type ProductBase as am, type ProductCategory as an, type ProductConfidence as ao, type ProductId as ap, type ProductSetup as aq, type PropertyDetailObject as ar, type PropertyLocation as as, type PropertyObject as at, type PropertyType as au, type PropertyTypeCode as av, type PropertyTypeSubcode as aw, type ProvidedFieldPath as ax, SESSION_IDEMPOTENCY_TTL_MS as ay, type SavingsSummaryResponse as az, type SessionGetResponse as b, type ProductsResponse as c, type PropertyDetailResponse as d, type CustomerCreateResponse as e, type CustomerId as f, type CustomerStatusResponse as g, type BankDetailsResponse as h, type AddressObject as i, type AddressesObject as j, type ApiVersion as k, type AppDeeplinks as l, type BankDetailsCollected as m, type BankDetailsConsent as n, type BankDetailsObject as o, type BankDetailsStatus as p, type BillType as q, type BreakdownCoverProduct as r, type BroadbandProduct as s, type BuildingStyle as t, type BuildingType as u, type CacheStatus as v, type ClientMode as w, type Consent as x, type ContextEntry as y, type CouncilTaxProduct as z };
|
|
@@ -257,6 +257,20 @@ interface SessionPayload {
|
|
|
257
257
|
consent: Consent;
|
|
258
258
|
context?: ContextEntry[];
|
|
259
259
|
}
|
|
260
|
+
/**
|
|
261
|
+
* Per-session toggles that gate embed pages and filter product categories.
|
|
262
|
+
* Snake_case end-to-end; the embed reads the `feature_flags` envelope as-is.
|
|
263
|
+
*/
|
|
264
|
+
interface FeatureFlags {
|
|
265
|
+
/** When false, the embed hides the Direct Debit page. */
|
|
266
|
+
direct_debit: boolean;
|
|
267
|
+
/** When false, the embed hides the Letter of Authority signing page. */
|
|
268
|
+
loa_signing: boolean;
|
|
269
|
+
/** When false, the API filters out removal-services products. */
|
|
270
|
+
allow_removal_services: boolean;
|
|
271
|
+
/** When false, the API filters out electoral-roll products. */
|
|
272
|
+
allow_electoral_roll: boolean;
|
|
273
|
+
}
|
|
260
274
|
/** Response from POST /partner/sessions. */
|
|
261
275
|
interface SessionResponse {
|
|
262
276
|
session_id: string;
|
|
@@ -270,6 +284,8 @@ interface SessionResponse {
|
|
|
270
284
|
provided_fields: ProvidedFieldPath[];
|
|
271
285
|
/** ISO 8601. Session resource expires after 90 days. */
|
|
272
286
|
expires_at: IsoDateTime;
|
|
287
|
+
/** Optional for back-compat with fixtures and pre-feature_flags payloads. */
|
|
288
|
+
feature_flags?: FeatureFlags;
|
|
273
289
|
}
|
|
274
290
|
/**
|
|
275
291
|
* Response from GET /partner/sessions/:id.
|
|
@@ -325,9 +341,9 @@ interface ProductBase {
|
|
|
325
341
|
interface EnergyProduct extends ProductBase {
|
|
326
342
|
category: 'energy';
|
|
327
343
|
details: {
|
|
328
|
-
unit_rate_pence_per_kwh: number;
|
|
344
|
+
unit_rate_pence_per_kwh: number | null;
|
|
329
345
|
unit_rate_pence_per_kwh_gas?: number;
|
|
330
|
-
standing_charge_pence_per_day: number;
|
|
346
|
+
standing_charge_pence_per_day: number | null;
|
|
331
347
|
standing_charge_pence_per_day_gas?: number;
|
|
332
348
|
estimated_annual_usage_kwh?: number;
|
|
333
349
|
estimated_annual_usage_kwh_gas?: number;
|
|
@@ -345,12 +361,12 @@ interface WaterProduct extends ProductBase {
|
|
|
345
361
|
metered: boolean;
|
|
346
362
|
estimated_litres_per_day?: number;
|
|
347
363
|
unit_rate_gbp_per_m3?: number;
|
|
348
|
-
standing_charge_gbp_per_year: number;
|
|
364
|
+
standing_charge_gbp_per_year: number | null;
|
|
349
365
|
rateable_value_pence?: number;
|
|
350
366
|
sewerage_annual_pence?: number;
|
|
351
367
|
surface_water_drainage_pence?: number;
|
|
352
|
-
effective_tariff_year: string;
|
|
353
|
-
region: string;
|
|
368
|
+
effective_tariff_year: string | null;
|
|
369
|
+
region: string | null;
|
|
354
370
|
};
|
|
355
371
|
}
|
|
356
372
|
interface BroadbandProduct extends ProductBase {
|
|
@@ -764,4 +780,4 @@ type BankDetailsCollected = WebhookEventBase<'bank_details.collected', {
|
|
|
764
780
|
type WebhookEvent = SessionEmbedOpened | SessionDetailsConfirmed | SessionProductsSelected | SessionLoaSigned | SessionAccountCreated | SessionAppInstalled | SessionAppDeferred | SubscriptionChanged | SetupStatusChanged | MoveOutNotificationSent | MoveOutNotificationFailed | BankDetailsCollected;
|
|
765
781
|
type WebhookEventType = WebhookEvent['event'];
|
|
766
782
|
|
|
767
|
-
export { type
|
|
783
|
+
export { type LoaRecord as $, type Address as A, type BankDetailsRequest as B, type CreateCustomerInput as C, type CreditCheckAddress as D, type CreditCheckObject as E, type Customer as F, type CustomerType as G, type DataCompleteness as H, type DiscoveryStatus as I, type Email as J, type EnergyProduct as K, type LoaListResponse as L, type Environment as M, type EpcRating as N, type FeatureFlags as O, type ProductsQuery as P, type FinalRead as Q, type RequestId as R, type SessionPayload as S, type FuelType as T, type HeatingType as U, type HomeInsuranceProduct as V, type IdempotencyKey as W, type IsoDate as X, type IsoDateTime as Y, type LoASignature as Z, type LoaId as _, type SessionResponse as a, type LocationRole as a0, type MaskedSortCode as a1, type Meters as a2, type MobileProduct as a3, type MoveIn as a4, type MoveObject as a5, type MoveOut as a6, type MoveOutNotificationFailed as a7, type MoveOutNotificationSent as a8, type MoveOutNotifyFlags as a9, type SelectedProduct as aA, type SessionAccountCreated as aB, type SessionAppDeferred as aC, type SessionAppInstalled as aD, type SessionDetailsConfirmed as aE, type SessionEmbedOpened as aF, type SessionLoaSigned as aG, type SessionProductsSelected as aH, type SetupStatus as aI, type SetupStatusChanged as aJ, type SignatureImage as aK, type StoredBankDetails as aL, type SubscriptionChanged as aM, type SubscriptionStatus as aN, type Title as aO, type TvLicenceProduct as aP, type Url as aQ, type WaterProduct as aR, type WebhookEvent as aS, type WebhookEventBase as aT, type WebhookEventId as aU, type WebhookEventType as aV, type MoveOutReason as aa, type MoveOutStatus as ab, type NearbyPoi as ac, type OccupantObject as ad, type OccupantType as ae, type OnboardingInfo as af, type OverallStatus as ag, type Paginated as ah, type Person as ai, type PhoneNumber as aj, type Postcode as ak, type Product as al, type ProductBase as am, type ProductCategory as an, type ProductConfidence as ao, type ProductId as ap, type ProductSetup as aq, type PropertyDetailObject as ar, type PropertyLocation as as, type PropertyObject as at, type PropertyType as au, type PropertyTypeCode as av, type PropertyTypeSubcode as aw, type ProvidedFieldPath as ax, SESSION_IDEMPOTENCY_TTL_MS as ay, type SavingsSummaryResponse as az, type SessionGetResponse as b, type ProductsResponse as c, type PropertyDetailResponse as d, type CustomerCreateResponse as e, type CustomerId as f, type CustomerStatusResponse as g, type BankDetailsResponse as h, type AddressObject as i, type AddressesObject as j, type ApiVersion as k, type AppDeeplinks as l, type BankDetailsCollected as m, type BankDetailsConsent as n, type BankDetailsObject as o, type BankDetailsStatus as p, type BillType as q, type BreakdownCoverProduct as r, type BroadbandProduct as s, type BuildingStyle as t, type BuildingType as u, type CacheStatus as v, type ClientMode as w, type Consent as x, type ContextEntry as y, type CouncilTaxProduct as z };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hello-bill/node",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.2.0-beta.0",
|
|
4
4
|
"description": "Server-side SDK for the HelloBill Partner API. Framework-agnostic core with an Express adapter; ships a webhook verifier and the spec-derived TypeScript types.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|