docbrown/db/migrate/20190819104106_create_webhook_endpoints.rb
2019-08-29 10:23:41 -04:00

12 lines
344 B
Ruby

class CreateWebhookEndpoints < ActiveRecord::Migration[5.2]
def change
create_table :webhook_endpoints do |t|
t.string :target_url, null: false
t.string :events, null: false, array: true
t.references :user, foreign_key: true, null: false
t.string :source
t.timestamps
t.index :events
end
end
end