Skip to content
FeedbackDashboard

Generate config suggestions

post/v0/projects/{project}/configs/guess
Generate suggestions for changes to config files based on an OpenAPI spec.
Path ParametersExpand Collapse
project: optional string
Body ParametersExpand Collapse
spec: string

OpenAPI spec

branch: optional string

Branch name

ReturnsExpand Collapse
content: string

The file content

Generate config suggestions
curl https://api.stainless.com/v0/projects/$PROJECT/configs/guess \
    -H 'Content-Type: application/json' \
    -H "Authorization: Bearer $STAINLESS_API_KEY" \
    -d '{
          "spec": "spec"
        }'
{
  "foo": {
    "content": "content"
  }
}
Returns Examples
{
  "foo": {
    "content": "content"
  }
}