@ptkl/sdk - v1.3.4
    Preparing search index...

    Base client for the platform API Classes that extend PlatformBaseClient have intentins of only working in platform context

    PlatformBaseClient

    The axios instance to use for the client

    // if sdk is used in the forge app that is running in the platform context
    const utils = new ComponentUtils()
    // this won't work outside of platform context because client needs authtorization to communicate with the API.

    Hierarchy (View Summary)

    Index

    Constructors

    • Parameters

      • Optionaloptions: { env?: string; host?: string; token?: string }

      Returns default

    Properties

    client: AxiosInstance
    env: null | string = null
    host: null | string = null
    token: null | string = null

    Methods

    • Parameters

      • ref: string
      • env: string

      Returns Promise<AxiosResponse<any, any>>

    • Parameters

      • ref: string

      Returns Promise<any>

    • Returns Promise<any>

    • Run platform function

      Parameters

      • id: string

        Function ID

      • d: {
            headers?: Record<string, string>;
            input?: Record<string, any>;
            query?: Record<string, string>;
        }

        Object containing input data, query parameters, and headers

      Returns Promise<any>

      • Function result
      const result = await platform.function().run("myFunction", {input: { foo: "bar" }})
      
    • Parameters

      • client: AxiosInstance

      Returns default

    • Parameters

      • uuid: string
      • update: any

      Returns Promise<any>