def METHOD_NAME(  # pylint: disable=inconsistent-return-statements
    status_code, message, description, amqp_transport
):
    condition = message.application_properties.get(
        MGMT_RESPONSE_MESSAGE_ERROR_CONDITION
    )
    if status_code == 200:
        return message.value[b"sequence-numbers"]
    amqp_transport.handle_amqp_mgmt_error(
        _LOGGER, "Scheduling messages failed.", condition, description, status_code
    )