I just signed up to Doppler and am trying to retrieve a secret value.
I created a new project named trevor
. Under the prd
config, I added a secret named TEST_SECRET
.
Then, under the Access tab, I generated a Service Token for the prd
config.
I used the documentation for Secret → Retrieve, to get the PowerShell code snippet to grab the secret value.
$headers=@{}
$headers.Add("accept", "application/json")
$headers.Add("authorization", "Bearer xxxxxxxxxxxxxxxx")
$response = Invoke-WebRequest -Uri 'https://api.doppler.com/v3/configs/config/secret?project=trevor&config=prd&name=TEST_SECRET' -Method GET -Headers $headers
All I get in response is:
{
"messages": [
"Invalid Auth token"
],
"success": false
}
How do I successfully retrieve a secret? Seems like this should be pretty straightforward.