[Skip to main content](#vessel-content)

#   trigger shipping plugin after payment

##

- **[bluewave](/forum/user/8288-bluewave "View bluewave's Profile")**
- [![bluewave's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/8288-bluewave "View bluewave's Profile") Topic Author
- [ Offline](/forum/user/8288-bluewave)

Less More

- Posts: 51
- Thank you received: 4
-
-

9 years 2 months ago [\#277100](#277100) by [bluewave](/forum/user/8288-bluewave "View bluewave's Profile")  *[trigger shipping plugin after payment](/forum/28-shipping-methods/891720-trigger-shipping-plugin-after-payment#277100 "-- Error-message(debug-mod must be tuned on) -- : Please advise, how can I get back to the shipping plugin I am writing after successful payment to actually book the pickup of the products, by the shipping company via their API?  Please advise, how can I get back to the shipping plugin I am writing after successful payment to actually book the pickup of the products, by the shipping company via their API?")* was created by *[bluewave](/forum/user/8288-bluewave "View bluewave's Profile")*

-- Error-message(debug-mod must be tuned on) -- : Please advise, how can I get back to the shipping plugin I am writing after successful payment to actually book the pickup of the products, by the shipping company via their API?

Please advise, how can I get back to the shipping plugin I am writing after successful payment to actually book the pickup of the products, by the shipping company via their API?

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI4LXNoaXBwaW5nLW1ldGhvZHMvODkxNzIwLXRyaWdnZXItc2hpcHBpbmctcGx1Z2luLWFmdGVyLXBheW1lbnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86584
- Thank you received: 14325
-
-

9 years 2 months ago [\#277104](#277104) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[trigger shipping plugin after payment](/forum/28-shipping-methods/891720-trigger-shipping-plugin-after-payment#277104 "-- Error-message(debug-mod must be tuned on) -- : Please advise, how can I get back to the shipping plugin I am writing after successful payment to actually book the pickup of the products, by the shipping company via their API?  Please advise, how can I get back to the shipping plugin I am writing after successful payment to actually book the pickup of the products, by the shipping company via their API?")*

Hi,

You want to implement the onAfterOrderUpdate trigger of our order API and check the order_status of the order so that if the order is being changed from "created" to "confirmed" you can do your processing for the booking of the pickup.
[ www.hikashop.com/support/documentation/6...mentation.html#order](https://www.hikashop.com/support/documentation/62-hikashop-developer-documentation.html#order)

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI4LXNoaXBwaW5nLW1ldGhvZHMvODkxNzIwLXRyaWdnZXItc2hpcHBpbmctcGx1Z2luLWFmdGVyLXBheW1lbnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[bluewave](/forum/user/8288-bluewave "View bluewave's Profile")**
- [![bluewave's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/8288-bluewave "View bluewave's Profile") Topic Author
- [ Offline](/forum/user/8288-bluewave)

Less More

- Posts: 51
- Thank you received: 4
-
-

9 years 2 months ago [\#277188](#277188) by [bluewave](/forum/user/8288-bluewave "View bluewave's Profile")  Replied by *[bluewave](/forum/user/8288-bluewave "View bluewave's Profile")* on topic *[trigger shipping plugin after payment](/forum/28-shipping-methods/891720-trigger-shipping-plugin-after-payment#277188 "-- Error-message(debug-mod must be tuned on) -- : Please advise, how can I get back to the shipping plugin I am writing after successful payment to actually book the pickup of the products, by the shipping company via their API?  Please advise, how can I get back to the shipping plugin I am writing after successful payment to actually book the pickup of the products, by the shipping company via their API?")*

I added function onAfterOrderUpdate()
to my shipping plugin and it is only triggered when the admin changes the status of the order, so it cannot be automatically executed to get the courier to come.
I need this to be dynamic after payment.

Any other ideas?
I tested with the paypal plugin and it doesn't hit the method.
I tested by changing status in the admin and hit the method.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI4LXNoaXBwaW5nLW1ldGhvZHMvODkxNzIwLXRyaWdnZXItc2hpcHBpbmctcGx1Z2luLWFmdGVyLXBheW1lbnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Mohamed Thelji](/forum/user/6861-mohamed-thelji "View Mohamed Thelji's Profile")**
- [![Mohamed Thelji's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar6861.png)](/forum/user/6861-mohamed-thelji "View Mohamed Thelji's Profile")
- [ Offline](/forum/user/6861-mohamed-thelji)

Less More

- Posts: 12953
- Thank you received: 1778
-
-
-

9 years 2 months ago [\#277202](#277202) by [Mohamed Thelji](/forum/user/6861-mohamed-thelji "View Mohamed Thelji's Profile")  Replied by *[Mohamed Thelji](/forum/user/6861-mohamed-thelji "View Mohamed Thelji's Profile")* on topic *[trigger shipping plugin after payment](/forum/28-shipping-methods/891720-trigger-shipping-plugin-after-payment#277202 "-- Error-message(debug-mod must be tuned on) -- : Please advise, how can I get back to the shipping plugin I am writing after successful payment to actually book the pickup of the products, by the shipping company via their API?  Please advise, how can I get back to the shipping plugin I am writing after successful payment to actually book the pickup of the products, by the shipping company via their API?")*

Hello,

> Please advise, how can I get back to the shipping plugin I am writing **after successful payment** to actually book the pickup of the products, by the shipping company via their API?

If you want your function to be triggered after your order status changes to "Confirmed" then you'll have to use the "onAfterOrderUpdate" trigger which will be called every time the status of your order changes.

Can you give us more information about what you want to achieve ?

Thank you.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI4LXNoaXBwaW5nLW1ldGhvZHMvODkxNzIwLXRyaWdnZXItc2hpcHBpbmctcGx1Z2luLWFmdGVyLXBheW1lbnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[bluewave](/forum/user/8288-bluewave "View bluewave's Profile")**
- [![bluewave's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/8288-bluewave "View bluewave's Profile") Topic Author
- [ Offline](/forum/user/8288-bluewave)

Less More

- Posts: 51
- Thank you received: 4
-
-

9 years 2 months ago [\#277550](#277550) by [bluewave](/forum/user/8288-bluewave "View bluewave's Profile")  Replied by *[bluewave](/forum/user/8288-bluewave "View bluewave's Profile")* on topic *[trigger shipping plugin after payment](/forum/28-shipping-methods/891720-trigger-shipping-plugin-after-payment#277550 "-- Error-message(debug-mod must be tuned on) -- : Please advise, how can I get back to the shipping plugin I am writing after successful payment to actually book the pickup of the products, by the shipping company via their API?  Please advise, how can I get back to the shipping plugin I am writing after successful payment to actually book the pickup of the products, by the shipping company via their API?")*

what I am trying to achieve.
I have added the onAfterOrderUpdate method to my shipping plugin.
Currently it just creates a text log file to show that the method is being hit during processing.

when a purchase is made, the shipping plugin calls the shiper api to get a price for the delivery and adds it to the car prior to payment. This is fine.
If I have the product in stock, I want the system to book the pickup immediately after payment.
Then once it's picked up, I can change the status to picked up.
via cron, or some other method, I need the system to check if the product has been delivered, dynamically, and change the status to delivered.

However, currently, the new method in the shipping plugin is not being hit when payments are made.
I have tested it with paypal. No log file created.
I tested it in the admin area and changed an order status, and it was hit.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI4LXNoaXBwaW5nLW1ldGhvZHMvODkxNzIwLXRyaWdnZXItc2hpcHBpbmctcGx1Z2luLWFmdGVyLXBheW1lbnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86584
- Thank you received: 14325
-
-

9 years 2 months ago [\#277556](#277556) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[trigger shipping plugin after payment](/forum/28-shipping-methods/891720-trigger-shipping-plugin-after-payment#277556 "-- Error-message(debug-mod must be tuned on) -- : Please advise, how can I get back to the shipping plugin I am writing after successful payment to actually book the pickup of the products, by the shipping company via their API?  Please advise, how can I get back to the shipping plugin I am writing after successful payment to actually book the pickup of the products, by the shipping company via their API?")*

Hi,

If the PayPal plugin changes the status of the order when receiving the payment notification, then your plugin will be triggered.
So if you say it's not triggered, then there must be a problem with the code of your plugin or your PayPal plugin is not confirming the orders automatically or something due to a problem on the server.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI4LXNoaXBwaW5nLW1ldGhvZHMvODkxNzIwLXRyaWdnZXItc2hpcHBpbmctcGx1Z2luLWFmdGVyLXBheW1lbnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.054 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)
