synchrone / google-auth-bash

dancing with google microservices since 2024

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Poor Man's Google Service Account Key

this converts your service account JSON key into a curl that gets an access token for brute access to GCP APIs in places where it's unfeasible to drag @google-cloud/* libraries

Usage

use it in your god-awful bash scripts

  • token="$(./get-token.js ~/Downloads/service-account-xxxxx.json | sh | jq '.access_token')"
  • curl -H "Authorization: Bearer ${token}" https://....

Google products outside Cloud Platform

About

dancing with google microservices since 2024


Languages

Language:JavaScript 100.0%