trident_generator

trident_generator can generate restful api by simple ways, use with trident, a example is telebot(https://pub .dev/packages/telebot).

Part Example from telebot

@Trident()
abstract class TelegramBotClient {
  
  @GET("/getUpdates")
  Future<List<Update>> getUpdates(
      {@Query("offset") int offset,
      @Query("limit") int limit,
      @Query("timeout") int timeout,
      @Query("allowed_updates") List<String> allowedUpdates});

  @GET("/setWebhook")
  Future<bool> setWebhook(
      {@Query("url") @required String url,
      @Query("certificate") File certificate,
      @Query("max_connections") int maxConnections,
      @Query("allowed_updates") List<String> allowedUpdates});

  @GET("/deleteWebhook")
  Future<bool> deleteWebhook();

  @GET("/getWebhookInfo")
  Future<WebhookInfo> getWebhookInfo();

  @GET("/getMe")
  Future<User> getMe();
}

Libraries

trident_builder.builder
trident_generator