Skip to content

feat: Allow str values for since_id in GetEventsRequest model #587

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

dtatarkin
Copy link
Contributor

Allow str values for since_id and until_id in GetEventsRequest to handle ULID id types.

E.g. endpoint https://broker-api.sandbox.alpaca.markets/v2/events/trades requires string as since_id and until_id query params

@dtatarkin dtatarkin requested a review from hiohiohio as a code owner April 17, 2025 19:53
Comment on lines +990 to +991
since_id: Optional[Union[int, str]] = None
until_id: Optional[Union[int, str]] = None
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for this PR. I have commented similar to the other PR: #588 (comment) .
I feel this change might make us hard to remove a method calling deprecated API endpoint. Therefore, prefer to have separate set of method/request/response models instead of making existing one compatible. It is hard to migrate to a new version seamlessly. Therefore, prefer to provide a chance to notice of deprecated method/request/response models for the upcoming removing of them.

Copy link

This PR is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.

@github-actions github-actions bot added the Stale label May 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants