You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: usage_record.rb
    path of file: ./repos/xero-ruby/lib/xero-ruby/models/app_store
    
    the code of the file until where you have to start completion: =begin
#Xero AppStore API

#These endpoints are for Xero Partners to interact with the App Store
    
    def valid?
      return false if @quantity.nil?
      return false if @subscription_id.nil?
      return false if @subscription_item_id.nil?
      return false if @test_mode.nil?
      return false if @recorded_at.nil?
      return false if @usage_record_id.nil?
      return false if @price_per_unit.nil?
      return false if @product_id.nil?
      true
    end