GET

/v1/schemas/cohere/chat/v1/generate

kind inputactivity chathash 4635ae08…extracted Aug 15, 2026version currentsource upstream spec ↗
fieldrecorded source
schemaSource linked above.

upstream-spec

Source trace
e567cbddb2cc3cbd6a156ba9d74213895fc4e6df55d489d401327ed177ab803b
{
  "fetchedAt": 1786771957,
  "extractorVersion": "1",
  "verifiedAt": null
}

Request body

17 properties · 1 required · 0 $defs
propertytypedescriptionconstraints
prompt*stringThe input text that serves as the starting point for generating the response. Note: The prompt will be pre-processed and modified before reaching the model.
modelstringThe identifier of the model to generate with. Currently available models are `command` (default), `command-nightly` (experimental), `command-light`, and `command-light-nightly` (experimental). Smaller, "light" models are faster, while larger models will perfor…
num_generationsintegerThe maximum number of generations that will be returned. Defaults to `1`, min value of `1`, max value of `5`.
streambooleanWhen `true`, the response will be a JSON stream of events. Streaming is beneficial for user interfaces that render the contents of the response piece by piece, as it gets generated.
max_tokensintegerThe maximum number of tokens the model will generate as part of the response. Note: Setting a low value may result in incomplete generations.
truncateenumOne of `NONE|START|END` to specify how the API will handle inputs longer than the maximum token length.NONE | START | END · default: "END"
temperaturenumberA non-negative float that tunes the degree of randomness in generation. Lower temperatures mean less random generations. See [Temperature](/temperature-wiki) for more details. Defaults to `0.75`, min value of `0.0`, max value of `5.0`.
seedintegerIf specified, the backend will make a best effort to sample tokens deterministically, such that repeated requests with the same seed and parameters should return the same result. However, determinism cannot be totally guaranteed. Compatible Deployments: Cohere…0 ≤ n ≤ 18446744073709552000
presetstringIdentifier of a custom preset. A preset is a combination of parameters, such as prompt, temperature etc. You can create presets in the [playground](https://dashboard.cohere.com/playground/generate). When a preset is specified, the `prompt` parameter becomes op…
end_sequencesstring[]The generated text will be cut at the beginning of the earliest occurrence of an end sequence. The sequence will be excluded from the text.
stop_sequencesstring[]The generated text will be cut at the end of the earliest occurrence of a stop sequence. The sequence will be included the text.
kintegerEnsures only the top `k` most likely tokens are considered for generation at each step. Defaults to `0`, min value of `0`, max value of `500`.
pnumberEnsures that only the most likely tokens, with total probability mass of `p`, are considered for generation at each step. If both `k` and `p` are enabled, `p` acts after `k`. Defaults to `0.75`. min value of `0.01`, max value of `0.99`.
frequency_penaltynumberUsed to reduce repetitiveness of generated tokens. The higher the value, the stronger a penalty is applied to previously present tokens, proportional to how many times they have already appeared in the prompt or prior generation.
presence_penaltynumberDefaults to `0.0`, min value of `0.0`, max value of `1.0`.
return_likelihoodsenumOne of `GENERATION|NONE` to specify how and if the token likelihoods are returned with the response. Defaults to `NONE`.GENERATION | ALL | NONE · default: "NONE"
raw_promptingbooleanWhen enabled, the user's prompt will be sent to the model without any pre-processing.

Validate a payload

before you spend tokens
shell
$ curl -X POST https://modelschemas.com/v1/validate \
    -d '{"provider":"cohere","endpointId":"v1/generate","payload":{…}}'
→ {"valid": false, "errors": [{"path": "#", "keyword": "required", …}]}