Implement headless USPS in-person proofing (LG-3855)#4523
Merged
mitchellhenke merged 5 commits intomasterfrom Dec 21, 2020
Merged
Implement headless USPS in-person proofing (LG-3855)#4523mitchellhenke merged 5 commits intomasterfrom
mitchellhenke merged 5 commits intomasterfrom
Conversation
zachmargolis
approved these changes
Dec 21, 2020
Contributor
zachmargolis
left a comment
There was a problem hiding this comment.
LGTM! thanks for the YARD documentation too!!
| password: AppConfig.env.usps_ipp_password, | ||
| grant_type: 'implicit', | ||
| response_type: 'token', | ||
| client_id: '424ada78-62ae-4c53-8e3a-0b737708a9db', |
Contributor
There was a problem hiding this comment.
can we make this a config as well?
Contributor
Author
There was a problem hiding this comment.
I don't think it changes as I understand it. Any IPP API will use that client_id.
Co-authored-by: Zach Margolis <zachmargolis@users.noreply.github.com>
Comment on lines
+68
to
+75
| PostOffice.new( | ||
| post_office['distance'], | ||
| post_office['streetAddress'], | ||
| post_office['city'], | ||
| post_office['phone'], | ||
| post_office['name'], | ||
| post_office['zip5'], | ||
| post_office['state'], |
Contributor
There was a problem hiding this comment.
I'd recommend keyword_init: true on the struct so we don't have to worry about ordering changes:
PostOffice.new(
distance: post_office['distance'],
address: post_office['street_address'],
# etc ...
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The aim was to be able to make the API calls that we'd use during the course of someone in-person proofing, and document some of the more surprising parts of the API to better prepare for the future integration. I wanted to keep it small and self-contained, so it notably doesn't subclass
Prooferand the token storage is not intuitive.