API → AIGenerate code completions for KCL
beta

Parameters

Name

Type

Req.

Returns

  • 201 Created

    successful creation

    Name

    Type

    Req.

    body

    object
    optional
    Object Properties
post
/ai/kcl/completions
$ curl -X POST "https://api.zoo.dev/ai/kcl/completions" \
	--header "Authorization: Bearer $TOKEN" \
	--header "Content-Type: application/json" \
	--data '{
  "extra": {
    "language": "BN8A5r1HdQOI",
    "next_indent": 2,
    "prompt_tokens": 21,
    "suffix_tokens": 19,
    "trim_by_indentation": true
  },
  "max_tokens": 26,
  "n": 17,
  "nwo": "KfbgTl31R",
  "prompt": "WCXH3xKB1r",
  "stop": [
    "G"
  ],
  "stream": true,
  "suffix": "nY2SXHQoaXpp",
  "temperature": 8,
  "top_p": 18
}'
201 Created
Response
{
  "completions": [
    "6CHgjKEdtALHaIj3DymVr4lesqu"
  ]
}