import { IConnection, IProductInfo } from './Connection'; import { RawSignedModel } from '../Cards/RawSignedModel'; /** * @hidden */ export interface ICardResult { readonly cardRaw: RawSignedModel; readonly isOutdated: boolean; } /** * Class responsible for sending requests to the Virgil Cards Service. * * @hidden */ export declare class CardClient { private readonly connection; /** * Initializes new instance of `CardClient`. * @param {IConnection | string} connection - Object implementing the * {@link IConnection} interface. */ constructor(connection?: IConnection | string, productInfo?: IProductInfo); /** * Issues a request to search cards by the `identity`. * @param {string[]} identities - Array of identities to search for. * @param {string} accessToken - A token to authenticate the request. * @returns {Promise} */ searchCards(identities: string[], accessToken: string): Promise; /** * Issues a request to get the card by id. * @param {string} cardId - Id of the card to fetch. * @param {string} accessToken - A token to authenticate the request. * @returns {Promise} */ getCard(cardId: string, accessToken: string): Promise; /** * Issues a request to publish the card. * @param {RawSignedModel} model - Card to publish. * @param {string} accessToken - A token to authenticate the request. * @returns {Promise} */ publishCard(model: RawSignedModel, accessToken: string): Promise; revokeCard(cardId: string, accessToken: string): Promise; }