BigCommerce API Product Import Error: Sorry, something went wrong. Go to product list - bigcommerce

I'm importing products via the API. The import runs well (no errors), but following the import, whenever I select to EDIT one of the imported products from the product list, I get the following error:
Sorry, something went wrong.
Go to product list
I assume something is wrong with the import data I sent, but without further information I don't know where to start looking for the issue.
For reference, below is the JSON POST data for one of the imported products:
Array
(
[name] => Calla Lily & Foliage Silk Flower Centerpiece
[type] => physical
[sku] => FLB108-WG
[description] => Lots of HTML shortened to make this code more vieweable
[weight] => 0
[price] => 159.00
[brand_id] => 38
[inventory_level] => 0
[inventory_warning_level] => 1
[is_free_shipping] =>
[is_visible] => 1
[layout_file] => product.html
[upc] => 848644000167
[availability] => disabled
[custom_url] => Array
(
[url] =>
[is_customized] =>
)
[categories] => Array
(
[0] => 23
)
[bulk_pricing_rules] => Array
(
)
[images] => Array
(
[0] => Array
(
[is_thumbnail] => 1
[sort_order] => 1
[image_url] => https://www.petals.com//files/imagesSF/product/750/flb108-wg_zoom.jpg
[description] => white green calla lily & foliage silk centerpiece, velvety texture, natural appearance green foliage, black stones in acrylic water in heavy 6" square tapered glass vase
)
)
[variants] => Array
(
)
[inventory_tracking] => product
[custom_fields] => Array
(
[0] => Array
(
[name] => pageId
[value] => 47
)
[1] => Array
(
[name] => notice
[value] => FLB108-WG
)
[2] => Array
(
[name] => summaryImage
[value] => /files/imagesSF/product/165/flb108-wg_cat.jpg
)
[3] => Array
(
[name] => product_productName
[value] => Calla Lily & Foliage
)
[4] => Array
(
[name] => product_title
[value] => Calla Lily & Foliage
)
[5] => Array
(
[name] => product_productNumber
[value] => FLB108-WG
)
[6] => Array
(
[name] => product_catalogNumber
[value] => FLB108-WG
)
[7] => Array
(
[name] => product_imagePath
[value] => files/imagesSF/product/165/flb108-wg_cat.jpg
)
[8] => Array
(
[name] => imageBurst
[value] => /files/imagesSF/global/bursts/new-bestseller-icon-burst-105.jpg
)
[9] => Array
(
[name] => acrylicWater
[value] => 1
)
[10] => Array
(
[name] => recipeLocation
[value] => right
)
[11] => Array
(
[name] => prodType
[value] => standard
)
[12] => Array
(
[name] => childTitle
[value] => Calla Lily & Foliage
)
[13] => Array
(
[name] => expShip
[value] => 1
)
[14] => Array
(
[name] => imageBurstLink
[value] => /files/filesSF/popups/express-shipping.html
)
[15] => Array
(
[name] => mobile_name
[value] => Calla Lily & Foliage
)
[16] => Array
(
[name] => googleTitle
[value] => Silk Calla Lily Flower Centerpiece with Foliage
)
)
)
Below is the response from BC:
stdClass Object
(
[data] => stdClass Object
(
[id] => 234
[name] => Calla Lily & Foliage
Silk Flower Centerpiece
[type] => physical
[sku] => FLB108-WG
[description] => Again reduced for your viewing pleasure
[weight] => 0
[width] => 0
[depth] => 0
[height] => 0
[price] => 159
[cost_price] => 0
[retail_price] => 0
[sale_price] => 0
[map_price] => 0
[tax_class_id] => 0
[product_tax_code] =>
[calculated_price] => 159
[categories] => Array
(
[0] => 23
)
[brand_id] => 38
[option_set_id] =>
[option_set_display] => right
[inventory_level] => 0
[inventory_warning_level] => 1
[inventory_tracking] => product
[reviews_rating_sum] => 0
[reviews_count] => 0
[total_sold] => 0
[fixed_cost_shipping_price] => 0
[is_free_shipping] =>
[is_visible] => 1
[is_featured] =>
[related_products] => Array
(
[0] => -1
)
[warranty] =>
[bin_picking_number] =>
[layout_file] => product.html
[upc] => 848644000167
[mpn] =>
[gtin] =>
[search_keywords] =>
[availability] => disabled
[availability_description] =>
[gift_wrapping_options_type] => any
[gift_wrapping_options_list] => Array
(
)
[sort_order] => 0
[condition] => New
[is_condition_shown] =>
[order_quantity_minimum] => 0
[order_quantity_maximum] => 0
[page_title] =>
[meta_keywords] => Array
(
)
[meta_description] =>
[date_created] => 2020-08-13T22:16:57+00:00
[date_modified] => 2020-08-13T22:16:57+00:00
[view_count] => 0
[preorder_release_date] =>
[preorder_message] =>
[is_preorder_only] =>
[is_price_hidden] =>
[price_hidden_label] =>
[custom_url] =>
[base_variant_id] => 222
[open_graph_type] => product
[open_graph_title] =>
[open_graph_description] =>
[open_graph_use_meta_description] => 1
[open_graph_use_product_name] => 1
[open_graph_use_image] => 1
[variants] => Array
(
[0] => stdClass Object
(
[id] => 222
[product_id] => 234
[sku] => FLB108-WG
[sku_id] =>
[price] => 159
[calculated_price] => 159
[sale_price] => 0
[retail_price] => 0
[map_price] => 0
[weight] => 0
[width] => 0
[height] => 0
[depth] => 0
[is_free_shipping] =>
[fixed_cost_shipping_price] => 0
[calculated_weight] => 0
[purchasing_disabled] => 1
[purchasing_disabled_message] =>
[image_url] => https://cdn11.bigcommerce.com/s-r932bs4ubb/products/234/images/471/flb108-wg_zoom__07246.1597357017.386.513.jpg?c=1
[cost_price] => 0
[upc] => 848644000167
[mpn] =>
[gtin] =>
[inventory_level] => 0
[inventory_warning_level] => 1
[bin_picking_number] =>
[option_values] => Array
(
)
)
)
[images] => Array
(
[0] => stdClass Object
(
[id] => 471
[product_id] => 234
[is_thumbnail] => 1
[sort_order] => 1
[description] => white green calla lily & foliage silk centerpiece, velvety texture, natural appearance green foliage, black stones in acrylic water in heavy 6" square tapered glass vase
[image_file] => h/864/flb108-wg_zoom__07246.jpg
[url_zoom] => https://cdn11.bigcommerce.com/s-r932bs4ubb/products/234/images/471/flb108-wg_zoom__07246.1597357017.1280.1280.jpg?c=1
[url_standard] => https://cdn11.bigcommerce.com/s-r932bs4ubb/products/234/images/471/flb108-wg_zoom__07246.1597357017.386.513.jpg?c=1
[url_thumbnail] => https://cdn11.bigcommerce.com/s-r932bs4ubb/products/234/images/471/flb108-wg_zoom__07246.1597357017.220.290.jpg?c=1
[url_tiny] => https://cdn11.bigcommerce.com/s-r932bs4ubb/products/234/images/471/flb108-wg_zoom__07246.1597357017.44.58.jpg?c=1
[date_modified] => 2020-08-13T22:16:57+00:00
)
)
[primary_image] => stdClass Object
(
[id] => 471
[product_id] => 234
[is_thumbnail] => 1
[sort_order] => 1
[description] => white green calla lily & foliage silk centerpiece, velvety texture, natural appearance green foliage, black stones in acrylic water in heavy 6" square tapered glass vase
[image_file] => h/864/flb108-wg_zoom__07246.jpg
[url_zoom] => https://cdn11.bigcommerce.com/s-r932bs4ubb/products/234/images/471/flb108-wg_zoom__07246.1597357017.1280.1280.jpg?c=1
[url_standard] => https://cdn11.bigcommerce.com/s-r932bs4ubb/products/234/images/471/flb108-wg_zoom__07246.1597357017.386.513.jpg?c=1
[url_thumbnail] => https://cdn11.bigcommerce.com/s-r932bs4ubb/products/234/images/471/flb108-wg_zoom__07246.1597357017.220.290.jpg?c=1
[url_tiny] => https://cdn11.bigcommerce.com/s-r932bs4ubb/products/234/images/471/flb108-wg_zoom__07246.1597357017.44.58.jpg?c=1
[date_modified] => 2020-08-13T22:16:57+00:00
)
[videos] => Array
(
)
[custom_fields] => Array
(
[0] => stdClass Object
(
[id] => 2808
[name] => pageId
[value] => 47
)
[1] => stdClass Object
(
[id] => 2809
[name] => notice
[value] => FLB108-WG
)
[2] => stdClass Object
(
[id] => 2810
[name] => summaryImage
[value] => /files/imagesSF/product/165/flb108-wg_cat.jpg
)
[3] => stdClass Object
(
[id] => 2811
[name] => product_productName
[value] => Calla Lily & Foliage
)
[4] => stdClass Object
(
[id] => 2812
[name] => product_title
[value] => Calla Lily & Foliage
)
[5] => stdClass Object
(
[id] => 2813
[name] => product_productNumber
[value] => FLB108-WG
)
[6] => stdClass Object
(
[id] => 2814
[name] => product_catalogNumber
[value] => FLB108-WG
)
[7] => stdClass Object
(
[id] => 2815
[name] => product_imagePath
[value] => files/imagesSF/product/165/flb108-wg_cat.jpg
)
[8] => stdClass Object
(
[id] => 2816
[name] => imageBurst
[value] => /files/imagesSF/global/bursts/new-bestseller-icon-burst-105.jpg
)
[9] => stdClass Object
(
[id] => 2817
[name] => acrylicWater
[value] => 1
)
[10] => stdClass Object
(
[id] => 2818
[name] => recipeLocation
[value] => right
)
[11] => stdClass Object
(
[id] => 2819
[name] => prodType
[value] => standard
)
[12] => stdClass Object
(
[id] => 2820
[name] => childTitle
[value] => Calla Lily & Foliage
)
[13] => stdClass Object
(
[id] => 2821
[name] => expShip
[value] => 1
)
[14] => stdClass Object
(
[id] => 2822
[name] => imageBurstLink
[value] => /files/filesSF/popups/express-shipping.html
)
[15] => stdClass Object
(
[id] => 2823
[name] => mobile_name
[value] => Calla Lily & Foliage
)
[16] => stdClass Object
(
[id] => 2824
[name] => googleTitle
[value] => Silk Calla Lily Flower Centerpiece with Foliage
)
)
[bulk_pricing_rules] => Array
(
)
[reviews] => Array
(
)
[options] => Array
(
)
[modifiers] => Array
(
)
[parent_relations] => Array
(
)
)
[meta] => stdClass Object
(
)
)

Turns out the issue is with the custom_url element:
[custom_url] => Array
(
[url] =>
[is_customized] =>
)
This should not be included at all if url is not customized.

Related

How to interpret vin/vout on a Bitcoin transaction?

I used nownodes api to get this response on a transaction:
(
[txid] => 38ac1348219f8aa9349f497bfa6f8d05f775cafbbd26354867d22ca84f15e1e1
[version] => 2
[vin] => Array
(
[0] => stdClass Object
(
[txid] => 38cff250be850140644a1abf022b22f3e59cab15c6091706c3f73218a4d72050
[vout] => 1
[sequence] => 4294967295
[n] => 0
[addresses] => Array
(
[0] => 1EJtMFThodiQ1j26xy1kugFck9325C38CQ
)
[isAddress] => 1
[value] => 158316
[hex] => 4830450221009548f997389fd9881dfed78fe25fcce77f5b96d1545da91dfa13f56db3c02f6e02207fe239ac7916681edc36afd6a9a569981cd12c2c6801616bc15794be5c024431012102afe2e887e3ff56edcebe6b1aa6bf48f4a5a7f02cfc8d743e778896df2054adee
)
)
[vout] => Array
(
[0] => stdClass Object
(
[value] => 7000
[n] => 0
[hex] => a9144a09be6e2917ef00e5d72bc38035db5c5a5ed8ec87
[addresses] => Array
(
[0] => 38SVbkkFE8qcJuGyTJ9fY2cbGS3xknEfYr
)
[isAddress] => 1
)
[1] => stdClass Object
(
[value] => 146856
[n] => 1
[hex] => 76a91491fb9214e6ad9b3ea19c1fd7d3a646e12f804d2688ac
[addresses] => Array
(
[0] => 1EJtMFThodiQ1j26xy1kugFck9325C38CQ
)
[isAddress] => 1
)
)
[blockHash] => 000000000000000000050bfb2a645a5eb7ac882aeb1782bce37ef6a2652c383b
[blockHeight] => 743696
[confirmations] => 8
[blockTime] => 1657005608
[value] => 153856
[valueIn] => 158316
[fees] => 4460
[hex] => 02000000015020d7a41832f7c3061709c615ab9ce5f3222b02bf1a4a64400185be50f2cf38010000006b4830450221009548f997389fd9881dfed78fe25fcce77f5b96d1545da91dfa13f56db3c02f6e02207fe239ac7916681edc36afd6a9a569981cd12c2c6801616bc15794be5c024431012102afe2e887e3ff56edcebe6b1aa6bf48f4a5a7f02cfc8d743e778896df2054adeeffffffff02581b00000000000017a9144a09be6e2917ef00e5d72bc38035db5c5a5ed8ec87a83d0200000000001976a91491fb9214e6ad9b3ea19c1fd7d3a646e12f804d2688ac00000000
)
The transaction was for: 0.0001146 BTC
And the fee was: 0.0000446
Totalling: 0.0001592
However, based on teh result from Nownodes, how can I see what the transaction total was? I can easily see the fee under "Fees". But how do I calculate the actually amount that came in or went out for this transaction?
Thanks!
valueIn = vout[0][value] + vout[1][value] + [fees]
valueIn = 158316
Is that what you have been looking for?

PayPal Orders API payment to a third party payee

I want to facilitate sending money to a merchant's PayPal account. I've made an additional Business Account in the PayPal Sandbox. I've made an order call with this account as a payee. But when I get the order (after approval from the payer) then the payee is still my actor account. Do I need some special configuration in the sandbox? And in production does the intended payee need to give me special permissions?
Array
(
[intent] => AUTHORIZE
[application_context] => Array
(
[return_url] => http://example.com/cart/PP_Payment.php?success=true
[cancel_url] => http://example.com/cart/PP_Payment.php?success=false
[brand_name] => Company X
)
[payee] => Array
(
[email_address] => sb-u4hosest4#business.example.com
)
[inovoice_id] => 1-GD2U-70E7-4Y
[items] => Array
(
[0] => Array
(
[quantity] => 1
[name] => Rabenhorst Klostergarten BIO Mini
[unit_amount] => Array
(
[currency_code] => EUR
[value] => 1.04
)
[sku] => 97899
)
[1] => Array
(
[quantity] => 1
[name] => Lupinen Filet
[unit_amount] => Array
(
[currency_code] => EUR
[value] => 3.87
)
[sku] => 66911
)
[2] => Array
(
[quantity] => 1
[name] => Kühltasche/-akku
[unit_amount] => Array
(
[currency_code] => EUR
[value] => 6
)
[sku] => P002
)
)
[purchase_units] => Array
(
[0] => Array
(
[amount] => Array
(
[currency_code] => EUR
[value] => 15.86
[breakdown] => Array
(
[item_total] => Array
(
[currency_code] => EUR
[value] => 10.91
)
[shipping] => Array
(
[currency_code] => EUR
[value] => 4.95
)
)
)
)
)
)
Result: ##########
Array
(
[id] => 5KPxxxx
[links] => Array
(
[0] => Array
(
[href] => https://api.sandbox.paypal.com/v2/checkout/orders/5KPxxxx
[rel] => self
[method] => GET
)
[1] => Array
(
[href] => https://www.sandbox.paypal.com/checkoutnow?token=5KPxxxx
[rel] => approve
[method] => GET
)
[2] => Array
(
[href] => https://api.sandbox.paypal.com/v2/checkout/orders/5KPxxxx
[rel] => update
[method] => PATCH
)
[3] => Array
(
[href] => https://api.sandbox.paypal.com/v2/checkout/orders/5KPxxxx/authorize
[rel] => authorize
[method] => POST
)
)
[status] => CREATED
)
but when I get the order then the payee is me and not the selected third party
Array
(
[id] => 5KPxxxx
[intent] => AUTHORIZE
[purchase_units] => Array
(
[0] => Array
(
[reference_id] => default
[amount] => Array
(
[currency_code] => EUR
[value] => 15.86
[breakdown] => Array
(
[item_total] => Array
(
[currency_code] => EUR
[value] => 10.91
)
[shipping] => Array
(
[currency_code] => EUR
[value] => 4.95
)
)
)
[payee] => Array
(
[email_address] => mike#www.org
[merchant_id] => FXXX
[display_data] => Array
(
[brand_name] => Company X
)
)
[shipping] => Array
(
[name] => Array
(
[full_name] => test buyer
)
[address] => Array
(
[address_line_1] => ESpachstr. 1
[admin_area_2] => Freiburg
[admin_area_1] => Empty
[postal_code] => 79111
[country_code] => DE
)
)
)
)
[payer] => Array
(
[name] => Array
(
[given_name] => test
[surname] => buyer
)
[email_address] => mt-buyer#w3xxx.org
[payer_id] => 4xxx
[address] => Array
(
[country_code] => DE
)
)
[create_time] => 2020-03-22T09:32:48Z
[links] => Array
(
[0] => Array
(
[href] => https://api.sandbox.paypal.com/v2/checkout/orders/5KPxxxx
[rel] => self
[method] => GET
)
[1] => Array
(
[href] => https://api.sandbox.paypal.com/v2/checkout/orders/5KPxxxx/authorize
[rel] => authorize
[method] => POST
)
)
[status] => APPROVED
)
[payee] => Array
(
[email_address] => sb-u4hosest4#business.example.com
)
This payee is being ignored because it is not in the purchase_units object.
See the example in the documentation.
While you can for sure do intent:CAPTURE, another consideration is that intent:AUTHORIZE (and later capture) might not be supported without permissions.

Ebay API:Update the Value of the SKU in a Variation using ReviseItemRequest

I am trying to update the stock for variations products, here is my feed xml code:
$itemid = 123137114746;
$sku = 5052933687242;
$qty = 1;
$feed = <<< EOD
<?xml version="1.0" encoding="utf-8"?>
<ReviseItemRequest xmlns="urn:ebay:apis:eBLBaseComponents">
<RequesterCredentials>
<eBayAuthToken>$eBay_auth_token</eBayAuthToken>
</RequesterCredentials>
<Item ComplexType="ItemType">
<ItemID>$itemid</ItemID>
<Variations>
<Variation>
<SKU>$sku</SKU>
<Quantity>$qty</Quantity>
</Variation>
</Variations>
</Item>
<MessageID>1</MessageID>
<WarningLevel>Low</WarningLevel>
<Version>$eBay_api_version</Version>
</ReviseItemRequest>​
EOD;
Inventory quantity are updating on ebay, but it gives warning in response
SimpleXMLElement Object
(
[Timestamp] => 2020-01-14T04:50:42.611Z
[Ack] => Warning
[CorrelationID] => 1
[Errors] => Array
(
[0] => SimpleXMLElement Object
(
[ShortMessage] => The item specific Vintage is missing.
[LongMessage] => The item specific Vintage is missing. Add Vintage to this listing, enter a valid value and then try again.
[ErrorCode] => 21919403
[SeverityCode] => Warning
[ErrorParameters] => Array
(
[0] => SimpleXMLElement Object
(
[#attributes] => Array
(
[ParamID] => 0
)
[Value] => The item specific Vintage is missing.
)
[1] => SimpleXMLElement Object
(
[#attributes] => Array
(
[ParamID] => 1
)
[Value] => The item specific Vintage is missing. Add Vintage to this listing, enter a valid value and then try again.
)
[2] => SimpleXMLElement Object
(
[#attributes] => Array
(
[ParamID] => 2
)
[Value] => Vintage
)
)
[ErrorClassification] => RequestError
)
[1] => SimpleXMLElement Object
(
[ShortMessage] => The item specific Fit is missing.
[LongMessage] => The item specific Fit is missing. Add Fit to this listing, enter a valid value and then try again.
[ErrorCode] => 21919403
[SeverityCode] => Warning
[ErrorParameters] => Array
(
[0] => SimpleXMLElement Object
(
[#attributes] => Array
(
[ParamID] => 0
)
[Value] => The item specific Fit is missing.
)
[1] => SimpleXMLElement Object
(
[#attributes] => Array
(
[ParamID] => 1
)
[Value] => The item specific Fit is missing. Add Fit to this listing, enter a valid value and then try again.
)
[2] => SimpleXMLElement Object
(
[#attributes] => Array
(
[ParamID] => 2
)
[Value] => Fit
)
)
[ErrorClassification] => RequestError
)
[2] => SimpleXMLElement Object
(
[ShortMessage] => The item specific Closure is missing.
[LongMessage] => The item specific Closure is missing. Add Closure to this listing, enter a valid value and then try again.
[ErrorCode] => 21919403
[SeverityCode] => Warning
[ErrorParameters] => Array
(
[0] => SimpleXMLElement Object
(
[#attributes] => Array
(
[ParamID] => 0
)
[Value] => The item specific Closure is missing.
)
[1] => SimpleXMLElement Object
(
[#attributes] => Array
(
[ParamID] => 1
)
[Value] => The item specific Closure is missing. Add Closure to this listing, enter a valid value and then try again.
)
[2] => SimpleXMLElement Object
(
[#attributes] => Array
(
[ParamID] => 2
)
[Value] => Closure
)
)
[ErrorClassification] => RequestError
)
[3] => SimpleXMLElement Object
(
[ShortMessage] => The item specific Front Type is missing.
[LongMessage] => The item specific Front Type is missing. Add Front Type to this listing, enter a valid value and then try again.
[ErrorCode] => 21919403
[SeverityCode] => Warning
[ErrorParameters] => Array
(
[0] => SimpleXMLElement Object
(
[#attributes] => Array
(
[ParamID] => 0
)
[Value] => The item specific Front Type is missing.
)
[1] => SimpleXMLElement Object
(
[#attributes] => Array
(
[ParamID] => 1
)
[Value] => The item specific Front Type is missing. Add Front Type to this listing, enter a valid value and then try again.
)
[2] => SimpleXMLElement Object
(
[#attributes] => Array
(
[ParamID] => 2
)
[Value] => Front Type
)
)
[ErrorClassification] => RequestError
)
[4] => SimpleXMLElement Object
(
[ShortMessage] => Funds from your sales will be unavailable and displayed as 'pending' in your PayPal account for a period of time.
[LongMessage] => Funds from your sales will be unavailable and displayed as 'pending' in your PayPal account for a period of time. Learn more: http://cgi6.ebay.co.uk/ws/eBayISAPI.dll?UserPolicyMessaging
[ErrorCode] => 21917236
[SeverityCode] => Warning
[ErrorParameters] => SimpleXMLElement Object
(
[#attributes] => Array
(
[ParamID] => 0
)
[Value] => http://cgi6.ebay.co.uk/ws/eBayISAPI.dll?UserPolicyMessaging
)
[ErrorClassification] => RequestError
)
)
[Version] => 1131
[Build] => E1131_UNI_API5_19109898_R1
[ItemID] => 123137114746
[StartTime] => 2018-05-16T15:39:44.000Z
[EndTime] => 2020-01-16T15:39:44.000Z
[Fees] => SimpleXMLElement Object
(
[Fee] => Array
(
[0] => SimpleXMLElement Object
(
[Name] => AuctionLengthFee
[Fee] => 0.0
)
[1] => SimpleXMLElement Object
(
[Name] => BoldFee
[Fee] => 0.0
)
[2] => SimpleXMLElement Object
(
[Name] => BuyItNowFee
[Fee] => 0.0
)
[3] => SimpleXMLElement Object
(
[Name] => CategoryFeaturedFee
[Fee] => 0.0
)
[4] => SimpleXMLElement Object
(
[Name] => FeaturedFee
[Fee] => 0.0
)
[5] => SimpleXMLElement Object
(
[Name] => GalleryPlusFee
[Fee] => 0.0
)
[6] => SimpleXMLElement Object
(
[Name] => FeaturedGalleryFee
[Fee] => 0.0
)
[7] => SimpleXMLElement Object
(
[Name] => FixedPriceDurationFee
[Fee] => 0.0
)
[8] => SimpleXMLElement Object
(
[Name] => GalleryFee
[Fee] => 0.0
)
[9] => SimpleXMLElement Object
(
[Name] => GiftIconFee
[Fee] => 0.0
)
[10] => SimpleXMLElement Object
(
[Name] => HighLightFee
[Fee] => 0.0
)
[11] => SimpleXMLElement Object
(
[Name] => InsertionFee
[Fee] => 0.0
)
[12] => SimpleXMLElement Object
(
[Name] => InternationalInsertionFee
[Fee] => 0.0
)
[13] => SimpleXMLElement Object
(
[Name] => ListingDesignerFee
[Fee] => 0.0
)
[14] => SimpleXMLElement Object
(
[Name] => ListingFee
[Fee] => 0.0
)
[15] => SimpleXMLElement Object
(
[Name] => PhotoDisplayFee
[Fee] => 0.0
)
[16] => SimpleXMLElement Object
(
[Name] => PhotoFee
[Fee] => 0.0
)
[17] => SimpleXMLElement Object
(
[Name] => ReserveFee
[Fee] => 0.0
)
[18] => SimpleXMLElement Object
(
[Name] => SchedulingFee
[Fee] => 0.0
)
[19] => SimpleXMLElement Object
(
[Name] => SubtitleFee
[Fee] => 0.0
)
[20] => SimpleXMLElement Object
(
[Name] => BorderFee
[Fee] => 0.0
)
[21] => SimpleXMLElement Object
(
[Name] => ProPackBundleFee
[Fee] => 0.0
)
[22] => SimpleXMLElement Object
(
[Name] => BasicUpgradePackBundleFee
[Fee] => 0.0
)
[23] => SimpleXMLElement Object
(
[Name] => ValuePackBundleFee
[Fee] => 0.0
)
[24] => SimpleXMLElement Object
(
[Name] => PrivateListingFee
[Fee] => 0.0
)
[25] => SimpleXMLElement Object
(
[Name] => ProPackPlusBundleFee
[Fee] => 0.0
)
[26] => SimpleXMLElement Object
(
[Name] => MotorsGermanySearchFee
[Fee] => 0.0
)
)
)
[DiscountReason] => SpecialOffer
)
In response it return Ack as Warning and long Error with [ErrorCode] => 21919403 [SeverityCode] => Warning
Is any thing missing here ?
Please help
thanks
Instead of 'ReviseItemRequest' I have used 'ReviseInventoryStatusRequest' that solve my problem ;)
Changed code:
$itemid = 123137114746;
$sku = 5052933687242;
$qty = 1;
$feed = <<< EOD
<?xml version="1.0" encoding="utf-8"?>
<ReviseInventoryStatusRequest xmlns="urn:ebay:apis:eBLBaseComponents">
<RequesterCredentials>
<eBayAuthToken>$eBay_auth_token</eBayAuthToken>
</RequesterCredentials>
<InventoryStatus> InventoryStatusType
<ItemID>$itemid</ItemID>
<Quantity>$qty</Quantity>
<SKU>$sku</SKU>
</InventoryStatus>
<MessageID>1</MessageID>
<WarningLevel>High</WarningLevel>
<Version>$eBay_api_version</Version>
</ReviseInventoryStatusRequest>​
EOD;
Response:
SimpleXMLElement Object
(
[Timestamp] => 2020-01-14T06:20:32.877Z
[Ack] => Success
[CorrelationID] => 1
[Version] => 1131
[Build] => E1131_UNI_API5_19109898_R1
[InventoryStatus] => SimpleXMLElement Object
(
[SKU] => 5052933687242
[ItemID] => 123137114746
[StartPrice] => 39.99
[Quantity] => 1
)
[Fees] => SimpleXMLElement Object
(
[ItemID] => 123137114746
[Fee] => Array
(
[0] => SimpleXMLElement Object
(
[Name] => AuctionLengthFee
[Fee] => 0.0
)
[1] => SimpleXMLElement Object
(
[Name] => BoldFee
[Fee] => 0.0
)
[2] => SimpleXMLElement Object
(
[Name] => BuyItNowFee
[Fee] => 0.0
)
[3] => SimpleXMLElement Object
(
[Name] => CategoryFeaturedFee
[Fee] => 0.0
)
[4] => SimpleXMLElement Object
(
[Name] => FeaturedFee
[Fee] => 0.0
)
[5] => SimpleXMLElement Object
(
[Name] => GalleryPlusFee
[Fee] => 0.0
)
[6] => SimpleXMLElement Object
(
[Name] => FeaturedGalleryFee
[Fee] => 0.0
)
[7] => SimpleXMLElement Object
(
[Name] => FixedPriceDurationFee
[Fee] => 0.0
)
[8] => SimpleXMLElement Object
(
[Name] => GalleryFee
[Fee] => 0.0
)
[9] => SimpleXMLElement Object
(
[Name] => GiftIconFee
[Fee] => 0.0
)
[10] => SimpleXMLElement Object
(
[Name] => HighLightFee
[Fee] => 0.0
)
[11] => SimpleXMLElement Object
(
[Name] => InsertionFee
[Fee] => 0.0
)
[12] => SimpleXMLElement Object
(
[Name] => InternationalInsertionFee
[Fee] => 0.0
)
[13] => SimpleXMLElement Object
(
[Name] => ListingDesignerFee
[Fee] => 0.0
)
[14] => SimpleXMLElement Object
(
[Name] => ListingFee
[Fee] => 0.0
)
[15] => SimpleXMLElement Object
(
[Name] => PhotoDisplayFee
[Fee] => 0.0
)
[16] => SimpleXMLElement Object
(
[Name] => PhotoFee
[Fee] => 0.0
)
[17] => SimpleXMLElement Object
(
[Name] => ReserveFee
[Fee] => 0.0
)
[18] => SimpleXMLElement Object
(
[Name] => SchedulingFee
[Fee] => 0.0
)
[19] => SimpleXMLElement Object
(
[Name] => SubtitleFee
[Fee] => 0.0
)
[20] => SimpleXMLElement Object
(
[Name] => BorderFee
[Fee] => 0.0
)
[21] => SimpleXMLElement Object
(
[Name] => ProPackBundleFee
[Fee] => 0.0
)
[22] => SimpleXMLElement Object
(
[Name] => BasicUpgradePackBundleFee
[Fee] => 0.0
)
[23] => SimpleXMLElement Object
(
[Name] => ValuePackBundleFee
[Fee] => 0.0
)
[24] => SimpleXMLElement Object
(
[Name] => PrivateListingFee
[Fee] => 0.0
)
[25] => SimpleXMLElement Object
(
[Name] => ProPackPlusBundleFee
[Fee] => 0.0
)
[26] => SimpleXMLElement Object
(
[Name] => MotorsGermanySearchFee
[Fee] => 0.0
)
)
)
)
Hope,this will help someone :)

Amazon API response "DetailPageURL" is my affilate link for Product?

i am creating a joomla script and i want to know Amazon API response "DetailPageURL" is my affiliate link for Product? or i need to create a link for product with my affiliate id etc?
here is my api response
stdClass Object(
[ASIN] => B00H9DKCLS
[DetailPageURL] => http://www.amazon.in/Chevron-Leather-Cover-Samsung-Galaxy/dp/B00H9DKCLS%3FSubscriptionId%3DAKIAJ7ECVOCWYGWRSAWA%26tag%3Dfindindia-21%26linkCode%3Dsp1%26camp%3D2025%26creative%3D165953%26creativeASIN%3DB00H9DKCLS
[SalesRank] => 1103
[SmallImage] => stdClass Object
(
[URL] => http://ecx.images-amazon.com/images/I/51VsYDdojQL._SL75_.jpg
[Height] => stdClass Object
(
[_] => 75
[Units] => pixels
)
[Width] => stdClass Object
(
[_] => 75
[Units] => pixels
)
)
[MediumImage] => stdClass Object
(
[URL] => http://ecx.images-amazon.com/images/I/51VsYDdojQL._SL160_.jpg
[Height] => stdClass Object
(
[_] => 160
[Units] => pixels
)
[Width] => stdClass Object
(
[_] => 160
[Units] => pixels
)
)
[LargeImage] => stdClass Object
(
[URL] => http://ecx.images-amazon.com/images/I/51VsYDdojQL.jpg
[Height] => stdClass Object
(
[_] => 500
[Units] => pixels
)
[Width] => stdClass Object
(
[_] => 500
[Units] => pixels
)
)
[ImageSets] => stdClass Object
(
[ImageSet] => Array
(
[0] => stdClass Object
(
[SwatchImage] => stdClass Object
(
[URL] => http://ecx.images-amazon.com/images/I/51VsYDdojQL._SL30_.jpg
[Height] => stdClass Object
(
[_] => 30
[Units] => pixels
)
[Width] => stdClass Object
(
[_] => 30
[Units] => pixels
)
)
[SmallImage] => stdClass Object
(
[URL] => http://ecx.images-amazon.com/images/I/51VsYDdojQL._SL75_.jpg
[Height] => stdClass Object
(
[_] => 75
[Units] => pixels
)
[Width] => stdClass Object
(
[_] => 75
[Units] => pixels
)
)
[ThumbnailImage] => stdClass Object
(
[URL] => http://ecx.images-amazon.com/images/I/51VsYDdojQL._SL75_.jpg
[Height] => stdClass Object
(
[_] => 75
[Units] => pixels
)
[Width] => stdClass Object
(
[_] => 75
[Units] => pixels
)
)
[TinyImage] => stdClass Object
(
[URL] => http://ecx.images-amazon.com/images/I/51VsYDdojQL._SL110_.jpg
[Height] => stdClass Object
(
[_] => 110
[Units] => pixels
)
[Width] => stdClass Object
(
[_] => 110
[Units] => pixels
)
)
[MediumImage] => stdClass Object
(
[URL] => http://ecx.images-amazon.com/images/I/51VsYDdojQL._SL160_.jpg
[Height] => stdClass Object
(
[_] => 160
[Units] => pixels
)
[Width] => stdClass Object
(
[_] => 160
[Units] => pixels
)
)
[LargeImage] => stdClass Object
(
[URL] => http://ecx.images-amazon.com/images/I/51VsYDdojQL.jpg
[Height] => stdClass Object
(
[_] => 500
[Units] => pixels
)
[Width] => stdClass Object
(
[_] => 500
[Units] => pixels
)
)
[Category] => primary
)
[1] => stdClass Object
(
[SwatchImage] => stdClass Object
(
[URL] => http://ecx.images-amazon.com/images/I/41ru1SlzYoL._SL30_.jpg
[Height] => stdClass Object
(
[_] => 20
[Units] => pixels
)
[Width] => stdClass Object
(
[_] => 30
[Units] => pixels
)
)
[SmallImage] => stdClass Object
(
[URL] => http://ecx.images-amazon.com/images/I/41ru1SlzYoL._SL75_.jpg
[Height] => stdClass Object
(
[_] => 50
[Units] => pixels
)
[Width] => stdClass Object
(
[_] => 75
[Units] => pixels
)
)
[ThumbnailImage] => stdClass Object
(
[URL] => http://ecx.images-amazon.com/images/I/41ru1SlzYoL._SL75_.jpg
[Height] => stdClass Object
(
[_] => 50
[Units] => pixels
)
[Width] => stdClass Object
(
[_] => 75
[Units] => pixels
)
)
[TinyImage] => stdClass Object
(
[URL] => http://ecx.images-amazon.com/images/I/41ru1SlzYoL._SL110_.jpg
[Height] => stdClass Object
(
[_] => 73
[Units] => pixels
)
[Width] => stdClass Object
(
[_] => 110
[Units] => pixels
)
)
[MediumImage] => stdClass Object
(
[URL] => http://ecx.images-amazon.com/images/I/41ru1SlzYoL._SL160_.jpg
[Height] => stdClass Object
(
[_] => 106
[Units] => pixels
)
[Width] => stdClass Object
(
[_] => 160
[Units] => pixels
)
)
[LargeImage] => stdClass Object
(
[URL] => http://ecx.images-amazon.com/images/I/41ru1SlzYoL.jpg
[Height] => stdClass Object
(
[_] => 332
[Units] => pixels
)
[Width] => stdClass Object
(
[_] => 500
[Units] => pixels
)
)
[Category] => variant
)
)
)
[ItemAttributes] => stdClass Object
(
[Binding] => Electronics
[Brand] => Generic
[Color] => Black
[EAN] => 8902714150076
[EANList] => stdClass Object
(
[EANListElement] => 8902714150076
)
[Feature] => Array
(
[0] => Made of high quality leather
[1] => Non sensor
[2] => Protects Phone when carrying it in pocket, purse, or travel bag
[3] => Stop worrying about scratching or dropping your phone.
[4] => Free screen-guard (Recommended to be used for your Phone)
)
[ItemDimensions] => stdClass Object
(
[Height] => stdClass Object
(
[_] => 105
[Units] => hundredths-inches
)
[Length] => stdClass Object
(
[_] => 708
[Units] => hundredths-inches
)
[Weight] => stdClass Object
(
[_] => 2
[Units] => hundredths-pounds
)
[Width] => stdClass Object
(
[_] => 215
[Units] => hundredths-inches
)
)
[LegalDisclaimer] => Terms & Conditions of Sale · The seller will not ship items outside Indian Territory. · Logos, Names and signs depicted in the listings are owned by the respective legal trademark owners. The seller is just using them for depiction purpose only. · The seller imports the items in bulk from market places outside Indian Territory. Few of the products come in retail package and most do not have retail package. The items are duty paid with proper import procedures. Any levy on Octroi, entry tax are not included in this commercial transaction.
[MPN] => S4 CALLER ID FLIP BLACK
[PackageDimensions] => stdClass Object
(
[Height] => stdClass Object
(
[_] => 39
[Units] => hundredths-inches
)
[Length] => stdClass Object
(
[_] => 701
[Units] => hundredths-inches
)
[Weight] => stdClass Object
(
[_] => 2
[Units] => hundredths-pounds
)
[Width] => stdClass Object
(
[_] => 362
[Units] => hundredths-inches
)
)
[PartNumber] => S4 CALLER ID FLIP BLACK
[ProductGroup] => CE
[ProductTypeName] => PHONE_ACCESSORY
[Title] => Chevron PU Leather Flip Cover Case For Samsung Galaxy S4 (Black)
)
[OfferSummary] => stdClass Object
(
[LowestNewPrice] => stdClass Object
(
[Amount] => 10400
[CurrencyCode] => INR
[FormattedPrice] => INR 104.00
)
[TotalNew] => 5
[TotalUsed] => 0
[TotalCollectible] => 0
[TotalRefurbished] => 0
)
[Offers] => stdClass Object
(
[TotalOffers] => 1
[TotalOfferPages] => 1
[MoreOffersUrl] => http://www.amazon.in/gp/offer-listing/B00H9DKCLS%3FSubscriptionId%3DAKIAJ7ECVOCWYGWRSAWA%26tag%3Dfindindia-21%26linkCode%3Dsp1%26camp%3D2025%26creative%3D165953%26creativeASIN%3DB00H9DKCLS
[Offer] => stdClass Object
(
[OfferAttributes] => stdClass Object
(
[Condition] => New
)
[OfferListing] => stdClass Object
(
[OfferListingId] => B8tvOIRHPCElfqnqn4HSiKxoSyUfKI1msSlJsvf1imk9VKvjz0KFnIZdDrVsYTzMKHsPtMPxKCh6%2B%2FQEbc4lHTdLueUuL9bvvxlqjwVkLvFKYAbP988II8gir45Mkm2ymdaBbfcMMMIjvfjVV1RBcLmSlHldxyCN
[Price] => stdClass Object
(
[Amount] => 10400
[CurrencyCode] => INR
[FormattedPrice] => INR 104.00
)
[Availability] => Usually dispatched within 1-2 business days
[AvailabilityAttributes] => stdClass Object
(
[AvailabilityType] => now
[MinimumHours] => 24
[MaximumHours] => 48
)
[IsEligibleForSuperSaverShipping] =>
)
)
)
[CustomerReviews] => stdClass Object
(
[IFrameURL] => http://www.amazon.in/reviews/iframe?akid=AKIAJ7ECVOCWYGWRSAWA&alinkCode=sp1&asin=B00H9DKCLS&atag=findindia-21&exp=2015-04-08T04%3A18%3A02Z&v=2&sig=a6XivzaLqHr1TSHd8QxiEAGN6WGaadcQlcG0I1Xq1DI%3D
[HasReviews] => 1
)
[EditorialReviews] => stdClass Object
(
[EditorialReview] => stdClass Object
(
[Source] => Product Description
[Content] => The Poly Urethane Leather Hard Back flip case cover with open window slot to display the top screen. The material protects the phone from scratches through inner thin micro velvet fabric protecting the screen.
[IsLinkSuppressed] =>
)
)
[SimilarProducts] => stdClass Object
(
[SimilarProduct] => Array
(
[0] => stdClass Object
(
[ASIN] => B00KHRD922
[Title] => Samsung Galaxy S4 GT-I9500 (Deep Black)
)
[1] => stdClass Object
(
[ASIN] => B00TSARS1C
[Title] => Samsung I9500 Galaxy S4 Tempered Glass Explosion Proof Screen Protector
)
[2] => stdClass Object
(
[ASIN] => B00BJ0KA1Y
[Title] => Case-Mate CM027011 Screen Protector for Samsung Galaxy S4
)
[3] => stdClass Object
(
[ASIN] => B00N0YYGIU
[Title] => S4 Screen Protector, JETech® Premium Tempered Glass Screen Protector for Samsung Galaxy S4 Galaxy S IV Galaxy SIV i9500
)
[4] => stdClass Object
(
[ASIN] => B00UJBY50G
[Title] => Original S-View Flip Cover for Samsung Galaxy S4 (White)
)
)
)
[BrowseNodes] => stdClass Object
(
[BrowseNode] => stdClass Object
(
[BrowseNodeId] => 1389409031
[Name] => Cases & Covers
[Ancestors] => stdClass Object
(
[BrowseNode] => stdClass Object
(
[BrowseNodeId] => 1389402031
[Name] => Mobile Accessories
[Ancestors] => stdClass Object
(
[BrowseNode] => stdClass Object
(
[BrowseNodeId] => 1389401031
[Name] => Mobiles & Accessories
[Ancestors] => stdClass Object
(
[BrowseNode] => stdClass Object
(
[BrowseNodeId] => 976420031
[Name] => Categories
[IsCategoryRoot] => 1
[Ancestors] => stdClass Object
(
[BrowseNode] => stdClass Object
(
[BrowseNodeId] => 976419031
[Name] => Electronics
)
)
)
)
)
)
)
)
)
))
You can use the DetailPageURL as the affiliate link for the product.
Whether it is valid or not can be checked by using the Amazon's link checker from the amazon affiliate's portal here - https://affiliate-program.amazon.com/gp/associates/network/tools/link-checker/main.html

ActiveRecord result return by findAll method needs in different format

I executed following statement
$posts = Post::model()->with(array( 'category', 'member', 'profile' ))->findAll();
I printed $posts in log file. I got following result.
Array
(
[0] => Post Object
(
[_new:CActiveRecord:private] =>
[_attributes:CActiveRecord:private] => Array
(
[id] => 1
[post_text] => Sales needs to be increase by the end of this month. I don't wnat any reason behind this.
[member_id] => 2
[category_id] => 3
[published] => 0
[draft] => 1
[date_added] => 2014-04-06
)
[_related:CActiveRecord:private] => Array
(
[category] => Category Object
(
[_new:CActiveRecord:private] =>
[_attributes:CActiveRecord:private] => Array
(
[id] => 1
[category_name] => Anything
[type] => General
[date_added] => 2014-04-05
)
[_related:CActiveRecord:private] => Array
(
)
[_c:CActiveRecord:private] =>
[_pk:CActiveRecord:private] => 1
[_alias:CActiveRecord:private] => t
[_errors:CModel:private] => Array
(
)
[_validators:CModel:private] =>
[_scenario:CModel:private] => update
[_e:CComponent:private] =>
[_m:CComponent:private] =>
)
[member] => Member Object
(
[_new:CActiveRecord:private] =>
[_attributes:CActiveRecord:private] => Array
(
[id] => 1
[screen_name] => prashantb
[email] => prashantbharambe22#gmail.com
[date_added] => 2014-04-05
[first_name] => prashant
[last_name] => bharambe
)
[_related:CActiveRecord:private] => Array
(
[profile] => MemberProfile Object
(
[_new:CActiveRecord:private] =>
[_attributes:CActiveRecord:private] => Array
(
[id] => 1
[member_id] => 1
[city] => kalyan
[state] => maharashtra
[country] => india
[designation] => php developer
[date_added] => 2014-04-05
)
[_related:CActiveRecord:private] => Array
(
)
[_c:CActiveRecord:private] =>
[_pk:CActiveRecord:private] => 1
[_alias:CActiveRecord:private] => t
[_errors:CModel:private] => Array
(
)
[_validators:CModel:private] =>
[_scenario:CModel:private] => update
[_e:CComponent:private] =>
[_m:CComponent:private] =>
)
)
[_c:CActiveRecord:private] =>
[_pk:CActiveRecord:private] => 1
[_alias:CActiveRecord:private] => t
[_errors:CModel:private] => Array
(
)
[_validators:CModel:private] =>
[_scenario:CModel:private] => update
[_e:CComponent:private] =>
[_m:CComponent:private] =>
)
)
[_c:CActiveRecord:private] =>
[_pk:CActiveRecord:private] => 1
[_alias:CActiveRecord:private] => t
[_errors:CModel:private] => Array
(
)
[_validators:CModel:private] =>
[_scenario:CModel:private] => update
[_e:CComponent:private] =>
[_m:CComponent:private] =>
)
)
But I need a result in following format.
Array
(
[0] => Array
(
[id] => 1,
[post_text] => Sales needs to be increase by the end of this month. I don't wnat any reason behind this,
[member_id] => 2,
[category_id] => 3,
[published] => 0,
[draft] => 1,
[date_added] => 2014-04-06,
[category] => Array (
[id] => 1,
[category_name] => Anything,
[type] => General,
[date_added] => 2014-04-05,
),
[member] => Array (
[id] => 1,
[screen_name] => prashantb,
[email] => prashantbharambe94#gmail.com,
[date_added] => 2014-04-05,
[first_name] => prashant,
[last_name] => bharambe,
[profile] => Array(
[id] => 1
[member_id] => 1
[city] => kalyan
[state] => maharashtra
[country] => india
[designation] => php developer
[date_added] => 2014-04-05
)
)
)
)
In short I need all attributes values in one array. ( Model Attributes and its related model attributes )
I am new to yii. Please help me on this.
Yii doesn't work with arrays. Each DB record is represented by an ActiveRecord object. This way you can access your column values like this:
echo $model->post_text; // Sales needs to be increase...
echo $model->date_added; // 2014-04-06
echo $model->etc...
If you did set up relations right, you can access that data like this:
echo $model->category->category_name; // Anything
echo $model->member->screen_name; // prashantb
You have to create the array you showed manually. If you still need the data in an array, you can also access the attributes value:
print_r($model->attributes); // array( [id] => 1, [post_text] => 'Sales needs to be increase', ...)