1
0
mirror of https://github.com/sasjs/adapter.git synced 2025-12-11 09:24:35 +00:00
Files
adapter/docs/modules/api_viya.html
2021-12-13 17:01:59 +05:00

455 lines
41 KiB
HTML

<!doctype html>
<html class="default no-js">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>api/viya | @sasjs/adapter</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="../assets/css/main.css">
<script async src="../assets/js/search.js" id="search-script"></script>
</head>
<body>
<header>
<div class="tsd-page-toolbar">
<div class="container">
<div class="table-wrap">
<div class="table-cell" id="tsd-search" data-index="../assets/js/search.json" data-base="..">
<div class="field">
<label for="tsd-search-field" class="tsd-widget search no-caption">Search</label>
<input id="tsd-search-field" type="text" />
</div>
<ul class="results">
<li class="state loading">Preparing search index...</li>
<li class="state failure">The search index is not available</li>
</ul>
<ul class="results-priority" style="display:none">
</ul>
<a href="../index.html" class="title">@sasjs/adapter</a>
&emsp;<a href="https://github.com/sasjs/adapter" class="title">SASjs on Github</a>
&emsp;<a href="https://sasjs.io" class="title">SASjs.io</a>
&emsp;<a href="https://github.com/sasjs/cli" class="title">SASjs CLI</a>
&emsp;<a href="https://github.com/sasjs/react-seed-app" class="title">React Seed App</a>
</div>
<div class="table-cell" id="tsd-widgets">
<div id="tsd-filter">
<a href="#" class="tsd-widget options no-caption" data-toggle="options">Options</a>
<div class="tsd-filter-group">
<div class="tsd-select" id="tsd-filter-visibility">
<span class="tsd-select-label">All</span>
<ul class="tsd-select-list">
<li data-value="public">Public</li>
<li data-value="protected">Public/Protected</li>
<li data-value="private" class="selected">All</li>
</ul>
</div>
<input type="checkbox" id="tsd-filter-inherited" checked />
<label class="tsd-widget" for="tsd-filter-inherited">Inherited</label>
</div>
</div>
<a href="#" class="tsd-widget menu no-caption" data-toggle="menu">Menu</a>
</div>
</div>
</div>
</div>
<div class="tsd-page-title">
<div class="container">
<ul class="tsd-breadcrumb">
<li>
<a href="api_viya.html">api/viya</a>
</li>
</ul>
</div>
</div>
</header>
<div class="container container-main">
<div class="row">
<div class="col-3 col-menu menu-sticky-wrap menu-highlight">
<nav class="tsd-navigation outline primary">
<a style="margin-left:0em" href="../modules.html">Modules</a>
<ul style="display:none">
{&quot;SAS Adapter&quot;:{&quot;SASjs&quot;:&quot;classes/reflection-717.reflection-180.sasjs&quot;,&quot;Types&quot;:&quot;modules/types&quot;},&quot;SAS Viya API Client&quot;:&quot;classes/reflection-717.reflection-180.sasviyaapiclient&quot;,&quot;SAS 9 API Client&quot;:&quot;classes/reflection-717.reflection-180.sas9apiclient&quot;}
</ul>
</nav>
</div>
<div class="col-7 offset-3 col-content">
<h1>Module api/viya</h1>
<section class="tsd-panel-group tsd-index-group">
<section class="tsd-panel tsd-index-panel">
<div class="tsd-index-content">
<section class="tsd-index-section ">
<h3>Functions</h3>
<ul class="tsd-index-list">
<li class="tsd-kind-function tsd-parent-kind-module"><a href="api_viya.html#executescript" class="tsd-kind-icon">execute<wbr>Script</a></li>
<li class="tsd-kind-function tsd-parent-kind-module"><a href="api_viya.html#getfilestream" class="tsd-kind-icon">get<wbr>File<wbr>Stream</a></li>
<li class="tsd-kind-function tsd-parent-kind-module"><a href="api_viya.html#polljobstate" class="tsd-kind-icon">poll<wbr>Job<wbr>State</a></li>
<li class="tsd-kind-function tsd-parent-kind-module"><a href="api_viya.html#savelog" class="tsd-kind-icon">save<wbr>Log</a></li>
<li class="tsd-kind-function tsd-parent-kind-module"><a href="api_viya.html#uploadtables" class="tsd-kind-icon">upload<wbr>Tables</a></li>
<li class="tsd-kind-function tsd-parent-kind-module"><a href="api_viya.html#writestream" class="tsd-kind-icon">write<wbr>Stream</a></li>
</ul>
</section>
</div>
</section>
</section>
<section class="tsd-panel-group tsd-member-group ">
<h2>Functions</h2>
<section class="tsd-panel tsd-member tsd-kind-function tsd-parent-kind-module">
<a name="executescript" class="tsd-anchor"></a>
<h3>execute<wbr>Script</h3>
<ul class="tsd-signatures tsd-kind-function tsd-parent-kind-module">
<li class="tsd-signature tsd-kind-icon">execute<wbr>Script<span class="tsd-signature-symbol">(</span>requestClient<span class="tsd-signature-symbol">: </span><a href="../classes/request.requestclient.html" class="tsd-signature-type">RequestClient</a>, sessionManager<span class="tsd-signature-symbol">: </span><a href="../classes/root.sessionmanager.html" class="tsd-signature-type">SessionManager</a>, rootFolderName<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span>, jobPath<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span>, linesOfCode<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span>, contextName<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span>, authConfig<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">AuthConfig</span>, data<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">any</span>, debug<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">boolean</span>, expectWebout<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">boolean</span>, waitForResult<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">boolean</span>, pollOptions<span class="tsd-signature-symbol">?: </span><a href="../interfaces/types.polloptions.html" class="tsd-signature-type">PollOptions</a>, printPid<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">boolean</span>, variables<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">MacroVar</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span></li>
</ul>
<ul class="tsd-descriptions">
<li class="tsd-description">
<aside class="tsd-sources">
<ul>
<li>Defined in
<a href="https://github.com/sasjs/adapter/blob/master/src/src/api/viya/executeScript.ts#L32">
src/api/viya/executeScript.ts:32
</a>
</li>
</ul>
</aside>
<div class="tsd-comment tsd-typography tsd-comment-shorttext">
<div class="lead">
<p>Executes code on the current SAS Viya server.</p>
</div>
</div>
<h4 class="tsd-parameters-title">Parameters</h4>
<ul class="tsd-parameters">
<li>
<h5>requestClient: <a href="../classes/request.requestclient.html" class="tsd-signature-type">RequestClient</a></h5>
</li>
<li>
<h5>sessionManager: <a href="../classes/root.sessionmanager.html" class="tsd-signature-type">SessionManager</a></h5>
</li>
<li>
<h5>rootFolderName: <span class="tsd-signature-type">string</span></h5>
</li>
<li>
<h5>jobPath: <span class="tsd-signature-type">string</span></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>the path to the file being submitted for execution.</p>
</div>
</li>
<li>
<h5>linesOfCode: <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>an array of code lines to execute.</p>
</div>
</li>
<li>
<h5>contextName: <span class="tsd-signature-type">string</span></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>the context to execute the code in.</p>
</div>
</li>
<li>
<h5><span class="tsd-flag ts-flagOptional">Optional</span> authConfig: <span class="tsd-signature-type">AuthConfig</span></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>an object containing an access token, refresh token, client ID and secret.</p>
</div>
</li>
<li>
<h5><span class="tsd-flag ts-flagDefault value">Default value</span> data: <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol"> = null</span></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>execution data.</p>
</div>
</li>
<li>
<h5><span class="tsd-flag ts-flagDefault value">Default value</span> debug: <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol"> = false</span></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>when set to true, the log will be returned.</p>
</div>
</li>
<li>
<h5><span class="tsd-flag ts-flagDefault value">Default value</span> expectWebout: <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol"> = false</span></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>when set to true, the automatic _webout fileref will be checked for content, and that content returned. This fileref is used when the Job contains a SASjs web request (as opposed to executing arbitrary SAS code).</p>
</div>
</li>
<li>
<h5><span class="tsd-flag ts-flagDefault value">Default value</span> waitForResult: <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol"> = true</span></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>when set to true, function will return the session</p>
</div>
</li>
<li>
<h5><span class="tsd-flag ts-flagOptional">Optional</span> pollOptions: <a href="../interfaces/types.polloptions.html" class="tsd-signature-type">PollOptions</a></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>an object that represents poll interval(milliseconds) and maximum amount of attempts. Object example: { MAX_POLL_COUNT: 24 * 60 * 60, POLL_INTERVAL: 1000 }.</p>
</div>
</li>
<li>
<h5><span class="tsd-flag ts-flagDefault value">Default value</span> printPid: <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol"> = false</span></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>a boolean that indicates whether the function should print (PID) of the started job.</p>
</div>
</li>
<li>
<h5><span class="tsd-flag ts-flagOptional">Optional</span> variables: <span class="tsd-signature-type">MacroVar</span></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>an object that represents macro variables.</p>
</div>
</li>
</ul>
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span></h4>
</li>
</ul>
</section>
<section class="tsd-panel tsd-member tsd-kind-function tsd-parent-kind-module">
<a name="getfilestream" class="tsd-anchor"></a>
<h3><span class="tsd-flag ts-flagConst">Const</span> get<wbr>File<wbr>Stream</h3>
<ul class="tsd-signatures tsd-kind-function tsd-parent-kind-module">
<li class="tsd-signature tsd-kind-icon">get<wbr>File<wbr>Stream<span class="tsd-signature-symbol">(</span>job<span class="tsd-signature-symbol">: </span><a href="../interfaces/types.job.html" class="tsd-signature-type">Job</a>, filePath<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span></li>
</ul>
<ul class="tsd-descriptions">
<li class="tsd-description">
<aside class="tsd-sources">
<ul>
<li>Defined in
<a href="https://github.com/sasjs/adapter/blob/master/src/src/api/viya/getFileStream.ts#L5">
src/api/viya/getFileStream.ts:5
</a>
</li>
</ul>
</aside>
<h4 class="tsd-parameters-title">Parameters</h4>
<ul class="tsd-parameters">
<li>
<h5>job: <a href="../interfaces/types.job.html" class="tsd-signature-type">Job</a></h5>
</li>
<li>
<h5><span class="tsd-flag ts-flagOptional">Optional</span> filePath: <span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">string</span></h5>
</li>
</ul>
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span></h4>
</li>
</ul>
</section>
<section class="tsd-panel tsd-member tsd-kind-function tsd-parent-kind-module">
<a name="polljobstate" class="tsd-anchor"></a>
<h3>poll<wbr>Job<wbr>State</h3>
<ul class="tsd-signatures tsd-kind-function tsd-parent-kind-module">
<li class="tsd-signature tsd-kind-icon">poll<wbr>Job<wbr>State<span class="tsd-signature-symbol">(</span>requestClient<span class="tsd-signature-symbol">: </span><a href="../classes/request.requestclient.html" class="tsd-signature-type">RequestClient</a>, postedJob<span class="tsd-signature-symbol">: </span><a href="../interfaces/types.job.html" class="tsd-signature-type">Job</a>, debug<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">boolean</span>, authConfig<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">AuthConfig</span>, pollOptions<span class="tsd-signature-symbol">?: </span><a href="../interfaces/types.polloptions.html" class="tsd-signature-type">PollOptions</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">&gt;</span></li>
</ul>
<ul class="tsd-descriptions">
<li class="tsd-description">
<aside class="tsd-sources">
<ul>
<li>Defined in
<a href="https://github.com/sasjs/adapter/blob/master/src/src/api/viya/pollJobState.ts#L9">
src/api/viya/pollJobState.ts:9
</a>
</li>
</ul>
</aside>
<h4 class="tsd-parameters-title">Parameters</h4>
<ul class="tsd-parameters">
<li>
<h5>requestClient: <a href="../classes/request.requestclient.html" class="tsd-signature-type">RequestClient</a></h5>
</li>
<li>
<h5>postedJob: <a href="../interfaces/types.job.html" class="tsd-signature-type">Job</a></h5>
</li>
<li>
<h5>debug: <span class="tsd-signature-type">boolean</span></h5>
</li>
<li>
<h5><span class="tsd-flag ts-flagOptional">Optional</span> authConfig: <span class="tsd-signature-type">AuthConfig</span></h5>
</li>
<li>
<h5><span class="tsd-flag ts-flagOptional">Optional</span> pollOptions: <a href="../interfaces/types.polloptions.html" class="tsd-signature-type">PollOptions</a></h5>
</li>
</ul>
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">&gt;</span></h4>
</li>
</ul>
</section>
<section class="tsd-panel tsd-member tsd-kind-function tsd-parent-kind-module">
<a name="savelog" class="tsd-anchor"></a>
<h3>save<wbr>Log</h3>
<ul class="tsd-signatures tsd-kind-function tsd-parent-kind-module">
<li class="tsd-signature tsd-kind-icon">save<wbr>Log<span class="tsd-signature-symbol">(</span>job<span class="tsd-signature-symbol">: </span><a href="../interfaces/types.job.html" class="tsd-signature-type">Job</a>, requestClient<span class="tsd-signature-symbol">: </span><a href="../classes/request.requestclient.html" class="tsd-signature-type">RequestClient</a>, startLine<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span>, endLine<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span>, logFileStream<span class="tsd-signature-symbol">?: </span><a href="../interfaces/types.writestream.html" class="tsd-signature-type">WriteStream</a>, accessToken<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></li>
</ul>
<ul class="tsd-descriptions">
<li class="tsd-description">
<aside class="tsd-sources">
<ul>
<li>Defined in
<a href="https://github.com/sasjs/adapter/blob/master/src/src/api/viya/saveLog.ts#L18">
src/api/viya/saveLog.ts:18
</a>
</li>
</ul>
</aside>
<div class="tsd-comment tsd-typography tsd-comment-shorttext">
<div class="lead">
<p>Appends logs to a supplied write stream.
This is useful for getting quick feedback on longer running jobs.</p>
</div>
</div><div class="tsd-comment tsd-typography tsd-comment-tags">
<dl class="tsd-comment-tags"><dt>accesstoken</dt>
<dd><ul>
<li>an optional access token for authentication/authorization
The access token is not required when fetching logs from the browser.</li>
</ul>
</dd></dl>
</div>
<h4 class="tsd-parameters-title">Parameters</h4>
<ul class="tsd-parameters">
<li>
<h5>job: <a href="../interfaces/types.job.html" class="tsd-signature-type">Job</a></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>the job to fetch logs for</p>
</div>
</li>
<li>
<h5>requestClient: <a href="../classes/request.requestclient.html" class="tsd-signature-type">RequestClient</a></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>the pre-configured HTTP request client</p>
</div>
</li>
<li>
<h5>startLine: <span class="tsd-signature-type">number</span></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>the line at which to start fetching the log</p>
</div>
</li>
<li>
<h5>endLine: <span class="tsd-signature-type">number</span></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>the line at which to stop fetching the log</p>
</div>
</li>
<li>
<h5><span class="tsd-flag ts-flagOptional">Optional</span> logFileStream: <a href="../interfaces/types.writestream.html" class="tsd-signature-type">WriteStream</a></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>the write stream to which the log is appended</p>
</div>
</li>
<li>
<h5><span class="tsd-flag ts-flagOptional">Optional</span> accessToken: <span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">string</span></h5>
</li>
</ul>
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4>
</li>
</ul>
</section>
<section class="tsd-panel tsd-member tsd-kind-function tsd-parent-kind-module">
<a name="uploadtables" class="tsd-anchor"></a>
<h3>upload<wbr>Tables</h3>
<ul class="tsd-signatures tsd-kind-function tsd-parent-kind-module">
<li class="tsd-signature tsd-kind-icon">upload<wbr>Tables<span class="tsd-signature-symbol">(</span>requestClient<span class="tsd-signature-symbol">: </span><a href="../classes/request.requestclient.html" class="tsd-signature-type">RequestClient</a>, data<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">any</span>, accessToken<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">object</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span></li>
</ul>
<ul class="tsd-descriptions">
<li class="tsd-description">
<aside class="tsd-sources">
<ul>
<li>Defined in
<a href="https://github.com/sasjs/adapter/blob/master/src/src/api/viya/uploadTables.ts#L13">
src/api/viya/uploadTables.ts:13
</a>
</li>
</ul>
</aside>
<div class="tsd-comment tsd-typography tsd-comment-shorttext">
<div class="lead">
<p>Uploads tables to SAS as specially formatted CSVs.
This is more compact than JSON, and easier to read within SAS.</p>
</div>
</div>
<h4 class="tsd-parameters-title">Parameters</h4>
<ul class="tsd-parameters">
<li>
<h5>requestClient: <a href="../classes/request.requestclient.html" class="tsd-signature-type">RequestClient</a></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>the pre-configured HTTP request client</p>
</div>
</li>
<li>
<h5>data: <span class="tsd-signature-type">any</span></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>the JSON representation of the data to be uploaded</p>
</div>
</li>
<li>
<h5><span class="tsd-flag ts-flagOptional">Optional</span> accessToken: <span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">string</span></h5>
<div class="tsd-comment tsd-typography tsd-comment-text">
<p>an optional access token for authentication/authorization
The access token is not required when uploading tables from the browser.</p>
</div>
</li>
</ul>
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">object</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span></h4>
</li>
</ul>
</section>
<section class="tsd-panel tsd-member tsd-kind-function tsd-parent-kind-module">
<a name="writestream" class="tsd-anchor"></a>
<h3><span class="tsd-flag ts-flagConst">Const</span> write<wbr>Stream</h3>
<ul class="tsd-signatures tsd-kind-function tsd-parent-kind-module">
<li class="tsd-signature tsd-kind-icon">write<wbr>Stream<span class="tsd-signature-symbol">(</span>stream<span class="tsd-signature-symbol">: </span><a href="../interfaces/types.writestream.html" class="tsd-signature-type">WriteStream</a>, content<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></li>
</ul>
<ul class="tsd-descriptions">
<li class="tsd-description">
<aside class="tsd-sources">
<ul>
<li>Defined in
<a href="https://github.com/sasjs/adapter/blob/master/src/src/api/viya/writeStream.ts#L3">
src/api/viya/writeStream.ts:3
</a>
</li>
</ul>
</aside>
<h4 class="tsd-parameters-title">Parameters</h4>
<ul class="tsd-parameters">
<li>
<h5>stream: <a href="../interfaces/types.writestream.html" class="tsd-signature-type">WriteStream</a></h5>
</li>
<li>
<h5>content: <span class="tsd-signature-type">string</span></h5>
</li>
</ul>
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4>
</li>
</ul>
</section>
</section>
<!--{&quot;options&quot;:&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter&quot;,&quot;tsconfig&quot;:&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter&quot;,&quot;inputFiles&quot;:[&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/ContextManager.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/SAS9ApiClient.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/SASViyaApiClient.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/SASViyaApiClient.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/SASjs.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/SASjsApiClient.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/SessionManager.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/index.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/__mocks__/axios.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/api/viya/executeScript.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/api/viya/getFileStream.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/api/viya/pollJobState.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/api/viya/saveLog.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/api/viya/uploadTables.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/api/viya/writeStream.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/api/viya/spec/executeScript.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/api/viya/spec/getFileStream.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/api/viya/spec/mockResponses.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/api/viya/spec/pollJobState.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/api/viya/spec/saveLog.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/api/viya/spec/uploadTables.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/api/viya/spec/writeStream.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/AuthManager.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/getAccessTokenForSasjs.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/getAccessTokenForViya.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/getAuthCodeForSasjs.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/getTokens.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/index.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/isAuthorizeFormRequired.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/isLoginRequired.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/openWebPage.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/refreshTokensForSasjs.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/refreshTokensForViya.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/verifySas9Login.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/verifySasViyaLogin.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/spec/AuthManager.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/spec/getAccessTokenForSasjs.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/spec/getAccessTokenForViya.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/spec/getTokens.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/spec/mockResponses.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/spec/openWebPage.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/spec/refreshTokensForSasjs.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/spec/refreshTokensForViya.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/spec/verifySas9Login.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/auth/spec/verifySasViyaLogin.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/file/generateFileUploadForm.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/file/generateTableUploadForm.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/job-execution/ComputeJobExecutor.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/job-execution/FileUploader.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/job-execution/JesJobExecutor.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/job-execution/JobExecutor.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/job-execution/Sas9JobExecutor.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/job-execution/WebJobExecutor.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/job-execution/index.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/request/RequestClient.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/request/Sas9RequestClient.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/request/SasjsRequestClient.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/test/ContextManager.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/test/FileUploader.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/test/FolderOperations.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/test/RequestClient.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/test/SAS_server_app.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/test/SessionManager.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/test/utils/getValidJson.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/test/utils/isUrl.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/test/utils/parseGeneratedCode.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/test/utils/parseSourceCode.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/Context.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/CsrfToken.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/ExecuteScript.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/File.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/FileTree.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/Folder.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/Job.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/JobDefinition.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/JobResult.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/Link.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/LogStatistics.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/Login.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/PollOptions.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/Process.d.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/SASjsConfig.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/SASjsRequest.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/Session.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/UploadFile.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/WriteStream.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/index.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/errors/AuthorizeError.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/errors/ComputeJobExecutionError.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/errors/ErrorResponse.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/errors/InternalServerError.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/errors/InvalidJsonError.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/errors/JobExecutionError.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/errors/JobStatePollError.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/errors/JsonParseArrayError.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/errors/LoginRequiredError.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/errors/NoSessionStateError.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/errors/NotFoundError.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/errors/RootFolderNotFoundError.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/errors/RootFolderNotFoundError.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/errors/SAS9AuthError.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/errors/WeboutResponseError.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/types/errors/index.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/appendExtraResponseAttributes.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/asyncForEach.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/compareTimestamps.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/convertToCsv.spec.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/convertToCsv.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/createAxiosInstance.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/delay.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/fetchLogByChunks.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/formatDataForRequest.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/getValidJson.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/index.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/isIeOrEdge.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/isNode.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/isRelativePath.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/isUri.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/isUrl.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/needsRetry.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/parseGeneratedCode.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/parseSasViyaLog.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/parseSourceCode.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/parseViyaDebugResponse.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/parseWeboutResponse.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/serialize.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/splitChunks.ts&quot;,&quot;/Users/saadjutt/projects/macropeople/sasjs/adapter/src/utils/loginPrompt/index.ts&quot;],&quot;mode&quot;:1,&quot;includeDeclarations&quot;:true,&quot;entryPoint&quot;:&quot;&quot;,&quot;exclude&quot;:[&quot;**/*+(index|.spec|.e2e).ts&quot;],&quot;externalPattern&quot;:[],&quot;excludeExternals&quot;:true,&quot;excludeNotExported&quot;:true,&quot;excludeNotDocumented&quot;:false,&quot;excludePrivate&quot;:true,&quot;excludeProtected&quot;:false,&quot;ignoreCompilerErrors&quot;:true,&quot;disableSources&quot;:false,&quot;includes&quot;:&quot;&quot;,&quot;media&quot;:&quot;&quot;,&quot;out&quot;:&quot;docs&quot;,&quot;json&quot;:&quot;&quot;,&quot;theme&quot;:&quot;./node_modules/typedoc-neo-theme/bin/default&quot;,&quot;name&quot;:&quot;&quot;,&quot;includeVersion&quot;:false,&quot;excludeTags&quot;:[],&quot;readme&quot;:&quot;&quot;,&quot;defaultCategory&quot;:&quot;Other&quot;,&quot;categoryOrder&quot;:[],&quot;categorizeByGroup&quot;:true,&quot;gitRevision&quot;:&quot;&quot;,&quot;gitRemote&quot;:&quot;origin&quot;,&quot;gaID&quot;:&quot;&quot;,&quot;gaSite&quot;:&quot;auto&quot;,&quot;hideGenerator&quot;:false,&quot;toc&quot;:[],&quot;disableOutputCheck&quot;:true,&quot;help&quot;:false,&quot;version&quot;:false,&quot;plugin&quot;:[],&quot;logger&quot;:&quot;console&quot;,&quot;listInvalidSymbolLinks&quot;:false,&quot;links&quot;:[{&quot;label&quot;:&quot;SASjs on Github&quot;,&quot;url&quot;:&quot;https://github.com/sasjs/adapter&quot;},{&quot;label&quot;:&quot;SASjs.io&quot;,&quot;url&quot;:&quot;https://sasjs.io&quot;},{&quot;label&quot;:&quot;SASjs CLI&quot;,&quot;url&quot;:&quot;https://github.com/sasjs/cli&quot;},{&quot;label&quot;:&quot;React Seed App&quot;,&quot;url&quot;:&quot;https://github.com/sasjs/react-seed-app&quot;}],&quot;outline&quot;:[{&quot;SAS Adapter&quot;:{&quot;SASjs&quot;:&quot;classes/reflection-717.reflection-180.sasjs&quot;,&quot;Types&quot;:&quot;modules/types&quot;},&quot;SAS Viya API Client&quot;:&quot;classes/reflection-717.reflection-180.sasviyaapiclient&quot;,&quot;SAS 9 API Client&quot;:&quot;classes/reflection-717.reflection-180.sas9apiclient&quot;}],&quot;source&quot;:[{&quot;path&quot;:&quot;https://github.com/sasjs/adapter/blob/master/src/&quot;,&quot;line&quot;:&quot;L&quot;}],&quot;disableAutoModuleName&quot;:&quot;false&quot;}-->
</div>
<div class="col-2 col-menu secondary-menu">
<nav class="tsd-navigation secondary menu-sticky">
<ul class="before-current">
<li class=" tsd-kind-function tsd-parent-kind-module root">
<a href="api_viya.html#executescript" class="tsd-kind-icon">execute<wbr>Script</a>
</li>
<li class=" tsd-kind-function tsd-parent-kind-module root">
<a href="api_viya.html#getfilestream" class="tsd-kind-icon">get<wbr>File<wbr>Stream</a>
</li>
<li class=" tsd-kind-function tsd-parent-kind-module root">
<a href="api_viya.html#polljobstate" class="tsd-kind-icon">poll<wbr>Job<wbr>State</a>
</li>
<li class=" tsd-kind-function tsd-parent-kind-module root">
<a href="api_viya.html#savelog" class="tsd-kind-icon">save<wbr>Log</a>
</li>
<li class=" tsd-kind-function tsd-parent-kind-module root">
<a href="api_viya.html#uploadtables" class="tsd-kind-icon">upload<wbr>Tables</a>
</li>
<li class=" tsd-kind-function tsd-parent-kind-module root">
<a href="api_viya.html#writestream" class="tsd-kind-icon">write<wbr>Stream</a>
</li>
</ul>
</nav>
</div>
</div>
</div>
<footer class="with-border-bottom">
</footer>
<div class="container tsd-generator">
<p>Generated using <a href="http://typedoc.org/" target="_blank">TypeDoc</a></p>
</div>
<div class="overlay"></div>
<script src="../assets/js/main.js"></script>
</body>
</html>