Skip to content

Commit

Permalink
deploy: cae204e
Browse files Browse the repository at this point in the history
  • Loading branch information
crispheaney committed Nov 27, 2023
1 parent 7686795 commit 59cbbdd
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1775,6 +1775,9 @@ <h2 id='settle-perp-pnl'>Settle Perp PNL</h2><div class="highlight"><pre class="
</tbody></table>
<h2 id='get-spot-market-account'>Get Spot Market Account</h2><div class="highlight"><pre class="highlight typescript tab-typescript"><code><span class="kd">const</span> <span class="nx">marketIndex</span> <span class="o">=</span> <span class="mi">1</span><span class="p">;</span>
<span class="kd">const</span> <span class="nx">spotMarketAccount</span> <span class="o">=</span> <span class="nx">driftClient</span><span class="p">.</span><span class="nx">getSpotMarketAccount</span><span class="p">(</span><span class="nx">marketIndex</span><span class="p">);</span>
</code></pre></div><div class="highlight"><pre class="highlight python tab-python"><code><span class="n">market_index</span> <span class="o">=</span> <span class="mi">0</span><span class="p">;</span>

<span class="n">spot_market_account</span> <span class="o">=</span> <span class="n">drift_client</span><span class="p">.</span><span class="n">get_spot_market_account</span><span class="p">(</span><span class="n">market_index</span><span class="p">);</span>
</code></pre></div>
<table><thead>
<tr>
Expand All @@ -1793,6 +1796,9 @@ <h2 id='get-spot-market-account'>Get Spot Market Account</h2><div class="highlig
</tbody></table>
<h2 id='get-perp-market-account'>Get Perp Market Account</h2><div class="highlight"><pre class="highlight typescript tab-typescript"><code><span class="kd">const</span> <span class="nx">marketIndex</span> <span class="o">=</span> <span class="mi">0</span><span class="p">;</span>
<span class="kd">const</span> <span class="nx">perpMarketAccount</span> <span class="o">=</span> <span class="nx">driftClient</span><span class="p">.</span><span class="nx">getPerpMarketAccount</span><span class="p">(</span><span class="nx">marketIndex</span><span class="p">);</span>
</code></pre></div><div class="highlight"><pre class="highlight python tab-python"><code><span class="n">market_index</span> <span class="o">=</span> <span class="mi">0</span><span class="p">;</span>

<span class="n">perp_market_account</span> <span class="o">=</span> <span class="n">drift_client</span><span class="p">.</span><span class="n">get_perp_market_account</span><span class="p">(</span><span class="n">market_index</span><span class="p">);</span>
</code></pre></div>
<table><thead>
<tr>
Expand Down

0 comments on commit 59cbbdd

Please sign in to comment.