Skip to contents

A function that sends a request to the Google AI Studio API and returns the response.

Usage

query_api_google(model, request_body, key = Sys.getenv("GOOGLE_API_KEY"))

Arguments

model

A character string that specifies the model to send to the API.

request_body

A list that contains the parameters for the task.

key

String containing a Google AI Studio API key. Defaults to the GOOGLE_API_KEY environmental variable if not specified.

Value

The response from the API.