toJson method

  1. @override
Map<String, dynamic> toJson()
override

Implementation

@override
Map<String, dynamic> toJson() => {
      "format": {
        'type': 'json_schema',
        'name': name,
        'schema': schema,
        if (description != null) 'description': description,
        if (strict != null) 'strict': strict,
      }
    };