Preparing search index...

    Configuration for request through "LensStudio:RemoteServiceModule".performApiRequest

        // RemoteApiRequest is the configuration object for performApiRequest().
    // It has a protected constructor — create instances via the static create() method.
    //
    // Properties:
    // body: string — request body content
    // endpoint: string — the API endpoint path
    // parameters: any — key-value parameters for the request
    // specId: string — identifier for the registered Snap service spec
    //
    // Static method:
    // RemoteApiRequest.create(): RemoteApiRequest

    const { RemoteApiRequest } = await import('LensStudio:RemoteServiceModule');

    const request = RemoteApiRequest.create();
    console.log('Created RemoteApiRequest via RemoteApiRequest.create().');

    request.endpoint = '/v1/my-service';
    console.log('endpoint set to:', request.endpoint);

    request.specId = 'my-spec-id';
    console.log('specId set to:', request.specId);

    request.parameters = { query: 'hello', limit: 10 };
    console.log('parameters set to:', JSON.stringify(request.parameters));

    request.body = '{"data":"payload"}';
    console.log('body set to:', request.body);
    Index

    Constructors

    Properties

    Methods

    Constructors

    Properties

    body: string | Uint8Array

    The body of the request.

    endpoint: string

    The endpoint of the request (e.g. API path).

    parameters: any

    Request parameters as key-value pairs.

    specId: string

    The spec id of the RemoteServiceModule.

    Methods