Ask A Question

Questions

16
ANSWERED

Validation Failure Error in API response

Hello Easyship team, I am using your API in my website in curl format, so i have used the following code: ---------------------------------------------code starts here ------------------------------------------ $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, "https://api.easyship.com/rate/v1/rates"); curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE); curl_setopt($ch, CURLOPT_HEADER, FALSE); curl_setopt($ch, CURLOPT_POST, TRUE); curl_setopt($ch, CURLOPT_POSTFIELDS, "{ \"origin_country_alpha2\": \"SG\", \"origin_postal_code\": \"WC2N\", \"destination_country_alpha2\": \"US\", \"destination_postal_code\": \"10030\", \"taxes_duties_paid_by\": \"Sender\", \"is_insured\": false, \"items\": [ { \"actual_weight\": 1.2, \"height\": 10, \"width\": 15, \"length\": 20, \"category\": \"mobiles\", \"declared_currency\": \"SGD\", \"declared_customs_value\": 100 } ] }"); curl_setopt($ch, CURLOPT_HTTPHEADER, array( "Content-Type: application/json", "Authorization: Bearer 4e2b327e2ef5471885cd0bc50a0c9fe52481793bd309b2c4f2a6bdac3f10ae1f" )); $response = curl_exec($ch); curl_close($ch); var_dump($response); -------------------------------------------------- code ends here ---------------------------------------- but it is giving me the following response : "string(146) "{"rates":[],"messages":["Validation Failure: No credentials","Sorry, we couldn't find any shipping solutions based on the information provided."]}"" Please provide me a solution so that i can use it. thanks

Posted by Mohit 2 years ago

0

Woocommerce Plugin Bug

The Easyship plug-in for Wordpress/Woocommerce is causing issues with my site and reading through the support section of the plug-in other are experiencing this as well. https://wordpress.org/plugins/easyship-woocommerce-shipping-rates Wordpress Site Health check is showing the 4 errors below when Easyship plug-in is turned on. 1. The REST API request failed due to an error. Error: [] cURL error 28: Operation timed out after 10001 milliseconds with 0 out of -1 bytes received 2. The loopback request to your site failed, this means features relying on them are not currently working as expected. Error: [] cURL error 28: Operation timed out after 10001 milliseconds with 0 out of -1 bytes received 3. The scheduled event, action_scheduler_run_queue, is late to run. Your site still works, but this may indicate that scheduling posts or automated updates may not work as intended. 4. Background updates ensure that WordPress can auto-update if a security update is released for the version you are currently using. When looking through the debug logs I noticed that my error logs are filling up with the following 4 error messages. 1. PHP Warning: session_start(): Cannot start session when headers already sent in /home/forgetme/public_html/wp-content/plugins/easyship-woocommerce-shipping-rates/easyship.php on line 73 2. PHP Notice: Undefined index: es_api_key in /home/forgetme/public_html/wp-content/plugins/easyship-woocommerce-shipping-rates/includes/easyship-api.php on line 32 3. PHP Notice: Undefined index: es_api_secret in /home/forgetme/public_html/wp-content/plugins/easyship-woocommerce-shipping-rates/includes/easyship-api.php on line 33 4. PHP Notice: Undefined index: es_taxes_duties in /home/forgetme/public_html/wp-content/plugins/easyship-woocommerce-shipping-rates/includes/easyship-api.php on line 36 I like using your product for my shipping needs, but this plug-in doesn't get fixed soon then I"m going to need to start looking for a different shipping partner since this is impact the performance of my Woocommerce site. Additional info that might be helpful: WordPress version: 5.3.2 WooCommerce version: 3.9.2 PHP version: 7.3.14

Posted by Darin 9 months ago

13
ANSWERED

Can't create shipment in Sandboc

Hi, I am software developer, i can't able to access the sandbox api. when i tried to create a shipment it throws bad request error. Request : URL : https://api.easyship.com/shipment/v1/shipments Method : POST Body : {"platform_name": "Shopify","platform_order_number": "Test07Aug001","destination_country_alpha2": "AU","selected_courier_id": "94c3cfc5-e6f1-4200-8dc5-eaef068e9ccd","destination_city": "Wetherill Park","destination_postal_code": "2164","destination_state": "NSW","destination_name": "Aloha Chen","destination_address_line_1": "TCT, Kamarajar Salai","destination_address_line_2": null,"destination_phone_number": "+1 234-567-890","destination_email_address": "[email protected]","items": [{"description": "Silk dress","sku": "test", "actual_weight": 1.2, "height": 10,"width": 15,"length": 20,"category": "fashion","declared_currency": "AUD","declared_customs_value": 100}]} Response : (400) Bad Request {"ActiveRecord::StatementInvalid":"PG::InFailedSqlTransaction: ERROR: current transaction is aborted, commands ignored until end of transaction block\n: INSERT INTO \"shipments\" (\"type\", \"company_id\", \"shipment_state\", \"pickup_state\", \"transaction_state\", \"label_state\", \"manifest_state\", \"delivery_state\", \"store_state\", \"warehouse_state\", \"fraud_state\", \"destination_name\", \"platform_order_number\", \"platform_name\", \"destination_country_id\", \"buyer_selected_courier_id\", \"address_line_1\", \"state\", \"city\", \"postal_code\", \"phone_number\", \"email_address\", \"store_id\", \"origin_country_id\", \"currency\", \"service\", \"sort_by\", \"tracking_engine\", \"easyship_shipment_id\", \"pickup_address_id\", \"created_at\", \"updated_at\") VALUES ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14, $15, $16, $17, $18, $19, $20, $21, $22, $23, $24, $25, $26, $27, $28, $29, $30, $31, $32) RETURNING \"id\""}

Posted by Ram 2 years ago