Actions13
- Accounts Actions
- Orders Actions
- Transactions Actions
- User Preference Actions
Overview
This node interacts with the Schwab Trader API to retrieve order data based on specific path parameters. The "Get Orders By Path Param" operation allows users to fetch orders filtered by account number, time range, status, and other criteria. This is useful for financial applications that need to monitor or analyze trading orders within a given account over a specified period.
Practical examples include:
- Retrieving all orders placed within a certain date range for auditing or reporting.
- Filtering orders by their status (e.g., only filled or pending orders) to track execution progress.
- Limiting the number of returned orders to optimize performance when dealing with large datasets.
Properties
| Name | Meaning |
|---|---|
| Account Number | The encrypted ID of the account whose orders are being retrieved. |
| Max Results | The maximum number of orders to retrieve. Default is 3000 if not specified. |
| From Entered Time | The start of the time window; no orders entered before this ISO-8601 timestamp will be returned. |
| To Entered Time | The end of the time window; no orders entered after this ISO-8601 timestamp will be returned. |
| Status | Filter to return only orders with the specified status. Options include: AWAITING_PARENT_ORDER, ACCEPTED, FILLED, REJECTED, etc. |
| Additional Headers | Optional custom HTTP headers to send with the request. Authorization headers are set automatically and should not be included here. |
Output
The node outputs JSON objects representing orders retrieved from the Schwab Trader API. Each output item corresponds to one order or a collection of orders depending on the response structure.
- The
jsonfield contains the order data as returned by the API. - If multiple orders are returned as an array, each order is output as a separate item.
- In case of errors, the output includes an error object with details such as the error message, HTTP status code, and the original request data.
- The node does not output binary data.
Dependencies
- Requires an OAuth2 API credential configured in n8n for authenticating requests to the Schwab Trader API.
- The base URL for API requests is
https://api.schwabapi.com/trader/v1. - The node automatically sets standard headers like
Accept: application/jsonandUser-Agent: n8n-nodes-schwab. - Users can add additional custom headers if needed.
Troubleshooting
Common issues:
- Missing or invalid OAuth2 credentials will cause authentication failures.
- Incorrectly formatted ISO-8601 timestamps for
fromEnteredTimeortoEnteredTimemay result in API errors or empty responses. - Not setting both
fromEnteredTimeandtoEnteredTimetogether could lead to incomplete filtering. - Exceeding the maximum allowed results without specifying
maxResultsmight cause performance issues or truncated data.
Error messages:
- Errors from the API are captured and returned in the output with details including HTTP status codes.
- Typical errors include authorization failures (401), bad requests due to invalid parameters (400), or server errors (500).
- When errors occur, enabling "Continue On Fail" allows the workflow to proceed while capturing error details per item.
Links and References
- Schwab Trader API Documentation (official API docs, requires login)
- ISO 8601 Date and Time Format
- n8n OAuth2 Credential Setup
If you need further details about other operations or resources, feel free to ask!