Class WorldFactory

Summary

Create an instance of SDKController class with credentials.

Usage

const credentials = {
assetId: "exampleAsset",
interactiveNonce: "exampleNonce"
interactivePublicKey: "examplePublicKey",
visitorId: 1,
url: "https://topia.io",
}
const topia = await new Topia({
apiDomain: "api.topia.io",
apiKey: "exampleKey",
interactiveKey: "key",
interactiveSecret: "secret",
}
await new SDKController({ credentials, topia });

Hierarchy

Constructors

Properties

credentials: undefined | InteractiveCredentials
jwt?: string
requestOptions: object
topia: Topia

Methods

  • Parameters

    • urlSlug: string
    • droppedAssetIds: string[]
    • credentials: {
          apiKey?: string;
          interactivePublicKey?: string;
          interactiveSecret?: string;
      }
      • Optional apiKey?: string
      • Optional interactivePublicKey?: string
      • Optional interactiveSecret?: string

    Returns Promise<{
        success: boolean;
    }>

  • Parameters

    • __namedParameters: {
          error?: unknown;
          message?: string;
          params?: object;
          sdkMethod?: string;
      }
      • Optional error?: unknown
      • Optional message?: string
      • Optional params?: object
      • Optional sdkMethod?: string

    Returns {
        data: {};
        message: string;
        method: string;
        params: object;
        sdkMethod: undefined | string;
        stack: string;
        stackTrace: Error;
        status: number;
        success: boolean;
        url: string;
    }

    • data: {}
      • message: string
      • method: string
      • params: object
      • sdkMethod: undefined | string
      • stack: string
      • stackTrace: Error
      • status: number
      • success: boolean
      • url: string
    • Returns AxiosInstance