@adyen/kyc-components
Version:
`adyen-kyc-components` provides the required pieces to build an onboarding flow based on a legal entity. To onboard and verify users, you need to create a user interface (UI) to collect user data. To speed up building your integration, Adyen offers onboar
15 lines (14 loc) • 974 B
TypeScript
import type { UseQueryResult } from '@tanstack/react-query';
import type { ExistingLegalEntity } from '../core/models/api/legal-entity';
import type { LegalEntityAssociationType } from '../core/models/api/legal-entity-association';
type UseAssociatedLegalEntity = Pick<UseQueryResult<ExistingLegalEntity>, 'data' | 'refetch' | 'isLoading'>;
/**
* Fetches and returns an entity of the given type which is associated to the given root legal entity.
* Also returns a callback that can be used to refetch the associated entity.
*
* @param parentLegalEntity the parent legal entity to find an associated entity for
* @param associationType the type of associated entity to fetch.
* If multiple types are provided, the first matching association is used.
*/
export declare function useAssociatedLegalEntity(parentLegalEntity: ExistingLegalEntity | undefined, associationType: LegalEntityAssociationType | LegalEntityAssociationType[]): UseAssociatedLegalEntity;
export {};