plenty_client 0.0.9 → 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/lib/plenty_client/account/address.rb +37 -0
- data/lib/plenty_client/account/contact/address.rb +8 -6
- data/lib/plenty_client/account/contact/bank.rb +7 -5
- data/lib/plenty_client/account/contact/type.rb +7 -5
- data/lib/plenty_client/account/contact.rb +7 -5
- data/lib/plenty_client/account.rb +11 -9
- data/lib/plenty_client/accounting.rb +6 -4
- data/lib/plenty_client/authentication.rb +7 -5
- data/lib/plenty_client/authorization.rb +4 -2
- data/lib/plenty_client/basket/item.rb +4 -2
- data/lib/plenty_client/basket.rb +3 -1
- data/lib/plenty_client/category/branch.rb +4 -2
- data/lib/plenty_client/category/template.rb +5 -3
- data/lib/plenty_client/category.rb +12 -10
- data/lib/plenty_client/comment.rb +8 -6
- data/lib/plenty_client/config.rb +6 -0
- data/lib/plenty_client/document/category.rb +6 -4
- data/lib/plenty_client/document/order.rb +7 -5
- data/lib/plenty_client/document.rb +4 -2
- data/lib/plenty_client/endpoint.rb +1 -1
- data/lib/plenty_client/item/attribute/name.rb +8 -6
- data/lib/plenty_client/item/attribute/value.rb +8 -6
- data/lib/plenty_client/item/attribute/value_name.rb +8 -6
- data/lib/plenty_client/item/attribute.rb +7 -5
- data/lib/plenty_client/item/barcode.rb +11 -9
- data/lib/plenty_client/item/cross_selling.rb +5 -3
- data/lib/plenty_client/item/image/availability.rb +6 -4
- data/lib/plenty_client/item/image/name.rb +8 -6
- data/lib/plenty_client/item/image.rb +15 -12
- data/lib/plenty_client/item/manufacturer/commission.rb +8 -6
- data/lib/plenty_client/item/manufacturer.rb +7 -5
- data/lib/plenty_client/item/property/market_reference.rb +8 -6
- data/lib/plenty_client/item/property/name.rb +8 -6
- data/lib/plenty_client/item/property.rb +7 -5
- data/lib/plenty_client/item/property_group.rb +7 -5
- data/lib/plenty_client/item/property_group_name.rb +8 -6
- data/lib/plenty_client/item/sales_price.rb +7 -5
- data/lib/plenty_client/item/shipping_profile.rb +5 -3
- data/lib/plenty_client/item/unit.rb +7 -5
- data/lib/plenty_client/item/unit_name.rb +7 -5
- data/lib/plenty_client/item/variation/barcode.rb +3 -1
- data/lib/plenty_client/item/variation/bundle.rb +8 -6
- data/lib/plenty_client/item/variation/category.rb +14 -6
- data/lib/plenty_client/item/variation/client.rb +6 -4
- data/lib/plenty_client/item/variation/default_category.rb +7 -5
- data/lib/plenty_client/item/variation/description.rb +8 -6
- data/lib/plenty_client/item/variation/image.rb +8 -6
- data/lib/plenty_client/item/variation/market.rb +6 -4
- data/lib/plenty_client/item/variation/market_ident_number.rb +8 -6
- data/lib/plenty_client/item/variation/property/text.rb +8 -6
- data/lib/plenty_client/item/variation/property.rb +22 -17
- data/lib/plenty_client/item/variation/sales_price.rb +15 -19
- data/lib/plenty_client/item/variation/sku.rb +8 -6
- data/lib/plenty_client/item/variation/stock.rb +9 -7
- data/lib/plenty_client/item/variation/supplier.rb +8 -6
- data/lib/plenty_client/item/variation/warehouse.rb +8 -6
- data/lib/plenty_client/item/variation.rb +8 -6
- data/lib/plenty_client/item.rb +11 -4
- data/lib/plenty_client/item_set/component.rb +9 -7
- data/lib/plenty_client/item_set/config.rb +4 -2
- data/lib/plenty_client/item_set.rb +9 -7
- data/lib/plenty_client/listing/layout_template.rb +5 -3
- data/lib/plenty_client/listing/market/directory.rb +6 -4
- data/lib/plenty_client/listing/market/history.rb +7 -5
- data/lib/plenty_client/listing/market/info.rb +3 -1
- data/lib/plenty_client/listing/market/text.rb +7 -5
- data/lib/plenty_client/listing/market.rb +9 -7
- data/lib/plenty_client/listing/option_template.rb +7 -5
- data/lib/plenty_client/listing/shipping_profile.rb +4 -2
- data/lib/plenty_client/listing/stock_dependence_type.rb +4 -2
- data/lib/plenty_client/listing/type.rb +4 -2
- data/lib/plenty_client/listing.rb +7 -5
- data/lib/plenty_client/market/credentials.rb +7 -5
- data/lib/plenty_client/market/ebay/authentication.rb +4 -2
- data/lib/plenty_client/market/ebay/parts_fitment.rb +8 -6
- data/lib/plenty_client/market/ebay/shop_category.rb +3 -1
- data/lib/plenty_client/order/contact_wish.rb +4 -2
- data/lib/plenty_client/order/coupon_code/contact.rb +3 -1
- data/lib/plenty_client/order/coupon_code/validation.rb +3 -1
- data/lib/plenty_client/order/coupon_code.rb +3 -1
- data/lib/plenty_client/order/currency.rb +6 -4
- data/lib/plenty_client/order/date.rb +6 -4
- data/lib/plenty_client/order/item/serial_number.rb +4 -2
- data/lib/plenty_client/order/item.rb +3 -1
- data/lib/plenty_client/order/referrer.rb +4 -2
- data/lib/plenty_client/order/shipping/country.rb +3 -1
- data/lib/plenty_client/order/shipping/information.rb +12 -17
- data/lib/plenty_client/order/shipping/package.rb +9 -7
- data/lib/plenty_client/order/shipping/profile.rb +4 -2
- data/lib/plenty_client/order/shipping/service_provider.rb +5 -3
- data/lib/plenty_client/order/status_history.rb +23 -0
- data/lib/plenty_client/order.rb +9 -7
- data/lib/plenty_client/order_summary.rb +9 -7
- data/lib/plenty_client/payment/contact.rb +4 -2
- data/lib/plenty_client/payment/method.rb +10 -8
- data/lib/plenty_client/payment/method_name.rb +5 -3
- data/lib/plenty_client/payment/order.rb +5 -3
- data/lib/plenty_client/payment/property/type/name.rb +7 -5
- data/lib/plenty_client/payment/property/type.rb +7 -5
- data/lib/plenty_client/payment/property.rb +9 -7
- data/lib/plenty_client/payment/status.rb +3 -1
- data/lib/plenty_client/payment/transaction.rb +3 -1
- data/lib/plenty_client/payment.rb +8 -6
- data/lib/plenty_client/request.rb +54 -24
- data/lib/plenty_client/sales_price/account.rb +5 -3
- data/lib/plenty_client/sales_price/country.rb +5 -3
- data/lib/plenty_client/sales_price/currency.rb +5 -3
- data/lib/plenty_client/sales_price/customer_class.rb +6 -4
- data/lib/plenty_client/sales_price/name.rb +7 -5
- data/lib/plenty_client/sales_price/online_store.rb +5 -3
- data/lib/plenty_client/sales_price/referrer.rb +5 -3
- data/lib/plenty_client/stock.rb +5 -3
- data/lib/plenty_client/ticket.rb +6 -4
- data/lib/plenty_client/version.rb +3 -1
- data/lib/plenty_client/warehouse/management/rack.rb +6 -4
- data/lib/plenty_client/warehouse/management/shelf.rb +6 -4
- data/lib/plenty_client/warehouse/management/storage_location.rb +6 -4
- data/lib/plenty_client/warehouse/management.rb +21 -5
- data/lib/plenty_client/warehouse/stock.rb +8 -6
- data/lib/plenty_client/warehouse.rb +5 -3
- data/lib/plenty_client/webstore.rb +3 -1
- data/lib/plenty_client.rb +5 -1
- metadata +5 -3
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Market
|
3
5
|
module Ebay
|
@@ -5,12 +7,12 @@ module PlentyClient
|
|
5
7
|
include PlentyClient::Endpoint
|
6
8
|
include PlentyClient::Request
|
7
9
|
|
8
|
-
LIST_MARKET_EBAY_PARTS_FITMENTS = '/markets/ebay/parts-fitments'
|
9
|
-
FIND_MARKET_EBAY_PARTS_FITMENT = '/markets/ebay/parts-fitments/{fitmentId}'
|
10
|
-
CREATE_MARKET_EBAY_PARTS_FITMENT = '/markets/ebay/parts-fitments'
|
11
|
-
UPDATE_MARKET_EBAY_PARTS_FITMENT = '/markets/ebay/parts-fitments/{fitmentId}'
|
12
|
-
DELETE_MARKET_EBAY_PARTS_FITMENT = '/markets/ebay/parts-fitments/{fitmentId}'
|
13
|
-
SEARCH_MARKET_EBAY_PARTS_FITMENTS = '/markets/ebay/parts-fitments/search'
|
10
|
+
LIST_MARKET_EBAY_PARTS_FITMENTS = '/markets/ebay/parts-fitments'
|
11
|
+
FIND_MARKET_EBAY_PARTS_FITMENT = '/markets/ebay/parts-fitments/{fitmentId}'
|
12
|
+
CREATE_MARKET_EBAY_PARTS_FITMENT = '/markets/ebay/parts-fitments'
|
13
|
+
UPDATE_MARKET_EBAY_PARTS_FITMENT = '/markets/ebay/parts-fitments/{fitmentId}'
|
14
|
+
DELETE_MARKET_EBAY_PARTS_FITMENT = '/markets/ebay/parts-fitments/{fitmentId}'
|
15
|
+
SEARCH_MARKET_EBAY_PARTS_FITMENTS = '/markets/ebay/parts-fitments/search'
|
14
16
|
|
15
17
|
class << self
|
16
18
|
def list(headers = {}, &block)
|
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Market
|
3
5
|
module Ebay
|
@@ -5,7 +7,7 @@ module PlentyClient
|
|
5
7
|
include PlentyClient::Endpoint
|
6
8
|
include PlentyClient::Request
|
7
9
|
|
8
|
-
LIST_MARKET_EBAY_SHOP_CATEGORIES = '/markets/ebay/shop_categories'
|
10
|
+
LIST_MARKET_EBAY_SHOP_CATEGORIES = '/markets/ebay/shop_categories'
|
9
11
|
|
10
12
|
class << self
|
11
13
|
def list(headers = {}, &block)
|
@@ -1,14 +1,16 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Order
|
3
5
|
module ContactWish
|
4
6
|
include PlentyClient::Endpoint
|
5
7
|
include PlentyClient::Request
|
6
8
|
|
7
|
-
|
9
|
+
FIND_ORDER_CONTACT_WISH = '/orders/{orderId}/contactWish'
|
8
10
|
|
9
11
|
class << self
|
10
12
|
def find(order_id, headers = {}, &block)
|
11
|
-
get(build_endpoint(
|
13
|
+
get(build_endpoint(FIND_ORDER_CONTACT_WISH, order: order_id), headers, &block)
|
12
14
|
end
|
13
15
|
end
|
14
16
|
end
|
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Order
|
3
5
|
module CouponCode
|
@@ -5,7 +7,7 @@ module PlentyClient
|
|
5
7
|
include PlentyClient::Endpoint
|
6
8
|
include PlentyClient::Request
|
7
9
|
|
8
|
-
LIST_COUPON_CONTACTS = '/orders/coupons/codes/contacts/{contactId}'
|
10
|
+
LIST_COUPON_CONTACTS = '/orders/coupons/codes/contacts/{contactId}'
|
9
11
|
|
10
12
|
class << self
|
11
13
|
def update(contact_id, headers = {}, &block)
|
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Order
|
3
5
|
module CouponCode
|
@@ -5,7 +7,7 @@ module PlentyClient
|
|
5
7
|
include PlentyClient::Endpoint
|
6
8
|
include PlentyClient::Request
|
7
9
|
|
8
|
-
VALIDATE_COUPON = '/orders/coupons/codes/{coupon}'
|
10
|
+
VALIDATE_COUPON = '/orders/coupons/codes/{coupon}'
|
9
11
|
|
10
12
|
class << self
|
11
13
|
def update(coupon_string, headers = {}, &block)
|
@@ -1,10 +1,12 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Order
|
3
5
|
module CouponCode
|
4
6
|
include PlentyClient::Endpoint
|
5
7
|
include PlentyClient::Request
|
6
8
|
|
7
|
-
UPDATE_COUPON_CODE = '/orders/{orderId}/coupons/{coupon}'
|
9
|
+
UPDATE_COUPON_CODE = '/orders/{orderId}/coupons/{coupon}'
|
8
10
|
|
9
11
|
class << self
|
10
12
|
def update(order_id, coupon_string, headers = {}, &block)
|
@@ -1,13 +1,15 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Order
|
3
5
|
class Currency
|
4
6
|
include PlentyClient::Endpoint
|
5
7
|
include PlentyClient::Request
|
6
8
|
|
7
|
-
LIST_CURRENCIES = '/orders/currencies'
|
8
|
-
FIND_CURRENCY_ISO = '/orders/currencies/{currencyIso}'
|
9
|
-
FIND_COUNTRIES_FOR_CURRENCY = '/orders/currencies/{currencyIso}/countries'
|
10
|
-
FIND_CURRENCY_FOR_COUNTRY = '/orders/currencies/countries/{countryId}'
|
9
|
+
LIST_CURRENCIES = '/orders/currencies'
|
10
|
+
FIND_CURRENCY_ISO = '/orders/currencies/{currencyIso}'
|
11
|
+
FIND_COUNTRIES_FOR_CURRENCY = '/orders/currencies/{currencyIso}/countries'
|
12
|
+
FIND_CURRENCY_FOR_COUNTRY = '/orders/currencies/countries/{countryId}'
|
11
13
|
|
12
14
|
class << self
|
13
15
|
def list(headers = {}, &block)
|
@@ -1,13 +1,15 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Order
|
3
5
|
class Date
|
4
6
|
include PlentyClient::Endpoint
|
5
7
|
include PlentyClient::Request
|
6
8
|
|
7
|
-
LIST_ORDER_DATE_TYPE_NAMES = '/orders/dates/types/{typeId}/names'
|
8
|
-
FIND_ORDER_DATE_TYPE_NAME = '/orders/dates/types/{typeId}/names/{lang}'
|
9
|
-
LIST_ORDER_DATES = '/orders/{orderId}/dates'
|
10
|
-
FIND_ORDER_DATE = '/orders/{orderId}/dates/{typeId}'
|
9
|
+
LIST_ORDER_DATE_TYPE_NAMES = '/orders/dates/types/{typeId}/names'
|
10
|
+
FIND_ORDER_DATE_TYPE_NAME = '/orders/dates/types/{typeId}/names/{lang}'
|
11
|
+
LIST_ORDER_DATES = '/orders/{orderId}/dates'
|
12
|
+
FIND_ORDER_DATE = '/orders/{orderId}/dates/{typeId}'
|
11
13
|
|
12
14
|
class << self
|
13
15
|
def list_date_type_names(type_id, headers = {}, &block)
|
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Order
|
3
5
|
module Item
|
@@ -5,8 +7,8 @@ module PlentyClient
|
|
5
7
|
include PlentyClient::Endpoint
|
6
8
|
include PlentyClient::Request
|
7
9
|
|
8
|
-
LIST_SERIAL_NUMBERS = '/orders/{orderId}/items/serialNumbers'
|
9
|
-
LIST_ORDER_ITEM_SERIAL_NUMBERS = '/orders/{orderId}/items/{orderItemId}/serialNumbers'
|
10
|
+
LIST_SERIAL_NUMBERS = '/orders/{orderId}/items/serialNumbers'
|
11
|
+
LIST_ORDER_ITEM_SERIAL_NUMBERS = '/orders/{orderId}/items/{orderItemId}/serialNumbers'
|
10
12
|
|
11
13
|
class << self
|
12
14
|
def list(order_id, headers = {}, &block)
|
@@ -1,10 +1,12 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Order
|
3
5
|
module Item
|
4
6
|
include PlentyClient::Endpoint
|
5
7
|
include PlentyClient::Request
|
6
8
|
|
7
|
-
DELETE_ORDERS_ORDER_ITEM = '/orders/{orderId}/items/{orderItemId}'
|
9
|
+
DELETE_ORDERS_ORDER_ITEM = '/orders/{orderId}/items/{orderItemId}'
|
8
10
|
|
9
11
|
class << self
|
10
12
|
def destroy(order_id, order_item_id)
|
@@ -1,11 +1,13 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Order
|
3
5
|
class Referrer
|
4
6
|
include PlentyClient::Endpoint
|
5
7
|
include PlentyClient::Request
|
6
8
|
|
7
|
-
LIST_REFERRERS = '/orders/referrers'
|
8
|
-
CREATE_ORDER_REFERRER = '/orders/referrers/{parentReferrerId}'
|
9
|
+
LIST_REFERRERS = '/orders/referrers'
|
10
|
+
CREATE_ORDER_REFERRER = '/orders/referrers/{parentReferrerId}'
|
9
11
|
|
10
12
|
class << self
|
11
13
|
def list(headers = {})
|
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Order
|
3
5
|
module Shipping
|
@@ -5,7 +7,7 @@ module PlentyClient
|
|
5
7
|
include PlentyClient::Endpoint
|
6
8
|
include PlentyClient::Request
|
7
9
|
|
8
|
-
LIST_SHIPPING_COUNTRIES = '/orders/shipping/countries'
|
10
|
+
LIST_SHIPPING_COUNTRIES = '/orders/shipping/countries'
|
9
11
|
|
10
12
|
class << self
|
11
13
|
def list(headers = {}, &block)
|
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Order
|
3
5
|
module Shipping
|
@@ -5,38 +7,31 @@ module PlentyClient
|
|
5
7
|
include PlentyClient::Endpoint
|
6
8
|
include PlentyClient::Request
|
7
9
|
|
8
|
-
|
10
|
+
SINGLE_PATH = '/orders/{orderId}/shipping/shipping_information'
|
11
|
+
MULTIPLE_PATH = '/orders/shipping/shipping_information'
|
9
12
|
|
10
|
-
|
11
|
-
|
12
|
-
CREATE_ORDER_SHIPPING_INFORMATION = '/shipping_information'.freeze
|
13
|
-
UPDATE_ORDER_SHIPPING_STATUS = '/shipping_information/status'.freeze
|
14
|
-
UPDATE_ORDER_SHIPPING_DATA = '/shipping_information/additional_data'.freeze
|
13
|
+
UPDATE_STATUS = SINGLE_PATH + '/status'
|
14
|
+
UPDATE_ADDITIONAL_DATA = SINGLE_PATH + '/additional_data'
|
15
15
|
|
16
16
|
class << self
|
17
17
|
def list(order_id, headers = {}, &block)
|
18
|
-
get(build_endpoint(
|
19
|
-
order: order_id), headers, &block)
|
18
|
+
get(build_endpoint(SINGLE_PATH, order: order_id), headers, &block)
|
20
19
|
end
|
21
20
|
|
22
|
-
def create(
|
23
|
-
post(
|
24
|
-
order: order_id), body)
|
21
|
+
def create(body = {})
|
22
|
+
post(MULTIPLE_PATH, body)
|
25
23
|
end
|
26
24
|
|
27
25
|
def update_status(order_id, body = {})
|
28
|
-
put(build_endpoint(
|
29
|
-
order: order_id), body)
|
26
|
+
put(build_endpoint(UPDATE_STATUS, order: order_id), body)
|
30
27
|
end
|
31
28
|
|
32
29
|
def update_data(order_id, body = {})
|
33
|
-
put(build_endpoint(
|
34
|
-
order: order_id), body)
|
30
|
+
put(build_endpoint(UPDATE_ADDITIONAL_DATA, order: order_id), body)
|
35
31
|
end
|
36
32
|
|
37
33
|
def destroy(order_id, body = {})
|
38
|
-
delete(build_endpoint(
|
39
|
-
order: order_id), body)
|
34
|
+
delete(build_endpoint(SINGLE_PATH, order: order_id), body)
|
40
35
|
end
|
41
36
|
end
|
42
37
|
end
|
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Order
|
3
5
|
module Shipping
|
@@ -5,14 +7,14 @@ module PlentyClient
|
|
5
7
|
include PlentyClient::Endpoint
|
6
8
|
include PlentyClient::Request
|
7
9
|
|
8
|
-
BASE_ORDERS_SHIPPING_PATH = '/orders/{orderId}/shipping'
|
10
|
+
BASE_ORDERS_SHIPPING_PATH = '/orders/{orderId}/shipping'
|
9
11
|
|
10
|
-
FIND_ORDERS_SHIPPING_PACKAGE = '/packages/{orderShippingPackageId}'
|
11
|
-
LIST_ORDERS_SHIPPING_PACKAGE = '/packages'
|
12
|
-
CREATE_ORDER_SHIPPING_PACKAGE = '/packages'
|
13
|
-
UPDATE_ORDER_SHIPPING_PACKAGE = '/packages/{orderShippingPackageId}'
|
14
|
-
DELETE_ORDER_SHIPPING_PACKAGE = '/packages/{orderShippingPackageId}'
|
15
|
-
DELETE_ORDER_SHIPPING_PACKAGES = '/packages'
|
12
|
+
FIND_ORDERS_SHIPPING_PACKAGE = '/packages/{orderShippingPackageId}'
|
13
|
+
LIST_ORDERS_SHIPPING_PACKAGE = '/packages'
|
14
|
+
CREATE_ORDER_SHIPPING_PACKAGE = '/packages'
|
15
|
+
UPDATE_ORDER_SHIPPING_PACKAGE = '/packages/{orderShippingPackageId}'
|
16
|
+
DELETE_ORDER_SHIPPING_PACKAGE = '/packages/{orderShippingPackageId}'
|
17
|
+
DELETE_ORDER_SHIPPING_PACKAGES = '/packages'
|
16
18
|
|
17
19
|
class << self
|
18
20
|
def list(order_id, headers = {}, &block)
|
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Order
|
3
5
|
module Shipping
|
@@ -5,8 +7,8 @@ module PlentyClient
|
|
5
7
|
include PlentyClient::Endpoint
|
6
8
|
include PlentyClient::Request
|
7
9
|
|
8
|
-
LIST_SHIPPING_PRESET = '/orders/shipping/presets'
|
9
|
-
FIND_SHIPPING_PRESETS = '/orders/shipping/presets/{presetId}'
|
10
|
+
LIST_SHIPPING_PRESET = '/orders/shipping/presets'
|
11
|
+
FIND_SHIPPING_PRESETS = '/orders/shipping/presets/{presetId}'
|
10
12
|
|
11
13
|
class << self
|
12
14
|
def list(headers = {}, &block)
|
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Order
|
3
5
|
module Shipping
|
@@ -5,10 +7,10 @@ module PlentyClient
|
|
5
7
|
include PlentyClient::Endpoint
|
6
8
|
include PlentyClient::Request
|
7
9
|
|
8
|
-
BASE_ORDERS_SHIPPING_SERVICE_PROVIDER_PATH = '/orders/shipping'
|
10
|
+
BASE_ORDERS_SHIPPING_SERVICE_PROVIDER_PATH = '/orders/shipping'
|
9
11
|
|
10
|
-
LIST_ORDERS_SHIPPING_SERVICE_PROVIDER = '/shipping_service_providers'
|
11
|
-
FIND_ORDER_SHIPPING_SERVICE_PROVIDER = '/shipping_service_providers/{shippingServiceProviderID}'
|
12
|
+
LIST_ORDERS_SHIPPING_SERVICE_PROVIDER = '/shipping_service_providers'
|
13
|
+
FIND_ORDER_SHIPPING_SERVICE_PROVIDER = '/shipping_service_providers/{shippingServiceProviderID}'
|
12
14
|
|
13
15
|
class << self
|
14
16
|
def list(headers = {}, &block)
|
@@ -0,0 +1,23 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module PlentyClient
|
4
|
+
module Order
|
5
|
+
module StatusHistory
|
6
|
+
include PlentyClient::Endpoint
|
7
|
+
include PlentyClient::Request
|
8
|
+
|
9
|
+
FIND_ORDER_STATUS_HISTORY = '/orders/{orderId}/status-history'
|
10
|
+
LIST_ORDER_STATUS_HISTORIES = '/orders/status-history'
|
11
|
+
|
12
|
+
class << self
|
13
|
+
def find(order_id, headers = {}, &block)
|
14
|
+
get(build_endpoint(FIND_ORDER_STATUS_HISTORY, order: order_id), headers, &block)
|
15
|
+
end
|
16
|
+
|
17
|
+
def list(headers = {}, &block)
|
18
|
+
get(build_endpoint(LIST_ORDER_STATUS_HISTORIES), headers, &block)
|
19
|
+
end
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
data/lib/plenty_client/order.rb
CHANGED
@@ -1,15 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Order
|
3
5
|
include PlentyClient::Endpoint
|
4
6
|
include PlentyClient::Request
|
5
7
|
|
6
|
-
CREATE_ORDER = '/orders'
|
7
|
-
LIST_ORDERS = '/orders'
|
8
|
-
FIND_ORDER = '/orders/{orderId}'
|
9
|
-
LIST_CONTACTS_ORDERS = '/orders/contacts/{contactId}'
|
10
|
-
UPDATE_ORDER = '/orders/{orderId}'
|
11
|
-
LIST_ORDERS_PACKAGE_NUMBERS = '/orders/{orderId}/packagenumbers'
|
12
|
-
DELETE_ORDER = '/orders/{orderId}'
|
8
|
+
CREATE_ORDER = '/orders'
|
9
|
+
LIST_ORDERS = '/orders'
|
10
|
+
FIND_ORDER = '/orders/{orderId}'
|
11
|
+
LIST_CONTACTS_ORDERS = '/orders/contacts/{contactId}'
|
12
|
+
UPDATE_ORDER = '/orders/{orderId}'
|
13
|
+
LIST_ORDERS_PACKAGE_NUMBERS = '/orders/{orderId}/packagenumbers'
|
14
|
+
DELETE_ORDER = '/orders/{orderId}'
|
13
15
|
|
14
16
|
class << self
|
15
17
|
def create(body = {})
|
@@ -1,15 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module OrderSummary
|
3
5
|
include PlentyClient::Endpoint
|
4
6
|
include PlentyClient::Request
|
5
7
|
|
6
|
-
LIST_ORDER_SUMMARYS = '/order_summaries'
|
7
|
-
CREATE_ORDER_SUMMARY = '/order_summaries'
|
8
|
-
FIND_ORDER_SUMMARY = '/order_summaries/{orderSummaryId}'
|
9
|
-
FIND_ORDER_SUMMARY_BY_CONTACT = '/order_summaries/contacts/{contactId}'
|
10
|
-
FIND_ORDER_SUMMARY_BY_ADDRESS = '/order_summaries/orders/{addressId}'
|
11
|
-
UPDATE_ORDER_SUMMARY = '/order_summaries/{orderSummaryId}'
|
12
|
-
DELETE_ORDER_SUMMARY = '/order_summaries/{orderSummaryId}'
|
8
|
+
LIST_ORDER_SUMMARYS = '/order_summaries'
|
9
|
+
CREATE_ORDER_SUMMARY = '/order_summaries'
|
10
|
+
FIND_ORDER_SUMMARY = '/order_summaries/{orderSummaryId}'
|
11
|
+
FIND_ORDER_SUMMARY_BY_CONTACT = '/order_summaries/contacts/{contactId}'
|
12
|
+
FIND_ORDER_SUMMARY_BY_ADDRESS = '/order_summaries/orders/{addressId}'
|
13
|
+
UPDATE_ORDER_SUMMARY = '/order_summaries/{orderSummaryId}'
|
14
|
+
DELETE_ORDER_SUMMARY = '/order_summaries/{orderSummaryId}'
|
13
15
|
|
14
16
|
class << self
|
15
17
|
def create(body = {})
|
@@ -1,11 +1,13 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Payment
|
3
5
|
class Contact
|
4
6
|
include PlentyClient::Endpoint
|
5
7
|
include PlentyClient::Request
|
6
8
|
|
7
|
-
CREATE_PAYMENT_CONTACT_RELATION = '/payment/{paymentId}/contact/{contactId}'
|
8
|
-
DELETE_CONTACTS_PAYMENT = '/payment/{paymentId}/contact'
|
9
|
+
CREATE_PAYMENT_CONTACT_RELATION = '/payment/{paymentId}/contact/{contactId}'
|
10
|
+
DELETE_CONTACTS_PAYMENT = '/payment/{paymentId}/contact'
|
9
11
|
|
10
12
|
class << self
|
11
13
|
def create(payment_id, contact_id, body = {})
|
@@ -1,17 +1,19 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Payment
|
3
5
|
module Method
|
4
6
|
include PlentyClient::Endpoint
|
5
7
|
include PlentyClient::Request
|
6
8
|
|
7
|
-
LIST_PAYMENT_METHODS = '/payments/methods'
|
8
|
-
FIND_PAYMENT_METHOD = '/payments/methods/{paymentMethodId}'
|
9
|
-
FIND_PLUGIN_PAYMENT_METHOD = '/payments/methods/{pluginKey}'
|
10
|
-
CREATE_PAYMENT_METHOD = '/payments/methods'
|
11
|
-
UPDATE_PAYMENT_METHOD = '/payments/methods'
|
12
|
-
UPDATE_PAYMENT_METHOD_WITH_ID = '/payments/methods/{pluginKey}'
|
13
|
-
LIST_PAYMENT_EBICS_ACCOUNTS = '/payments/methods/ebics'
|
14
|
-
CREATE_PAYMENT_EBICS_ACCOUNT = '/payments/methods/ebics'
|
9
|
+
LIST_PAYMENT_METHODS = '/payments/methods'
|
10
|
+
FIND_PAYMENT_METHOD = '/payments/methods/{paymentMethodId}'
|
11
|
+
FIND_PLUGIN_PAYMENT_METHOD = '/payments/methods/{pluginKey}'
|
12
|
+
CREATE_PAYMENT_METHOD = '/payments/methods'
|
13
|
+
UPDATE_PAYMENT_METHOD = '/payments/methods'
|
14
|
+
UPDATE_PAYMENT_METHOD_WITH_ID = '/payments/methods/{pluginKey}'
|
15
|
+
LIST_PAYMENT_EBICS_ACCOUNTS = '/payments/methods/ebics'
|
16
|
+
CREATE_PAYMENT_EBICS_ACCOUNT = '/payments/methods/ebics'
|
15
17
|
|
16
18
|
class << self
|
17
19
|
def list(headers = {}, &block)
|
@@ -1,12 +1,14 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Payment
|
3
5
|
module MethodName
|
4
6
|
include PlentyClient::Endpoint
|
5
7
|
include PlentyClient::Request
|
6
8
|
|
7
|
-
LIST_METHOD_NAMES = '/payments/methodNames'
|
8
|
-
LIST_METHOD_NAMES_FOR_PAYMENT_METHOD = '/payments/methodNames/{paymentMethodId}'
|
9
|
-
FIND_METHOD_NAMES_FOR_PAYMENT_METHOD_BY_LANG = '/payments/methodNames/{paymentMethodId}/{land}'
|
9
|
+
LIST_METHOD_NAMES = '/payments/methodNames'
|
10
|
+
LIST_METHOD_NAMES_FOR_PAYMENT_METHOD = '/payments/methodNames/{paymentMethodId}'
|
11
|
+
FIND_METHOD_NAMES_FOR_PAYMENT_METHOD_BY_LANG = '/payments/methodNames/{paymentMethodId}/{land}'
|
10
12
|
|
11
13
|
class << self
|
12
14
|
def list(headers = {}, &block)
|
@@ -1,12 +1,14 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Payment
|
3
5
|
class Order
|
4
6
|
include PlentyClient::Endpoint
|
5
7
|
include PlentyClient::Request
|
6
8
|
|
7
|
-
LIST_ORDERS_PAYMENTS = '/payments/orders/{orderId}'
|
8
|
-
CREATE_PAYMENT_ORDER_RELATION = '/payment/{paymentId}/order/{orderId}'
|
9
|
-
DELETE_ORDERS_PAYMENT = '/payment/{paymentId}/order'
|
9
|
+
LIST_ORDERS_PAYMENTS = '/payments/orders/{orderId}'
|
10
|
+
CREATE_PAYMENT_ORDER_RELATION = '/payment/{paymentId}/order/{orderId}'
|
11
|
+
DELETE_ORDERS_PAYMENT = '/payment/{paymentId}/order'
|
10
12
|
|
11
13
|
class << self
|
12
14
|
def list(order_id, headers = {}, &block)
|
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Payment
|
3
5
|
module Property
|
@@ -6,11 +8,11 @@ module PlentyClient
|
|
6
8
|
include PlentyClient::Endpoint
|
7
9
|
include PlentyClient::Request
|
8
10
|
|
9
|
-
LIST_PAYMENT_PROPERTY_TYPE_NAMES = '/payments/properties/types/names/{lang}'
|
10
|
-
FIND_PAYMENT_PROPERTY_TYPE_NAME = '/payments/properties/types/names/{nameId}'
|
11
|
-
CREATE_PAYMENT_PROPERTY_TYPE_NAME = '/payments/properties/types/names'
|
12
|
-
UPDATE_PAYMENT_PROPERTY_TYPE_NAME_WITH_ID = '/payments/properties/types/names/{nameId}'
|
13
|
-
UPDATE_PAYMENT_PROPERTY_TYPE_NAME = '/payments/properties/types/names'
|
11
|
+
LIST_PAYMENT_PROPERTY_TYPE_NAMES = '/payments/properties/types/names/{lang}'
|
12
|
+
FIND_PAYMENT_PROPERTY_TYPE_NAME = '/payments/properties/types/names/{nameId}'
|
13
|
+
CREATE_PAYMENT_PROPERTY_TYPE_NAME = '/payments/properties/types/names'
|
14
|
+
UPDATE_PAYMENT_PROPERTY_TYPE_NAME_WITH_ID = '/payments/properties/types/names/{nameId}'
|
15
|
+
UPDATE_PAYMENT_PROPERTY_TYPE_NAME = '/payments/properties/types/names'
|
14
16
|
|
15
17
|
class << self
|
16
18
|
def list(lang, headers = {}, &block)
|
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Payment
|
3
5
|
module Property
|
@@ -5,11 +7,11 @@ module PlentyClient
|
|
5
7
|
include PlentyClient::Endpoint
|
6
8
|
include PlentyClient::Request
|
7
9
|
|
8
|
-
LIST_PAYMENT_PROPERTY_TYPES = '/payments/properties/types'
|
9
|
-
FIND_PAYMENT_PROPERTY_TYPE = '/payments/properties/types/{typeId}'
|
10
|
-
CREATE_PAYMENT_PROPERTY_TYPE = '/payments/properties/types'
|
11
|
-
UPDATE_PAYMENT_PROPERTY_TYPE_WITH_ID = '/payments/properties/types/{typeId}'
|
12
|
-
UPDATE_PAYMENT_PROPERTY_TYPE = '/payments/properties/types'
|
10
|
+
LIST_PAYMENT_PROPERTY_TYPES = '/payments/properties/types'
|
11
|
+
FIND_PAYMENT_PROPERTY_TYPE = '/payments/properties/types/{typeId}'
|
12
|
+
CREATE_PAYMENT_PROPERTY_TYPE = '/payments/properties/types'
|
13
|
+
UPDATE_PAYMENT_PROPERTY_TYPE_WITH_ID = '/payments/properties/types/{typeId}'
|
14
|
+
UPDATE_PAYMENT_PROPERTY_TYPE = '/payments/properties/types'
|
13
15
|
|
14
16
|
class << self
|
15
17
|
def list(headers = {}, &block)
|
@@ -1,16 +1,18 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Payment
|
3
5
|
module Property
|
4
6
|
include PlentyClient::Endpoint
|
5
7
|
include PlentyClient::Request
|
6
8
|
|
7
|
-
LIST_PAYMENT_PROPERTIES = '/payments/properties'
|
8
|
-
LIST_PAYMENT_PROPERTIES_BY_PAYMENT = '/payments/{paymentId}/properties'
|
9
|
-
FIND_PLUGIN_PAYMENT_PROPERTY = '/payments/properties/{propertyId}'
|
10
|
-
CREATE_PAYMENT_PROPERTY = '/payments/properties'
|
11
|
-
UPDATE_PAYMENT_PROPERTY_WITH_ID = '/payments/properties/{propertyId}'
|
12
|
-
UPDATE_PAYMENT_PROPERTY = '/payments/properties'
|
13
|
-
LIST_P_PROPERTIES_BY_TYPE_AND_VALUE = '/payments/property/{propertyTypeId}/{propertyValue}'
|
9
|
+
LIST_PAYMENT_PROPERTIES = '/payments/properties'
|
10
|
+
LIST_PAYMENT_PROPERTIES_BY_PAYMENT = '/payments/{paymentId}/properties'
|
11
|
+
FIND_PLUGIN_PAYMENT_PROPERTY = '/payments/properties/{propertyId}'
|
12
|
+
CREATE_PAYMENT_PROPERTY = '/payments/properties'
|
13
|
+
UPDATE_PAYMENT_PROPERTY_WITH_ID = '/payments/properties/{propertyId}'
|
14
|
+
UPDATE_PAYMENT_PROPERTY = '/payments/properties'
|
15
|
+
LIST_P_PROPERTIES_BY_TYPE_AND_VALUE = '/payments/property/{propertyTypeId}/{propertyValue}'
|
14
16
|
class << self
|
15
17
|
def list(headers = {}, &block)
|
16
18
|
get(build_endpoint(LIST_PAYMENT_PROPERTIES), headers, &block)
|
@@ -1,10 +1,12 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Payment
|
3
5
|
class Status
|
4
6
|
include PlentyClient::Endpoint
|
5
7
|
include PlentyClient::Request
|
6
8
|
|
7
|
-
FIND_PAYMENT_STATUS = '/payments/status/{statusId}'
|
9
|
+
FIND_PAYMENT_STATUS = '/payments/status/{statusId}'
|
8
10
|
|
9
11
|
class << self
|
10
12
|
def find(status_id, headers = {}, &block)
|
@@ -1,10 +1,12 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Payment
|
3
5
|
class Transaction
|
4
6
|
include PlentyClient::Endpoint
|
5
7
|
include PlentyClient::Request
|
6
8
|
|
7
|
-
FIND_PAYMENT_TRANSACTIONS = '/payments/transactions/{transactionTypeId}'
|
9
|
+
FIND_PAYMENT_TRANSACTIONS = '/payments/transactions/{transactionTypeId}'
|
8
10
|
|
9
11
|
class << self
|
10
12
|
def find(transaction_type_id, headers = {}, &block)
|
@@ -1,14 +1,16 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module PlentyClient
|
2
4
|
module Payment
|
3
5
|
include PlentyClient::Endpoint
|
4
6
|
include PlentyClient::Request
|
5
7
|
|
6
|
-
LIST_PAYMENTS = '/payments'
|
7
|
-
FIND_PAYMENT = '/payments/{paymentId}'
|
8
|
-
CREATE_PAYMENT = '/payments'
|
9
|
-
UPDATE_PAYMENT = '/payments/{paymentId}'
|
10
|
-
PAYMENT_ENTRYDATE = '/payments/entrydate'
|
11
|
-
PAYMENT_IMPORTDATE = '/payments/importdate'
|
8
|
+
LIST_PAYMENTS = '/payments'
|
9
|
+
FIND_PAYMENT = '/payments/{paymentId}'
|
10
|
+
CREATE_PAYMENT = '/payments'
|
11
|
+
UPDATE_PAYMENT = '/payments/{paymentId}'
|
12
|
+
PAYMENT_ENTRYDATE = '/payments/entrydate'
|
13
|
+
PAYMENT_IMPORTDATE = '/payments/importdate'
|
12
14
|
|
13
15
|
class << self
|
14
16
|
def list(headers = {}, &block)
|