interface WasmExtension {
    wasm: {
        getAllContractState: ((address, paginationKey?) => Promise<QueryAllContractStateResponse>);
        getCode: ((id) => Promise<QueryCodeResponse>);
        getContractCodeHistory: ((address, paginationKey?) => Promise<QueryContractHistoryResponse>);
        getContractInfo: ((address) => Promise<QueryContractInfoResponse>);
        listCodeInfo: ((paginationKey?) => Promise<QueryCodesResponse>);
        listContractsByCodeId: ((id, paginationKey?) => Promise<QueryContractsByCodeResponse>);
        listContractsByCreator: ((creator, paginationKey?) => Promise<QueryContractsByCreatorResponse>);
        queryContractRaw: ((address, key) => Promise<QueryRawContractStateResponse>);
        queryContractSmart: ((address, query) => Promise<any>);
    };
}

Properties

Properties

wasm: {
    getAllContractState: ((address, paginationKey?) => Promise<QueryAllContractStateResponse>);
    getCode: ((id) => Promise<QueryCodeResponse>);
    getContractCodeHistory: ((address, paginationKey?) => Promise<QueryContractHistoryResponse>);
    getContractInfo: ((address) => Promise<QueryContractInfoResponse>);
    listCodeInfo: ((paginationKey?) => Promise<QueryCodesResponse>);
    listContractsByCodeId: ((id, paginationKey?) => Promise<QueryContractsByCodeResponse>);
    listContractsByCreator: ((creator, paginationKey?) => Promise<QueryContractsByCreatorResponse>);
    queryContractRaw: ((address, key) => Promise<QueryRawContractStateResponse>);
    queryContractSmart: ((address, query) => Promise<any>);
}

Type declaration

  • Readonly getAllContractState: ((address, paginationKey?) => Promise<QueryAllContractStateResponse>)

    Returns all contract state. This is an empty array if no such contract, or contract has no data.

      • (address, paginationKey?): Promise<QueryAllContractStateResponse>
      • Returns all contract state. This is an empty array if no such contract, or contract has no data.

        Parameters

        • address: string
        • Optional paginationKey: Uint8Array

        Returns Promise<QueryAllContractStateResponse>

  • Readonly getCode: ((id) => Promise<QueryCodeResponse>)

    Downloads the original wasm bytecode by code ID.

    Throws an error if no code with this id

      • (id): Promise<QueryCodeResponse>
      • Downloads the original wasm bytecode by code ID.

        Throws an error if no code with this id

        Parameters

        • id: number

        Returns Promise<QueryCodeResponse>

  • Readonly getContractCodeHistory: ((address, paginationKey?) => Promise<QueryContractHistoryResponse>)

    Returns null when contract history was not found for this address.

      • (address, paginationKey?): Promise<QueryContractHistoryResponse>
      • Returns null when contract history was not found for this address.

        Parameters

        • address: string
        • Optional paginationKey: Uint8Array

        Returns Promise<QueryContractHistoryResponse>

  • Readonly getContractInfo: ((address) => Promise<QueryContractInfoResponse>)

    Returns null when contract was not found at this address.

      • (address): Promise<QueryContractInfoResponse>
      • Returns null when contract was not found at this address.

        Parameters

        • address: string

        Returns Promise<QueryContractInfoResponse>

  • Readonly listCodeInfo: ((paginationKey?) => Promise<QueryCodesResponse>)
      • (paginationKey?): Promise<QueryCodesResponse>
      • Parameters

        • Optional paginationKey: Uint8Array

        Returns Promise<QueryCodesResponse>

  • Readonly listContractsByCodeId: ((id, paginationKey?) => Promise<QueryContractsByCodeResponse>)
      • (id, paginationKey?): Promise<QueryContractsByCodeResponse>
      • Parameters

        • id: number
        • Optional paginationKey: Uint8Array

        Returns Promise<QueryContractsByCodeResponse>

  • Readonly listContractsByCreator: ((creator, paginationKey?) => Promise<QueryContractsByCreatorResponse>)

    Returns a list of contract addresses created by the given creator.

      • (creator, paginationKey?): Promise<QueryContractsByCreatorResponse>
      • Returns a list of contract addresses created by the given creator.

        Parameters

        • creator: string
        • Optional paginationKey: Uint8Array

        Returns Promise<QueryContractsByCreatorResponse>

  • Readonly queryContractRaw: ((address, key) => Promise<QueryRawContractStateResponse>)

    Returns the data at the key if present (unknown decoded json), or null if no data at this (contract address, key) pair

      • (address, key): Promise<QueryRawContractStateResponse>
      • Returns the data at the key if present (unknown decoded json), or null if no data at this (contract address, key) pair

        Parameters

        • address: string
        • key: Uint8Array

        Returns Promise<QueryRawContractStateResponse>

  • Readonly queryContractSmart: ((address, query) => Promise<any>)

    Makes a smart query on the contract and parses the response as JSON. Throws error if no such contract exists, the query format is invalid or the response is invalid.

      • (address, query): Promise<any>
      • Makes a smart query on the contract and parses the response as JSON. Throws error if no such contract exists, the query format is invalid or the response is invalid.

        Parameters

        • address: string
        • query: any

        Returns Promise<any>

Generated using TypeDoc