mints 0.0.17 → 0.0.21

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.
Files changed (73) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +2 -1
  3. data/lib/client.rb +96 -37
  4. data/lib/contact.rb +659 -94
  5. data/lib/generators/mints_files_generator.rb +6 -0
  6. data/lib/generators/mints_link.rb +61 -0
  7. data/lib/generators/short_link_controller.rb +41 -0
  8. data/lib/mints/controllers/admin_base_controller.rb +2 -2
  9. data/lib/mints/controllers/base_api_controller.rb +12 -11
  10. data/lib/mints/controllers/base_controller.rb +38 -9
  11. data/lib/mints_helper.rb +47 -0
  12. data/lib/pub.rb +258 -139
  13. data/lib/user/config/api_keys.rb +65 -0
  14. data/lib/user/config/appointments.rb +221 -0
  15. data/lib/user/config/attribute_groups.rb +77 -0
  16. data/lib/user/config/attributes.rb +86 -0
  17. data/lib/user/config/calendars.rb +89 -0
  18. data/lib/user/config/config.rb +65 -0
  19. data/lib/user/config/importers.rb +184 -0
  20. data/lib/user/config/public_folders.rb +108 -0
  21. data/lib/user/config/relationships.rb +138 -0
  22. data/lib/user/config/roles.rb +84 -0
  23. data/lib/user/config/seeds.rb +14 -0
  24. data/lib/user/config/system_settings.rb +53 -0
  25. data/lib/user/config/tags.rb +63 -0
  26. data/lib/user/config/taxonomies.rb +124 -0
  27. data/lib/user/config/teams.rb +70 -0
  28. data/lib/user/config/users.rb +76 -0
  29. data/lib/user/contacts/contacts.rb +21 -0
  30. data/lib/user/content/assets.rb +260 -0
  31. data/lib/user/content/content.rb +235 -0
  32. data/lib/user/content/content_instances.rb +147 -0
  33. data/lib/user/content/content_templates.rb +111 -0
  34. data/lib/user/content/conversations.rb +174 -0
  35. data/lib/user/content/dam.rb +88 -0
  36. data/lib/user/content/forms.rb +168 -0
  37. data/lib/user/content/message_templates.rb +162 -0
  38. data/lib/user/content/messages.rb +90 -0
  39. data/lib/user/content/pages.rb +81 -0
  40. data/lib/user/content/stories.rb +164 -0
  41. data/lib/user/content/story_templates.rb +95 -0
  42. data/lib/user/crm/companies.rb +111 -0
  43. data/lib/user/crm/contacts.rb +312 -0
  44. data/lib/user/crm/crm.rb +21 -0
  45. data/lib/user/crm/deals.rb +111 -0
  46. data/lib/user/crm/favorites.rb +17 -0
  47. data/lib/user/crm/segments.rb +132 -0
  48. data/lib/user/crm/users.rb +22 -0
  49. data/lib/user/crm/workflow_step_objects.rb +89 -0
  50. data/lib/user/crm/workflow_steps.rb +49 -0
  51. data/lib/user/crm/workflows.rb +70 -0
  52. data/lib/user/ecommerce/ecommerce.rb +29 -0
  53. data/lib/user/ecommerce/item_prices.rb +86 -0
  54. data/lib/user/ecommerce/locations.rb +166 -0
  55. data/lib/user/ecommerce/order_items_groups.rb +109 -0
  56. data/lib/user/ecommerce/order_statuses.rb +26 -0
  57. data/lib/user/ecommerce/orders.rb +258 -0
  58. data/lib/user/ecommerce/price_lists.rb +73 -0
  59. data/lib/user/ecommerce/product_templates.rb +104 -0
  60. data/lib/user/ecommerce/product_variations.rb +129 -0
  61. data/lib/user/ecommerce/products.rb +169 -0
  62. data/lib/user/ecommerce/skus.rb +88 -0
  63. data/lib/user/ecommerce/taxes.rb +82 -0
  64. data/lib/user/ecommerce/variant_options.rb +69 -0
  65. data/lib/user/ecommerce/variant_values.rb +72 -0
  66. data/lib/user/helpers/helpers.rb +113 -0
  67. data/lib/user/helpers/object_activities.rb +83 -0
  68. data/lib/user/helpers/object_folders.rb +82 -0
  69. data/lib/user/helpers/user_folders.rb +83 -0
  70. data/lib/user/marketing/marketing.rb +120 -0
  71. data/lib/user/profile/profile.rb +111 -0
  72. data/lib/user.rb +24 -368
  73. metadata +64 -2
@@ -0,0 +1,111 @@
1
+ module Deals
2
+ ##
3
+ # == Deals
4
+ #
5
+
6
+ ##
7
+ # === Get deal permits.
8
+ # Get permits of a deal.
9
+ #
10
+ # ==== Parameters
11
+ # id:: (Integer) -- Deal id.
12
+ #
13
+ # ==== Example
14
+ # @data = @mints_user.get_deal_permits(7)
15
+ def get_deal_permits(id)
16
+ return @client.raw("get", "/crm/deals/#{id}/permits")
17
+ end
18
+
19
+ ##
20
+ # === Get deal support data.
21
+ # Get support data of deals.
22
+ #
23
+ # ==== Example
24
+ # @data = @mints_user.get_deal_support_data
25
+ def get_deal_support_data
26
+ return @client.raw("get", "/crm/deals/support-data")
27
+ end
28
+
29
+ ##
30
+ # === Get deal currencies.
31
+ # Get currencies of deals.
32
+ #
33
+ # ==== Example
34
+ # @data = @mints_user.get_deal_currencies
35
+ def get_deal_currencies
36
+ return @client.raw("get", "/crm/deal/currencies")
37
+ end
38
+
39
+ # === Get deals.
40
+ # Get a collection of deals.
41
+ #
42
+ # ==== Parameters
43
+ # options:: (Hash) -- List of Resource Collection Options shown above can be used as parameter.
44
+ # use_post:: (Boolean) -- Variable to determine if the request is by 'post' or 'get' functions.
45
+ #
46
+ # ==== First Example
47
+ # @data = @mints_user.get_deals
48
+ #
49
+ # ==== Second Example
50
+ # options = { "fields": "id, title" }
51
+ # @data = @mints_user.get_deals(options)
52
+ #
53
+ # ==== Third Example
54
+ # options = { "fields": "id, title" }
55
+ # @data = @mints_user.get_deals(options, false)
56
+ def get_deals(options = nil, use_post = true)
57
+ return get_query_results("/crm/deals", options, use_post)
58
+ end
59
+
60
+ # === Get deal.
61
+ # Get a deal info.
62
+ #
63
+ # ==== Parameters
64
+ # id:: (Integer) -- Deal id.
65
+ # options:: (Hash) -- List of Resource Collection Options shown above can be used as parameter.
66
+ #
67
+ # ==== First Example
68
+ # @data = @mints_user.get_deal(1)
69
+ #
70
+ # ==== Second Example
71
+ # options = { "fields": "id, title" }
72
+ # @data = @mints_user.get_deal(1, options)
73
+ def get_deal(id, options = nil)
74
+ return @client.raw("get", "/crm/deals/#{id}", options)
75
+ end
76
+
77
+ # === Create deal.
78
+ # Create a deal with data.
79
+ #
80
+ # ==== Parameters
81
+ # data:: (Hash) -- Data to be submited.
82
+ #
83
+ # ==== Example
84
+ # data = {
85
+ # "dealData": {
86
+ # "title": "New deal",
87
+ # "stepId": 1,
88
+ # "value": 10500
89
+ # }
90
+ # }
91
+ # @data = @mints_user.create_deal(data.to_json)
92
+ def create_deal(data)
93
+ return @client.raw("post", "/crm/deals", nil, data)
94
+ end
95
+
96
+ # === Update deal.
97
+ # Update a deal data.
98
+ #
99
+ # ==== Parameters
100
+ # id:: (Integer) -- Deal id.
101
+ # data:: (Hash) -- Data to be submited.
102
+ #
103
+ # ==== Example
104
+ # data = {
105
+ # "title": "New Deal Modified"
106
+ # }
107
+ # @data = @mints_user.update_deal(102, data.to_json)
108
+ def update_deal(id, data)
109
+ return @client.raw("put", "/crm/deals/#{id}", nil, data)
110
+ end
111
+ end
@@ -0,0 +1,17 @@
1
+ module Favorites
2
+ ##
3
+ # == Favorites #TODO: NOT CHECKED, NO DATA IN DB
4
+ #
5
+
6
+ def update_multiple_favorites(data)
7
+ return @client.raw("put", "/crm/favorites", nil, data)
8
+ end
9
+
10
+ def get_favorites(options = nil)
11
+ return @client.raw("get", "/crm/favorites", options)
12
+ end
13
+
14
+ def update_favorites(id, data)
15
+ return @client.raw("put", "/crm/favorites/#{id}", nil, data)
16
+ end
17
+ end
@@ -0,0 +1,132 @@
1
+ module Segments
2
+ ##
3
+ # == Segments
4
+ #
5
+
6
+ # === Get segments support data.
7
+ # Get segments support data.
8
+ #
9
+ # ==== Example
10
+ # @data = @mints_user.get_segments_support_data
11
+ def get_segments_support_data
12
+ return @client.raw("get", "/crm/segments/support-data")
13
+ end
14
+
15
+ # === Get segments attributes.
16
+ # Get segments attributes.
17
+ #
18
+ # ==== Parameters
19
+ # options:: (Hash) -- List of Resource Collection Options shown above can be used as parameter.
20
+ #
21
+ # ==== Example
22
+ # options = { "object_type": "contacts" }
23
+ # @data = @mints_user.get_segments_attributes(options)
24
+ def get_segments_attributes(options = nil)
25
+ return @client.raw("get", "/crm/segments/attributes", options)
26
+ end
27
+
28
+ # === Get segment group.
29
+ # Get segment group.
30
+ #
31
+ # ==== Parameters
32
+ # groupId:: (String) -- Group's name.
33
+ #
34
+ # ==== Example
35
+ # @data = @mints_user.get_segment_group("users")
36
+ def get_segment_group(groupId)
37
+ return @client.raw("get", "/crm/segments/groups/#{groupId}")
38
+ end
39
+
40
+ # === Duplicate segment.
41
+ # Duplicate a segment.
42
+ #
43
+ # ==== Parameters
44
+ # id:: (Integer) -- Segment id.
45
+ # data:: (Hash) -- Data to be submited.
46
+ #
47
+ # ==== Example
48
+ # data = {
49
+ # "options": []
50
+ # }
51
+ # @data = @mints_user.duplicate_segment(107, data)
52
+ def duplicate_segment(id, data)
53
+ return @client.raw("post", "/crm/segments/#{id}/duplicate", nil, data)
54
+ end
55
+
56
+ # === Get segments.
57
+ # Get a collection of segments.
58
+ #
59
+ # ==== Parameters
60
+ # options:: (Hash) -- List of Resource Collection Options shown above can be used as parameter.
61
+ #
62
+ # ==== First Example
63
+ # @data = @mints_user.get_segments
64
+ #
65
+ # ==== Second Example
66
+ # options = { "fields": "id", "sort": "-id" }
67
+ # @data = @mints_user.get_segments(options)
68
+ def get_segments(options = nil)
69
+ return @client.raw("get", "/crm/segments", options)
70
+ end
71
+
72
+ # === Get segment.
73
+ # Get a segment info.
74
+ #
75
+ # ==== Parameters
76
+ # id:: (Integer) -- Segment id.
77
+ # options:: (Hash) -- List of Resource Collection Options shown above can be used as parameter.
78
+ #
79
+ # ==== First Example
80
+ # @data = @mints_user.get_segment(1)
81
+ #
82
+ # ==== Second Example
83
+ # options = { "fields": "id, title" }
84
+ # @data = @mints_user.get_segment(1, options)
85
+ def get_segment(id, options = nil)
86
+ return @client.raw("get", "/crm/segments/#{id}", options)
87
+ end
88
+
89
+ # === Create segment.
90
+ # Create a segment with data.
91
+ #
92
+ # ==== Parameters
93
+ # data:: (Hash) -- Data to be submited.
94
+ #
95
+ # ==== Example
96
+ # data = {
97
+ # "title": "New Segment",
98
+ # "object_type": "deals"
99
+ # }
100
+ # @data = @mints_user.create_segment(data)
101
+ def create_segment(data)
102
+ return @client.raw("post", "/crm/segments", nil, data_transform(data))
103
+ end
104
+
105
+ # === Update segment.
106
+ # Update a segment info.
107
+ #
108
+ # ==== Parameters
109
+ # id:: (Integer) -- Segment id.
110
+ # data:: (Hash) -- Data to be submited.
111
+ #
112
+ # ==== Example
113
+ # data = {
114
+ # "title": "New Segment Modified"
115
+ # }
116
+ # @data = @mints_user.update_segment(118, data)
117
+ def update_segment(id, data)
118
+ return @client.raw("put", "/crm/segments/#{id}", nil, data_transform(data))
119
+ end
120
+
121
+ # === Delete segment.
122
+ # Delete a segment.
123
+ #
124
+ # ==== Parameters
125
+ # id:: (Integer) -- Segment id.
126
+ #
127
+ # ==== Example
128
+ # @mints_user.delete_segment(113)
129
+ def delete_segment(id)
130
+ return @client.raw("delete", "/crm/segments/#{id}")
131
+ end
132
+ end
@@ -0,0 +1,22 @@
1
+ module Users
2
+ ##
3
+ # == Users
4
+ #
5
+
6
+ ###
7
+ # === Get crm users.
8
+ # Get users info in crm.
9
+ #
10
+ # ==== Parameters
11
+ # options:: (Hash) -- List of Resource Collection Options shown above can be used as parameter.
12
+ #
13
+ # ==== First Example
14
+ # @data = @mints_user.get_crm_users
15
+ #
16
+ # ==== Second Example
17
+ # options = { "sort": "id", "fields": "id, email" }
18
+ # @data = @mints_user.get_crm_users(options)
19
+ def get_crm_users(options = nil)
20
+ return @client.raw("get", "/crm/users", options)
21
+ end
22
+ end
@@ -0,0 +1,89 @@
1
+ module WorkflowStepObjects
2
+ ##
3
+ # == Workflow Step Objects
4
+ #
5
+
6
+ # === Get workflow step objects.
7
+ # Get a collection of workflow step objects.
8
+ #
9
+ # ==== Parameters
10
+ # options:: (Hash) -- List of Resource Collection Options shown above can be used as parameter.
11
+ #
12
+ # ==== First Example
13
+ # @data = @mints_user.get_step_objects
14
+ #
15
+ # ==== Second Example
16
+ # options = { "fields": "id" }
17
+ # @data = @mints_user.get_step_objects(options)
18
+ def get_step_objects(options = nil)
19
+ return @client.raw("get", "/crm/step-objects", options)
20
+ end
21
+
22
+ # === Get workflow step object.
23
+ # Get a workflow step object info.
24
+ #
25
+ # ==== Parameters
26
+ # id:: (Integer) -- Workflow step object id.
27
+ # options:: (Hash) -- List of Resource Collection Options shown above can be used as parameter.
28
+ #
29
+ # ==== First Example
30
+ # @data = @mints_user.get_step_object(1)
31
+ #
32
+ # ==== Second Example
33
+ # options = { "fields": "id, step_id" }
34
+ # @data = @mints_user.get_step_object(1, options)
35
+ def get_step_object(id, options = nil)
36
+ return @client.raw("get", "/crm/step-objects/#{id}", options)
37
+ end
38
+
39
+ # === Create workflow step object.
40
+ # Create a workflow step object with data.
41
+ #
42
+ # ==== Parameters
43
+ # data:: (Hash) -- Data to be submited.
44
+ #
45
+ # ==== Example
46
+ # data = {
47
+ # "objectType": "deals",
48
+ # "stepId": 9,
49
+ # "objectId": 1
50
+ # }
51
+ # @data = @mints_user.create_step_object(data)
52
+ def create_step_object(data)
53
+ return @client.raw("post", "/crm/step-objects/", nil, data_transform(data))
54
+ end
55
+
56
+ # === Update workflow step object.
57
+ # Update a workflow step object info.
58
+ #
59
+ # ==== Parameters
60
+ # id:: (Integer) -- Workflow step object id.
61
+ # data:: (Hash) -- Data to be submited.
62
+ #
63
+ # ==== Example
64
+ # data = {
65
+ # "stepId": 10
66
+ # }
67
+ # @data = @mints_user.update_step_object(128, data.to_json)
68
+ def update_step_object(id, data)
69
+ return @client.raw("put", "/crm/step-objects/#{id}", nil, data)
70
+ end
71
+
72
+ # === Get workflow step object by object type.
73
+ # Get a workflow step object info by an object type.
74
+ #
75
+ # ==== Parameters
76
+ # objectType:: (String) -- Object type.
77
+ # objectId:: (Integer) -- Workflow step object id.
78
+ # options:: (Hash) -- List of Resource Collection Options shown above can be used as parameter.
79
+ #
80
+ # ==== First Example
81
+ # @data = @mints_user.get_step_object_by_object_type("deals", 1)
82
+ #
83
+ # ==== Second Example
84
+ # options = { "fields": "id, object_id" }
85
+ # @data = @mints_user.get_step_object_by_object_type("deals", 1, options)
86
+ def get_step_object_by_object_type(objectType, objectId, options = nil)
87
+ return @client.raw("get", "/crm/step-objects/#{objectType}/#{objectId}", options)
88
+ end
89
+ end
@@ -0,0 +1,49 @@
1
+ module WorkFlowSteps
2
+ ##
3
+ # == Workflow Steps
4
+ #
5
+
6
+ # === Create workflow step.
7
+ # Create a workflow step with data.
8
+ #
9
+ # ==== Parameters
10
+ # data:: (Hash) -- Data to be submited.
11
+ #
12
+ # ==== Example
13
+ # data = {
14
+ # "stepTitle": "Step Title",
15
+ # "workflowId": 1
16
+ # }
17
+ # @data = @mints_user.create_workflow_step(data.to_json)
18
+ def create_workflow_step(data)
19
+ return @client.raw("post", "/crm/steps", nil, data)
20
+ end
21
+
22
+ # === Update workflow step.
23
+ # Update a workflow step info.
24
+ #
25
+ # ==== Parameters
26
+ # id:: (Integer) -- Workflow step id.
27
+ # data:: (Hash) -- Data to be submited.
28
+ #
29
+ # ==== Example
30
+ # data = {
31
+ # "stepTitle": "Step Title Modified"
32
+ # }
33
+ # @data = @mints_user.update_workflow_step(23, data)
34
+ def update_workflow_step(id, data)
35
+ return @client.raw("put", "/crm/steps/#{id}", nil, data)
36
+ end
37
+
38
+ # === Delete workflow step.
39
+ # Delete a workflow step.
40
+ #
41
+ # ==== Parameters
42
+ # id:: (Integer) -- Workflow step id.
43
+ #
44
+ # ==== Example
45
+ # @data = @mints_user.delete_workflow_step(51)
46
+ def delete_workflow_step(id)
47
+ return @client.raw("delete", "/crm/steps/#{id}")
48
+ end
49
+ end
@@ -0,0 +1,70 @@
1
+ module Workflows
2
+ ##
3
+ # == Workflows
4
+ #
5
+
6
+ # === Get workflows.
7
+ # Get a collection of workflows.
8
+ #
9
+ # ==== Parameters
10
+ # options:: (Hash) -- List of Resource Collection Options shown above can be used as parameter.
11
+ #
12
+ # ==== First Example
13
+ # @data = @mints_user.get_workflows
14
+ #
15
+ # ==== Second Example
16
+ # options = { "sort": "title", "fields": "title" }
17
+ # @data = @mints_user.get_workflows(options)
18
+ def get_workflows(options = nil)
19
+ return @client.raw("get", "/crm/workflows", options)
20
+ end
21
+
22
+ # === Get workflow.
23
+ # Get a workflow.
24
+ #
25
+ # ==== Parameters
26
+ # id:: (Integer) -- Workflow id.
27
+ # options:: (Hash) -- List of Resource Collection Options shown above can be used as parameter.
28
+ #
29
+ # ==== First Example
30
+ # @data = @mints_user.get_workflow(1)
31
+ #
32
+ # ==== Second Example
33
+ # options = { "fields": "id, title" }
34
+ # @data = @mints_user.get_workflow(1, options)
35
+ def get_workflow(id, options = nil)
36
+ return @client.raw("get", "/crm/workflows/#{id}", options)
37
+ end
38
+
39
+ # === Create workflow.
40
+ # Create a workflow with data.
41
+ #
42
+ # ==== Parameters
43
+ # data:: (Hash) -- Data to be submited.
44
+ #
45
+ # ==== Example
46
+ # data = {
47
+ # "title": "New Workflow",
48
+ # "object_type": "deals"
49
+ # }
50
+ # @data = @mints_user.create_workflow(data.to_json)
51
+ def create_workflow(data)
52
+ return @client.raw("post", "/crm/workflows/", nil, data)
53
+ end
54
+
55
+ # === Update workflow.
56
+ # Update a workflow info.
57
+ #
58
+ # ==== Parameters
59
+ # id:: (Integer) -- Workflow id.
60
+ # data:: (Hash) -- Data to be submited.
61
+ #
62
+ # ==== Example
63
+ # data = {
64
+ # "title": "New Workflow Modified"
65
+ # }
66
+ # @data = @mints_user.update_workflow(7, data)
67
+ def update_workflow(id, data)
68
+ return @client.raw("put", "/crm/workflows/#{id}", nil, correct_json(data))
69
+ end
70
+ end
@@ -0,0 +1,29 @@
1
+ require_relative './item_prices.rb'
2
+ require_relative './locations.rb'
3
+ require_relative './order_items_groups.rb'
4
+ require_relative './order_statuses.rb'
5
+ require_relative './orders.rb'
6
+ require_relative './price_lists.rb'
7
+ require_relative './product_templates.rb'
8
+ require_relative './product_variations.rb'
9
+ require_relative './products.rb'
10
+ require_relative './skus.rb'
11
+ require_relative './taxes.rb'
12
+ require_relative './variant_options.rb'
13
+ require_relative './variant_values.rb'
14
+
15
+ module Ecommerce
16
+ include ItemPrices
17
+ include Locations
18
+ include OrderItemsGroups
19
+ include OrderStatuses
20
+ include Orders
21
+ include PriceList
22
+ include ProductTemplates
23
+ include ProductVariations
24
+ include Products
25
+ include Skus
26
+ include Taxes
27
+ include VariantOptions
28
+ include VariantValues
29
+ end
@@ -0,0 +1,86 @@
1
+ module ItemPrices
2
+ ##
3
+ # == Item Prices
4
+ #
5
+
6
+ # === Get item prices.
7
+ # Get a collection of item prices.
8
+ #
9
+ # ==== Parameters
10
+ # options:: (Hash) -- List of Resource Collection Options shown above can be used as parameter.
11
+ #
12
+ # ==== First Example
13
+ # @data = @mints_user.get_item_prices
14
+ #
15
+ # ==== Second Example
16
+ # options = { "fields": "price_cents" }
17
+ # @data = @mints_user.get_item_prices(options)
18
+ def get_item_prices(options = nil)
19
+ return @client.raw("get", "/ecommerce/item-prices", options)
20
+ end
21
+
22
+ # === Get item price.
23
+ # Get a item price info.
24
+ #
25
+ # ==== Parameters
26
+ # id:: (Integer) -- Item price id.
27
+ # options:: (Hash) -- List of Resource Collection Options shown above can be used as parameter.
28
+ #
29
+ # ==== First Example
30
+ # @data = @mints_user.get_item_price(1)
31
+ #
32
+ # ==== Second Example
33
+ # options = { "fields": "price_cents" }
34
+ # @data = @mints_user.get_item_price(1, options)
35
+ def get_item_price(id, options = nil)
36
+ return @client.raw("get", "/ecommerce/item-prices/#{id}", options)
37
+ end
38
+
39
+ # === Create item price.
40
+ # Create a item price with data.
41
+ #
42
+ # ==== Parameters
43
+ # data:: (Hash) -- Data to be submited.
44
+ #
45
+ # ==== Example
46
+ # data = {
47
+ # "price_list": [
48
+ # { "id": 1 },
49
+ # { "id": 2 }
50
+ # ],
51
+ # "price_list_id": 1,
52
+ # "title": "New Item Price"
53
+ # }
54
+ # @data = @mints_user.create_item_price(data)
55
+ def create_item_price(data) #FIXME: Api send sku_id as null and DB doesnt allow that.
56
+ return @client.raw("post", "/ecommerce/item-prices", nil, data_transform(data))
57
+ end
58
+
59
+ # === Update item price.
60
+ # Update a item price info.
61
+ #
62
+ # ==== Parameters
63
+ # id:: (Integer) -- Order item price id.
64
+ # data:: (Hash) -- Data to be submited.
65
+ #
66
+ # ==== Example
67
+ # data = {
68
+ # "price": 12345
69
+ # }
70
+ # @data = @mints_user.update_item_price(1, data)
71
+ def update_item_price(id, data)
72
+ return @client.raw("put", "/ecommerce/item-prices/#{id}", nil, data_transform(data))
73
+ end
74
+
75
+ # === Delete item price.
76
+ # Delete a item price.
77
+ #
78
+ # ==== Parameters
79
+ # id:: (Integer) -- Item price id.
80
+ #
81
+ # ==== Example
82
+ # @data = @mints_user.delete_item_price(803)
83
+ def delete_item_price(id)
84
+ return @client.raw("delete", "/ecommerce/item-prices/#{id}")
85
+ end
86
+ end