def create(identity_id = '', service = '', total_allowance = nil, analyze_queries = nil)
      fail BadParametersError, 'identity_id is required' if identity_id.empty?
      fail BadParametersError, 'service is required' if service.empty?
      fail BadParametersError, 'Must set total_allowance or analyze_queries' if
        total_allowance.nil? && analyze_queries.nil?
      params = { service: service }
      params[:total_allowance] = total_allowance unless total_allowance.nil?
      params[:analyze_queries] = analyze_queries unless analyze_queries.nil?

      DataSift.request(:POST, "account/identity/#{identity_id}/limit", @config, params)
    end
def create(identity_id = '', service = '', total_allowance = nil, analyze_queries = nil)
      fail BadParametersError, 'identity_id is required' if identity_id.empty?
      fail BadParametersError, 'service is required' if service.empty?
      fail BadParametersError, 'Must set total_allowance or analyze_queries' if
        total_allowance.nil? && analyze_queries.nil?
      params = { service: service }
      params[:total_allowance] = total_allowance unless total_allowance.nil?
      params[:analyze_queries] = analyze_queries unless analyze_queries.nil?

      DataSift.request(:POST, "account/identity/#{identity_id}/limit", @config, params)
    end
Creates a Limit for an Identity

 @param identity_id [String] ID of the Identity for which you are creating
   a limit
 @param service [String] The service this limit will apply to. For example;
   'facebook'
 @param total_allowance [Integer] (Optional) The daily interaction limit for this Identity
 @param analyze_queries [Integer] (Optional) The hourly analysis query limit for this Identity
 @return [Object] API reponse object