en-US/Trackyon.Invest-Help.xml

<?xml version="1.0" encoding="utf-8"?>
<helpItems schema="maml" xmlns="http://msh">
  <command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp">
    <command:details>
      <command:name>Connect-TkyAccount</command:name>
      <command:verb>Connect</command:verb>
      <command:noun>TkyAccount</command:noun>
      <maml:description>
        <maml:para>Stores the subscription key in the PowerShell session.</maml:para>
      </maml:description>
    </command:details>
    <maml:description>
      <maml:para></maml:para>
    </maml:description>
    <command:syntax>
      <command:syntaxItem>
        <maml:name>Connect-TkyAccount</maml:name>
        <command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="0" aliases="none">
          <maml:name>Key</maml:name>
          <maml:description>
            <maml:para>Subscription key to access API</maml:para>
          </maml:description>
          <command:parameterValue required="true" variableLength="false">SecureString</command:parameterValue>
          <dev:type>
            <maml:name>SecureString</maml:name>
            <maml:uri />
          </dev:type>
          <dev:defaultValue>None</dev:defaultValue>
        </command:parameter>
        <command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases="none">
          <maml:name>Level</maml:name>
          <maml:description>
            <maml:para>On Windows allows you to store your key at the Process, User or Machine levels.</maml:para>
            <maml:para>When saved at the User or Machine level your key will be in any future PowerShell processes.</maml:para>
          </maml:description>
          <command:parameterValue required="true" variableLength="false">String</command:parameterValue>
          <dev:type>
            <maml:name>String</maml:name>
            <maml:uri />
          </dev:type>
          <dev:defaultValue>None</dev:defaultValue>
        </command:parameter>
      </command:syntaxItem>
    </command:syntax>
    <command:parameters>
      <command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="0" aliases="none">
        <maml:name>Key</maml:name>
        <maml:description>
          <maml:para>Subscription key to access API</maml:para>
        </maml:description>
        <command:parameterValue required="true" variableLength="false">SecureString</command:parameterValue>
        <dev:type>
          <maml:name>SecureString</maml:name>
          <maml:uri />
        </dev:type>
        <dev:defaultValue>None</dev:defaultValue>
      </command:parameter>
      <command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases="none">
        <maml:name>Level</maml:name>
        <maml:description>
          <maml:para>On Windows allows you to store your key at the Process, User or Machine levels.</maml:para>
          <maml:para>When saved at the User or Machine level your key will be in any future PowerShell processes.</maml:para>
        </maml:description>
        <command:parameterValue required="true" variableLength="false">String</command:parameterValue>
        <dev:type>
          <maml:name>String</maml:name>
          <maml:uri />
        </dev:type>
        <dev:defaultValue>None</dev:defaultValue>
      </command:parameter>
    </command:parameters>
    <command:inputTypes />
    <command:returnValues />
    <maml:alertSet>
      <maml:alert>
        <maml:para></maml:para>
      </maml:alert>
    </maml:alertSet>
    <command:examples>
      <command:example>
        <maml:title>---------- Example 1: Connect-TkyAccount interactive ----------</maml:title>
        <dev:code>Connect-TkyAccount</dev:code>
        <dev:remarks>
          <maml:para>This example will prompt the user for the subscription key</maml:para>
        </dev:remarks>
      </command:example>
      <command:example>
        <maml:title>----------- Example 2: Connect-TkyAccount scriptable -----------</maml:title>
        <dev:code>$key = ConvertTo-SecureString "yourKey" -AsPlainText -Force
$credentials = New-Object System.Management.Automation.PSCredential ("subscription", $key)
Connect-TkyAccount -key $credentials.Password -level Machine</dev:code>
        <dev:remarks>
          <maml:para>This example will not prompt the user for the subscription key and store it for use in future PowerShell sessions</maml:para>
        </dev:remarks>
      </command:example>
    </command:examples>
    <command:relatedLinks />
  </command:command>
  <command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp">
    <command:details>
      <command:name>Disconnect-TkyAccount</command:name>
      <command:verb>Disconnect</command:verb>
      <command:noun>TkyAccount</command:noun>
      <maml:description>
        <maml:para>Removes the subscription key from the PowerShell session.</maml:para>
      </maml:description>
    </command:details>
    <maml:description>
      <maml:para></maml:para>
    </maml:description>
    <command:syntax>
      <command:syntaxItem>
        <maml:name>Disconnect-TkyAccount</maml:name>
        <command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="0" aliases="none">
          <maml:name>Key</maml:name>
          <maml:description>
            <maml:para>Subscription key to access API</maml:para>
          </maml:description>
          <command:parameterValue required="true" variableLength="false">SecureString</command:parameterValue>
          <dev:type>
            <maml:name>SecureString</maml:name>
            <maml:uri />
          </dev:type>
          <dev:defaultValue>None</dev:defaultValue>
        </command:parameter>
        <command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases="none">
          <maml:name>Level</maml:name>
          <maml:description>
            <maml:para>On Windows allows you to store your key at the Process, User or Machine levels.</maml:para>
            <maml:para>When saved at the User or Machine level your key will be in any future PowerShell processes.</maml:para>
          </maml:description>
          <command:parameterValue required="true" variableLength="false">String</command:parameterValue>
          <dev:type>
            <maml:name>String</maml:name>
            <maml:uri />
          </dev:type>
          <dev:defaultValue>None</dev:defaultValue>
        </command:parameter>
      </command:syntaxItem>
    </command:syntax>
    <command:parameters>
      <command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="0" aliases="none">
        <maml:name>Key</maml:name>
        <maml:description>
          <maml:para>Subscription key to access API</maml:para>
        </maml:description>
        <command:parameterValue required="true" variableLength="false">SecureString</command:parameterValue>
        <dev:type>
          <maml:name>SecureString</maml:name>
          <maml:uri />
        </dev:type>
        <dev:defaultValue>None</dev:defaultValue>
      </command:parameter>
      <command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases="none">
        <maml:name>Level</maml:name>
        <maml:description>
          <maml:para>On Windows allows you to store your key at the Process, User or Machine levels.</maml:para>
          <maml:para>When saved at the User or Machine level your key will be in any future PowerShell processes.</maml:para>
        </maml:description>
        <command:parameterValue required="true" variableLength="false">String</command:parameterValue>
        <dev:type>
          <maml:name>String</maml:name>
          <maml:uri />
        </dev:type>
        <dev:defaultValue>None</dev:defaultValue>
      </command:parameter>
    </command:parameters>
    <command:inputTypes />
    <command:returnValues />
    <maml:alertSet>
      <maml:alert>
        <maml:para>When you return price you must store the results or use Format-Table * to see the price. The default format for the stocks does not include price.</maml:para>
      </maml:alert>
    </maml:alertSet>
    <command:examples>
      <command:example>
        <maml:title>--------------- Example 1: Disconnect-TkyAccount ---------------</maml:title>
        <dev:code>Disconnect-TkyAccount</dev:code>
        <dev:remarks>
          <maml:para>This example will remove the subscription key from the current PowerShell session</maml:para>
        </dev:remarks>
      </command:example>
      <command:example>
        <maml:title>--------------- Example 2: Disconnect-TkyAccount ---------------</maml:title>
        <dev:code>Disconnect-TkyAccount -level User</dev:code>
        <dev:remarks>
          <maml:para>This example will remove the subscription key from future PowerShell sessions</maml:para>
        </dev:remarks>
      </command:example>
    </command:examples>
    <command:relatedLinks />
  </command:command>
  <command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp">
    <command:details>
      <command:name>Get-TkyDate</command:name>
      <command:verb>Get</command:verb>
      <command:noun>TkyDate</command:noun>
      <maml:description>
        <maml:para>Returns stocks that are going to go ex-dividend in the next five trading days.</maml:para>
      </maml:description>
    </command:details>
    <maml:description>
      <maml:para>This function defaults to reading the ticker symbols from an environment variable named 'Trackyon_Tickers'. It should be a compressed JSON array.</maml:para>
      <maml:para>PS &gt; $env:Trackyon_Tickers ["FE","COP","QYLD","IVZ","MAC","PFE","ADM","AGNC","VLO","MSFT","IBM"]</maml:para>
      <maml:para>You can override these values using the tickers or tickerFile parameters. If the tickers or tickerFile parameters are used the environment variable is ignored.</maml:para>
      <maml:para>By passing the prices switch you can have a price property added to the returned data. Querying the price of each stock will add to the time required to return the stocks.</maml:para>
      <maml:para>By default Get-TkyDate only returns the ticker symbol, company name, purchase by date, amount of dividend, and the date paid. To view additional data including the price if requested use the Format-List or Format-Table CmdLets with a * (Get-TkyDate -prices | ft *).</maml:para>
    </maml:description>
    <command:syntax>
      <command:syntaxItem>
        <maml:name>Get-TkyDate</maml:name>
        <command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="0" aliases="none">
          <maml:name>Tickers</maml:name>
          <maml:description>
            <maml:para>An array of ticker symbols to check.</maml:para>
          </maml:description>
          <command:parameterValue required="true" variableLength="false">String[]</command:parameterValue>
          <dev:type>
            <maml:name>String[]</maml:name>
            <maml:uri />
          </dev:type>
          <dev:defaultValue>None</dev:defaultValue>
        </command:parameter>
        <command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases="none">
          <maml:name>Prices</maml:name>
          <maml:description>
            <maml:para>Returns the price of each stock returned. This adds significant time to execution.</maml:para>
          </maml:description>
          <dev:type>
            <maml:name>SwitchParameter</maml:name>
            <maml:uri />
          </dev:type>
          <dev:defaultValue>False</dev:defaultValue>
        </command:parameter>
      </command:syntaxItem>
      <command:syntaxItem>
        <maml:name>Get-TkyDate</maml:name>
        <command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases="none">
          <maml:name>TickerFile</maml:name>
          <maml:description>
            <maml:para>Path to a file containing a JSON array of ticker symbols.</maml:para>
          </maml:description>
          <command:parameterValue required="true" variableLength="false">String</command:parameterValue>
          <dev:type>
            <maml:name>String</maml:name>
            <maml:uri />
          </dev:type>
          <dev:defaultValue>None</dev:defaultValue>
        </command:parameter>
        <command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases="none">
          <maml:name>Prices</maml:name>
          <maml:description>
            <maml:para>Returns the price of each stock returned. This adds significant time to execution.</maml:para>
          </maml:description>
          <dev:type>
            <maml:name>SwitchParameter</maml:name>
            <maml:uri />
          </dev:type>
          <dev:defaultValue>False</dev:defaultValue>
        </command:parameter>
      </command:syntaxItem>
      <command:syntaxItem>
        <maml:name>Get-TkyDate</maml:name>
        <command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases="none">
          <maml:name>Prices</maml:name>
          <maml:description>
            <maml:para>Returns the price of each stock returned. This adds significant time to execution.</maml:para>
          </maml:description>
          <dev:type>
            <maml:name>SwitchParameter</maml:name>
            <maml:uri />
          </dev:type>
          <dev:defaultValue>False</dev:defaultValue>
        </command:parameter>
      </command:syntaxItem>
    </command:syntax>
    <command:parameters>
      <command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="0" aliases="none">
        <maml:name>Tickers</maml:name>
        <maml:description>
          <maml:para>An array of ticker symbols to check.</maml:para>
        </maml:description>
        <command:parameterValue required="true" variableLength="false">String[]</command:parameterValue>
        <dev:type>
          <maml:name>String[]</maml:name>
          <maml:uri />
        </dev:type>
        <dev:defaultValue>None</dev:defaultValue>
      </command:parameter>
      <command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases="none">
        <maml:name>TickerFile</maml:name>
        <maml:description>
          <maml:para>Path to a file containing a JSON array of ticker symbols.</maml:para>
        </maml:description>
        <command:parameterValue required="true" variableLength="false">String</command:parameterValue>
        <dev:type>
          <maml:name>String</maml:name>
          <maml:uri />
        </dev:type>
        <dev:defaultValue>None</dev:defaultValue>
      </command:parameter>
      <command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases="none">
        <maml:name>Prices</maml:name>
        <maml:description>
          <maml:para>Returns the price of each stock returned. This adds significant time to execution.</maml:para>
        </maml:description>
        <command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue>
        <dev:type>
          <maml:name>SwitchParameter</maml:name>
          <maml:uri />
        </dev:type>
        <dev:defaultValue>False</dev:defaultValue>
      </command:parameter>
    </command:parameters>
    <command:inputTypes />
    <command:returnValues />
    <maml:alertSet>
      <maml:alert>
        <maml:para>When you return price you must store the results or use Format-Table * to see the price. The default format for the stocks does not include price.</maml:para>
      </maml:alert>
    </maml:alertSet>
    <command:examples>
      <command:example>
        <maml:title>-------------------- Example 1: Get stocks --------------------</maml:title>
        <dev:code>Get-TkyDate</dev:code>
        <dev:remarks>
          <maml:para>This example returns all the stocks that are going ex-dividend in the next five trading days using the environment variable Trackyon_Tickers.</maml:para>
        </dev:remarks>
      </command:example>
      <command:example>
        <maml:title>--------------- Example 2: Get stocks with price ---------------</maml:title>
        <dev:code>Get-TkyDate MMM,MSFT,CLM,GLAD -prices | ft *</dev:code>
        <dev:remarks>
          <maml:para>This example returns the stocks that are going ex-dividend in the next five trading days with the price form the list provided.</maml:para>
        </dev:remarks>
      </command:example>
      <command:example>
        <maml:title>-------- Example 3: Stores stocks in file and uses file --------</maml:title>
        <dev:code>@("MMM", "GLAD", "MSFT", "CLM") | ConvertTo-Json | Set-Content tickers.json
Get-TkyDate -tickerFile .\tickers.json</dev:code>
        <dev:remarks>
          <maml:para>This example stores a set of tickers in a JSON file and uses that file to call Get-TkyDate.</maml:para>
        </dev:remarks>
      </command:example>
      <command:example>
        <maml:title>------------- Example 4: Get stocks from csv file -------------</maml:title>
        <dev:code>Get-TkyDate $(Import-Csv C:\Downloads\Portfolio_Position_Feb-04-2022.csv).Symbol</dev:code>
        <dev:remarks>
          <maml:para>This example uses the Symbol column of the csv file as the tickers array parameter.</maml:para>
        </dev:remarks>
      </command:example>
    </command:examples>
    <command:relatedLinks />
  </command:command>
</helpItems>