INSR-110: Add USPS tracker registration API examples - #235
Conversation
Co-authored-by: Cursor <cursoragent@cursor.com>
Justin Hammond (Justintime50)
left a comment
There was a problem hiding this comment.
We typically do not document non-native API requests for each language lib. When there are (not yet) supported endpoints, we've historically only added the curl snippet and response examples.
Are there plans to add support for this to the libs? I've not heard of this endpoint yet.
Client libraries do not expose this endpoint yet; document curl and response examples only until native SDK support ships. Co-authored-by: Cursor <cursoragent@cursor.com>
|
Thanks Justin Hammond (@Justintime50) — agreed. I dropped the Python and Ruby request snippets and kept curl + JSON response examples only, matching the pattern used for other endpoints that are not yet in the client libraries (e.g. Lib support: This is a new public API (
Endpoint constant: We can add native SDK examples to this repo once those lib PRs land; until then docs will show curl only. |
Match other retrieve examples by documenting utr_... instead of a full sample id. Co-authored-by: Cursor <cursoragent@cursor.com>
Sam Guyette (sam-ep)
left a comment
There was a problem hiding this comment.
LGTM -- curl and json samples match the public api
|
Copilot review |
There was a problem hiding this comment.
🔵 Needs a closer look
Rename the response fixtures to the repository convention and add the missing has_more field.
Pull request overview
Adds cURL examples and sample JSON responses for USPS tracker registration create, list, and retrieve endpoints.
Changes:
- Added create, list, and retrieve cURL snippets.
- Added corresponding API response examples.
- Uses the curl-only convention pending official client-library support.
File summaries
| File | Summary |
|---|---|
official/docs/responses/usps-tracker-registrations/retrieve.json |
Retrieve response; filename requires convention correction. |
official/docs/responses/usps-tracker-registrations/list.json |
List response; filename and pagination flag require correction. |
official/docs/responses/usps-tracker-registrations/create.json |
Create response; filename requires convention correction. |
official/docs/curl/current/usps-tracker-registrations/retrieve.sh |
Retrieve request example. |
official/docs/curl/current/usps-tracker-registrations/list.sh |
List request example. |
official/docs/curl/current/usps-tracker-registrations/create.sh |
Create request example. |
Review details
Suppressed comments (4)
official/docs/responses/usps-tracker-registrations/create.json:1
- This response file's basename does not follow the repository's response convention: files under a resource directory are named
<resource>-<action>.json(for example,official/docs/responses/refunds/refunds-create.json), and the response builder derives that name intools/build_doc_json_responses/builder/snippets.py:99-110. As written, the docs consumer will not resolve this response alongside the newcreate.sh; rename it tousps-tracker-registrations-create.json.
{
official/docs/responses/usps-tracker-registrations/list.json:1
- This response file's basename does not follow the repository's response convention: files under a resource directory are named
<resource>-<action>.json(for example,official/docs/responses/refunds/refunds-list.json), and the response builder derives that name intools/build_doc_json_responses/builder/snippets.py:99-110. As written, the docs consumer will not resolve this response alongside the newlist.sh; rename it tousps-tracker-registrations-list.json.
{
official/docs/responses/usps-tracker-registrations/list.json:17
- This list response omits the standard
has_morepagination flag. The other paginated object-list fixtures include it (for example,official/docs/responses/refunds/refunds-list.json:15), and consumers need it to know whether another page is available. Add"has_more": false(or the actual value) after the array.
]
}
official/docs/responses/usps-tracker-registrations/retrieve.json:1
- This response file's basename does not follow the repository's response convention: files under a resource directory are named
<resource>-<action>.json(for example,official/docs/responses/refunds/refunds-retrieve.json), and the response builder derives that name intools/build_doc_json_responses/builder/snippets.py:99-110. As written, the docs consumer will not resolve this response alongside the newretrieve.sh; rename it tousps-tracker-registrations-retrieve.json.
{
- Files reviewed: 6/6 changed files
- Comments generated: 0
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Include recipient and mail_class fields in curl/response samples so docs match the API contract. Co-authored-by: Cursor <cursoragent@cursor.com>
|
Copilot review |
There was a problem hiding this comment.
🟡 Changes recommended
Critical response-file naming issues must be fixed before approval.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Review details
- Files reviewed: 6/6 changed files
- Comments generated: 3
- Review effort level: Lite
Co-authored-by: apeasypost <205667805+apeasypost@users.noreply.github.com>
|
Copilot review |
Re-ran final checks on the current branch state; no additional issues were found and no further changes are needed. |
There was a problem hiding this comment.
🟢 Approval recommended
Only a minor pagination-convention nit was identified; there are no approval-blocking issues.
Review details
Suppressed comments (1)
official/docs/curl/current/usps-tracker-registrations/list.sh:1
- The list cURL examples in this repository consistently bound the result set with
?page_size=5(for example,official/docs/curl/current/claims/list.sh:1andofficial/docs/curl/current/trackers/list.sh:1). Please include the same query parameter here so this canonical example follows the repository's pagination convention and does not rely on the endpoint's default page size.
curl -X GET https://api.easypost.com/v2/carrier_claims/usps_tracker_registrations \
- Files reviewed: 6/6 changed files
- Comments generated: 0 new
- Review effort level: Lite
Summary
Add canonical cURL request snippets and sample JSON responses for the USPS tracker registrations public API (INSR-110).
Python and Ruby request snippets are intentionally omitted until the endpoint ships in the official client libraries (curl + responses only, per repo convention).
Branch status: Already on latest
master; CI green.File changes
official/docs/curl/current/usps-tracker-registrations/create.shofficial/docs/curl/current/usps-tracker-registrations/list.shofficial/docs/curl/current/usps-tracker-registrations/retrieve.shofficial/docs/responses/usps-tracker-registrations/usps-tracker-registrations-create.jsonofficial/docs/responses/usps-tracker-registrations/usps-tracker-registrations-list.jsonofficial/docs/responses/usps-tracker-registrations/usps-tracker-registrations-retrieve.jsonRelease Test Plan
Stack (INSR-110)
claims_usps_standalone_trackers)ELIGIBLE(no standard USPS upload in phase 1)Phase 1: Monitor BYO-label USPS tracking →
ELIGIBLE/INELIGIBLE. Registrations do not enter the standard USPS claims upload pipeline;ELIGIBLErows remain until a future standalone filing flow ships.Jira: INSR-110
Related