@zenginehq/backend-get-service-url

1.0.1 • Public • Published

zn-backend-get-service-url

Helper module for getting the absolute base URL to the backend service endpoint. Includes the workspace id context where the plugin is currently running. Does not include query params or any additional path that the service may add.

Example: https://plugins.zenginehq.com/workspaces/123/myPluginNamespace/myServiceName

Installation

npm i @zenginehq/backend-get-service-url --save

Usage

const $getServiceUrl = require('@zenginehq/backend-get-service-url');

exports.run = function(eventData) {

    const baseUrl = $getServiceUrl(eventData.request);
    
    // ...

};

Dependencies (0)

    Dev Dependencies (4)

    Package Sidebar

    Install

    npm i @zenginehq/backend-get-service-url

    Weekly Downloads

    0

    Version

    1.0.1

    License

    MIT

    Unpacked Size

    4.04 kB

    Total Files

    8

    Last publish

    Collaborators

    • chris.manjoine
    • dwmcnelis-wizehive
    • wizehive-jeremyf