Support

Documentation

8.2.Text generation endpoint

8.2.Text generation endpoint

URL

POST /api/v1/aitiny/generate

Parameters

All parameters are sent as form-encoded POST body fields:

useCase

Required. The use case identifier. Available values: gen (general content generation), proofread (proofreading), friendly (friendly rewrite), professional (professional rewrite), concise (concise rewrite), alt (alt text generation), metadesc (meta description generation), metakey (meta keywords generation), as well as any custom preset actions you have defined.

prompt

Required. The text prompt or content to process. For content generation this is your instruction to the AI. For proofreading and rewriting, this is the text to be processed.

tone

Optional. A tone of voice identifier (e.g. friendly_inclusive, straightforward_pragmatic, academic_scholarly, etc.). See the Tones of Voice section for all available identifiers.

context

Optional. An array of previous messages for conversational context (continue conversation feature).

Example request

POST /api/v1/aitiny/generate HTTP/1.1Host: www.example.comAuthorization: Bearer your_api_token_hereX-Joomla-Token: your_api_token_hereAccept: application/vnd.api+jsonContent-Type: application/x-www-form-urlencodeduseCase=gen&prompt=write+two+paragraphs+introducing+the+world+to+joomla

Response

The response follows the JSON API specification. The generated text is returned in the message attribute:

{  "links": {    "self": "https://www.example.com/api/v1/aitiny/generate"  },  "data": {    "type": "plg_system_aitiny.default",    "id": "",    "attributes": {      "message": "The generated text content goes here..."    }  }}