Create Returns
When you create a return, in Customer Service > Orders in the Order Management System (OMS) Admin, the magento.postsales.return_management.authorize operation is sent.
To create a return, the applicable order lines must be in a SHIPPED status.
The order can be in a LOGISTICS order status, because the validation to allow to create returns occurs at the order line level.
Example of error when order does not have
LOGISTICSCOMPLETEstatus

Example of a
magento.postsales.return_management.authorizemessage
{
    "return": {
        "sales_channel_id": "ST1",
        "order_id": "000000255",
        "source_id": "SOU1",
        "user": "userA",
        "custom_attributes": [],
        "lines": [
            {
                "id": "98",
                "line_number": 1,
                "custom_attributes": [],
                "reason": "Wrong",
                "reason_description": "I dont like"
            }
        ]
    }
}
OMS does not update stock with return activity.
Available sources for returns
It is possible to return an order to a different source than the one selected in the original order. This feature is enabled in the SI Portal.
These definitions are configured and enabled in your SI Portal, which is not yet accessible externally. Contact Magento Support for assistance.
After Magento Support enables sources, navigate to the OMS Admin via System > Fulfillment > Sources to see the list of sources in your OMS.
Sources in OMS Admin

Select the desired source and enable the Accepts returns? capability.
Capabilities for a source

Enabling this feature allows a source to be available when a new return is created for an order. A dropdown menu is displayed with the available sources for a return.
Returned to column

The original source will only appear in the dropdown when the Accepts returns capability is enabled.
The Comment field allows for a maximum length of 1000 characters.
For more information about new returns, see Customer service actions topic.
Auto approval of returns
When the magento.postsales.return_management.authorize operation is sent the return will be approved or not approved, depending on the Auto Approve Return configuration.
Auto-approval disabled
When auto-approval is disabled:
The magento.postsales.return_management.reported operation is triggered.
  {
      "return": {
          "sales_channel_id": "ST1",
          "order_id": "000000255",
          "source_id": "SOU1",
          "user": "userA",
          "rma": "RMA-CS-000000255-1",
          "custom_attributes": [],
          "status": {
              "code": "REQUESTED",
              "name": "REQUESTED",
              "reason_code": "CSRREQUEST",
              "date": "2018-03-15T14:43:54+00:00"
          },
          "lines": [
              {
                  "id": "98",
                  "line_number": 1,
                  "sku": "24-MB04",
                  "status": "REQUESTED",
                  "custom_attributes": [],
                  "reason": "Wrong",
                  "reason_description": "I dont like"
              }
          ]
      }
  }
The magento.postsales.return_management.updated operation is also triggered.
  {
      "return": {
          "sales_channel_id": "ST1",
          "order_id": "000000255",
          "source_id": "SOU1",
          "user": "userB",
          "rma": "RMA-CS-000000255-1",
          "custom_attributes": [],
          "status": {
              "code": "REQUESTED",
              "name": "REQUESTED",
              "reason_code": "CSRREQUEST",
              "date": "2018-03-15T15:03:04+00:00"
          },
          "lines": [
              {
                  "id": "98",
                  "line_number": 1,
                  "sku": "24-MB04",
                  "status": "APPROVED",
                  "custom_attributes": [],
                  "reason": "Wrong",
                  "reason_description": "I dont like"
              }
          ]
      }
  }
Manually approve a return
When you manually approve a return, in the OMS Admin > Customer Service > Orders > specific order:
The magento.postsales.return_management.received operation is triggered:

  {
      "return": {
          "sales_channel_id": "ST1",
          "order_id": "000000255",
          "user": "userA",
          "rma": "RMA-CS-000000255-1",
          "lines": [
              {
                  "id": "98",
                  "line_number": 1,
                  "sku": "24-MB04"
              }
          ]
      }
  }
The magento.postsales.return_management.updated operation is triggered:
      "return": {
          "sales_channel_id": "ST1",
          "order_id": "000000255",
          "source_id": "SOU1",
          "user": "userA",
          "rma": "RMA-CS-000000255-1",
          "custom_attributes": [],
          "status": {
              "code": "APPROVED",
              "name": "APPROVED",
              "reason_code": "CSRREQUEST",
              "date": "2018-03-15T15:03:04+00:00"
          },
          "lines": [
              {
                  "id": "98",
                  "line_number": 1,
                  "sku": "24-MB04",
                  "status": "APPROVED",
                  "custom_attributes": [],
                  "reason": "Wrong",
                  "reason_description": "I dont like"
              }
          ]
      }
  }
The magento.postsales.refund_management.reported operation is triggered:
  {
      "refund": {
          "order_id": "000000255",
          "store_id": "200001",
          "sales_channel_id": "ST1",
          "credit_note_number": "CES222",
          "credit_note_date": "2018-03-15T14:43:53+00:00",
          "status": {
              "code": "RELEASED",
              "name": "RELEASED",
              "reason_code": "REQUESTED",
              "reason_name": "REQUESTED",
              "date": "2018-03-15T14:43:53+00:00"
          },
          "refund_type": "Return",
          "rma": "RMA-CS-000000255-1",
          "user": "LOGISTICS",
          "refund_reason": "REQUESTED",
          "lines": [
              {
                  "order_line": "1",
                  "order_item_id": "98",
                  "reason": "Wrong",
                  "reason_description": "I dont like",
                  "payments": [
                      {
                          "details": {
                              "cost_gross": "34.64",
                              "cost_net": "32",
                              "cost_vat": "2.64",
                              "vat_rate": "8.25",
                              "vat_detail": [
                                  {
                                      "type": "VAT",
                                      "amount": "2.64",
                                      "rate": "8.25"
                                  }
                              ]
                          },
                          "status": {
                              "code": "REFUNDED",
                              "name": "REFUNDED"
                          }
                      }
                  ]
              }
          ],
          "custom_attributes": []
      }
  }
The magento.postsales.refund_management.updated operation is triggered:
  {
      "refund": {
          "order_id": "000000255",
          "store_id": "200001",
          "sales_channel_id": "ST1",
          "credit_note_number": "CES222",
          "credit_note_date": "2018-03-15T14:43:53+00:00",
          "status": {
              "code": "RELEASED",
              "name": "RELEASED",
              "reason_code": "REQUESTED",
              "reason_name": "REQUESTED",
              "date": "2018-03-15T14:43:53+00:00"
          },
          "refund_type": "Return",
          "rma": "RMA-CS-000000255-1",
          "user": "LOGISTICS",
          "refund_reason": "REQUESTED",
          "lines": [
              {
                  "order_line": "1",
                  "order_item_id": "98",
                  "reason": "Wrong",
                  "reason_description": "I dont like",
                  "payments": [
                      {
                          "details": {
                              "cost_gross": "34.64",
                              "cost_net": "32",
                              "cost_vat": "2.64",
                              "vat_rate": "8.25",
                              "vat_detail": [
                                  {
                                      "type": "VAT",
                                      "amount": "2.64",
                                      "rate": "8.25"
                                  }
                              ]
                          },
                          "status": {
                              "code": "REFUNDED",
                              "name": "REFUNDED"
                          }
                      }
                  ]
              }
          ],
          "custom_attributes": []
      }
  }
Auto-approval enabled
When auto-approval is enabled:
The magento.postsales.return_management.reported operation is triggered:
  {
      "return": {
          "sales_channel_id": "ST1",
          "order_id": "000000255",
          "source_id": "SOU1",
          "user": "userA",
          "rma": "RMA-CS-000000255-1",
          "custom_attributes": [],
          "status": {
              "code": "REQUESTED",
              "name": "REQUESTED",
              "reason_code": "CSRREQUEST",
              "date": "2018-03-15T14:43:54+00:00"
          },
          "lines": [
              {
                  "id": "98",
                  "line_number": 1,
                  "sku": "24-MB04",
                  "status": "REQUESTED",
                  "custom_attributes": [],
                  "reason": "Wrong",
                  "reason_description": "I dont like"
              }
          ]
      }
  }
The magento.postsales.return_management.updated operation is triggered:
  {
      "return": {
          "sales_channel_id": "ST1",
          "order_id": "000000255",
          "source_id": "SOU1",
          "user": "userA",
          "rma": "RMA-CS-000000255-1",
          "custom_attributes": [],
          "status": {
              "code": "REQUESTED",
              "name": "REQUESTED",
              "reason_code": "CSRREQUEST",
              "date": "2018-03-15T15:03:04+00:00"
          },
          "lines": [
              {
                  "id": "98",
                  "line_number": 1,
                  "sku": "24-MB04",
                  "status": "REQUESTED",
                  "custom_attributes": [],
                  "reason": "Wrong",
                  "reason_description": "I dont like"
              }
          ]
      }
  }
The magento.postsales.return_management.authorize operation will be automatically sent:
  {
      "return": {
          "sales_channel_id": "ST1",
          "order_id": "000000257",
          "source_id": "SOU1",
          "user": "userA",
          "custom_attributes": [],
          "lines": [
              {
                  "id": "98",
                  "line_number": 1,
                  "custom_attributes": [],
                  "reason": "Wrong",
                  "reason_description": "I don't like"
              }
          ]
      }
  }
The magento.postsales.return_management.reported operation is triggered:
  {
      "return": {
          "sales_channel_id": "ST1",
          "order_id": "000000255",
          "source_id": "SOU1",
          "user": "userA",
          "rma": "RMA-CS-000000255-1",
          "custom_attributes": [],
          "status": {
              "code": "APPROVED",
              "name": "APPROVED",
              "reason_code": "CSRREQUEST",
              "date": "2018-03-15T14:43:54+00:00"
          },
          "lines": [
              {
                  "id": "98",
                  "line_number": 1,
                  "sku": "24-MB04",
                  "status": "APPROVED",
                  "custom_attributes": [],
                  "reason": "Wrong",
                  "reason_description": "I dont like"
              }
          ]
      }
  }
The magento.postsales.refund_management.reported operation is triggered:
    {
      "refund": {
          "order_id": "000000257",
          "store_id": "200001",
          "sales_channel_id": "ST1",
          "credit_note_number": "CES224",
          "credit_note_date": "2018-03-15T15:48:28+00:00",
          "status": {
              "code": "RELEASED",
              "name": "RELEASED",
              "reason_code": "REQUESTED",
              "reason_name": "REQUESTED",
              "date": "2018-03-15T15:48:28+00:00"
          },
          "refund_type": "Return",
          "rma": "RMA-CS-000000257-1",
          "user": "LOGISTICS",
          "refund_reason": "REQUESTED",
          "lines": [
              {
                  "order_line": "1",
                  "order_item_id": "98",
                  "reason": "Wrong",
                  "reason_description": "I don't like",
                  "payments": [
                      {
                          "details": {
                              "cost_gross": "34.64",
                              "cost_net": "32",
                              "cost_vat": "2.64",
                              "vat_rate": "8.25",
                              "vat_detail": [
                                  {
                                      "type": "VAT",
                                      "amount": "2.64",
                                      "rate": "8.25"
                                  }
                              ]
                          },
                          "status": {
                              "code": "REFUNDED",
                              "name": "REFUNDED"
                          }
                      }
                  ]
              }
          ],
          "custom_attributes": []
      }
  }
The magento.postsales.return_management.updated operation is triggered:
  {
      "return": {
          "sales_channel_id": "ST1",
          "order_id": "000000257",
          "source_id": "SOU1",
          "user": "userA",
          "rma": "RMA-CS-000000257-1",
          "custom_attributes": [],
          "status": {
              "code": "APPROVED",
              "name": "APPROVED",
              "reason_code": "CSRREQUEST",
              "date": "2018-03-15T15:48:30+00:00"
          },
          "lines": [
              {
                  "id": "98",
                  "line_number": 1,
                  "sku": "24-MB04",
                  "status": "APPROVED",
                  "custom_attributes": [],
                  "reason": "Wrong",
                  "reason_description": "I don't like"
              }
          ]
      }
  }
The magento.postsales.refund_management.updated operation is triggered:
  {
      "refund": {
          "order_id": "000000257",
          "store_id": "200001",
          "sales_channel_id": "ST1",
          "credit_note_number": "CES224",
          "credit_note_date": "2018-03-15T15:48:28+00:00",
          "status": {
              "code": "RELEASED",
              "name": "RELEASED",
              "reason_code": "REQUESTED",
              "reason_name": "REQUESTED",
              "date": "2018-03-15T15:48:28+00:00"
          },
          "refund_type": "Return",
          "rma": "RMA-CS-000000257-1",
          "user": "LOGISTICS",
          "refund_reason": "REQUESTED",
          "lines": [
              {
                  "order_line": "1",
                  "order_item_id": "98",
                  "reason": "Wrong",
                  "reason_description": "I don't like",
                  "payments": [
                      {
                          "details": {
                              "cost_gross": "34.64",
                              "cost_net": "32",
                              "cost_vat": "2.64",
                              "vat_rate": "8.25",
                              "vat_detail": [
                                  {
                                      "type": "VAT",
                                      "amount": "2.64",
                                      "rate": "8.25"
                                  }
                              ]
                          },
                          "status": {
                              "code": "REFUNDED",
                              "name": "REFUNDED"
                          }
                      }
                  ]
              }
          ],
          "custom_attributes": []
      }
  }
See the Auto release refund topic for more information about how to manually approve a refund for an order or for order lines.