createTheme method

Future<Result<ThemeBase>> createTheme({
  1. required String slug,
  2. required String title,
  3. InputDocumentBase? document,
  4. List<InputThemeSettingsBase>? settings,
})

Create Theme.

ID: 652e4400.

Implementation

Future<Result<ThemeBase>> createTheme({
  required String slug,
  required String title,
  InputDocumentBase? document,
  List<InputThemeSettingsBase>? settings,
}) async {
  // Preparing the request.
  final request = AccountCreateTheme(
    slug: slug,
    title: title,
    document: document,
    settings: settings,
  );

  // Invoke and wait for response.
  final response = await _c.invoke(request);

  // Return the result.
  return response._to<ThemeBase>();
}