npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@juspay-tech/capacitor-hyperswitch

v1.0.0-alpha.1

Published

Hyperswitch SDK bindings for Capacitor Applications

Readme

capacitor-hyperswitch

Hyperswitch SDK bindings for Capacitor Applications

Install

To use npm

npm install capacitor-hyperswitch

To use yarn

yarn add capacitor-hyperswitch

Sync native files

npx cap sync

API

init(...)

init(config: HyperConfig) => Promise<void>

| Param | Type | | ------------ | --------------------------------------------------- | | config | HyperConfig |


elements(...)

elements(options: { elementsOptions: JSONValue; }) => Promise<{ handlerId: string; }>

| Param | Type | | ------------- | --------------------------------------------------------------------- | | options | { elementsOptions: JSONValue; } |

Returns: Promise<{ handlerId: string; }>


createElement(...)

createElement(options: { type: string; createOptions: JSONValue; }) => Promise<void>

| Param | Type | | ------------- | --------------------------------------------------------------------------------- | | options | { type: string; createOptions: JSONValue; } |


updateIntent(...)

updateIntent(options: { sdkAuthorization: string; }) => Promise<UpdateIntentResult>

| Param | Type | | ------------- | ------------------------------------------ | | options | { sdkAuthorization: string; } |

Returns: Promise<UpdateIntentResult>


getCustomerSavedPaymentMethods()

getCustomerSavedPaymentMethods() => Promise<{ handlerId: string; }>

Returns: Promise<{ handlerId: string; }>


getCustomerSavedPaymentMethodData(...)

getCustomerSavedPaymentMethodData(options: { handlerId: string; }) => Promise<JSONValue>

| Param | Type | | ------------- | ----------------------------------- | | options | { handlerId: string; } |

Returns: Promise<JSONValue>


getCustomerDefaultSavedPaymentMethodData(...)

getCustomerDefaultSavedPaymentMethodData(options: { handlerId: string; }) => Promise<JSONValue>

| Param | Type | | ------------- | ----------------------------------- | | options | { handlerId: string; } |

Returns: Promise<JSONValue>


getCustomerLastUsedPaymentMethodData(...)

getCustomerLastUsedPaymentMethodData(options: { handlerId: string; }) => Promise<JSONValue>

| Param | Type | | ------------- | ----------------------------------- | | options | { handlerId: string; } |

Returns: Promise<JSONValue>


confirmWithCustomerDefaultPaymentMethod(...)

confirmWithCustomerDefaultPaymentMethod(options: { handlerId: string; }) => Promise<PaymentResult>

| Param | Type | | ------------- | ----------------------------------- | | options | { handlerId: string; } |

Returns: Promise<PaymentResult>


confirmWithCustomerLastUsedPaymentMethod(...)

confirmWithCustomerLastUsedPaymentMethod(options: { handlerId: string; }) => Promise<PaymentResult>

| Param | Type | | ------------- | ----------------------------------- | | options | { handlerId: string; } |

Returns: Promise<PaymentResult>


confirmPayment(...)

confirmPayment(options: { confirmParams: JSONValue; }) => Promise<PaymentResult>

| Param | Type | | ------------- | ------------------------------------------------------------------- | | options | { confirmParams: JSONValue; } |

Returns: Promise<PaymentResult>


initPaymentSession(...)

initPaymentSession(options: { paymentSessionOptions: JSONValue; }) => Promise<void>

| Param | Type | | ------------- | --------------------------------------------------------------------------- | | options | { paymentSessionOptions: JSONValue; } |


presentPaymentSheet(...)

presentPaymentSheet(options: { sheetOptions: JSONValue; }) => Promise<PaymentResult>

| Param | Type | | ------------- | ------------------------------------------------------------------ | | options | { sheetOptions: JSONValue; } |

Returns: Promise<PaymentResult>


elementOn(...)

elementOn(options: { event: string; }) => Promise<void>

| Param | Type | | ------------- | ------------------------------- | | options | { event: string; } |


elementCollapse()

elementCollapse() => Promise<void>

elementBlur()

elementBlur() => Promise<void>

elementUpdate(...)

elementUpdate(options: { updateOptions: JSONValue; }) => Promise<void>

| Param | Type | | ------------- | ------------------------------------------------------------------- | | options | { updateOptions: JSONValue; } |


elementDestroy()

elementDestroy() => Promise<void>

elementUnmount()

elementUnmount() => Promise<void>

elementMount(...)

elementMount(options: { selector: string; }) => Promise<void>

| Param | Type | | ------------- | ---------------------------------- | | options | { selector: string; } |


elementFocus()

elementFocus() => Promise<void>

elementClear()

elementClear() => Promise<void>

addListener('paymentEvent', ...)

addListener(event: 'paymentEvent', handler: (data: PaymentEventData) => void) => Promise<{ remove: () => Promise<void>; }>

Subscribe to native widget events emitted by PaymentElement or CvcWidget. The handler receives a PaymentEventData object with type and payload.

Use element.on(eventType, handler) in the JS wrapper layer instead of calling this directly.

| Param | Type | | ------------- | -------------------------------------------------------------------------------- | | event | 'paymentEvent' | | handler | (data: PaymentEventData) => void |

Returns: Promise<{ remove: () => Promise<void>; }>


Interfaces

HyperConfig

| Prop | Type | | ---------------------------- | ----------------------------------------------------- | | publishableKey | string | | profileId | string | | platformPublishableKey | string | | customConfig | CustomConfig |

CustomConfig

| Prop | Type | | ----------------------------- | ------------------- | | customEndpoint | string | | customBackendEndpoint | string | | customLoggingEndpoint | string | | customAssetEndpoint | string | | customSDKConfigEndpoint | string | | customAirborneEndpoint | string |

UpdateIntentResult

| Prop | Type | Description | | -------------------- | ------------------- | ----------------------------------------------- | | type | string | "success" | "totalFailure" | "partialFailure" | | message | string | | | failedCount | number | | | succeededCount | number | |

PaymentResult

| Prop | Type | | ------------- | -------------------------------------------------- | | type | 'completed' | 'canceled' | 'failed' | | message | string |

PaymentEventData

Native event emitted by PaymentElement or CvcWidget.

type values: PaymentElement: "FORM_STATUS" | "PAYMENT_METHOD_STATUS" | "PAYMENT_METHOD_INFO_CARD" | "PAYMENT_METHOD_INFO_BILLING_ADDRESS" CvcWidget: "CVC_STATUS"

payload is the raw key/value data from the SDK (values serialised to strings on Android).

| Prop | Type | | ------------- | --------------------------------------------------------------- | | type | string | | payload | Record<string, string> |

Type Aliases

JSONValue

Record<string, unknown>

Record

Construct a type with a set of properties K of type T

{ [P in K]: T; }