@hello-bill/node 2.1.1-beta.6 → 2.1.1

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.
Files changed (40) hide show
  1. package/CHANGELOG.md +21 -24
  2. package/dist/express/index.d.cts +2 -2
  3. package/dist/express/index.d.ts +2 -2
  4. package/dist/express/index.js +1 -20
  5. package/dist/express/index.js.map +1 -1
  6. package/dist/express/index.mjs +1 -20
  7. package/dist/express/index.mjs.map +1 -1
  8. package/dist/hono/index.d.cts +2 -2
  9. package/dist/hono/index.d.ts +2 -2
  10. package/dist/hono/index.js +1 -20
  11. package/dist/hono/index.js.map +1 -1
  12. package/dist/hono/index.mjs +1 -20
  13. package/dist/hono/index.mjs.map +1 -1
  14. package/dist/{index-BAETgMms.d.ts → index-D5WlUYVZ.d.cts} +1 -7
  15. package/dist/{index-9PkSdjVq.d.cts → index-jK9cEnEY.d.ts} +1 -7
  16. package/dist/index.d.cts +4 -4
  17. package/dist/index.d.ts +4 -4
  18. package/dist/index.js +1 -17
  19. package/dist/index.js.map +1 -1
  20. package/dist/index.mjs +1 -17
  21. package/dist/index.mjs.map +1 -1
  22. package/dist/koa/index.d.cts +2 -2
  23. package/dist/koa/index.d.ts +2 -2
  24. package/dist/koa/index.js +1 -20
  25. package/dist/koa/index.js.map +1 -1
  26. package/dist/koa/index.mjs +1 -20
  27. package/dist/koa/index.mjs.map +1 -1
  28. package/dist/next/index.d.cts +2 -2
  29. package/dist/next/index.d.ts +2 -2
  30. package/dist/next/index.js +1 -23
  31. package/dist/next/index.js.map +1 -1
  32. package/dist/next/index.mjs +1 -23
  33. package/dist/next/index.mjs.map +1 -1
  34. package/dist/types/index.d.cts +2 -2
  35. package/dist/types/index.d.ts +2 -2
  36. package/dist/webhook/index.d.cts +2 -2
  37. package/dist/webhook/index.d.ts +2 -2
  38. package/dist/{webhooks-Cv4e8oXp.d.cts → webhooks-DePW-Bjp.d.cts} +16 -1
  39. package/dist/{webhooks-Cv4e8oXp.d.ts → webhooks-DePW-Bjp.d.ts} +16 -1
  40. package/package.json +1 -1
@@ -1,4 +1,4 @@
1
- import { aO as WebhookEvent, aC as SessionEmbedOpened, aB as SessionDetailsConfirmed, aE as SessionProductsSelected, aD as SessionLoaSigned, ay as SessionAccountCreated, aA as SessionAppInstalled, az as SessionAppDeferred, aJ as SubscriptionChanged, aG as SetupStatusChanged, a5 as MoveOutNotificationSent, a4 as MoveOutNotificationFailed, m as BankDetailsCollected, S as SessionPayload } from './webhooks-Cv4e8oXp.js';
1
+ import { aR as WebhookEvent, aE as SessionEmbedOpened, aD as SessionDetailsConfirmed, aG as SessionProductsSelected, aF as SessionLoaSigned, aA as SessionAccountCreated, aC as SessionAppInstalled, aB as SessionAppDeferred, aL as SubscriptionChanged, aI as SetupStatusChanged, a7 as MoveOutNotificationSent, a6 as MoveOutNotificationFailed, m as BankDetailsCollected, S as SessionPayload } from './webhooks-DePW-Bjp.cjs';
2
2
 
3
3
  interface TokenStorage {
4
4
  get(clientId: string): Promise<{
@@ -340,12 +340,6 @@ interface HellobillHandlerSet {
340
340
  * Scoped to the partner's access_token — no session_token required.
341
341
  */
342
342
  serviceSlots: (req: HellobillRequest, res: HellobillResponse) => Promise<void>;
343
- /**
344
- * Proxies GET /partner/loa/:id/document.
345
- * Reads the loa id from req.query.loa_id or req.params.id.
346
- * Scoped to the partner's access_token — no session_token required.
347
- */
348
- loaDocument: (req: HellobillRequest, res: HellobillResponse) => Promise<void>;
349
343
  /**
350
344
  * Optional webhook receiver. Present only when `opts.webhook` is supplied to
351
345
  * `createHellobillHandler`. The Express adapter mounts POST /webhooks when
@@ -1,4 +1,4 @@
1
- import { aO as WebhookEvent, aC as SessionEmbedOpened, aB as SessionDetailsConfirmed, aE as SessionProductsSelected, aD as SessionLoaSigned, ay as SessionAccountCreated, aA as SessionAppInstalled, az as SessionAppDeferred, aJ as SubscriptionChanged, aG as SetupStatusChanged, a5 as MoveOutNotificationSent, a4 as MoveOutNotificationFailed, m as BankDetailsCollected, S as SessionPayload } from './webhooks-Cv4e8oXp.cjs';
1
+ import { aR as WebhookEvent, aE as SessionEmbedOpened, aD as SessionDetailsConfirmed, aG as SessionProductsSelected, aF as SessionLoaSigned, aA as SessionAccountCreated, aC as SessionAppInstalled, aB as SessionAppDeferred, aL as SubscriptionChanged, aI as SetupStatusChanged, a7 as MoveOutNotificationSent, a6 as MoveOutNotificationFailed, m as BankDetailsCollected, S as SessionPayload } from './webhooks-DePW-Bjp.js';
2
2
 
3
3
  interface TokenStorage {
4
4
  get(clientId: string): Promise<{
@@ -340,12 +340,6 @@ interface HellobillHandlerSet {
340
340
  * Scoped to the partner's access_token — no session_token required.
341
341
  */
342
342
  serviceSlots: (req: HellobillRequest, res: HellobillResponse) => Promise<void>;
343
- /**
344
- * Proxies GET /partner/loa/:id/document.
345
- * Reads the loa id from req.query.loa_id or req.params.id.
346
- * Scoped to the partner's access_token — no session_token required.
347
- */
348
- loaDocument: (req: HellobillRequest, res: HellobillResponse) => Promise<void>;
349
343
  /**
350
344
  * Optional webhook receiver. Present only when `opts.webhook` is supplied to
351
345
  * `createHellobillHandler`. The Express adapter mounts POST /webhooks when
package/dist/index.d.cts CHANGED
@@ -1,7 +1,7 @@
1
- import { T as TokenStorage, L as Logger } from './index-9PkSdjVq.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-9PkSdjVq.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-Cv4e8oXp.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 Customer, E as CustomerType, F as DataCompleteness, G as DiscoveryStatus, H as Email, I as EnergyProduct, J as Environment, K as EpcRating, M as FinalRead, N as FuelType, O as HeatingType, Q as HomeInsuranceProduct, T as IdempotencyKey, U as IsoDate, V as IsoDateTime, W as LoASignature, X as LoaId, Y as LoaRecord, Z as LocationRole, _ as MaskedSortCode, $ as Meters, a0 as MobileProduct, a1 as MoveIn, a2 as MoveObject, a3 as MoveOut, a4 as MoveOutNotificationFailed, a5 as MoveOutNotificationSent, a6 as MoveOutNotifyFlags, a7 as MoveOutReason, a8 as MoveOutStatus, a9 as NearbyPoi, aa as OccupantObject, ab as OccupantType, ac as OnboardingInfo, ad as OverallStatus, ae as Paginated, af as Person, ag as PhoneNumber, ah as Postcode, ai as Product, aj as ProductBase, ak as ProductCategory, al as ProductConfidence, am as ProductId, an as ProductSetup, ao as PropertyDetailObject, ap as PropertyLocation, aq as PropertyObject, ar as PropertyType, as as PropertyTypeCode, at as PropertyTypeSubcode, au as ProvidedFieldPath, av as SESSION_IDEMPOTENCY_TTL_MS, aw as SavingsSummaryResponse, ax as SelectedProduct, ay as SessionAccountCreated, az as SessionAppDeferred, aA as SessionAppInstalled, aB as SessionDetailsConfirmed, aC as SessionEmbedOpened, aD as SessionLoaSigned, aE as SessionProductsSelected, aF as SetupStatus, aG as SetupStatusChanged, aH as SignatureImage, aI as StoredBankDetails, aJ as SubscriptionChanged, aK as SubscriptionStatus, aL as TvLicenceProduct, aM as Url, aN as WaterProduct, aO as WebhookEvent, aP as WebhookEventBase, aQ as WebhookEventId, aR as WebhookEventType } from './webhooks-Cv4e8oXp.cjs';
1
+ import { T as TokenStorage, L as Logger } from './index-D5WlUYVZ.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-D5WlUYVZ.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-DePW-Bjp.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 FinalRead, Q as FuelType, T as HeatingType, U as HomeInsuranceProduct, V as IdempotencyKey, W as IsoDate, X as IsoDateTime, Y as LoASignature, Z as LoaId, _ as LoaRecord, $ as LocationRole, a0 as MaskedSortCode, a1 as Meters, a2 as MobileProduct, a3 as MoveIn, a4 as MoveObject, a5 as MoveOut, a6 as MoveOutNotificationFailed, a7 as MoveOutNotificationSent, a8 as MoveOutNotifyFlags, a9 as MoveOutReason, aa as MoveOutStatus, ab as NearbyPoi, ac as OccupantObject, ad as OccupantType, ae as OnboardingInfo, af as OverallStatus, ag as Paginated, ah as Person, ai as PhoneNumber, aj as Postcode, ak as Product, al as ProductBase, am as ProductCategory, an as ProductConfidence, ao as ProductId, ap as ProductSetup, aq as PropertyDetailObject, ar as PropertyLocation, as as PropertyObject, at as PropertyType, au as PropertyTypeCode, av as PropertyTypeSubcode, aw as ProvidedFieldPath, ax as SESSION_IDEMPOTENCY_TTL_MS, ay as SavingsSummaryResponse, az as SelectedProduct, aA as SessionAccountCreated, aB as SessionAppDeferred, aC as SessionAppInstalled, aD as SessionDetailsConfirmed, aE as SessionEmbedOpened, aF as SessionLoaSigned, aG as SessionProductsSelected, aH as SetupStatus, aI as SetupStatusChanged, aJ as SignatureImage, aK as StoredBankDetails, aL as SubscriptionChanged, aM as SubscriptionStatus, aN as Title, aO as TvLicenceProduct, aP as Url, aQ as WaterProduct, aR as WebhookEvent, aS as WebhookEventBase, aT as WebhookEventId, aU as WebhookEventType } from './webhooks-DePW-Bjp.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-BAETgMms.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-BAETgMms.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-Cv4e8oXp.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 Customer, E as CustomerType, F as DataCompleteness, G as DiscoveryStatus, H as Email, I as EnergyProduct, J as Environment, K as EpcRating, M as FinalRead, N as FuelType, O as HeatingType, Q as HomeInsuranceProduct, T as IdempotencyKey, U as IsoDate, V as IsoDateTime, W as LoASignature, X as LoaId, Y as LoaRecord, Z as LocationRole, _ as MaskedSortCode, $ as Meters, a0 as MobileProduct, a1 as MoveIn, a2 as MoveObject, a3 as MoveOut, a4 as MoveOutNotificationFailed, a5 as MoveOutNotificationSent, a6 as MoveOutNotifyFlags, a7 as MoveOutReason, a8 as MoveOutStatus, a9 as NearbyPoi, aa as OccupantObject, ab as OccupantType, ac as OnboardingInfo, ad as OverallStatus, ae as Paginated, af as Person, ag as PhoneNumber, ah as Postcode, ai as Product, aj as ProductBase, ak as ProductCategory, al as ProductConfidence, am as ProductId, an as ProductSetup, ao as PropertyDetailObject, ap as PropertyLocation, aq as PropertyObject, ar as PropertyType, as as PropertyTypeCode, at as PropertyTypeSubcode, au as ProvidedFieldPath, av as SESSION_IDEMPOTENCY_TTL_MS, aw as SavingsSummaryResponse, ax as SelectedProduct, ay as SessionAccountCreated, az as SessionAppDeferred, aA as SessionAppInstalled, aB as SessionDetailsConfirmed, aC as SessionEmbedOpened, aD as SessionLoaSigned, aE as SessionProductsSelected, aF as SetupStatus, aG as SetupStatusChanged, aH as SignatureImage, aI as StoredBankDetails, aJ as SubscriptionChanged, aK as SubscriptionStatus, aL as TvLicenceProduct, aM as Url, aN as WaterProduct, aO as WebhookEvent, aP as WebhookEventBase, aQ as WebhookEventId, aR as WebhookEventType } from './webhooks-Cv4e8oXp.js';
1
+ import { T as TokenStorage, L as Logger } from './index-jK9cEnEY.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-jK9cEnEY.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-DePW-Bjp.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 FinalRead, Q as FuelType, T as HeatingType, U as HomeInsuranceProduct, V as IdempotencyKey, W as IsoDate, X as IsoDateTime, Y as LoASignature, Z as LoaId, _ as LoaRecord, $ as LocationRole, a0 as MaskedSortCode, a1 as Meters, a2 as MobileProduct, a3 as MoveIn, a4 as MoveObject, a5 as MoveOut, a6 as MoveOutNotificationFailed, a7 as MoveOutNotificationSent, a8 as MoveOutNotifyFlags, a9 as MoveOutReason, aa as MoveOutStatus, ab as NearbyPoi, ac as OccupantObject, ad as OccupantType, ae as OnboardingInfo, af as OverallStatus, ag as Paginated, ah as Person, ai as PhoneNumber, aj as Postcode, ak as Product, al as ProductBase, am as ProductCategory, an as ProductConfidence, ao as ProductId, ap as ProductSetup, aq as PropertyDetailObject, ar as PropertyLocation, as as PropertyObject, at as PropertyType, au as PropertyTypeCode, av as PropertyTypeSubcode, aw as ProvidedFieldPath, ax as SESSION_IDEMPOTENCY_TTL_MS, ay as SavingsSummaryResponse, az as SelectedProduct, aA as SessionAccountCreated, aB as SessionAppDeferred, aC as SessionAppInstalled, aD as SessionDetailsConfirmed, aE as SessionEmbedOpened, aF as SessionLoaSigned, aG as SessionProductsSelected, aH as SetupStatus, aI as SetupStatusChanged, aJ as SignatureImage, aK as StoredBankDetails, aL as SubscriptionChanged, aM as SubscriptionStatus, aN as Title, aO as TvLicenceProduct, aP as Url, aQ as WaterProduct, aR as WebhookEvent, aS as WebhookEventBase, aT as WebhookEventId, aU as WebhookEventType } from './webhooks-DePW-Bjp.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/index.js CHANGED
@@ -972,21 +972,6 @@ function createHellobillHandler(opts) {
972
972
  if (!result2) return;
973
973
  passthroughUpstream(res, result2.status, result2.body, result2.requestId, result2.headers);
974
974
  };
975
- const loaDocument = async (req, res) => {
976
- const rawLoa = req.query.loa_id ?? req.params?.id;
977
- const loaId = Array.isArray(rawLoa) ? rawLoa[0] : rawLoa;
978
- if (!loaId) {
979
- sendError(res, 400, "validation.missing_required_field", "loa_id query parameter required");
980
- return;
981
- }
982
- const result2 = await safeCallUpstream(res, {
983
- method: "GET",
984
- path: `/partner/loa/${encodeURIComponent(loaId)}/document`,
985
- logger
986
- });
987
- if (!result2) return;
988
- passthroughUpstream(res, result2.status, result2.body, result2.requestId, result2.headers);
989
- };
990
975
  const webhookHandler = opts.webhook ? createWebhookHandler({ ...opts.webhook, logger: opts.webhook.logger ?? opts.logger }) : void 0;
991
976
  const result = {
992
977
  session,
@@ -998,8 +983,7 @@ function createHellobillHandler(opts) {
998
983
  property,
999
984
  sessions: { list: sessionsList, get: sessionsGet },
1000
985
  savingsSummary,
1001
- serviceSlots,
1002
- loaDocument
986
+ serviceSlots
1003
987
  };
1004
988
  if (webhookHandler !== void 0) {
1005
989
  result.webhook = webhookHandler;