{"files":{"SKILL.md":"---\nname: groqcloud-api-swagger\ndescription: \"GroqCloud API Swagger API skill. Use when working with GroqCloud API Swagger for openai. Covers 7 endpoints.\"\nversion: 1.0.0\ngenerator: lapsh\n---\n\n# GroqCloud API Swagger\nAPI version: 2.0\n\n## Auth\nBearer bearer\n\n## Base URL\nhttps://api.groq.com\n\n## Setup\n1. Set Authorization header with Bearer token\n2. GET /openai/v1/models -- list models\n3. POST /openai/v1/audio/transcriptions -- create first transcription\n\n## Endpoints\n7 endpoints across 1 group. See references/api-spec.lap for full details.\n\n### Openai\n| Method | Path | Description |\n|--------|------|-------------|\n| POST | /openai/v1/audio/transcriptions | Transcribes audio into the input language. |\n| POST | /openai/v1/audio/translations | Translates audio into English. |\n| POST | /openai/v1/chat/completions | Creates a model response for the given chat conversation. |\n| POST | /openai/v1/embeddings | Creates an embedding vector representing the input text. |\n| GET | /openai/v1/models | List models |\n| DELETE | /openai/v1/models/{model} | Delete model |\n| GET | /openai/v1/models/{model} | Get model |\n\n## Common Questions\nMatch user requests to endpoints in references/api-spec.lap. Key patterns:\n- \"Create a transcription?\" -> POST /openai/v1/audio/transcriptions\n- \"Create a translation?\" -> POST /openai/v1/audio/translations\n- \"Create a completion?\" -> POST /openai/v1/chat/completions\n- \"Create a embedding?\" -> POST /openai/v1/embeddings\n- \"List all models?\" -> GET /openai/v1/models\n- \"Delete a model?\" -> DELETE /openai/v1/models/{model}\n- \"Get model details?\" -> GET /openai/v1/models/{model}\n- \"How to authenticate?\" -> See Auth section above\n\n## Response Tips\n- Check response schemas in references/api-spec.lap for field details\n- Create/update endpoints return the modified resource on success\n\n## References\n- Full spec: See references/api-spec.lap for complete endpoint details, parameter tables, and response schemas\n\n> Generated from the official API spec by [LAP](https://lap.sh)\n","references/api-spec.lap":"@lap v0.3\n# Machine-readable API spec. Each @endpoint block is one API call.\n@api GroqCloud API Swagger\n@base https://api.groq.com\n@version 2.0\n@auth Bearer bearer\n@endpoints 7\n@toc openai(7)\n\n@endpoint POST /openai/v1/audio/transcriptions\n@desc Transcribes audio into the input language.\n@returns(200) {text: str} # OK\n\n@endpoint POST /openai/v1/audio/translations\n@desc Translates audio into English.\n@returns(200) {text: str} # OK\n\n@endpoint POST /openai/v1/chat/completions\n@desc Creates a model response for the given chat conversation.\n@required {messages: [any] # A list of messages comprising the conversation so far., model: any # ID of the model to use. For details on which models are compatible with the Chat API, see available [models](/docs/models)}\n@optional {frequency_penalty: num=0 # Number between -2.0 and 2.0. Positive values penalize new tokens based on their existing frequency in the text so far, decreasing the model's likelihood to repeat the same line verbatim., function_call: any # Deprecated in favor of `tool_choice`.  Controls which (if any) function is called by the model. `none` means the model will not call a function and instead generates a message. `auto` means the model can pick between generating a message or calling a function. Specifying a particular function via `{\"name\": \"my_function\"}` forces the model to call that function.  `none` is the default when no functions are present. `auto` is the default if functions are present., functions: [map{description: str, name!: str, parameters: map}] # Deprecated in favor of `tools`.  A list of functions the model may generate JSON inputs for., logit_bias: map=null # This is not yet supported by any of our models. Modify the likelihood of specified tokens appearing in the completion., logprobs: bool=false # This is not yet supported by any of our models. Whether to return log probabilities of the output tokens or not. If true, returns the log probabilities of each output token returned in the `content` of `message`., max_tokens: int # The maximum number of tokens that can be generated in the chat completion. The total length of input tokens and generated tokens is limited by the model's context length., n: int=1 # How many chat completion choices to generate for each input message. Note that the current moment, only n=1 is supported. Other values will result in a 400 response., parallel_tool_calls: bool=true # Whether to enable parallel function calling during tool use., presence_penalty: num=0 # Number between -2.0 and 2.0. Positive values penalize new tokens based on whether they appear in the text so far, increasing the model's likelihood to talk about new topics., response_format: map{type: str} # An object specifying the format that the model must output.   Setting to `{ \"type\": \"json_object\" }` enables JSON mode, which guarantees the message the model generates is valid JSON.  **Important:** when using JSON mode, you **must** also instruct the model to produce JSON yourself via a system or user message., seed: int # If specified, our system will make a best effort to sample deterministically, such that repeated requests with the same `seed` and parameters should return the same result. Determinism is not guaranteed, and you should refer to the `system_fingerprint` response parameter to monitor changes in the backend., stop: any=null # Up to 4 sequences where the API will stop generating further tokens. The returned text will not contain the stop sequence., stream: bool=false # If set, partial message deltas will be sent. Tokens will be sent as data-only [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format) as they become available, with the stream terminated by a `data: [DONE]` message. [Example code](/docs/text-chat#streaming-a-chat-completion)., temperature: num=1 # What sampling temperature to use, between 0 and 2. Higher values like 0.8 will make the output more random, while lower values like 0.2 will make it more focused and deterministic. We generally recommend altering this or top_p but not both, tool_choice: any # Controls which (if any) tool is called by the model. `none` means the model will not call any tool and instead generates a message. `auto` means the model can pick between generating a message or calling one or more tools. `required` means the model must call one or more tools. Specifying a particular tool via `{\"type\": \"function\", \"function\": {\"name\": \"my_function\"}}` forces the model to call that tool.  `none` is the default when no tools are present. `auto` is the default if tools are present., tools: [map{function!: map, type!: str}] # A list of tools the model may call. Currently, only functions are supported as a tool. Use this to provide a list of functions the model may generate JSON inputs for. A max of 128 functions are supported., top_logprobs: int # This is not yet supported by any of our models. An integer between 0 and 20 specifying the number of most likely tokens to return at each token position, each with an associated log probability. `logprobs` must be set to `true` if this parameter is used., top_p: num=1 # An alternative to sampling with temperature, called nucleus sampling, where the model considers the results of the tokens with top_p probability mass. So 0.1 means only the tokens comprising the top 10% probability mass are considered. We generally recommend altering this or temperature but not both., user: str # A unique identifier representing your end-user, which can help us monitor and detect abuse.}\n@returns(200) {choices: [map], created: int, id: str, model: str, object: str, system_fingerprint: str, usage: map{completion_time: num, completion_tokens: int, prompt_time: num, prompt_tokens: int, queue_time: num, total_time: num, total_tokens: int}} # OK\n\n@endpoint POST /openai/v1/embeddings\n@desc Creates an embedding vector representing the input text.\n@required {input: any # Input text to embed, encoded as a string or array of tokens. To embed multiple inputs in a single request, pass an array of strings or array of token arrays. The input must not exceed the max input tokens for the model, cannot be an empty string, and any array must be 2048 dimensions or less., model: any # ID of the model to use.}\n@optional {encoding_format: str(float/base64)=float # The format to return the embeddings in. Can only be `float` or `base64`., user: str # A unique identifier representing your end-user, which can help us monitor and detect abuse.}\n@returns(200) {data: [map], model: str, object: str, usage: map{prompt_tokens: int, total_tokens: int}} # OK\n\n@endpoint GET /openai/v1/models\n@desc List models\n@returns(200) {data: [any], object: str} # OK\n\n@endpoint DELETE /openai/v1/models/{model}\n@desc Delete model\n@required {model: str # The model to delete}\n@returns(200) {deleted: bool, id: str, object: str} # OK\n\n@endpoint GET /openai/v1/models/{model}\n@desc Get model\n@required {model: str # The model to get}\n@returns(200) {created: int, id: str, object: str, owned_by: str} # OK\n\n@end\n"}}