toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  final json = <String, dynamic>{};
  json[r'object'] = this.object;
  json[r'id'] = this.id;
  json[r'name'] = this.name;
  json[r'key'] = this.key;
  if (this.description != null) {
    json[r'description'] = this.description;
  } else {
    json[r'description'] = null;
  }
  json[r'roles'] = this.roles;
  if (this.defaultRole != null) {
    json[r'default_role'] = this.defaultRole;
  } else {
    json[r'default_role'] = null;
  }
  if (this.creatorRole != null) {
    json[r'creator_role'] = this.creatorRole;
  } else {
    json[r'creator_role'] = null;
  }
  json[r'type'] = this.type;
  if (this.roleSetMigration != null) {
    json[r'role_set_migration'] = this.roleSetMigration;
  } else {
    json[r'role_set_migration'] = null;
  }
  json[r'created_at'] = this.createdAt;
  json[r'updated_at'] = this.updatedAt;
  return json;
}