module.exports = {
  up(queryInterface, Sequelize) {
    return queryInterface.createTable('user_subscriptions', {
      id: {
        type: Sequelize.INTEGER,
        primaryKey: true,
        autoIncrement: true
      },
      userId: {
        type: Sequelize.INTEGER,
        required: true
      },
      updatedAt: Sequelize.DATE,
      createdAt: Sequelize.DATE,
      premium: {
        type: Sequelize.STRING(191),
        default: "Free",
        unique: false,
      },
      premiumType: {
        type: Sequelize.INTEGER,
        default: false,
        unique: false,
      },
      cancelledAt: {
        type: Sequelize.DATE,
        default: false,
        unique: false,
      },
      subscriptionStart: {
        type: Sequelize.DATE,
        default: false,
        unique: false,
      },
      subscriptionEnd: {
        type: Sequelize.DATE,
        default: false,
        unique: false,
      },
      paymentMethodID: {
        type: Sequelize.INTEGER,
        default: false,
        unique: false,
      }
    })
  }
}
