Orchestrator Workflow Action to Add a REST Host with No Credentials

by Simon Sparks · 1 May 2025

To use this function add it to the class library file named vCloudService.ts

GitHub Repository: https://github.com/SimonSparksUK/Orchestrator

Filename: vCloudService.ts

Description: Orchestrator Function to adds a REST Host with No Credentials

Function: RESTHostCreateNoCredentials

public RESTHostCreateNoCredentials(strName: string, strUrl: string): RESTHost {
    let arrAuthenticationParams: string[] = ["Per User Session", "", ""];

    let objRESTAuthentication: RESTAuthentication = RESTAuthenticationManager.createAuthentication("Basic", arrAuthenticationParams);

    let objRESTHost: RESTHost = new RESTHost(strName);
    objRESTHost.url = strUrl;
    objRESTHost.connectionTimeout = 30.0;
    objRESTHost.operationTimeout = 60.0;
    objRESTHost.authentication = objRESTAuthentication;

    objRESTHost = RESTHostManager.addHost(objRESTHost);

    return objRESTHost;
}

Discover more from Cloud Build Tools

Subscribe to get the latest posts sent to your email.

You may also like