import { Transaction } from './transaction';
import { SnapTransaction } from 'types/transaction';
import { Parameter } from 'types/parameter';
import { MidtransError } from './midtransError';
/**
 * Snap object used to do request to Midtrans Snap API
 */
export declare class Snap {
    private apiConfig;
    private httpClient;
    private transaction;
    constructor(options?: {
        isProduction?: boolean;
        serverKey: string;
        clientKey: string;
    });
    /**
     * Do `/transactions` API request to Snap API
     * @param  {Object} parameter - object of Core API JSON body as parameter, will be converted to JSON
     * @return {Promise<Object>} - Promise contains Object from JSON decoded response
     */
    createTransaction(parameter: Parameter): Promise<SnapTransaction | MidtransError>;
    /**
     * Wrapper function that call `createTransaction` then:
     * @return {Promise<string>} - Promise of String token
     */
    createTransactionToken(parameter: Parameter): Promise<string>;
    /**
     * Wrapper function that call `createTransaction` then:
     * @return {Promise<string>} - Promise of String redirect_url
     */
    createTransactionRedirectUrl(parameter: Parameter): Promise<string>;
    getTransaction(): Transaction;
}
