Skip to content
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

Google API, Base64 implementation + other goodies #2455

Merged
merged 19 commits into from
Sep 18, 2024

Conversation

engelhartrueben
Copy link
Collaborator

Fixes # (issue)

The previous implementation of the Google Import feature had the application use a rather large and uncomfortable JSON object that would be placed in the env as a string. This method often fractured, or introduced unexpected tokens in the object. This PR replaces GOOGLE_SECRET with BASE64_GOOGLE_SECRET.

Description

The Google Secrete JSON object will now be encoded in base64, representing important information such as the API private key and client email. Instructions have been added to the documentation for how to convert the JSON object directly to base64, a method I had to use to ensure that the JSON object is represented 1 to 1 when eventually parsed in the application.

Encoding private keys in base64 is also industry standard.

Other Goodies

Upgraded googleapis
Removed abortController for native support
Upgrade gitHub actions upload-artifact to V4 (V2 was deprecated June 30th, 2024)
Add spoke-pm2.config.js to .gitignore

Checklist:

  • I have manually tested my changes on desktop and mobile
  • The test suite passes locally with my changes
  • If my change is a UI change, I have attached a screenshot to the description section of this pull request
  • My change is 300 lines of code or less, or has a documented reason in the description why it’s longer
  • I have made any necessary changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • My PR is labeled [WIP] if it is in progress

@@ -127,7 +127,7 @@
"express": "^4.19.2",
"fs": "^0.0.2",
"google-libphonenumber": "^3.2.35",
"googleapis": "^39.2.0",
"googleapis": "^144.0.0",
Copy link
Member

Choose a reason for hiding this comment

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

😮 lol

Copy link
Member

@mau11 mau11 left a comment

Choose a reason for hiding this comment

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

🎉

@engelhartrueben engelhartrueben merged commit 6f6fd49 into stage-main-14.1 Sep 18, 2024
17 checks passed
@engelhartrueben engelhartrueben deleted the re/google-api-stuff branch September 18, 2024 18:58
@mau11 mau11 mentioned this pull request Sep 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: 14.1
Development

Successfully merging this pull request may close these issues.

2 participants