Adding get_for_service_account_json function in credentials.#641
Merged
Conversation
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
Contributor
|
This LGTM. That said - I think it'd be useful to add an example which would ideally go in a separate "auth" section in the docs. Do we have an open issue for that or should I create one? |
Contributor
Author
|
#633 is the issue, I actually have a branch I've been working on for awhile, I just keep getting sidetracked on it. |
Contributor
Author
|
Renamed to |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
Contributor
|
LGTM after pep8 passes. |
Was private_key_path.
dhermes
added a commit
that referenced
this pull request
Feb 15, 2015
Adding get_for_service_account_json function in credentials.
vchudnov-g
pushed a commit
that referenced
this pull request
Sep 20, 2023
* feat: added dialogflow_assist_answer feat: added session_ttl feat: added human_agent_side_config feat: added suggestion_input feat: added suggest_dialogflow_assists_response feat: added suggest_entity_extraction_response PiperOrigin-RevId: 542021587 Source-Link: googleapis/googleapis@f40416d Source-Link: googleapis/googleapis-gen@04ca491 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiMDRjYTQ5MWRlYzhmMzUxNzNlZTU5OWQ3ZWQwNzkzNmI0MDg2ZTk2ZCJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * feat: added dialogflow_assist_answer feat: added session_ttl feat: added human_agent_side_config feat: added suggestion_input feat: added suggest_dialogflow_assists_response feat: added suggest_entity_extraction_response PiperOrigin-RevId: 542024928 Source-Link: googleapis/googleapis@06f7999 Source-Link: googleapis/googleapis-gen@0f124f3 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiMGYxMjRmM2MzN2I1YTYwNDk5MDZhOTUxNGNkOTk0ZGFmMDczZGMwMSJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --------- Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
parthea
pushed a commit
that referenced
this pull request
Sep 18, 2025
Source-Link: googleapis/synthtool@cb96037 Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-python:latest@sha256:2d816f26f728ac8b24248741e7d4c461c09764ef9f7be3684d557c9632e46dbd Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
parthea
pushed a commit
that referenced
this pull request
Nov 24, 2025
The return type is an Awaitable that produces an AsyncIterator.
parthea
pushed a commit
that referenced
this pull request
Nov 24, 2025
- [ ] Regenerate this pull request now. PiperOrigin-RevId: 473833416 Source-Link: googleapis/googleapis@565a550 Source-Link: googleapis/googleapis-gen@1ee1a06 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiMWVlMWEwNmM2ZGUzY2E4Yjg0MzU3MmMxZmRlMDU0OGY4NDIzNjk4OSJ9 feat: add firestore aggregation query apis to the stable googleapis branch PiperOrigin-RevId: 473753776 Source-Link: googleapis/googleapis@a8c6c7c Source-Link: googleapis/googleapis-gen@6e3b0d6 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiNmUzYjBkNmVhZDQyNjVjYTZmMGFkM2UxODI5ZjRlM2E1YmMxMDlhMiJ9
parthea
pushed a commit
that referenced
this pull request
Nov 24, 2025
Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
parthea
pushed a commit
that referenced
this pull request
Nov 25, 2025
Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
parthea
pushed a commit
that referenced
this pull request
Nov 26, 2025
🤖 I have created a release \*beep\* \*boop\* --- ## [1.23.0](https://www.github.com/googleapis/google-auth-library-python/compare/v1.22.1...v1.23.0) (2020-10-29) ### Features * Add custom scopes for access tokens from the metadata service ([#633](https://www.github.com/googleapis/google-auth-library-python/issues/633)) ([0323cf3](https://www.github.com/googleapis/google-auth-library-python/commit/0323cf390b16e8483660ac88775e8ea4e7f7702d)) ### Bug Fixes * **deps:** Revert "fix: pin 'aoihttp < 3.7.0dev' ([#634](https://www.github.com/googleapis/google-auth-library-python/issues/634))" ([#632](https://www.github.com/googleapis/google-auth-library-python/issues/632)) ([#640](https://www.github.com/googleapis/google-auth-library-python/issues/640)) ([b790e65](https://www.github.com/googleapis/google-auth-library-python/commit/b790e6535cc37591b23866027a426cde312e07c1)) * pin 'aoihttp < 3.7.0dev' ([#634](https://www.github.com/googleapis/google-auth-library-python/issues/634)) ([05f9524](https://www.github.com/googleapis/google-auth-library-python/commit/05f95246fab928fe2f445781117eeac8088497fb)) * remove checks for ancient versions of Cryptography ([#596](https://www.github.com/googleapis/google-auth-library-python/issues/596)) ([6407258](https://www.github.com/googleapis/google-auth-library-python/commit/6407258956ec42e3b722418cb7f366e5ae9272ec)), closes [/github.com/googleapis/google-auth-library-python/issues/595#issuecomment-683903062](https://www.github.com/googleapis//github.com/googleapis/google-auth-library-python/issues/595/issues/issuecomment-683903062) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please).
parthea
pushed a commit
that referenced
this pull request
Mar 6, 2026
parthea
pushed a commit
that referenced
this pull request
Mar 6, 2026
…n use by another test (#641) * test: fix run testing worker code to reduce the chance of same instance id being used by different workers * fix: remove delete of instance if it already exists, as it might be in use by another test
parthea
pushed a commit
that referenced
this pull request
Mar 9, 2026
* docs: add section for more examples * docs: revise example usage
parthea
pushed a commit
that referenced
this pull request
Mar 9, 2026
🤖 I have created a release \*beep\* \*boop\* --- ## [1.43.0](https://www.github.com/googleapis/python-storage/compare/v1.42.3...v1.43.0) (2021-11-15) ### Features * add ignore_flush parameter to BlobWriter ([#644](https://www.github.com/googleapis/python-storage/issues/644)) ([af9c9dc](https://www.github.com/googleapis/python-storage/commit/af9c9dc83d8582167b74105167af17c9809455de)) * add support for Python 3.10 ([#615](https://www.github.com/googleapis/python-storage/issues/615)) ([f81a2d0](https://www.github.com/googleapis/python-storage/commit/f81a2d054616c1ca1734997a16a8f47f98ab346b)) ### Bug Fixes * raise a ValueError in BucketNotification.create() if a topic name is not set ([#617](https://www.github.com/googleapis/python-storage/issues/617)) ([9dd78df](https://www.github.com/googleapis/python-storage/commit/9dd78df444d21af51af7858e8958b505a26c0b79)) ### Documentation * add contributing and authoring guides under samples/ ([#633](https://www.github.com/googleapis/python-storage/issues/633)) ([420591a](https://www.github.com/googleapis/python-storage/commit/420591a2b71f823dbe80f4a4405d8a514f87e0fb)) * add links to samples and how to guides ([#641](https://www.github.com/googleapis/python-storage/issues/641)) ([49f78b0](https://www.github.com/googleapis/python-storage/commit/49f78b09fed6d9f486639fd0a72542c30a0df084)) * add README to samples subdirectory ([#639](https://www.github.com/googleapis/python-storage/issues/639)) ([58af882](https://www.github.com/googleapis/python-storage/commit/58af882c047c31f59486513c568737082bca6350)) * update samples readme with cli args ([#651](https://www.github.com/googleapis/python-storage/issues/651)) ([75dda81](https://www.github.com/googleapis/python-storage/commit/75dda810e808074d18dfe7915f1403ad01bf2f02)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
parthea
added a commit
that referenced
this pull request
Mar 9, 2026
parthea
added a commit
that referenced
this pull request
Mar 9, 2026
* chore: changing default region to us-west1 * chore(deps): update all dependencies (#602) * chore: add default_version and codeowner_team to .repo-metadata.json (#641) * feat(db_api): support stale reads (#584) * feat: removing changes from samples * chore: change region * fix: fix in sample list-backups Co-authored-by: WhiteSource Renovate <bot@renovateapp.com> Co-authored-by: Anthonios Partheniou <partheniou@google.com> Co-authored-by: Ilya Gurov <ilya.faer@mail.ru> Co-authored-by: larkee <31196561+larkee@users.noreply.github.com>
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.
Fixes #638.
@jgeewax PTAL
I thought about wrapping JSON key and PKCS12 key into one method but the JSON key is actual a JSON payload with everything needed, e.g.
{ "private_key_id": "0996.....", "private_key": "-----BEGIN PRIVATE KEY-----\nMIICdgIBADA.....\n-----END PRIVATE KEY-----\n", "client_email": "32578400.......@developer.gserviceaccount.com", "client_id": "32578400.........apps.googleusercontent.com", "type": "service_account" }whereas a P12 key is just the bytes in
private_key(and created for PKCS12 rather than PEM).I don't think it's worth trying to smash together the two API surfaces: