Isaac Deyán

Members
  • Content Count

    3
  • Joined

  • Last visited

Posts posted by Isaac Deyán


  1. Just now, Isaac Deyán said:

    Saludos, me encuentro teniendo problemas similares al usar SDK oficial para PHP. El JSON de retorno indica lo siguiente:

    
    Array
    (
        [body] => stdClass Object
            (
                [message] => Validation error
                [error] => validation_error
                [status] => 400
                [cause] => Array
                    (
                        [0] => stdClass Object
                            (
                                [cause_id] => 310
                                [type] => warning
                                [code] => item.description.text.not_allowed
                                [references] => Array
                                    (
                                        [0] => item.description
                                    )
    
                                [message] => The text property is deprecated. And will soon be rejected. Please use plain_text
                            )
    
                        [1] => stdClass Object
                            (
                                [cause_id] => 126
                                [type] => error
                                [code] => item.category_id.invalid
                                [references] => Array
                                    (
                                        [0] => item.category_id
                                    )
    
                                [message] => Is not allowed to post in category MLV1051. Make sure you're posting in a leaf category
                            )
    
                    )
    
            )
    
        [httpCode] => 400
    )

    Quisiera saber si alguno tiene idea de que puede estar ocasionando el error y como corregirlo, anexo el array con el que cargo el Item:

     

     

    // We construct the item to POST
        $item = array(
            "title" => "Item De Prueba Via API",
            "category_id" => "MLV1051",
            "price" => 10,
            "currency_id" => "VES",
            "available_quantity" => 1,
            "buying_mode" => "buy_it_now",
            "listing_type_id" => "bronze",
            "condition" => "new",
            "description" => "Prueba.",
            "video_id" => "Q6dsRpVyyWs",
            "warranty" => "12 month",
            "pictures" => array(
                array(
                    "source" => "https://upload.wikimedia.org/wikipedia/commons/thumb/6/64/IPhone_7_Plus_Jet_Black.svg/440px-IPhone_7_Plus_Jet_Black.svg.png"
                ),
                array(
                    "source" => "https://upload.wikimedia.org/wikipedia/commons/thumb/b/bc/IPhone7.jpg/440px-IPhone7.jpg"
                )
            ),
            "attributes" => array(
                array(
                    "id" => "EAN",
                    "value_name" => "190198043566"
                ),
                array(
                    "id" => "COLOR",
                    "value_id" => "52049"
                ),
                array(
                    "id" => "WEIGHT",
                    "value_name" => "188g"
                ),
                array(
                    "id" => "SCREEN_SIZE",
                    "value_name" => "4.7 polegadas"
                ),
                array(
                    "id" => "TOUCH_SCREEN",
                    "value_id" => "242085"
                ),
                array(
                    "id" => "DIGITAL_CAMERA",
                    "value_id" => "242085"
                ),
                array(
                    "id" => "GPS",
                    "value_id" => "242085"
                ),
                array(
                    "id" => "MP3",
                    "value_id" => "242085"
                ),
                array(
                    "id" => "OPERATING_SYSTEM",
                    "value_id" => "296859"
                ),
                array(
                    "id" => "OPERATING_SYSTEM_VERSION",
                    "value_id" => "iOS 10"
                ),
                array(
                    "id" => "DISPLAY_RESOLUTION",
                    "value_id" => "1920 x 1080"
                ),
                array(
                    "id" => "BATTERY_CAPACITY",
                    "value_name" => "3980 mAh"
                ),
                array(
                    "id" => "FRONT_CAMERA_RESOLUTION",
                    "value_name" => "7 mpx"
                )
            )
        );

    Gracias de antemano !


  2. Saludos, me encuentro teniendo problemas similares al usar SDK oficial para PHP. El JSON de retorno indica lo siguiente:

    Array
    (
        [body] => stdClass Object
            (
                [message] => Validation error
                [error] => validation_error
                [status] => 400
                [cause] => Array
                    (
                        [0] => stdClass Object
                            (
                                [cause_id] => 310
                                [type] => warning
                                [code] => item.description.text.not_allowed
                                [references] => Array
                                    (
                                        [0] => item.description
                                    )
    
                                [message] => The text property is deprecated. And will soon be rejected. Please use plain_text
                            )
    
                        [1] => stdClass Object
                            (
                                [cause_id] => 126
                                [type] => error
                                [code] => item.category_id.invalid
                                [references] => Array
                                    (
                                        [0] => item.category_id
                                    )
    
                                [message] => Is not allowed to post in category MLV1051. Make sure you're posting in a leaf category
                            )
    
                    )
    
            )
    
        [httpCode] => 400
    )

    Quisiera saber si alguno tiene idea de que puede estar ocasionando el error y como corregirlo, anexo el array con el que cargo el Item:

     

     

    // We construct the item to POST
        $item = array(
            "title" => "Item De Prueba Via API",
            "category_id" => "MLV1051",
            "price" => 10,
            "currency_id" => "VES",
            "available_quantity" => 1,
            "buying_mode" => "buy_it_now",
            "listing_type_id" => "bronze",
            "condition" => "new",
            "description" => "Prueba.",
            "video_id" => "Q6dsRpVyyWs",
            "warranty" => "12 month",
            "pictures" => array(
                array(
                    "source" => "https://upload.wikimedia.org/wikipedia/commons/thumb/6/64/IPhone_7_Plus_Jet_Black.svg/440px-IPhone_7_Plus_Jet_Black.svg.png"
                ),
                array(
                    "source" => "https://upload.wikimedia.org/wikipedia/commons/thumb/b/bc/IPhone7.jpg/440px-IPhone7.jpg"
                )
            ),
            "attributes" => array(
                array(
                    "id" => "EAN",
                    "value_name" => "190198043566"
                ),
                array(
                    "id" => "COLOR",
                    "value_id" => "52049"
                ),
                array(
                    "id" => "WEIGHT",
                    "value_name" => "188g"
                ),
                array(
                    "id" => "SCREEN_SIZE",
                    "value_name" => "4.7 polegadas"
                ),
                array(
                    "id" => "TOUCH_SCREEN",
                    "value_id" => "242085"
                ),
                array(
                    "id" => "DIGITAL_CAMERA",
                    "value_id" => "242085"
                ),
                array(
                    "id" => "GPS",
                    "value_id" => "242085"
                ),
                array(
                    "id" => "MP3",
                    "value_id" => "242085"
                ),
                array(
                    "id" => "OPERATING_SYSTEM",
                    "value_id" => "296859"
                ),
                array(
                    "id" => "OPERATING_SYSTEM_VERSION",
                    "value_id" => "iOS 10"
                ),
                array(
                    "id" => "DISPLAY_RESOLUTION",
                    "value_id" => "1920 x 1080"
                ),
                array(
                    "id" => "BATTERY_CAPACITY",
                    "value_name" => "3980 mAh"
                ),
                array(
                    "id" => "FRONT_CAMERA_RESOLUTION",
                    "value_name" => "7 mpx"
                )
            )
        );