easy_hubspot 0.1.7 → 0.1.8
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 +4 -4
- data/CHANGELOG.md +11 -3
- data/README.md +6 -3
- data/lib/easy_hubspot/client.rb +4 -1
- data/lib/easy_hubspot/exceptions.rb +6 -0
- data/lib/easy_hubspot/version.rb +1 -1
- data/lib/easy_hubspot.rb +1 -0
- metadata +2 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8afd7c12ba165b752df83f2a711ad3220f0efb7f9fef8a73340ae9dd9c95adeb
|
4
|
+
data.tar.gz: dcd135320a2274849e576f7b2c5497a74323c1713b330f275c6c4f6dfa3cedef
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4b5da8b90ae02f92056d2af35dea0cbbe8207e84d486345dd89fd7d155b75a13680b735788f2e4b64ba3c9acc617830c8fe29feb3a5b3156c5ceb3cab3b2f724
|
7
|
+
data.tar.gz: c90fb31a0954a82c9bdfbf7c3b0c5df4fde0e4f5c40da12fa09f32afad0f8ca5c7679ae561ca52196b016bebf06bcdeb93edb6d14c57ed354b99b2faf5a75f95
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,13 @@
|
|
1
|
-
## [
|
1
|
+
## [Official Release]
|
2
|
+
- [0.1.7] - 2023-02-10
|
2
3
|
|
3
|
-
## [
|
4
|
+
## [Unreleased]
|
4
5
|
|
5
|
-
|
6
|
+
## [Initial releases]
|
7
|
+
- [0.1.0] - 2023-02-08
|
8
|
+
- [0.1.1] - 2023-02-09
|
9
|
+
- [0.1.2] - 2023-02-09
|
10
|
+
- [0.1.3] - 2023-02-09
|
11
|
+
- [0.1.4] - 2023-02-09
|
12
|
+
- [0.1.5] - 2023-02-09
|
13
|
+
- [0.1.6] - 2023-02-09
|
data/README.md
CHANGED
@@ -1,11 +1,12 @@
|
|
1
1
|
# EasyHubspot
|
2
|
-

|
3
3
|
[](https://github.com/oroth8/easy_hubspot/actions/workflows/ci.yml)
|
4
4
|
[](https://codeclimate.com/github/oroth8/easy_hubspot)
|
5
5
|
|
6
|
-
|
6
|
+
This is a lightweight wrapper for the Hubspot API. It is designed to be easy to use and to provide a simple setup for the most common use cases.
|
7
|
+
|
8
|
+
This gem utilizes the `v3` hubspot-api
|
7
9
|
|
8
|
-
This is a lightweight wrapper for the Hubspot API. It is designed to be easy to use and to provide a simple interface for the most common use cases.
|
9
10
|
## Installation
|
10
11
|
|
11
12
|
Add this line to your application's Gemfile:
|
@@ -33,6 +34,8 @@ rails g easy_hubspot:install
|
|
33
34
|
|
34
35
|
### Contacts
|
35
36
|
|
37
|
+
Please refrence the [hubspot docs](https://developers.hubspot.com/docs/api/crm/contacts)
|
38
|
+
|
36
39
|
```ruby
|
37
40
|
# Create a contact
|
38
41
|
EasyHubspot::Contact.create_contact(properties: { email: '', firstname: '', lastname: '' , etc: ''})
|
data/lib/easy_hubspot/client.rb
CHANGED
@@ -33,7 +33,10 @@ module EasyHubspot
|
|
33
33
|
def parse_response(res)
|
34
34
|
return if res.body.nil?
|
35
35
|
|
36
|
-
JSON.parse res, symbolize_names: true
|
36
|
+
parsed_res = JSON.parse res, symbolize_names: true
|
37
|
+
raise EasyHubspot::HubspotApiError, parsed_res[:message] if parsed_res[:status] == 'error'
|
38
|
+
|
39
|
+
parsed_res
|
37
40
|
end
|
38
41
|
end
|
39
42
|
end
|
data/lib/easy_hubspot/version.rb
CHANGED
data/lib/easy_hubspot.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: easy_hubspot
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Owen Roth
|
@@ -184,6 +184,7 @@ files:
|
|
184
184
|
- lib/easy_hubspot/base.rb
|
185
185
|
- lib/easy_hubspot/client.rb
|
186
186
|
- lib/easy_hubspot/contact.rb
|
187
|
+
- lib/easy_hubspot/exceptions.rb
|
187
188
|
- lib/easy_hubspot/generators/install_generator.rb
|
188
189
|
- lib/easy_hubspot/generators/templates/easy_hubspot.rb
|
189
190
|
- lib/easy_hubspot/version.rb
|