lib/revrise/track.rb in revrise-0.0.1 vs lib/revrise/track.rb in revrise-0.0.2
- old
+ new
@@ -1,23 +1,11 @@
-module Fortnox
- class Track < API
- class << self
- def create(attributes={})
- attributes = attributes.reject { |k,v| k == :id } if attributes[:id]
+require 'net/http'
+require 'json'
- response = run(:post, :set_contact, with_root(attributes))
- response['result'] ? response['result']['id'].to_i : false
- end
-
- def update(attributes={})
- response = run :post, :set_contact, with_root(attributes)
- response['result'] ? response['result']['id'].to_i : false
- end
-
- private
-
- def with_root(attributes)
- {:contact => attributes}
- end
+module RevRise
+ class Track < API
+ def initialize( token )
+ @endpoint = "http://api.revrise.com"
end
+
end
end