Generate Post

This functionality allows the user to generate post suitable for social media platform starting from a small description. A

Set of parameters are available that enables some customization.

Parameter
Type
Description

text

string

Description for the generated article

lanaguage

English | Arabic

platforms

(FACEBOOK | INSTAGRAM | X | YOUTUBE)[]

model

GPT_35 | GPT_4O

notes

FORMAL | INFORMATIVE | INSPIRATIONAL

import { AIService } from '@tradinos/cms-backend-ai';

export class AIController {
  constructor(private readonly _ai: AIService) {}

  @Post('post')
  generatePost(@Body() body: /** */) {
      return this._ai.generatePost({
          text: body.text,
          model: body.model,
          platforms: body.platforms,
          language: body.language,
          notes: body.notes,
        });
  }
}

Last updated