frederick_api 0.1.2 → 0.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 49e604b17a3e27bba56beaa861431ad3cf06b880
4
- data.tar.gz: 65d4d51f7e6d34cd7a67f5b8292c104253c4b52b
3
+ metadata.gz: ee366b5f2850705f2f10fe5109a9407da890a1f5
4
+ data.tar.gz: e42fcbac6a892638da9fd39ffdeec4270ab7b752
5
5
  SHA512:
6
- metadata.gz: 14df284fcec910ee7a9769f734944cd577cacff9b94b619cbead4eb8a6b743ff5aab90c21f05e1683fd59511d67e295b2bef60e3b451b5188126164e4aab8d16
7
- data.tar.gz: 432864cd9629aa3575a230750f8bcb756f9089acdaaad201f3cf96789369076ec968193e4ab2d2cf0650ee516305da460879e53f9bcf19986ba10e278ea9d610
6
+ metadata.gz: f10057c5c901a53eea6a345b26268ed0eaa9031d53e430e4af172e2c6ccd0aade5e47c58b6a7848112d5c1a81848d1ed7e44c826600007fb9c7e83df6146ba6e
7
+ data.tar.gz: 23f43c15957daa32d722c8f91a9b2c7c9fe3f49e80ad29eefcf5c4a978841b904b1ef2ccd15d8b00f40ae8e8ff536bbbe0871837ff80bdc35dd26ec41df04060
data/README.md CHANGED
@@ -78,8 +78,8 @@ FrederickAPI::V2::Location.with_access_token(access_token) do
78
78
  location.save
79
79
  # => true
80
80
 
81
- # To instantiate a resource for update without fetching it first, set an id
82
- location = FrederickAPI::V2::Location.new(id: location_id)
81
+ # To instantiate a resource for update without fetching it first, use `.load` with id
82
+ location = FrederickAPI::V2::Location.load(id: location_id)
83
83
  location.update_attributes(phone_number: '(555) 555-5555')
84
84
  # => true
85
85
  end
@@ -97,4 +97,4 @@ FrederickAPI::V2::Location.with_access_token(access_token) do
97
97
  contacts = FrederickAPI::V2::Contact.where(location_id: location_id).page(1).per(100).to_a
98
98
  # => [...]
99
99
  end
100
- ```
100
+ ```
@@ -5,6 +5,7 @@ module FrederickAPI
5
5
  # /v2/locations/:location_id/contacts
6
6
  class Contact < Resource
7
7
  belongs_to :location
8
+ self.read_only_attributes << :location_id
8
9
  end
9
10
  end
10
11
  end
@@ -5,6 +5,7 @@ module FrederickAPI
5
5
  # /v2/locations/:location_id/contact_lists
6
6
  class ContactList < Resource
7
7
  belongs_to :location
8
+ self.read_only_attributes << :location_id
8
9
  end
9
10
  end
10
11
  end
@@ -5,6 +5,7 @@ module FrederickAPI
5
5
  # /v2/locations/:location_id/contact_properties
6
6
  class ContactProperty < Resource
7
7
  belongs_to :location
8
+ self.read_only_attributes << :location_id
8
9
  end
9
10
  end
10
11
  end
@@ -5,6 +5,7 @@ module FrederickAPI
5
5
  # /v2/locations/:location_id/contact_types
6
6
  class ContactType < Resource
7
7
  belongs_to :location
8
+ self.read_only_attributes << :location_id
8
9
  end
9
10
  end
10
11
  end
@@ -5,6 +5,7 @@ module FrederickAPI
5
5
  # /v2/locations/:location_id/interactions
6
6
  class Interaction < Resource
7
7
  belongs_to :location
8
+ self.read_only_attributes << :location_id
8
9
  end
9
10
  end
10
11
  end
@@ -2,5 +2,5 @@
2
2
 
3
3
  module FrederickAPI
4
4
  # Current gem version
5
- VERSION = '0.1.2'
5
+ VERSION = '0.1.3'
6
6
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: frederick_api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Frederick Engineering
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 1.5.1
19
+ version: '1.5'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: 1.5.1
26
+ version: '1.5'
27
27
  description: Ruby client for the Frederick API
28
28
  email:
29
29
  - tech@hirefrederick.com