This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Thing < ActiveRecord::Base | |
class Create < Trailblazer::Operation | |
contract do | |
property :name | |
property :description | |
validates :name, presence: true | |
validates :description, length: {in: 4..160}, allow_blank: true end | |
def process(params) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Services | |
module Alacrity | |
extend self | |
# Services::Alacrity.create_claim | |
# | |
def create_claim | |
opts = { | |
claimNumber: 'AT0003', | |
zipCode: '97401', |