feat(sdks): update pagination field naming and Python overlay configuration#634
Conversation
…ration - Make pagination fixes overlay Python-only (TypeScript/Go use next/prev, Python uses next_cursor/prev_cursor) - Update Python gen.yaml: add requestBodyFieldName: params, remove next from allowedRedefinedBuiltins - Update pagination-fixes-overlay.yaml: rename query parameters to next_cursor/prev_cursor for Python - Update upgrade guide: document pagination field naming changes for all SDKs - Update workflow.yaml: create separate Python source with pagination overlay Breaking changes: - TypeScript v0.6.0 and Go v0.5.0: nextCursor/prevCursor → next/prev - Python v0.5.0: continues using next_cursor/prev_cursor
…pdate # Conflicts: # .speakeasy/workflow.lock
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
Pull request overview
This PR updates SDK pagination field naming to be consistent across languages while avoiding Python built-in conflicts. It introduces a Python-specific source configuration that applies a pagination overlay to rename next/prev to next_cursor/prev_cursor for Python SDK only.
Changes:
- Created separate "Outpost API (Python)" source in workflow.yaml with pagination-fixes-overlay.yaml
- Updated pagination-fixes-overlay.yaml to rename query parameters and response properties for Python
- Updated Python SDK version from 0.6.0 to 0.5.0
- Added upgrade guide documentation for pagination field naming changes
Reviewed changes
Copilot reviewed 4 out of 5 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| sdks/schemas/pagination-fixes-overlay.yaml | Added query parameter renames for /tenants, /tenants/{tenant_id}/events, and /tenants/{tenant_id}/destinations/{destination_id}/events endpoints; updated pagination configuration to use next_cursor |
| sdks/outpost-python/.speakeasy/gen.yaml | Downgraded Python SDK version from 0.6.0 to 0.5.0 |
| docs/pages/guides/upgrade-v0.12.mdx | Added comprehensive documentation for pagination field naming changes with examples and migration guidance |
| .speakeasy/workflow.yaml | Created separate "Outpost API (Python)" source with pagination overlay; updated Python target to use new source |
| .speakeasy/workflow.lock | Updated source digests and references to reflect workflow changes |
Comments suppressed due to low confidence (2)
sdks/schemas/pagination-fixes-overlay.yaml:90
- The pagination configuration references
$.nextin the outputs, but the overlay renames the response property tonext_cursor. This should be$.next_cursorto match the renamed field.
nextCursor: $.next
sdks/schemas/pagination-fixes-overlay.yaml:109
- The pagination configuration references
$.nextin the outputs, but the overlay renames the response property tonext_cursor. This should be$.next_cursorto match the renamed field.
nextCursor: $.next
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
@leggetter I've opened a new pull request, #635, to work on those changes. Once the pull request is ready, I'll request review from you. |
Summary
This PR updates SDK pagination field naming to be consistent across languages while avoiding Python built-in conflicts.
Changes
next/prev(OpenAPI-defined names)next_cursor/prev_cursor(avoids Python built-innext()conflict)requestBodyFieldName: paramsnextfromallowedRedefinedBuiltins(now handled via overlay)next_cursor/prev_cursorfor PythonBreaking Changes
nextCursor/prevCursor→next/previn response objectsnext_cursor/prev_cursorTesting