Generation

Generate structured JSON response

Generates structured JSON response from Claude CLI. The schema is passed in the request to instruct Claude to output valid JSON.

post/generate-object

Request body

systemstring
promptstring required
sessionIdstring
modelstring
allowedToolsstring[]
maxTokensinteger

Response

Successful object generation

{"stackTrail":"paths:/generate-object:post:responses:200:content:application/json:schema:properties:object","oasType":"schema","type":"unknown"}
rawTextstring required
sessionIdstring required

Changes

Changed in 6 of the 7 revisions of this API.41616

  • f7074f1efbee21See the full diff
    • added the new NO_TOOLS_AVAILABLE enum value to the code response property for the response status 400

      response-property-enum-value-added

    • added the new NO_TOOLS_AVAILABLE enum value to the code response property for the response status 500

      response-property-enum-value-added

    • added the new optional request property allowedTools

      new-optional-request-property

    • removed the request property userEmail

      request-property-removed

    • added the new optional request property schema/$ref

      new-optional-request-property

    • added the new optional request property schema/allOf

      new-optional-request-property

    • added the new optional request property schema/anyOf

      new-optional-request-property

    • added the new optional request property schema/const

      new-optional-request-property

    • added the new optional request property schema/enum

      new-optional-request-property

    • added the new optional request property schema/items

      new-optional-request-property

    • added the new optional request property schema/oneOf

      new-optional-request-property

    • added the new optional request property schema/properties

      new-optional-request-property

    • added the new optional request property schema/type

      new-optional-request-property

  • 5aa7ce43bc1211See the full diff
    • the maxTokens request property type/format changed from number/ to integer/

      request-property-type-changed

    • the maxTokens request property's exclusiveMinimum was set to 0.00

      request-property-exclusive-min-set

    • added the new CONCURRENCY_LIMIT_ERROR enum value to the code response property for the response status 400

      response-property-enum-value-added

    • added the new CONCURRENCY_LIMIT_ERROR enum value to the code response property for the response status 500

      response-property-enum-value-added

  • 62c4085e0ca03106See the full diff
    • the usage/inputTokens response's property type/format changed from integer/ to number/ for status 200

      response-property-type-changed

    • the usage/outputTokens response's property type/format changed from integer/ to number/ for status 200

      response-property-type-changed

    • the usage/totalTokens response's property type/format changed from integer/ to number/ for status 200

      response-property-type-changed

    • removed the request property allowedTools

      request-property-removed

    • removed the request property schema/$ref

      request-property-removed

    • removed the request property schema/allOf

      request-property-removed

    • removed the request property schema/anyOf

      request-property-removed

    • removed the request property schema/const

      request-property-removed

    • removed the request property schema/enum

      request-property-removed

    • removed the request property schema/items

      request-property-removed

    • removed the request property schema/oneOf

      request-property-removed

    • removed the request property schema/properties

      request-property-removed

    • removed the request property schema/type

      request-property-removed

    • added the new optional request property userEmail

      new-optional-request-property

    • the maxTokens request property type/format was generalized from integer/ to number/

      request-property-type-generalized

    • removed the CONCURRENCY_LIMIT_ERROR enum value from the code response property for the response status 400

      response-property-enum-value-removed

    • removed the CONCURRENCY_LIMIT_ERROR enum value from the code response property for the response status 500

      response-property-enum-value-removed

    • removed the NO_TOOLS_AVAILABLE enum value from the code response property for the response status 400

      response-property-enum-value-removed

    • removed the NO_TOOLS_AVAILABLE enum value from the code response property for the response status 500

      response-property-enum-value-removed

    This revision also has 1 change that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog