magento2 – Magento 2: the post-command command plug-in does not work

By creating a payment plugin Magento 2, I want to recover the data of the order and send it to a third party for the management of the order.

I've created a plugin for the Magento Sales Api OrderManagementInterface class, where I want to write a new function for the place method.

it's my code:

etc / di.xml


Digitaq CbFashion Plugin Order PlaceAfterPlugin

<? php

Digitaq  CbFashion  Plugin  Order namespace;

PlaceAfterPlugin class {

public service afterPlace ()

Even though I did not add any new features, the cashier redirects to the cart containing the articles still present, and I do not see any error during logging.

Can any one tell me what is the right way to get the order data once the order is placed, both by the administrator and by the customer? What's wrong with this situation?

I've also tried doing this with an observer using the sales_order_place_after event, but this has given the same result. Any help would be very appreciated!