Class ContractAppURI<TContract>

Have an official Application URI for this contract.

Remarks

Configure an official Application URI for this contract.

Example

const contract = await sdk.getContract("{{contract_address}}");
const appURI = await contract.app.get();
appURI = "ipfs://some_ipfs_hash";

await contract.app.set(appURI)

Type Parameters

  • TContract extends BaseContract

Hierarchy

  • ContractAppURI

Implements

  • DetectableFeature

Constructors

Properties

contractWrapper: ContractWrapper<TContract>
featureName: "AppURI" = FEATURE_APPURI.name
metadata: ContractMetadata<BaseContract, any>
set: {
    prepare: ((...args) => Promise<Transaction<Omit<TransactionResultWithMetadata<unknown>, "data">>>);
    (...args): Promise<TResult>;
} = ...

Type declaration

    • (...args): Promise<TResult>
    • Set App URI

      Parameters

      • Rest ...args: [appURI: string]

      Returns Promise<TResult>

      Example

      const appURI = "ipfs://some_ipfs_hash";
      await contract.app.set(appURI);

      Twfeature

      AppURI

  • prepare: ((...args) => Promise<Transaction<Omit<TransactionResultWithMetadata<unknown>, "data">>>)
      • (...args): Promise<Transaction<Omit<TransactionResultWithMetadata<unknown>, "data">>>
      • Parameters

        • Rest ...args: [appURI: string]

        Returns Promise<Transaction<Omit<TransactionResultWithMetadata<unknown>, "data">>>

storage: ThirdwebStorage<IpfsUploadBatchOptions>

Methods

  • Get App URI

    Returns Promise<string>

    the appURI (typically an IPFS hash)

    Example

    const appURI = await contract.app.get();
    console.log(appURI) // "ipfs://some_ipfs_hash";

    Twfeature

    AppURI

Generated using TypeDoc