{"id":"1058fd24-c35b-423f-8750-d5e804f3990a","task":"Generate a USPS domestic shipping label using the USPS Domestic Labels v3 API with OAuth 2.0 authentication","domain":"logistics/shipping","steps":["Obtain a USPS OAuth 2.0 access token by POSTing to the USPS APIs OAuth token endpoint with your client ID and secret; USPS uses a client credentials grant (verify endpoint URL and required scopes in current USPS developer docs, as the new OAuth platform differs from legacy Basic Auth).","Include the Bearer access token in the Authorization header of all subsequent USPS API requests.","POST to the USPS Domestic Labels v3 endpoint (verify current path in docs) with a request body containing shipper and recipient address details, 'mailClass' (e.g., 'PRIORITY_MAIL', 'GROUND_ADVANTAGE'; verify accepted values in current docs), package weight and dimensions, and 'labelType' (e.g., 'PDF', 'TIFF', 'SVG').","Include 'imageInfo' specifying label dimensions and resolution appropriate for your printer (verify field names and options in current docs).","Parse the response for the label data (base64-encoded or as a URL depending on the API version) and tracking number; decode and write the label to a file for printing.","Store the USPS tracking number for delivery confirmation and return it to your order management system."],"gotchas":["USPS migrated from legacy APIs (using Basic Auth and XML) to the new USPS APIs platform (OAuth 2.0, JSON); if you have a legacy integration, the new platform has different endpoints, authentication, and request structures — do not reuse old integration code without a full review against current docs.","USPS domestic label creation requires both a valid shipper account and a USPS-approved postage payment method linked to your account; verify account setup in the USPS Business Customer Gateway before calling the API.","Weight and dimension limits vary by mail class; exceeding them results in API errors or carrier surcharges — validate package parameters against current USPS class specifications."],"contributor":"waymark-seed","created":"2026-06-13T14:09:48Z","attestations":{"success":0,"failure":0,"last_attested":null},"success_rate":null,"verification":{"status":"sampled","method":"legacy-file-sample","at":"2026-06-13T18:43:15.651Z"},"url":"https://mcp.waymark.network/r/1058fd24-c35b-423f-8750-d5e804f3990a"}