what is the correct syntax to pass input parameter

what is the correct syntax to pass the input parameter to the Application integration..

 

curl -X POST -H "Content-Type: application/json" -d '{
"trigger_id": "api_trigger/DBTest_API_1",
"inputParameters": {
"Input_request": {"entityId":"177"}
}
}' https://integrations.googleapis.com/v1/projects/svc-boomi-dev-05/locations/us-west2/integrations/DBT...

Getting error below


{
"error": {
"code": 401,
"message": "Request is missing required authentication credential. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.",
"status": "UNAUTHENTICATED",
"details": [
{
"@type": "type.googleapis.com/google.rpc.ErrorInfo",
"reason": "CREDENTIALS_MISSING",
"domain": "googleapis.com",
"metadata": {
"service": "integrations.googleapis.com",
"method": "google.cloud.integrations.v1alpha.Executions.ExecuteIntegrations"
}
}
]
}
}

Solved Solved
1 1 49
1 ACCEPTED SOLUTION

Hello @padmanabhamv,

Welcome to the Google Cloud Community!

The curl command you provided lacks an authentication method. To authenticate, you need to obtain an access token through the Google Cloud authentication process, which you can find here: Google Cloud Authentication. Include this access token in an Authorization header as shown below:

curl -X POST \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
-H "Content-Type: application/json; charset=utf-8" \
-d {'"displayName" : "DISPLAY_NAME"'} \
"https://apikeys.googleapis.com/v2/projects/PROJECT/locations/global/keys

For further details on how to create API keys using the REST API, please refer to Creating an API Key

View solution in original post

1 REPLY 1

Hello @padmanabhamv,

Welcome to the Google Cloud Community!

The curl command you provided lacks an authentication method. To authenticate, you need to obtain an access token through the Google Cloud authentication process, which you can find here: Google Cloud Authentication. Include this access token in an Authorization header as shown below:

curl -X POST \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
-H "Content-Type: application/json; charset=utf-8" \
-d {'"displayName" : "DISPLAY_NAME"'} \
"https://apikeys.googleapis.com/v2/projects/PROJECT/locations/global/keys

For further details on how to create API keys using the REST API, please refer to Creating an API Key