Skip to content

Commit

Permalink
feat(api): account number support (#74)
Browse files Browse the repository at this point in the history
  • Loading branch information
stainless-app[bot] committed Dec 9, 2024
1 parent 75e4f25 commit c91236d
Show file tree
Hide file tree
Showing 24 changed files with 76 additions and 49 deletions.
2 changes: 1 addition & 1 deletion .stats.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
configured_endpoints: 31
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/clear-street%2Fstudio-sdk-5efb317738842339f6e8bd32592691a65d19a54adc34bfa319d6bac2404404a7.yml
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/clear-street%2Fstudio-sdk-507601d533175bf3b74a3b04c29d55029c585b24a4ec873bc43d93fe76528076.yml
4 changes: 2 additions & 2 deletions src/studio_sdk/resources/accounts/accounts.py
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ def retrieve(
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> Account:
"""
Get an account by its ID.
Get an account by its ID or number.
Args:
account_id: Account ID for the account.
Expand Down Expand Up @@ -303,7 +303,7 @@ async def retrieve(
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> Account:
"""
Get an account by its ID.
Get an account by its ID or number.
Args:
account_id: Account ID for the account.
Expand Down
4 changes: 2 additions & 2 deletions src/studio_sdk/resources/accounts/bulk_orders.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ def create(
downstream venues.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to create orders for.
orders: An array of orders to create.
Expand Down Expand Up @@ -148,7 +148,7 @@ async def create(
downstream venues.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to create orders for.
orders: An array of orders to create.
Expand Down
4 changes: 2 additions & 2 deletions src/studio_sdk/resources/accounts/easy_borrows.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ def list(
daily.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to list easy borrows for.
extra_headers: Send extra headers
Expand Down Expand Up @@ -114,7 +114,7 @@ async def list(
daily.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to list easy borrows for.
extra_headers: Send extra headers
Expand Down
4 changes: 2 additions & 2 deletions src/studio_sdk/resources/accounts/holdings.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ def list(
regardless of where trades occur.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to list holdings for.
date: The historical date to get holdings for. If omitted, current real-time holdings
will be returned.
Expand Down Expand Up @@ -136,7 +136,7 @@ async def list(
regardless of where trades occur.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to list holdings for.
date: The historical date to get holdings for. If omitted, current real-time holdings
will be returned.
Expand Down
4 changes: 2 additions & 2 deletions src/studio_sdk/resources/accounts/inventories.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ def retrieve(
Get located inventory for a symbol.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to get the inventory for.
extra_headers: Send extra headers
Expand Down Expand Up @@ -114,7 +114,7 @@ async def retrieve(
Get located inventory for a symbol.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to get the inventory for.
extra_headers: Send extra headers
Expand Down
16 changes: 8 additions & 8 deletions src/studio_sdk/resources/accounts/locate_orders.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def create(
Create locate order to borrow inventory for short-selling.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to create the locate order for.
mpid: The market participant where the locate will be sent.
Expand Down Expand Up @@ -119,7 +119,7 @@ def retrieve(
Get locate order by its unique locate order ID.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to get the locate order for.
locate_order_id: Locate order ID to get.
Expand Down Expand Up @@ -160,7 +160,7 @@ def update(
Accept or decline locate order that has been offered.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to update the locate order for.
locate_order_id: Unique locate ID assigned by us.
Expand Down Expand Up @@ -203,7 +203,7 @@ def list(
List all locate orders
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to list locate orders for.
extra_headers: Send extra headers
Expand Down Expand Up @@ -264,7 +264,7 @@ async def create(
Create locate order to borrow inventory for short-selling.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to create the locate order for.
mpid: The market participant where the locate will be sent.
Expand Down Expand Up @@ -318,7 +318,7 @@ async def retrieve(
Get locate order by its unique locate order ID.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to get the locate order for.
locate_order_id: Locate order ID to get.
Expand Down Expand Up @@ -359,7 +359,7 @@ async def update(
Accept or decline locate order that has been offered.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to update the locate order for.
locate_order_id: Unique locate ID assigned by us.
Expand Down Expand Up @@ -402,7 +402,7 @@ async def list(
List all locate orders
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to list locate orders for.
extra_headers: Send extra headers
Expand Down
24 changes: 12 additions & 12 deletions src/studio_sdk/resources/accounts/orders.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ def create(
utilize our WebSocket APIs to listen for changes in order lifecycle events.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to create the order for.
order_type:
The type of order, can be one of the following:
Expand Down Expand Up @@ -174,7 +174,7 @@ def retrieve(
Get an order that was previously created.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to get the order for.
order_id: Unique order ID assigned by us.
Expand Down Expand Up @@ -218,7 +218,7 @@ def list(
given query parameters.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to list orders for.
from_: Milliseconds since epoch timestamp. This will constrain the search for orders
created after this timestamp, inclusively. Timestamps for orders prior the
Expand Down Expand Up @@ -281,7 +281,7 @@ def delete(
cannot be guaranteed as there might be in-flight executions.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to cancel orders for.
symbol: Cancel orders only for this specific symbol. If this is omitted, all open orders
will be cancelled.
Expand Down Expand Up @@ -334,7 +334,7 @@ def cancel(
as there might be in-flight executions.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to attempt to cancel the order for.
order_id: Unique order ID assigned by us.
Expand Down Expand Up @@ -380,7 +380,7 @@ def patch(
order's attributes, for example price and quantity.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to attempt to update the order for.
order_id: Unique order ID assigned by us.
Expand Down Expand Up @@ -470,7 +470,7 @@ async def create(
utilize our WebSocket APIs to listen for changes in order lifecycle events.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to create the order for.
order_type:
The type of order, can be one of the following:
Expand Down Expand Up @@ -564,7 +564,7 @@ async def retrieve(
Get an order that was previously created.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to get the order for.
order_id: Unique order ID assigned by us.
Expand Down Expand Up @@ -608,7 +608,7 @@ async def list(
given query parameters.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to list orders for.
from_: Milliseconds since epoch timestamp. This will constrain the search for orders
created after this timestamp, inclusively. Timestamps for orders prior the
Expand Down Expand Up @@ -671,7 +671,7 @@ async def delete(
cannot be guaranteed as there might be in-flight executions.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to cancel orders for.
symbol: Cancel orders only for this specific symbol. If this is omitted, all open orders
will be cancelled.
Expand Down Expand Up @@ -724,7 +724,7 @@ async def cancel(
as there might be in-flight executions.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to attempt to cancel the order for.
order_id: Unique order ID assigned by us.
Expand Down Expand Up @@ -770,7 +770,7 @@ async def patch(
order's attributes, for example price and quantity.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to attempt to update the order for.
order_id: Unique order ID assigned by us.
Expand Down
4 changes: 2 additions & 2 deletions src/studio_sdk/resources/accounts/pnl_details.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ def list(
List PNL details for a given account.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to list PNL details for.
extra_headers: Send extra headers
Expand Down Expand Up @@ -110,7 +110,7 @@ async def list(
List PNL details for a given account.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to list PNL details for.
extra_headers: Send extra headers
Expand Down
4 changes: 2 additions & 2 deletions src/studio_sdk/resources/accounts/pnl_summary.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ def retrieve(
Get PNL summary for a given account.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to get a PNL summary for.
extra_headers: Send extra headers
Expand Down Expand Up @@ -110,7 +110,7 @@ async def retrieve(
Get PNL summary for a given account.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to get a PNL summary for.
extra_headers: Send extra headers
Expand Down
4 changes: 2 additions & 2 deletions src/studio_sdk/resources/accounts/pnl_sums.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ def list(
filtered on the given query parameters.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to list PNL sums for.
ending_date: The ending date to accumulate PNL data for, inclusive.
Expand Down Expand Up @@ -146,7 +146,7 @@ async def list(
filtered on the given query parameters.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to list PNL sums for.
ending_date: The ending date to accumulate PNL data for, inclusive.
Expand Down
12 changes: 6 additions & 6 deletions src/studio_sdk/resources/accounts/positions.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,10 @@ def retrieve(
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> Position:
"""
Get current positions for a given account for a given symbol.
Get current position for a given account for a given symbol.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to get the position for.
symbol: Symbol to get position for.
Expand Down Expand Up @@ -102,7 +102,7 @@ def list(
List current positions for a given account.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to list positions for.
page_size: Number of positions to return per page.
Expand Down Expand Up @@ -170,10 +170,10 @@ async def retrieve(
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> Position:
"""
Get current positions for a given account for a given symbol.
Get current position for a given account for a given symbol.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to get the position for.
symbol: Symbol to get position for.
Expand Down Expand Up @@ -214,7 +214,7 @@ async def list(
List current positions for a given account.
Args:
account_id: Account ID for the account.
account_id: The account ID or account number to list positions for.
page_size: Number of positions to return per page.
Expand Down
Loading

0 comments on commit c91236d

Please sign in to comment.