// WARNING: Please don't edit this file. It was generated by Python/WinRT v1.0.0-alpha.6

#include "pybase.h"
#include "py.Windows.Devices.Bluetooth.GenericAttributeProfile.h"

PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicsResult>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattClientNotificationResult>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptor>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptorUuids>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptorsResult>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceServicesResult>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicParameters>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicResult>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptor>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorParameters>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorResult>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalService>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormat>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadClientCharacteristicConfigurationDescriptorResult>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequest>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequestedEventArgs>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadResult>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReliableWriteTransaction>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattRequestStateChangedEventArgs>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProvider>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisementStatusChangedEventArgs>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisingParameters>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderResult>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSessionStatusChangedEventArgs>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSubscribedClient>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattValueChangedEventArgs>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequest>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequestedEventArgs>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteResult>::python_type;

namespace py::cpp::Windows::Devices::Bluetooth::GenericAttributeProfile
{
    // ----- GattCharacteristic class --------------------
    constexpr const char* const _type_name_GattCharacteristic = "GattCharacteristic";

    static PyObject* _new_GattCharacteristic(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattCharacteristic);
        return nullptr;
    }

    static void _dealloc_GattCharacteristic(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattCharacteristic_ConvertShortIdToUuid(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<uint16_t>(args, 0);

                return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic::ConvertShortIdToUuid(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattCharacteristic_GetAllDescriptors(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.GetAllDescriptors());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattCharacteristic_GetDescriptors(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::guid>(args, 0);

                return py::convert(self->obj.GetDescriptors(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattCharacteristic_GetDescriptorsAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.GetDescriptorsAsync());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::BluetoothCacheMode>(args, 0);

                return py::convert(self->obj.GetDescriptorsAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattCharacteristic_GetDescriptorsForUuidAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::guid>(args, 0);

                return py::convert(self->obj.GetDescriptorsForUuidAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else if (arg_count == 2)
        {
            try
            {
                auto param0 = py::convert_to<winrt::guid>(args, 0);
                auto param1 = py::convert_to<winrt::Windows::Devices::Bluetooth::BluetoothCacheMode>(args, 1);

                return py::convert(self->obj.GetDescriptorsForUuidAsync(param0, param1));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattCharacteristic_ReadClientCharacteristicConfigurationDescriptorAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.ReadClientCharacteristicConfigurationDescriptorAsync());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattCharacteristic_ReadValueAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.ReadValueAsync());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::BluetoothCacheMode>(args, 0);

                return py::convert(self->obj.ReadValueAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattCharacteristic_WriteClientCharacteristicConfigurationDescriptorAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattClientCharacteristicConfigurationDescriptorValue>(args, 0);

                return py::convert(self->obj.WriteClientCharacteristicConfigurationDescriptorAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattCharacteristic_WriteClientCharacteristicConfigurationDescriptorWithResultAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattClientCharacteristicConfigurationDescriptorValue>(args, 0);

                return py::convert(self->obj.WriteClientCharacteristicConfigurationDescriptorWithResultAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattCharacteristic_WriteValueAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Storage::Streams::IBuffer>(args, 0);

                return py::convert(self->obj.WriteValueAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else if (arg_count == 2)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Storage::Streams::IBuffer>(args, 0);
                auto param1 = py::convert_to<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteOption>(args, 1);

                return py::convert(self->obj.WriteValueAsync(param0, param1));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattCharacteristic_WriteValueWithResultAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Storage::Streams::IBuffer>(args, 0);

                return py::convert(self->obj.WriteValueWithResultAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else if (arg_count == 2)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Storage::Streams::IBuffer>(args, 0);
                auto param1 = py::convert_to<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteOption>(args, 1);

                return py::convert(self->obj.WriteValueWithResultAsync(param0, param1));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattCharacteristic_get_ProtectionLevel(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ProtectionLevel());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int GattCharacteristic_put_ProtectionLevel(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtectionLevel>(arg);

            self->obj.ProtectionLevel(param0);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyObject* GattCharacteristic_get_AttributeHandle(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.AttributeHandle());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristic_get_CharacteristicProperties(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.CharacteristicProperties());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristic_get_PresentationFormats(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.PresentationFormats());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristic_get_UserDescription(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.UserDescription());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristic_get_Uuid(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Uuid());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristic_get_Service(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Service());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristic_add_ValueChanged(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic, winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattValueChangedEventArgs>>(arg);

            return py::convert(self->obj.ValueChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristic_remove_ValueChanged(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.ValueChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattCharacteristic(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattCharacteristic[] = {
        { "get_descriptors", (PyCFunction)GattCharacteristic_GetDescriptors, METH_VARARGS, nullptr },
        { "read_value_async", (PyCFunction)GattCharacteristic_ReadValueAsync, METH_VARARGS, nullptr },
        { "write_value_async", (PyCFunction)GattCharacteristic_WriteValueAsync, METH_VARARGS, nullptr },
        { "read_client_characteristic_configuration_descriptor_async", (PyCFunction)GattCharacteristic_ReadClientCharacteristicConfigurationDescriptorAsync, METH_VARARGS, nullptr },
        { "write_client_characteristic_configuration_descriptor_async", (PyCFunction)GattCharacteristic_WriteClientCharacteristicConfigurationDescriptorAsync, METH_VARARGS, nullptr },
        { "get_all_descriptors", (PyCFunction)GattCharacteristic_GetAllDescriptors, METH_VARARGS, nullptr },
        { "get_descriptors_async", (PyCFunction)GattCharacteristic_GetDescriptorsAsync, METH_VARARGS, nullptr },
        { "get_descriptors_for_uuid_async", (PyCFunction)GattCharacteristic_GetDescriptorsForUuidAsync, METH_VARARGS, nullptr },
        { "write_value_with_result_async", (PyCFunction)GattCharacteristic_WriteValueWithResultAsync, METH_VARARGS, nullptr },
        { "write_client_characteristic_configuration_descriptor_with_result_async", (PyCFunction)GattCharacteristic_WriteClientCharacteristicConfigurationDescriptorWithResultAsync, METH_VARARGS, nullptr },
        { "convert_short_id_to_uuid", (PyCFunction)GattCharacteristic_ConvertShortIdToUuid, METH_VARARGS | METH_STATIC, nullptr },
        { "add_value_changed", (PyCFunction)GattCharacteristic_add_ValueChanged, METH_O, nullptr },
        { "remove_value_changed", (PyCFunction)GattCharacteristic_remove_ValueChanged, METH_O, nullptr },
        { "_from", (PyCFunction)_from_GattCharacteristic, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattCharacteristic[] = {
        { const_cast<char*>("protection_level"), (getter)GattCharacteristic_get_ProtectionLevel, (setter)GattCharacteristic_put_ProtectionLevel, nullptr, nullptr },
        { const_cast<char*>("attribute_handle"), (getter)GattCharacteristic_get_AttributeHandle, nullptr, nullptr, nullptr },
        { const_cast<char*>("characteristic_properties"), (getter)GattCharacteristic_get_CharacteristicProperties, nullptr, nullptr, nullptr },
        { const_cast<char*>("presentation_formats"), (getter)GattCharacteristic_get_PresentationFormats, nullptr, nullptr, nullptr },
        { const_cast<char*>("user_description"), (getter)GattCharacteristic_get_UserDescription, nullptr, nullptr, nullptr },
        { const_cast<char*>("uuid"), (getter)GattCharacteristic_get_Uuid, nullptr, nullptr, nullptr },
        { const_cast<char*>("service"), (getter)GattCharacteristic_get_Service, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattCharacteristic[] = 
    {
        { Py_tp_new, _new_GattCharacteristic },
        { Py_tp_dealloc, _dealloc_GattCharacteristic },
        { Py_tp_methods, _methods_GattCharacteristic },
        { Py_tp_getset, _getset_GattCharacteristic },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattCharacteristic =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattCharacteristic",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattCharacteristic
    };

    // ----- GattCharacteristicUuids class --------------------
    constexpr const char* const _type_name_GattCharacteristicUuids = "GattCharacteristicUuids";

    static PyObject* _new_GattCharacteristicUuids(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattCharacteristicUuids);
        return nullptr;
    }

    static PyObject* GattCharacteristicUuids_get_HeartRateMeasurement(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::HeartRateMeasurement());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_BatteryLevel(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::BatteryLevel());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_BloodPressureFeature(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::BloodPressureFeature());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_BloodPressureMeasurement(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::BloodPressureMeasurement());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_BodySensorLocation(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::BodySensorLocation());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_CscFeature(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::CscFeature());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_CscMeasurement(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::CscMeasurement());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_GlucoseFeature(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::GlucoseFeature());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_GlucoseMeasurement(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::GlucoseMeasurement());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_GlucoseMeasurementContext(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::GlucoseMeasurementContext());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_HeartRateControlPoint(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::HeartRateControlPoint());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_IntermediateCuffPressure(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::IntermediateCuffPressure());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_IntermediateTemperature(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::IntermediateTemperature());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_MeasurementInterval(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::MeasurementInterval());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_RecordAccessControlPoint(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::RecordAccessControlPoint());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_RscFeature(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::RscFeature());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_RscMeasurement(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::RscMeasurement());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_SCControlPoint(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::SCControlPoint());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_SensorLocation(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::SensorLocation());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_TemperatureMeasurement(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::TemperatureMeasurement());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_TemperatureType(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::TemperatureType());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_GapPeripheralPreferredConnectionParameters(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::GapPeripheralPreferredConnectionParameters());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_GapPeripheralPrivacyFlag(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::GapPeripheralPrivacyFlag());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_GapReconnectionAddress(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::GapReconnectionAddress());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_GattServiceChanged(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::GattServiceChanged());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_HardwareRevisionString(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::HardwareRevisionString());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_HidControlPoint(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::HidControlPoint());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_HidInformation(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::HidInformation());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_Ieee1107320601RegulatoryCertificationDataList(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::Ieee1107320601RegulatoryCertificationDataList());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_LnControlPoint(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::LnControlPoint());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_LnFeature(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::LnFeature());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_LocalTimeInformation(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::LocalTimeInformation());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_LocationAndSpeed(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::LocationAndSpeed());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_ManufacturerNameString(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::ManufacturerNameString());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_ModelNumberString(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::ModelNumberString());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_Navigation(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::Navigation());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_NewAlert(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::NewAlert());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_PnpId(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::PnpId());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_PositionQuality(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::PositionQuality());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_ProtocolMode(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::ProtocolMode());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_CyclingPowerFeature(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::CyclingPowerFeature());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_Report(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::Report());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_ReportMap(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::ReportMap());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_RingerControlPoint(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::RingerControlPoint());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_RingerSetting(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::RingerSetting());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_ScanIntervalWindow(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::ScanIntervalWindow());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_ScanRefresh(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::ScanRefresh());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_SerialNumberString(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::SerialNumberString());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_SoftwareRevisionString(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::SoftwareRevisionString());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_SupportUnreadAlertCategory(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::SupportUnreadAlertCategory());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_SupportedNewAlertCategory(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::SupportedNewAlertCategory());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_SystemId(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::SystemId());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_TimeAccuracy(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::TimeAccuracy());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_TimeSource(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::TimeSource());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_TimeUpdateControlPoint(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::TimeUpdateControlPoint());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_TimeUpdateState(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::TimeUpdateState());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_TimeWithDst(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::TimeWithDst());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_TimeZone(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::TimeZone());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_TxPowerLevel(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::TxPowerLevel());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_UnreadAlertStatus(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::UnreadAlertStatus());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_AlertCategoryId(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::AlertCategoryId());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_AlertCategoryIdBitMask(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::AlertCategoryIdBitMask());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_AlertLevel(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::AlertLevel());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_AlertNotificationControlPoint(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::AlertNotificationControlPoint());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_AlertStatus(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::AlertStatus());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_BootKeyboardInputReport(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::BootKeyboardInputReport());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_BootKeyboardOutputReport(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::BootKeyboardOutputReport());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_BootMouseInputReport(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::BootMouseInputReport());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_CurrentTime(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::CurrentTime());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_CyclingPowerControlPoint(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::CyclingPowerControlPoint());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_ReferenceTimeInformation(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::ReferenceTimeInformation());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_CyclingPowerMeasurement(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::CyclingPowerMeasurement());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_CyclingPowerVector(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::CyclingPowerVector());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_DateTime(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::DateTime());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_DayDateTime(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::DayDateTime());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_DayOfWeek(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::DayOfWeek());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_DstOffset(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::DstOffset());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_ExactTime256(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::ExactTime256());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_FirmwareRevisionString(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::FirmwareRevisionString());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_GapAppearance(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::GapAppearance());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicUuids_get_GapDeviceName(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids::GapDeviceName());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattCharacteristicUuids[] = {
        { "get_heart_rate_measurement", (PyCFunction)GattCharacteristicUuids_get_HeartRateMeasurement, METH_NOARGS | METH_STATIC, nullptr },
        { "get_battery_level", (PyCFunction)GattCharacteristicUuids_get_BatteryLevel, METH_NOARGS | METH_STATIC, nullptr },
        { "get_blood_pressure_feature", (PyCFunction)GattCharacteristicUuids_get_BloodPressureFeature, METH_NOARGS | METH_STATIC, nullptr },
        { "get_blood_pressure_measurement", (PyCFunction)GattCharacteristicUuids_get_BloodPressureMeasurement, METH_NOARGS | METH_STATIC, nullptr },
        { "get_body_sensor_location", (PyCFunction)GattCharacteristicUuids_get_BodySensorLocation, METH_NOARGS | METH_STATIC, nullptr },
        { "get_csc_feature", (PyCFunction)GattCharacteristicUuids_get_CscFeature, METH_NOARGS | METH_STATIC, nullptr },
        { "get_csc_measurement", (PyCFunction)GattCharacteristicUuids_get_CscMeasurement, METH_NOARGS | METH_STATIC, nullptr },
        { "get_glucose_feature", (PyCFunction)GattCharacteristicUuids_get_GlucoseFeature, METH_NOARGS | METH_STATIC, nullptr },
        { "get_glucose_measurement", (PyCFunction)GattCharacteristicUuids_get_GlucoseMeasurement, METH_NOARGS | METH_STATIC, nullptr },
        { "get_glucose_measurement_context", (PyCFunction)GattCharacteristicUuids_get_GlucoseMeasurementContext, METH_NOARGS | METH_STATIC, nullptr },
        { "get_heart_rate_control_point", (PyCFunction)GattCharacteristicUuids_get_HeartRateControlPoint, METH_NOARGS | METH_STATIC, nullptr },
        { "get_intermediate_cuff_pressure", (PyCFunction)GattCharacteristicUuids_get_IntermediateCuffPressure, METH_NOARGS | METH_STATIC, nullptr },
        { "get_intermediate_temperature", (PyCFunction)GattCharacteristicUuids_get_IntermediateTemperature, METH_NOARGS | METH_STATIC, nullptr },
        { "get_measurement_interval", (PyCFunction)GattCharacteristicUuids_get_MeasurementInterval, METH_NOARGS | METH_STATIC, nullptr },
        { "get_record_access_control_point", (PyCFunction)GattCharacteristicUuids_get_RecordAccessControlPoint, METH_NOARGS | METH_STATIC, nullptr },
        { "get_rsc_feature", (PyCFunction)GattCharacteristicUuids_get_RscFeature, METH_NOARGS | METH_STATIC, nullptr },
        { "get_rsc_measurement", (PyCFunction)GattCharacteristicUuids_get_RscMeasurement, METH_NOARGS | METH_STATIC, nullptr },
        { "get_s_c_control_point", (PyCFunction)GattCharacteristicUuids_get_SCControlPoint, METH_NOARGS | METH_STATIC, nullptr },
        { "get_sensor_location", (PyCFunction)GattCharacteristicUuids_get_SensorLocation, METH_NOARGS | METH_STATIC, nullptr },
        { "get_temperature_measurement", (PyCFunction)GattCharacteristicUuids_get_TemperatureMeasurement, METH_NOARGS | METH_STATIC, nullptr },
        { "get_temperature_type", (PyCFunction)GattCharacteristicUuids_get_TemperatureType, METH_NOARGS | METH_STATIC, nullptr },
        { "get_gap_peripheral_preferred_connection_parameters", (PyCFunction)GattCharacteristicUuids_get_GapPeripheralPreferredConnectionParameters, METH_NOARGS | METH_STATIC, nullptr },
        { "get_gap_peripheral_privacy_flag", (PyCFunction)GattCharacteristicUuids_get_GapPeripheralPrivacyFlag, METH_NOARGS | METH_STATIC, nullptr },
        { "get_gap_reconnection_address", (PyCFunction)GattCharacteristicUuids_get_GapReconnectionAddress, METH_NOARGS | METH_STATIC, nullptr },
        { "get_gatt_service_changed", (PyCFunction)GattCharacteristicUuids_get_GattServiceChanged, METH_NOARGS | METH_STATIC, nullptr },
        { "get_hardware_revision_string", (PyCFunction)GattCharacteristicUuids_get_HardwareRevisionString, METH_NOARGS | METH_STATIC, nullptr },
        { "get_hid_control_point", (PyCFunction)GattCharacteristicUuids_get_HidControlPoint, METH_NOARGS | METH_STATIC, nullptr },
        { "get_hid_information", (PyCFunction)GattCharacteristicUuids_get_HidInformation, METH_NOARGS | METH_STATIC, nullptr },
        { "get_ieee1107320601_regulatory_certification_data_list", (PyCFunction)GattCharacteristicUuids_get_Ieee1107320601RegulatoryCertificationDataList, METH_NOARGS | METH_STATIC, nullptr },
        { "get_ln_control_point", (PyCFunction)GattCharacteristicUuids_get_LnControlPoint, METH_NOARGS | METH_STATIC, nullptr },
        { "get_ln_feature", (PyCFunction)GattCharacteristicUuids_get_LnFeature, METH_NOARGS | METH_STATIC, nullptr },
        { "get_local_time_information", (PyCFunction)GattCharacteristicUuids_get_LocalTimeInformation, METH_NOARGS | METH_STATIC, nullptr },
        { "get_location_and_speed", (PyCFunction)GattCharacteristicUuids_get_LocationAndSpeed, METH_NOARGS | METH_STATIC, nullptr },
        { "get_manufacturer_name_string", (PyCFunction)GattCharacteristicUuids_get_ManufacturerNameString, METH_NOARGS | METH_STATIC, nullptr },
        { "get_model_number_string", (PyCFunction)GattCharacteristicUuids_get_ModelNumberString, METH_NOARGS | METH_STATIC, nullptr },
        { "get_navigation", (PyCFunction)GattCharacteristicUuids_get_Navigation, METH_NOARGS | METH_STATIC, nullptr },
        { "get_new_alert", (PyCFunction)GattCharacteristicUuids_get_NewAlert, METH_NOARGS | METH_STATIC, nullptr },
        { "get_pnp_id", (PyCFunction)GattCharacteristicUuids_get_PnpId, METH_NOARGS | METH_STATIC, nullptr },
        { "get_position_quality", (PyCFunction)GattCharacteristicUuids_get_PositionQuality, METH_NOARGS | METH_STATIC, nullptr },
        { "get_protocol_mode", (PyCFunction)GattCharacteristicUuids_get_ProtocolMode, METH_NOARGS | METH_STATIC, nullptr },
        { "get_cycling_power_feature", (PyCFunction)GattCharacteristicUuids_get_CyclingPowerFeature, METH_NOARGS | METH_STATIC, nullptr },
        { "get_report", (PyCFunction)GattCharacteristicUuids_get_Report, METH_NOARGS | METH_STATIC, nullptr },
        { "get_report_map", (PyCFunction)GattCharacteristicUuids_get_ReportMap, METH_NOARGS | METH_STATIC, nullptr },
        { "get_ringer_control_point", (PyCFunction)GattCharacteristicUuids_get_RingerControlPoint, METH_NOARGS | METH_STATIC, nullptr },
        { "get_ringer_setting", (PyCFunction)GattCharacteristicUuids_get_RingerSetting, METH_NOARGS | METH_STATIC, nullptr },
        { "get_scan_interval_window", (PyCFunction)GattCharacteristicUuids_get_ScanIntervalWindow, METH_NOARGS | METH_STATIC, nullptr },
        { "get_scan_refresh", (PyCFunction)GattCharacteristicUuids_get_ScanRefresh, METH_NOARGS | METH_STATIC, nullptr },
        { "get_serial_number_string", (PyCFunction)GattCharacteristicUuids_get_SerialNumberString, METH_NOARGS | METH_STATIC, nullptr },
        { "get_software_revision_string", (PyCFunction)GattCharacteristicUuids_get_SoftwareRevisionString, METH_NOARGS | METH_STATIC, nullptr },
        { "get_support_unread_alert_category", (PyCFunction)GattCharacteristicUuids_get_SupportUnreadAlertCategory, METH_NOARGS | METH_STATIC, nullptr },
        { "get_supported_new_alert_category", (PyCFunction)GattCharacteristicUuids_get_SupportedNewAlertCategory, METH_NOARGS | METH_STATIC, nullptr },
        { "get_system_id", (PyCFunction)GattCharacteristicUuids_get_SystemId, METH_NOARGS | METH_STATIC, nullptr },
        { "get_time_accuracy", (PyCFunction)GattCharacteristicUuids_get_TimeAccuracy, METH_NOARGS | METH_STATIC, nullptr },
        { "get_time_source", (PyCFunction)GattCharacteristicUuids_get_TimeSource, METH_NOARGS | METH_STATIC, nullptr },
        { "get_time_update_control_point", (PyCFunction)GattCharacteristicUuids_get_TimeUpdateControlPoint, METH_NOARGS | METH_STATIC, nullptr },
        { "get_time_update_state", (PyCFunction)GattCharacteristicUuids_get_TimeUpdateState, METH_NOARGS | METH_STATIC, nullptr },
        { "get_time_with_dst", (PyCFunction)GattCharacteristicUuids_get_TimeWithDst, METH_NOARGS | METH_STATIC, nullptr },
        { "get_time_zone", (PyCFunction)GattCharacteristicUuids_get_TimeZone, METH_NOARGS | METH_STATIC, nullptr },
        { "get_tx_power_level", (PyCFunction)GattCharacteristicUuids_get_TxPowerLevel, METH_NOARGS | METH_STATIC, nullptr },
        { "get_unread_alert_status", (PyCFunction)GattCharacteristicUuids_get_UnreadAlertStatus, METH_NOARGS | METH_STATIC, nullptr },
        { "get_alert_category_id", (PyCFunction)GattCharacteristicUuids_get_AlertCategoryId, METH_NOARGS | METH_STATIC, nullptr },
        { "get_alert_category_id_bit_mask", (PyCFunction)GattCharacteristicUuids_get_AlertCategoryIdBitMask, METH_NOARGS | METH_STATIC, nullptr },
        { "get_alert_level", (PyCFunction)GattCharacteristicUuids_get_AlertLevel, METH_NOARGS | METH_STATIC, nullptr },
        { "get_alert_notification_control_point", (PyCFunction)GattCharacteristicUuids_get_AlertNotificationControlPoint, METH_NOARGS | METH_STATIC, nullptr },
        { "get_alert_status", (PyCFunction)GattCharacteristicUuids_get_AlertStatus, METH_NOARGS | METH_STATIC, nullptr },
        { "get_boot_keyboard_input_report", (PyCFunction)GattCharacteristicUuids_get_BootKeyboardInputReport, METH_NOARGS | METH_STATIC, nullptr },
        { "get_boot_keyboard_output_report", (PyCFunction)GattCharacteristicUuids_get_BootKeyboardOutputReport, METH_NOARGS | METH_STATIC, nullptr },
        { "get_boot_mouse_input_report", (PyCFunction)GattCharacteristicUuids_get_BootMouseInputReport, METH_NOARGS | METH_STATIC, nullptr },
        { "get_current_time", (PyCFunction)GattCharacteristicUuids_get_CurrentTime, METH_NOARGS | METH_STATIC, nullptr },
        { "get_cycling_power_control_point", (PyCFunction)GattCharacteristicUuids_get_CyclingPowerControlPoint, METH_NOARGS | METH_STATIC, nullptr },
        { "get_reference_time_information", (PyCFunction)GattCharacteristicUuids_get_ReferenceTimeInformation, METH_NOARGS | METH_STATIC, nullptr },
        { "get_cycling_power_measurement", (PyCFunction)GattCharacteristicUuids_get_CyclingPowerMeasurement, METH_NOARGS | METH_STATIC, nullptr },
        { "get_cycling_power_vector", (PyCFunction)GattCharacteristicUuids_get_CyclingPowerVector, METH_NOARGS | METH_STATIC, nullptr },
        { "get_date_time", (PyCFunction)GattCharacteristicUuids_get_DateTime, METH_NOARGS | METH_STATIC, nullptr },
        { "get_day_date_time", (PyCFunction)GattCharacteristicUuids_get_DayDateTime, METH_NOARGS | METH_STATIC, nullptr },
        { "get_day_of_week", (PyCFunction)GattCharacteristicUuids_get_DayOfWeek, METH_NOARGS | METH_STATIC, nullptr },
        { "get_dst_offset", (PyCFunction)GattCharacteristicUuids_get_DstOffset, METH_NOARGS | METH_STATIC, nullptr },
        { "get_exact_time256", (PyCFunction)GattCharacteristicUuids_get_ExactTime256, METH_NOARGS | METH_STATIC, nullptr },
        { "get_firmware_revision_string", (PyCFunction)GattCharacteristicUuids_get_FirmwareRevisionString, METH_NOARGS | METH_STATIC, nullptr },
        { "get_gap_appearance", (PyCFunction)GattCharacteristicUuids_get_GapAppearance, METH_NOARGS | METH_STATIC, nullptr },
        { "get_gap_device_name", (PyCFunction)GattCharacteristicUuids_get_GapDeviceName, METH_NOARGS | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattCharacteristicUuids[] = {
        { nullptr }
    };

    static PyType_Slot _type_slots_GattCharacteristicUuids[] = 
    {
        { Py_tp_new, _new_GattCharacteristicUuids },
        { Py_tp_methods, _methods_GattCharacteristicUuids },
        { Py_tp_getset, _getset_GattCharacteristicUuids },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattCharacteristicUuids =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattCharacteristicUuids",
        0,
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattCharacteristicUuids
    };

    // ----- GattCharacteristicsResult class --------------------
    constexpr const char* const _type_name_GattCharacteristicsResult = "GattCharacteristicsResult";

    static PyObject* _new_GattCharacteristicsResult(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattCharacteristicsResult);
        return nullptr;
    }

    static void _dealloc_GattCharacteristicsResult(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicsResult* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattCharacteristicsResult_get_Characteristics(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicsResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Characteristics());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicsResult_get_ProtocolError(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicsResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ProtocolError());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattCharacteristicsResult_get_Status(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicsResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Status());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattCharacteristicsResult(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicsResult>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattCharacteristicsResult[] = {
        { "_from", (PyCFunction)_from_GattCharacteristicsResult, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattCharacteristicsResult[] = {
        { const_cast<char*>("characteristics"), (getter)GattCharacteristicsResult_get_Characteristics, nullptr, nullptr, nullptr },
        { const_cast<char*>("protocol_error"), (getter)GattCharacteristicsResult_get_ProtocolError, nullptr, nullptr, nullptr },
        { const_cast<char*>("status"), (getter)GattCharacteristicsResult_get_Status, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattCharacteristicsResult[] = 
    {
        { Py_tp_new, _new_GattCharacteristicsResult },
        { Py_tp_dealloc, _dealloc_GattCharacteristicsResult },
        { Py_tp_methods, _methods_GattCharacteristicsResult },
        { Py_tp_getset, _getset_GattCharacteristicsResult },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattCharacteristicsResult =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattCharacteristicsResult",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicsResult),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattCharacteristicsResult
    };

    // ----- GattClientNotificationResult class --------------------
    constexpr const char* const _type_name_GattClientNotificationResult = "GattClientNotificationResult";

    static PyObject* _new_GattClientNotificationResult(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattClientNotificationResult);
        return nullptr;
    }

    static void _dealloc_GattClientNotificationResult(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattClientNotificationResult* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattClientNotificationResult_get_ProtocolError(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattClientNotificationResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ProtocolError());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattClientNotificationResult_get_Status(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattClientNotificationResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Status());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattClientNotificationResult_get_SubscribedClient(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattClientNotificationResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.SubscribedClient());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattClientNotificationResult_get_BytesSent(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattClientNotificationResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.BytesSent());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattClientNotificationResult(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattClientNotificationResult>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattClientNotificationResult[] = {
        { "_from", (PyCFunction)_from_GattClientNotificationResult, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattClientNotificationResult[] = {
        { const_cast<char*>("protocol_error"), (getter)GattClientNotificationResult_get_ProtocolError, nullptr, nullptr, nullptr },
        { const_cast<char*>("status"), (getter)GattClientNotificationResult_get_Status, nullptr, nullptr, nullptr },
        { const_cast<char*>("subscribed_client"), (getter)GattClientNotificationResult_get_SubscribedClient, nullptr, nullptr, nullptr },
        { const_cast<char*>("bytes_sent"), (getter)GattClientNotificationResult_get_BytesSent, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattClientNotificationResult[] = 
    {
        { Py_tp_new, _new_GattClientNotificationResult },
        { Py_tp_dealloc, _dealloc_GattClientNotificationResult },
        { Py_tp_methods, _methods_GattClientNotificationResult },
        { Py_tp_getset, _getset_GattClientNotificationResult },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattClientNotificationResult =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattClientNotificationResult",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattClientNotificationResult),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattClientNotificationResult
    };

    // ----- GattDescriptor class --------------------
    constexpr const char* const _type_name_GattDescriptor = "GattDescriptor";

    static PyObject* _new_GattDescriptor(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattDescriptor);
        return nullptr;
    }

    static void _dealloc_GattDescriptor(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptor* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattDescriptor_ConvertShortIdToUuid(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<uint16_t>(args, 0);

                return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptor::ConvertShortIdToUuid(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDescriptor_ReadValueAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptor* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.ReadValueAsync());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::BluetoothCacheMode>(args, 0);

                return py::convert(self->obj.ReadValueAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDescriptor_WriteValueAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptor* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Storage::Streams::IBuffer>(args, 0);

                return py::convert(self->obj.WriteValueAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDescriptor_WriteValueWithResultAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptor* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Storage::Streams::IBuffer>(args, 0);

                return py::convert(self->obj.WriteValueWithResultAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDescriptor_get_ProtectionLevel(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptor* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ProtectionLevel());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int GattDescriptor_put_ProtectionLevel(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptor* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtectionLevel>(arg);

            self->obj.ProtectionLevel(param0);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyObject* GattDescriptor_get_AttributeHandle(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptor* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.AttributeHandle());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattDescriptor_get_Uuid(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptor* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Uuid());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattDescriptor(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptor>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattDescriptor[] = {
        { "read_value_async", (PyCFunction)GattDescriptor_ReadValueAsync, METH_VARARGS, nullptr },
        { "write_value_async", (PyCFunction)GattDescriptor_WriteValueAsync, METH_VARARGS, nullptr },
        { "write_value_with_result_async", (PyCFunction)GattDescriptor_WriteValueWithResultAsync, METH_VARARGS, nullptr },
        { "convert_short_id_to_uuid", (PyCFunction)GattDescriptor_ConvertShortIdToUuid, METH_VARARGS | METH_STATIC, nullptr },
        { "_from", (PyCFunction)_from_GattDescriptor, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattDescriptor[] = {
        { const_cast<char*>("protection_level"), (getter)GattDescriptor_get_ProtectionLevel, (setter)GattDescriptor_put_ProtectionLevel, nullptr, nullptr },
        { const_cast<char*>("attribute_handle"), (getter)GattDescriptor_get_AttributeHandle, nullptr, nullptr, nullptr },
        { const_cast<char*>("uuid"), (getter)GattDescriptor_get_Uuid, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattDescriptor[] = 
    {
        { Py_tp_new, _new_GattDescriptor },
        { Py_tp_dealloc, _dealloc_GattDescriptor },
        { Py_tp_methods, _methods_GattDescriptor },
        { Py_tp_getset, _getset_GattDescriptor },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattDescriptor =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattDescriptor",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptor),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattDescriptor
    };

    // ----- GattDescriptorUuids class --------------------
    constexpr const char* const _type_name_GattDescriptorUuids = "GattDescriptorUuids";

    static PyObject* _new_GattDescriptorUuids(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattDescriptorUuids);
        return nullptr;
    }

    static PyObject* GattDescriptorUuids_get_CharacteristicAggregateFormat(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptorUuids::CharacteristicAggregateFormat());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattDescriptorUuids_get_CharacteristicExtendedProperties(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptorUuids::CharacteristicExtendedProperties());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattDescriptorUuids_get_CharacteristicPresentationFormat(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptorUuids::CharacteristicPresentationFormat());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattDescriptorUuids_get_CharacteristicUserDescription(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptorUuids::CharacteristicUserDescription());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattDescriptorUuids_get_ClientCharacteristicConfiguration(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptorUuids::ClientCharacteristicConfiguration());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattDescriptorUuids_get_ServerCharacteristicConfiguration(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptorUuids::ServerCharacteristicConfiguration());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattDescriptorUuids[] = {
        { "get_characteristic_aggregate_format", (PyCFunction)GattDescriptorUuids_get_CharacteristicAggregateFormat, METH_NOARGS | METH_STATIC, nullptr },
        { "get_characteristic_extended_properties", (PyCFunction)GattDescriptorUuids_get_CharacteristicExtendedProperties, METH_NOARGS | METH_STATIC, nullptr },
        { "get_characteristic_presentation_format", (PyCFunction)GattDescriptorUuids_get_CharacteristicPresentationFormat, METH_NOARGS | METH_STATIC, nullptr },
        { "get_characteristic_user_description", (PyCFunction)GattDescriptorUuids_get_CharacteristicUserDescription, METH_NOARGS | METH_STATIC, nullptr },
        { "get_client_characteristic_configuration", (PyCFunction)GattDescriptorUuids_get_ClientCharacteristicConfiguration, METH_NOARGS | METH_STATIC, nullptr },
        { "get_server_characteristic_configuration", (PyCFunction)GattDescriptorUuids_get_ServerCharacteristicConfiguration, METH_NOARGS | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattDescriptorUuids[] = {
        { nullptr }
    };

    static PyType_Slot _type_slots_GattDescriptorUuids[] = 
    {
        { Py_tp_new, _new_GattDescriptorUuids },
        { Py_tp_methods, _methods_GattDescriptorUuids },
        { Py_tp_getset, _getset_GattDescriptorUuids },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattDescriptorUuids =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattDescriptorUuids",
        0,
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattDescriptorUuids
    };

    // ----- GattDescriptorsResult class --------------------
    constexpr const char* const _type_name_GattDescriptorsResult = "GattDescriptorsResult";

    static PyObject* _new_GattDescriptorsResult(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattDescriptorsResult);
        return nullptr;
    }

    static void _dealloc_GattDescriptorsResult(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptorsResult* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattDescriptorsResult_get_Descriptors(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptorsResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Descriptors());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattDescriptorsResult_get_ProtocolError(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptorsResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ProtocolError());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattDescriptorsResult_get_Status(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptorsResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Status());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattDescriptorsResult(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptorsResult>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattDescriptorsResult[] = {
        { "_from", (PyCFunction)_from_GattDescriptorsResult, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattDescriptorsResult[] = {
        { const_cast<char*>("descriptors"), (getter)GattDescriptorsResult_get_Descriptors, nullptr, nullptr, nullptr },
        { const_cast<char*>("protocol_error"), (getter)GattDescriptorsResult_get_ProtocolError, nullptr, nullptr, nullptr },
        { const_cast<char*>("status"), (getter)GattDescriptorsResult_get_Status, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattDescriptorsResult[] = 
    {
        { Py_tp_new, _new_GattDescriptorsResult },
        { Py_tp_dealloc, _dealloc_GattDescriptorsResult },
        { Py_tp_methods, _methods_GattDescriptorsResult },
        { Py_tp_getset, _getset_GattDescriptorsResult },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattDescriptorsResult =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattDescriptorsResult",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptorsResult),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattDescriptorsResult
    };

    // ----- GattDeviceService class --------------------
    constexpr const char* const _type_name_GattDeviceService = "GattDeviceService";

    static PyObject* _new_GattDeviceService(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattDeviceService);
        return nullptr;
    }

    static void _dealloc_GattDeviceService(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattDeviceService_Close(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                self->obj.Close();
                Py_RETURN_NONE;
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_ConvertShortIdToUuid(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<uint16_t>(args, 0);

                return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService::ConvertShortIdToUuid(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_FromIdAsync(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 2)
        {
            try
            {
                auto param0 = py::convert_to<winrt::hstring>(args, 0);
                auto param1 = py::convert_to<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSharingMode>(args, 1);

                return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService::FromIdAsync(param0, param1));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::hstring>(args, 0);

                return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService::FromIdAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_GetAllCharacteristics(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.GetAllCharacteristics());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_GetAllIncludedServices(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.GetAllIncludedServices());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_GetCharacteristics(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::guid>(args, 0);

                return py::convert(self->obj.GetCharacteristics(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_GetCharacteristicsAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.GetCharacteristicsAsync());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::BluetoothCacheMode>(args, 0);

                return py::convert(self->obj.GetCharacteristicsAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_GetCharacteristicsForUuidAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::guid>(args, 0);

                return py::convert(self->obj.GetCharacteristicsForUuidAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else if (arg_count == 2)
        {
            try
            {
                auto param0 = py::convert_to<winrt::guid>(args, 0);
                auto param1 = py::convert_to<winrt::Windows::Devices::Bluetooth::BluetoothCacheMode>(args, 1);

                return py::convert(self->obj.GetCharacteristicsForUuidAsync(param0, param1));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_GetDeviceSelectorForBluetoothDeviceId(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::BluetoothDeviceId>(args, 0);

                return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService::GetDeviceSelectorForBluetoothDeviceId(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else if (arg_count == 2)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::BluetoothDeviceId>(args, 0);
                auto param1 = py::convert_to<winrt::Windows::Devices::Bluetooth::BluetoothCacheMode>(args, 1);

                return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService::GetDeviceSelectorForBluetoothDeviceId(param0, param1));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_GetDeviceSelectorForBluetoothDeviceIdAndUuid(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 2)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::BluetoothDeviceId>(args, 0);
                auto param1 = py::convert_to<winrt::guid>(args, 1);

                return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService::GetDeviceSelectorForBluetoothDeviceIdAndUuid(param0, param1));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else if (arg_count == 3)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::BluetoothDeviceId>(args, 0);
                auto param1 = py::convert_to<winrt::guid>(args, 1);
                auto param2 = py::convert_to<winrt::Windows::Devices::Bluetooth::BluetoothCacheMode>(args, 2);

                return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService::GetDeviceSelectorForBluetoothDeviceIdAndUuid(param0, param1, param2));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_GetDeviceSelectorFromShortId(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<uint16_t>(args, 0);

                return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService::GetDeviceSelectorFromShortId(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_GetDeviceSelectorFromUuid(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::guid>(args, 0);

                return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService::GetDeviceSelectorFromUuid(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_GetIncludedServices(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::guid>(args, 0);

                return py::convert(self->obj.GetIncludedServices(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_GetIncludedServicesAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.GetIncludedServicesAsync());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::BluetoothCacheMode>(args, 0);

                return py::convert(self->obj.GetIncludedServicesAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_GetIncludedServicesForUuidAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::guid>(args, 0);

                return py::convert(self->obj.GetIncludedServicesForUuidAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else if (arg_count == 2)
        {
            try
            {
                auto param0 = py::convert_to<winrt::guid>(args, 0);
                auto param1 = py::convert_to<winrt::Windows::Devices::Bluetooth::BluetoothCacheMode>(args, 1);

                return py::convert(self->obj.GetIncludedServicesForUuidAsync(param0, param1));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_OpenAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSharingMode>(args, 0);

                return py::convert(self->obj.OpenAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_RequestAccessAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.RequestAccessAsync());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_get_AttributeHandle(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.AttributeHandle());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_get_DeviceId(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.DeviceId());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_get_Uuid(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Uuid());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_get_Device(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Device());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_get_ParentServices(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ParentServices());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_get_DeviceAccessInformation(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.DeviceAccessInformation());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_get_Session(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Session());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattDeviceService_get_SharingMode(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.SharingMode());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattDeviceService(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _enter_GattDeviceService(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self) noexcept
    {
        Py_INCREF(self);
        return (PyObject*)self;
    }

    static PyObject* _exit_GattDeviceService(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService* self) noexcept
    {
        try
        {
            self->obj.Close();
            Py_RETURN_FALSE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattDeviceService[] = {
        { "get_characteristics", (PyCFunction)GattDeviceService_GetCharacteristics, METH_VARARGS, nullptr },
        { "get_included_services", (PyCFunction)GattDeviceService_GetIncludedServices, METH_VARARGS, nullptr },
        { "close", (PyCFunction)GattDeviceService_Close, METH_VARARGS, nullptr },
        { "get_all_characteristics", (PyCFunction)GattDeviceService_GetAllCharacteristics, METH_VARARGS, nullptr },
        { "get_all_included_services", (PyCFunction)GattDeviceService_GetAllIncludedServices, METH_VARARGS, nullptr },
        { "request_access_async", (PyCFunction)GattDeviceService_RequestAccessAsync, METH_VARARGS, nullptr },
        { "open_async", (PyCFunction)GattDeviceService_OpenAsync, METH_VARARGS, nullptr },
        { "get_characteristics_async", (PyCFunction)GattDeviceService_GetCharacteristicsAsync, METH_VARARGS, nullptr },
        { "get_characteristics_for_uuid_async", (PyCFunction)GattDeviceService_GetCharacteristicsForUuidAsync, METH_VARARGS, nullptr },
        { "get_included_services_async", (PyCFunction)GattDeviceService_GetIncludedServicesAsync, METH_VARARGS, nullptr },
        { "get_included_services_for_uuid_async", (PyCFunction)GattDeviceService_GetIncludedServicesForUuidAsync, METH_VARARGS, nullptr },
        { "from_id_async", (PyCFunction)GattDeviceService_FromIdAsync, METH_VARARGS | METH_STATIC, nullptr },
        { "get_device_selector_for_bluetooth_device_id", (PyCFunction)GattDeviceService_GetDeviceSelectorForBluetoothDeviceId, METH_VARARGS | METH_STATIC, nullptr },
        { "get_device_selector_for_bluetooth_device_id_and_uuid", (PyCFunction)GattDeviceService_GetDeviceSelectorForBluetoothDeviceIdAndUuid, METH_VARARGS | METH_STATIC, nullptr },
        { "get_device_selector_from_uuid", (PyCFunction)GattDeviceService_GetDeviceSelectorFromUuid, METH_VARARGS | METH_STATIC, nullptr },
        { "get_device_selector_from_short_id", (PyCFunction)GattDeviceService_GetDeviceSelectorFromShortId, METH_VARARGS | METH_STATIC, nullptr },
        { "convert_short_id_to_uuid", (PyCFunction)GattDeviceService_ConvertShortIdToUuid, METH_VARARGS | METH_STATIC, nullptr },
        { "_from", (PyCFunction)_from_GattDeviceService, METH_O | METH_STATIC, nullptr },
        { "__enter__", (PyCFunction)_enter_GattDeviceService, METH_NOARGS, nullptr },
        { "__exit__",  (PyCFunction)_exit_GattDeviceService, METH_VARARGS, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattDeviceService[] = {
        { const_cast<char*>("attribute_handle"), (getter)GattDeviceService_get_AttributeHandle, nullptr, nullptr, nullptr },
        { const_cast<char*>("device_id"), (getter)GattDeviceService_get_DeviceId, nullptr, nullptr, nullptr },
        { const_cast<char*>("uuid"), (getter)GattDeviceService_get_Uuid, nullptr, nullptr, nullptr },
        { const_cast<char*>("device"), (getter)GattDeviceService_get_Device, nullptr, nullptr, nullptr },
        { const_cast<char*>("parent_services"), (getter)GattDeviceService_get_ParentServices, nullptr, nullptr, nullptr },
        { const_cast<char*>("device_access_information"), (getter)GattDeviceService_get_DeviceAccessInformation, nullptr, nullptr, nullptr },
        { const_cast<char*>("session"), (getter)GattDeviceService_get_Session, nullptr, nullptr, nullptr },
        { const_cast<char*>("sharing_mode"), (getter)GattDeviceService_get_SharingMode, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattDeviceService[] = 
    {
        { Py_tp_new, _new_GattDeviceService },
        { Py_tp_dealloc, _dealloc_GattDeviceService },
        { Py_tp_methods, _methods_GattDeviceService },
        { Py_tp_getset, _getset_GattDeviceService },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattDeviceService =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattDeviceService",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattDeviceService
    };

    // ----- GattDeviceServicesResult class --------------------
    constexpr const char* const _type_name_GattDeviceServicesResult = "GattDeviceServicesResult";

    static PyObject* _new_GattDeviceServicesResult(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattDeviceServicesResult);
        return nullptr;
    }

    static void _dealloc_GattDeviceServicesResult(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceServicesResult* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattDeviceServicesResult_get_ProtocolError(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceServicesResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ProtocolError());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattDeviceServicesResult_get_Services(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceServicesResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Services());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattDeviceServicesResult_get_Status(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceServicesResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Status());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattDeviceServicesResult(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceServicesResult>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattDeviceServicesResult[] = {
        { "_from", (PyCFunction)_from_GattDeviceServicesResult, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattDeviceServicesResult[] = {
        { const_cast<char*>("protocol_error"), (getter)GattDeviceServicesResult_get_ProtocolError, nullptr, nullptr, nullptr },
        { const_cast<char*>("services"), (getter)GattDeviceServicesResult_get_Services, nullptr, nullptr, nullptr },
        { const_cast<char*>("status"), (getter)GattDeviceServicesResult_get_Status, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattDeviceServicesResult[] = 
    {
        { Py_tp_new, _new_GattDeviceServicesResult },
        { Py_tp_dealloc, _dealloc_GattDeviceServicesResult },
        { Py_tp_methods, _methods_GattDeviceServicesResult },
        { Py_tp_getset, _getset_GattDeviceServicesResult },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattDeviceServicesResult =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattDeviceServicesResult",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceServicesResult),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattDeviceServicesResult
    };

    // ----- GattLocalCharacteristic class --------------------
    constexpr const char* const _type_name_GattLocalCharacteristic = "GattLocalCharacteristic";

    static PyObject* _new_GattLocalCharacteristic(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattLocalCharacteristic);
        return nullptr;
    }

    static void _dealloc_GattLocalCharacteristic(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattLocalCharacteristic_CreateDescriptorAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 2)
        {
            try
            {
                auto param0 = py::convert_to<winrt::guid>(args, 0);
                auto param1 = py::convert_to<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorParameters>(args, 1);

                return py::convert(self->obj.CreateDescriptorAsync(param0, param1));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattLocalCharacteristic_NotifyValueAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Storage::Streams::IBuffer>(args, 0);

                return py::convert(self->obj.NotifyValueAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else if (arg_count == 2)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Storage::Streams::IBuffer>(args, 0);
                auto param1 = py::convert_to<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSubscribedClient>(args, 1);

                return py::convert(self->obj.NotifyValueAsync(param0, param1));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattLocalCharacteristic_get_CharacteristicProperties(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.CharacteristicProperties());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalCharacteristic_get_Descriptors(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Descriptors());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalCharacteristic_get_PresentationFormats(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.PresentationFormats());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalCharacteristic_get_ReadProtectionLevel(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ReadProtectionLevel());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalCharacteristic_get_StaticValue(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.StaticValue());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalCharacteristic_get_SubscribedClients(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.SubscribedClients());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalCharacteristic_get_UserDescription(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.UserDescription());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalCharacteristic_get_Uuid(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Uuid());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalCharacteristic_get_WriteProtectionLevel(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.WriteProtectionLevel());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalCharacteristic_add_ReadRequested(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic, winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequestedEventArgs>>(arg);

            return py::convert(self->obj.ReadRequested(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalCharacteristic_remove_ReadRequested(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.ReadRequested(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalCharacteristic_add_SubscribedClientsChanged(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic, winrt::Windows::Foundation::IInspectable>>(arg);

            return py::convert(self->obj.SubscribedClientsChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalCharacteristic_remove_SubscribedClientsChanged(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.SubscribedClientsChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalCharacteristic_add_WriteRequested(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic, winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequestedEventArgs>>(arg);

            return py::convert(self->obj.WriteRequested(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalCharacteristic_remove_WriteRequested(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.WriteRequested(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattLocalCharacteristic(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattLocalCharacteristic[] = {
        { "create_descriptor_async", (PyCFunction)GattLocalCharacteristic_CreateDescriptorAsync, METH_VARARGS, nullptr },
        { "notify_value_async", (PyCFunction)GattLocalCharacteristic_NotifyValueAsync, METH_VARARGS, nullptr },
        { "add_read_requested", (PyCFunction)GattLocalCharacteristic_add_ReadRequested, METH_O, nullptr },
        { "remove_read_requested", (PyCFunction)GattLocalCharacteristic_remove_ReadRequested, METH_O, nullptr },
        { "add_subscribed_clients_changed", (PyCFunction)GattLocalCharacteristic_add_SubscribedClientsChanged, METH_O, nullptr },
        { "remove_subscribed_clients_changed", (PyCFunction)GattLocalCharacteristic_remove_SubscribedClientsChanged, METH_O, nullptr },
        { "add_write_requested", (PyCFunction)GattLocalCharacteristic_add_WriteRequested, METH_O, nullptr },
        { "remove_write_requested", (PyCFunction)GattLocalCharacteristic_remove_WriteRequested, METH_O, nullptr },
        { "_from", (PyCFunction)_from_GattLocalCharacteristic, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattLocalCharacteristic[] = {
        { const_cast<char*>("characteristic_properties"), (getter)GattLocalCharacteristic_get_CharacteristicProperties, nullptr, nullptr, nullptr },
        { const_cast<char*>("descriptors"), (getter)GattLocalCharacteristic_get_Descriptors, nullptr, nullptr, nullptr },
        { const_cast<char*>("presentation_formats"), (getter)GattLocalCharacteristic_get_PresentationFormats, nullptr, nullptr, nullptr },
        { const_cast<char*>("read_protection_level"), (getter)GattLocalCharacteristic_get_ReadProtectionLevel, nullptr, nullptr, nullptr },
        { const_cast<char*>("static_value"), (getter)GattLocalCharacteristic_get_StaticValue, nullptr, nullptr, nullptr },
        { const_cast<char*>("subscribed_clients"), (getter)GattLocalCharacteristic_get_SubscribedClients, nullptr, nullptr, nullptr },
        { const_cast<char*>("user_description"), (getter)GattLocalCharacteristic_get_UserDescription, nullptr, nullptr, nullptr },
        { const_cast<char*>("uuid"), (getter)GattLocalCharacteristic_get_Uuid, nullptr, nullptr, nullptr },
        { const_cast<char*>("write_protection_level"), (getter)GattLocalCharacteristic_get_WriteProtectionLevel, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattLocalCharacteristic[] = 
    {
        { Py_tp_new, _new_GattLocalCharacteristic },
        { Py_tp_dealloc, _dealloc_GattLocalCharacteristic },
        { Py_tp_methods, _methods_GattLocalCharacteristic },
        { Py_tp_getset, _getset_GattLocalCharacteristic },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattLocalCharacteristic =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattLocalCharacteristic",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattLocalCharacteristic
    };

    // ----- GattLocalCharacteristicParameters class --------------------
    constexpr const char* const _type_name_GattLocalCharacteristicParameters = "GattLocalCharacteristicParameters";

    static PyObject* _new_GattLocalCharacteristicParameters(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        if (kwds != nullptr)
        {
            py::set_invalid_kwd_args_error();
            return nullptr;
        }

        Py_ssize_t arg_count = PyTuple_Size(args);
        if (arg_count == 0)
        {
            try
            {
                winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicParameters instance{  };
                return py::wrap(instance, type);
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static void _dealloc_GattLocalCharacteristicParameters(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicParameters* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattLocalCharacteristicParameters_get_WriteProtectionLevel(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicParameters* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.WriteProtectionLevel());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int GattLocalCharacteristicParameters_put_WriteProtectionLevel(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicParameters* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtectionLevel>(arg);

            self->obj.WriteProtectionLevel(param0);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyObject* GattLocalCharacteristicParameters_get_UserDescription(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicParameters* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.UserDescription());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int GattLocalCharacteristicParameters_put_UserDescription(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicParameters* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            auto param0 = py::convert_to<winrt::hstring>(arg);

            self->obj.UserDescription(param0);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyObject* GattLocalCharacteristicParameters_get_StaticValue(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicParameters* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.StaticValue());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int GattLocalCharacteristicParameters_put_StaticValue(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicParameters* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            auto param0 = py::convert_to<winrt::Windows::Storage::Streams::IBuffer>(arg);

            self->obj.StaticValue(param0);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyObject* GattLocalCharacteristicParameters_get_ReadProtectionLevel(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicParameters* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ReadProtectionLevel());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int GattLocalCharacteristicParameters_put_ReadProtectionLevel(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicParameters* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtectionLevel>(arg);

            self->obj.ReadProtectionLevel(param0);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyObject* GattLocalCharacteristicParameters_get_CharacteristicProperties(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicParameters* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.CharacteristicProperties());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int GattLocalCharacteristicParameters_put_CharacteristicProperties(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicParameters* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicProperties>(arg);

            self->obj.CharacteristicProperties(param0);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyObject* GattLocalCharacteristicParameters_get_PresentationFormats(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicParameters* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.PresentationFormats());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattLocalCharacteristicParameters(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicParameters>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattLocalCharacteristicParameters[] = {
        { "_from", (PyCFunction)_from_GattLocalCharacteristicParameters, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattLocalCharacteristicParameters[] = {
        { const_cast<char*>("write_protection_level"), (getter)GattLocalCharacteristicParameters_get_WriteProtectionLevel, (setter)GattLocalCharacteristicParameters_put_WriteProtectionLevel, nullptr, nullptr },
        { const_cast<char*>("user_description"), (getter)GattLocalCharacteristicParameters_get_UserDescription, (setter)GattLocalCharacteristicParameters_put_UserDescription, nullptr, nullptr },
        { const_cast<char*>("static_value"), (getter)GattLocalCharacteristicParameters_get_StaticValue, (setter)GattLocalCharacteristicParameters_put_StaticValue, nullptr, nullptr },
        { const_cast<char*>("read_protection_level"), (getter)GattLocalCharacteristicParameters_get_ReadProtectionLevel, (setter)GattLocalCharacteristicParameters_put_ReadProtectionLevel, nullptr, nullptr },
        { const_cast<char*>("characteristic_properties"), (getter)GattLocalCharacteristicParameters_get_CharacteristicProperties, (setter)GattLocalCharacteristicParameters_put_CharacteristicProperties, nullptr, nullptr },
        { const_cast<char*>("presentation_formats"), (getter)GattLocalCharacteristicParameters_get_PresentationFormats, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattLocalCharacteristicParameters[] = 
    {
        { Py_tp_new, _new_GattLocalCharacteristicParameters },
        { Py_tp_dealloc, _dealloc_GattLocalCharacteristicParameters },
        { Py_tp_methods, _methods_GattLocalCharacteristicParameters },
        { Py_tp_getset, _getset_GattLocalCharacteristicParameters },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattLocalCharacteristicParameters =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattLocalCharacteristicParameters",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicParameters),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattLocalCharacteristicParameters
    };

    // ----- GattLocalCharacteristicResult class --------------------
    constexpr const char* const _type_name_GattLocalCharacteristicResult = "GattLocalCharacteristicResult";

    static PyObject* _new_GattLocalCharacteristicResult(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattLocalCharacteristicResult);
        return nullptr;
    }

    static void _dealloc_GattLocalCharacteristicResult(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicResult* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattLocalCharacteristicResult_get_Characteristic(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Characteristic());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalCharacteristicResult_get_Error(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Error());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattLocalCharacteristicResult(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicResult>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattLocalCharacteristicResult[] = {
        { "_from", (PyCFunction)_from_GattLocalCharacteristicResult, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattLocalCharacteristicResult[] = {
        { const_cast<char*>("characteristic"), (getter)GattLocalCharacteristicResult_get_Characteristic, nullptr, nullptr, nullptr },
        { const_cast<char*>("error"), (getter)GattLocalCharacteristicResult_get_Error, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattLocalCharacteristicResult[] = 
    {
        { Py_tp_new, _new_GattLocalCharacteristicResult },
        { Py_tp_dealloc, _dealloc_GattLocalCharacteristicResult },
        { Py_tp_methods, _methods_GattLocalCharacteristicResult },
        { Py_tp_getset, _getset_GattLocalCharacteristicResult },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattLocalCharacteristicResult =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattLocalCharacteristicResult",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicResult),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattLocalCharacteristicResult
    };

    // ----- GattLocalDescriptor class --------------------
    constexpr const char* const _type_name_GattLocalDescriptor = "GattLocalDescriptor";

    static PyObject* _new_GattLocalDescriptor(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattLocalDescriptor);
        return nullptr;
    }

    static void _dealloc_GattLocalDescriptor(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptor* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattLocalDescriptor_get_ReadProtectionLevel(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptor* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ReadProtectionLevel());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalDescriptor_get_StaticValue(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptor* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.StaticValue());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalDescriptor_get_Uuid(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptor* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Uuid());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalDescriptor_get_WriteProtectionLevel(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptor* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.WriteProtectionLevel());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalDescriptor_add_ReadRequested(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptor* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptor, winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequestedEventArgs>>(arg);

            return py::convert(self->obj.ReadRequested(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalDescriptor_remove_ReadRequested(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptor* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.ReadRequested(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalDescriptor_add_WriteRequested(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptor* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptor, winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequestedEventArgs>>(arg);

            return py::convert(self->obj.WriteRequested(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalDescriptor_remove_WriteRequested(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptor* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.WriteRequested(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattLocalDescriptor(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptor>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattLocalDescriptor[] = {
        { "add_read_requested", (PyCFunction)GattLocalDescriptor_add_ReadRequested, METH_O, nullptr },
        { "remove_read_requested", (PyCFunction)GattLocalDescriptor_remove_ReadRequested, METH_O, nullptr },
        { "add_write_requested", (PyCFunction)GattLocalDescriptor_add_WriteRequested, METH_O, nullptr },
        { "remove_write_requested", (PyCFunction)GattLocalDescriptor_remove_WriteRequested, METH_O, nullptr },
        { "_from", (PyCFunction)_from_GattLocalDescriptor, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattLocalDescriptor[] = {
        { const_cast<char*>("read_protection_level"), (getter)GattLocalDescriptor_get_ReadProtectionLevel, nullptr, nullptr, nullptr },
        { const_cast<char*>("static_value"), (getter)GattLocalDescriptor_get_StaticValue, nullptr, nullptr, nullptr },
        { const_cast<char*>("uuid"), (getter)GattLocalDescriptor_get_Uuid, nullptr, nullptr, nullptr },
        { const_cast<char*>("write_protection_level"), (getter)GattLocalDescriptor_get_WriteProtectionLevel, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattLocalDescriptor[] = 
    {
        { Py_tp_new, _new_GattLocalDescriptor },
        { Py_tp_dealloc, _dealloc_GattLocalDescriptor },
        { Py_tp_methods, _methods_GattLocalDescriptor },
        { Py_tp_getset, _getset_GattLocalDescriptor },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattLocalDescriptor =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattLocalDescriptor",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptor),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattLocalDescriptor
    };

    // ----- GattLocalDescriptorParameters class --------------------
    constexpr const char* const _type_name_GattLocalDescriptorParameters = "GattLocalDescriptorParameters";

    static PyObject* _new_GattLocalDescriptorParameters(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        if (kwds != nullptr)
        {
            py::set_invalid_kwd_args_error();
            return nullptr;
        }

        Py_ssize_t arg_count = PyTuple_Size(args);
        if (arg_count == 0)
        {
            try
            {
                winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorParameters instance{  };
                return py::wrap(instance, type);
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static void _dealloc_GattLocalDescriptorParameters(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorParameters* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattLocalDescriptorParameters_get_WriteProtectionLevel(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorParameters* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.WriteProtectionLevel());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int GattLocalDescriptorParameters_put_WriteProtectionLevel(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorParameters* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtectionLevel>(arg);

            self->obj.WriteProtectionLevel(param0);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyObject* GattLocalDescriptorParameters_get_StaticValue(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorParameters* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.StaticValue());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int GattLocalDescriptorParameters_put_StaticValue(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorParameters* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            auto param0 = py::convert_to<winrt::Windows::Storage::Streams::IBuffer>(arg);

            self->obj.StaticValue(param0);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyObject* GattLocalDescriptorParameters_get_ReadProtectionLevel(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorParameters* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ReadProtectionLevel());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int GattLocalDescriptorParameters_put_ReadProtectionLevel(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorParameters* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtectionLevel>(arg);

            self->obj.ReadProtectionLevel(param0);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyObject* _from_GattLocalDescriptorParameters(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorParameters>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattLocalDescriptorParameters[] = {
        { "_from", (PyCFunction)_from_GattLocalDescriptorParameters, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattLocalDescriptorParameters[] = {
        { const_cast<char*>("write_protection_level"), (getter)GattLocalDescriptorParameters_get_WriteProtectionLevel, (setter)GattLocalDescriptorParameters_put_WriteProtectionLevel, nullptr, nullptr },
        { const_cast<char*>("static_value"), (getter)GattLocalDescriptorParameters_get_StaticValue, (setter)GattLocalDescriptorParameters_put_StaticValue, nullptr, nullptr },
        { const_cast<char*>("read_protection_level"), (getter)GattLocalDescriptorParameters_get_ReadProtectionLevel, (setter)GattLocalDescriptorParameters_put_ReadProtectionLevel, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattLocalDescriptorParameters[] = 
    {
        { Py_tp_new, _new_GattLocalDescriptorParameters },
        { Py_tp_dealloc, _dealloc_GattLocalDescriptorParameters },
        { Py_tp_methods, _methods_GattLocalDescriptorParameters },
        { Py_tp_getset, _getset_GattLocalDescriptorParameters },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattLocalDescriptorParameters =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattLocalDescriptorParameters",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorParameters),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattLocalDescriptorParameters
    };

    // ----- GattLocalDescriptorResult class --------------------
    constexpr const char* const _type_name_GattLocalDescriptorResult = "GattLocalDescriptorResult";

    static PyObject* _new_GattLocalDescriptorResult(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattLocalDescriptorResult);
        return nullptr;
    }

    static void _dealloc_GattLocalDescriptorResult(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorResult* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattLocalDescriptorResult_get_Descriptor(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Descriptor());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalDescriptorResult_get_Error(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Error());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattLocalDescriptorResult(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorResult>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattLocalDescriptorResult[] = {
        { "_from", (PyCFunction)_from_GattLocalDescriptorResult, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattLocalDescriptorResult[] = {
        { const_cast<char*>("descriptor"), (getter)GattLocalDescriptorResult_get_Descriptor, nullptr, nullptr, nullptr },
        { const_cast<char*>("error"), (getter)GattLocalDescriptorResult_get_Error, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattLocalDescriptorResult[] = 
    {
        { Py_tp_new, _new_GattLocalDescriptorResult },
        { Py_tp_dealloc, _dealloc_GattLocalDescriptorResult },
        { Py_tp_methods, _methods_GattLocalDescriptorResult },
        { Py_tp_getset, _getset_GattLocalDescriptorResult },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattLocalDescriptorResult =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattLocalDescriptorResult",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorResult),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattLocalDescriptorResult
    };

    // ----- GattLocalService class --------------------
    constexpr const char* const _type_name_GattLocalService = "GattLocalService";

    static PyObject* _new_GattLocalService(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattLocalService);
        return nullptr;
    }

    static void _dealloc_GattLocalService(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalService* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattLocalService_CreateCharacteristicAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalService* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 2)
        {
            try
            {
                auto param0 = py::convert_to<winrt::guid>(args, 0);
                auto param1 = py::convert_to<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicParameters>(args, 1);

                return py::convert(self->obj.CreateCharacteristicAsync(param0, param1));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattLocalService_get_Characteristics(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalService* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Characteristics());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattLocalService_get_Uuid(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalService* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Uuid());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattLocalService(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalService>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattLocalService[] = {
        { "create_characteristic_async", (PyCFunction)GattLocalService_CreateCharacteristicAsync, METH_VARARGS, nullptr },
        { "_from", (PyCFunction)_from_GattLocalService, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattLocalService[] = {
        { const_cast<char*>("characteristics"), (getter)GattLocalService_get_Characteristics, nullptr, nullptr, nullptr },
        { const_cast<char*>("uuid"), (getter)GattLocalService_get_Uuid, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattLocalService[] = 
    {
        { Py_tp_new, _new_GattLocalService },
        { Py_tp_dealloc, _dealloc_GattLocalService },
        { Py_tp_methods, _methods_GattLocalService },
        { Py_tp_getset, _getset_GattLocalService },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattLocalService =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattLocalService",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalService),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattLocalService
    };

    // ----- GattPresentationFormat class --------------------
    constexpr const char* const _type_name_GattPresentationFormat = "GattPresentationFormat";

    static PyObject* _new_GattPresentationFormat(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattPresentationFormat);
        return nullptr;
    }

    static void _dealloc_GattPresentationFormat(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormat* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattPresentationFormat_FromParts(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 5)
        {
            try
            {
                auto param0 = py::convert_to<uint8_t>(args, 0);
                auto param1 = py::convert_to<int32_t>(args, 1);
                auto param2 = py::convert_to<uint16_t>(args, 2);
                auto param3 = py::convert_to<uint8_t>(args, 3);
                auto param4 = py::convert_to<uint16_t>(args, 4);

                return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormat::FromParts(param0, param1, param2, param3, param4));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormat_get_Description(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormat* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Description());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormat_get_Exponent(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormat* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Exponent());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormat_get_FormatType(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormat* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.FormatType());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormat_get_Namespace(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormat* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Namespace());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormat_get_Unit(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormat* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Unit());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormat_get_BluetoothSigAssignedNumbers(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormat::BluetoothSigAssignedNumbers());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattPresentationFormat(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormat>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattPresentationFormat[] = {
        { "from_parts", (PyCFunction)GattPresentationFormat_FromParts, METH_VARARGS | METH_STATIC, nullptr },
        { "get_bluetooth_sig_assigned_numbers", (PyCFunction)GattPresentationFormat_get_BluetoothSigAssignedNumbers, METH_NOARGS | METH_STATIC, nullptr },
        { "_from", (PyCFunction)_from_GattPresentationFormat, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattPresentationFormat[] = {
        { const_cast<char*>("description"), (getter)GattPresentationFormat_get_Description, nullptr, nullptr, nullptr },
        { const_cast<char*>("exponent"), (getter)GattPresentationFormat_get_Exponent, nullptr, nullptr, nullptr },
        { const_cast<char*>("format_type"), (getter)GattPresentationFormat_get_FormatType, nullptr, nullptr, nullptr },
        { const_cast<char*>("namespace"), (getter)GattPresentationFormat_get_Namespace, nullptr, nullptr, nullptr },
        { const_cast<char*>("unit"), (getter)GattPresentationFormat_get_Unit, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattPresentationFormat[] = 
    {
        { Py_tp_new, _new_GattPresentationFormat },
        { Py_tp_dealloc, _dealloc_GattPresentationFormat },
        { Py_tp_methods, _methods_GattPresentationFormat },
        { Py_tp_getset, _getset_GattPresentationFormat },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattPresentationFormat =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattPresentationFormat",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormat),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattPresentationFormat
    };

    // ----- GattPresentationFormatTypes class --------------------
    constexpr const char* const _type_name_GattPresentationFormatTypes = "GattPresentationFormatTypes";

    static PyObject* _new_GattPresentationFormatTypes(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattPresentationFormatTypes);
        return nullptr;
    }

    static PyObject* GattPresentationFormatTypes_get_Bit2(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::Bit2());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_Boolean(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::Boolean());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_DUInt16(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::DUInt16());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_Float(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::Float());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_Float32(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::Float32());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_Float64(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::Float64());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_Nibble(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::Nibble());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_SFloat(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::SFloat());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_SInt12(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::SInt12());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_SInt128(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::SInt128());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_SInt16(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::SInt16());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_SInt24(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::SInt24());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_SInt32(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::SInt32());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_SInt48(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::SInt48());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_SInt64(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::SInt64());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_SInt8(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::SInt8());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_Struct(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::Struct());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_UInt12(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::UInt12());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_UInt128(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::UInt128());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_UInt16(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::UInt16());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_UInt24(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::UInt24());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_UInt32(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::UInt32());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_UInt48(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::UInt48());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_UInt64(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::UInt64());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_UInt8(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::UInt8());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_Utf16(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::Utf16());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattPresentationFormatTypes_get_Utf8(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes::Utf8());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattPresentationFormatTypes[] = {
        { "get_bit2", (PyCFunction)GattPresentationFormatTypes_get_Bit2, METH_NOARGS | METH_STATIC, nullptr },
        { "get_boolean", (PyCFunction)GattPresentationFormatTypes_get_Boolean, METH_NOARGS | METH_STATIC, nullptr },
        { "get_d_uint16", (PyCFunction)GattPresentationFormatTypes_get_DUInt16, METH_NOARGS | METH_STATIC, nullptr },
        { "get_float", (PyCFunction)GattPresentationFormatTypes_get_Float, METH_NOARGS | METH_STATIC, nullptr },
        { "get_float32", (PyCFunction)GattPresentationFormatTypes_get_Float32, METH_NOARGS | METH_STATIC, nullptr },
        { "get_float64", (PyCFunction)GattPresentationFormatTypes_get_Float64, METH_NOARGS | METH_STATIC, nullptr },
        { "get_nibble", (PyCFunction)GattPresentationFormatTypes_get_Nibble, METH_NOARGS | METH_STATIC, nullptr },
        { "get_s_float", (PyCFunction)GattPresentationFormatTypes_get_SFloat, METH_NOARGS | METH_STATIC, nullptr },
        { "get_s_int12", (PyCFunction)GattPresentationFormatTypes_get_SInt12, METH_NOARGS | METH_STATIC, nullptr },
        { "get_s_int128", (PyCFunction)GattPresentationFormatTypes_get_SInt128, METH_NOARGS | METH_STATIC, nullptr },
        { "get_s_int16", (PyCFunction)GattPresentationFormatTypes_get_SInt16, METH_NOARGS | METH_STATIC, nullptr },
        { "get_s_int24", (PyCFunction)GattPresentationFormatTypes_get_SInt24, METH_NOARGS | METH_STATIC, nullptr },
        { "get_s_int32", (PyCFunction)GattPresentationFormatTypes_get_SInt32, METH_NOARGS | METH_STATIC, nullptr },
        { "get_s_int48", (PyCFunction)GattPresentationFormatTypes_get_SInt48, METH_NOARGS | METH_STATIC, nullptr },
        { "get_s_int64", (PyCFunction)GattPresentationFormatTypes_get_SInt64, METH_NOARGS | METH_STATIC, nullptr },
        { "get_s_int8", (PyCFunction)GattPresentationFormatTypes_get_SInt8, METH_NOARGS | METH_STATIC, nullptr },
        { "get_struct", (PyCFunction)GattPresentationFormatTypes_get_Struct, METH_NOARGS | METH_STATIC, nullptr },
        { "get_uint12", (PyCFunction)GattPresentationFormatTypes_get_UInt12, METH_NOARGS | METH_STATIC, nullptr },
        { "get_uint128", (PyCFunction)GattPresentationFormatTypes_get_UInt128, METH_NOARGS | METH_STATIC, nullptr },
        { "get_uint16", (PyCFunction)GattPresentationFormatTypes_get_UInt16, METH_NOARGS | METH_STATIC, nullptr },
        { "get_uint24", (PyCFunction)GattPresentationFormatTypes_get_UInt24, METH_NOARGS | METH_STATIC, nullptr },
        { "get_uint32", (PyCFunction)GattPresentationFormatTypes_get_UInt32, METH_NOARGS | METH_STATIC, nullptr },
        { "get_uint48", (PyCFunction)GattPresentationFormatTypes_get_UInt48, METH_NOARGS | METH_STATIC, nullptr },
        { "get_uint64", (PyCFunction)GattPresentationFormatTypes_get_UInt64, METH_NOARGS | METH_STATIC, nullptr },
        { "get_uint8", (PyCFunction)GattPresentationFormatTypes_get_UInt8, METH_NOARGS | METH_STATIC, nullptr },
        { "get_utf16", (PyCFunction)GattPresentationFormatTypes_get_Utf16, METH_NOARGS | METH_STATIC, nullptr },
        { "get_utf8", (PyCFunction)GattPresentationFormatTypes_get_Utf8, METH_NOARGS | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattPresentationFormatTypes[] = {
        { nullptr }
    };

    static PyType_Slot _type_slots_GattPresentationFormatTypes[] = 
    {
        { Py_tp_new, _new_GattPresentationFormatTypes },
        { Py_tp_methods, _methods_GattPresentationFormatTypes },
        { Py_tp_getset, _getset_GattPresentationFormatTypes },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattPresentationFormatTypes =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattPresentationFormatTypes",
        0,
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattPresentationFormatTypes
    };

    // ----- GattProtocolError class --------------------
    constexpr const char* const _type_name_GattProtocolError = "GattProtocolError";

    static PyObject* _new_GattProtocolError(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattProtocolError);
        return nullptr;
    }

    static PyObject* GattProtocolError_get_AttributeNotFound(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError::AttributeNotFound());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattProtocolError_get_AttributeNotLong(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError::AttributeNotLong());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattProtocolError_get_InsufficientAuthentication(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError::InsufficientAuthentication());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattProtocolError_get_InsufficientAuthorization(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError::InsufficientAuthorization());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattProtocolError_get_InsufficientEncryption(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError::InsufficientEncryption());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattProtocolError_get_InsufficientEncryptionKeySize(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError::InsufficientEncryptionKeySize());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattProtocolError_get_InsufficientResources(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError::InsufficientResources());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattProtocolError_get_InvalidAttributeValueLength(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError::InvalidAttributeValueLength());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattProtocolError_get_InvalidHandle(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError::InvalidHandle());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattProtocolError_get_InvalidOffset(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError::InvalidOffset());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattProtocolError_get_InvalidPdu(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError::InvalidPdu());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattProtocolError_get_PrepareQueueFull(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError::PrepareQueueFull());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattProtocolError_get_ReadNotPermitted(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError::ReadNotPermitted());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattProtocolError_get_RequestNotSupported(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError::RequestNotSupported());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattProtocolError_get_UnlikelyError(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError::UnlikelyError());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattProtocolError_get_UnsupportedGroupType(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError::UnsupportedGroupType());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattProtocolError_get_WriteNotPermitted(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError::WriteNotPermitted());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattProtocolError[] = {
        { "get_attribute_not_found", (PyCFunction)GattProtocolError_get_AttributeNotFound, METH_NOARGS | METH_STATIC, nullptr },
        { "get_attribute_not_long", (PyCFunction)GattProtocolError_get_AttributeNotLong, METH_NOARGS | METH_STATIC, nullptr },
        { "get_insufficient_authentication", (PyCFunction)GattProtocolError_get_InsufficientAuthentication, METH_NOARGS | METH_STATIC, nullptr },
        { "get_insufficient_authorization", (PyCFunction)GattProtocolError_get_InsufficientAuthorization, METH_NOARGS | METH_STATIC, nullptr },
        { "get_insufficient_encryption", (PyCFunction)GattProtocolError_get_InsufficientEncryption, METH_NOARGS | METH_STATIC, nullptr },
        { "get_insufficient_encryption_key_size", (PyCFunction)GattProtocolError_get_InsufficientEncryptionKeySize, METH_NOARGS | METH_STATIC, nullptr },
        { "get_insufficient_resources", (PyCFunction)GattProtocolError_get_InsufficientResources, METH_NOARGS | METH_STATIC, nullptr },
        { "get_invalid_attribute_value_length", (PyCFunction)GattProtocolError_get_InvalidAttributeValueLength, METH_NOARGS | METH_STATIC, nullptr },
        { "get_invalid_handle", (PyCFunction)GattProtocolError_get_InvalidHandle, METH_NOARGS | METH_STATIC, nullptr },
        { "get_invalid_offset", (PyCFunction)GattProtocolError_get_InvalidOffset, METH_NOARGS | METH_STATIC, nullptr },
        { "get_invalid_pdu", (PyCFunction)GattProtocolError_get_InvalidPdu, METH_NOARGS | METH_STATIC, nullptr },
        { "get_prepare_queue_full", (PyCFunction)GattProtocolError_get_PrepareQueueFull, METH_NOARGS | METH_STATIC, nullptr },
        { "get_read_not_permitted", (PyCFunction)GattProtocolError_get_ReadNotPermitted, METH_NOARGS | METH_STATIC, nullptr },
        { "get_request_not_supported", (PyCFunction)GattProtocolError_get_RequestNotSupported, METH_NOARGS | METH_STATIC, nullptr },
        { "get_unlikely_error", (PyCFunction)GattProtocolError_get_UnlikelyError, METH_NOARGS | METH_STATIC, nullptr },
        { "get_unsupported_group_type", (PyCFunction)GattProtocolError_get_UnsupportedGroupType, METH_NOARGS | METH_STATIC, nullptr },
        { "get_write_not_permitted", (PyCFunction)GattProtocolError_get_WriteNotPermitted, METH_NOARGS | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattProtocolError[] = {
        { nullptr }
    };

    static PyType_Slot _type_slots_GattProtocolError[] = 
    {
        { Py_tp_new, _new_GattProtocolError },
        { Py_tp_methods, _methods_GattProtocolError },
        { Py_tp_getset, _getset_GattProtocolError },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattProtocolError =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattProtocolError",
        0,
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattProtocolError
    };

    // ----- GattReadClientCharacteristicConfigurationDescriptorResult class --------------------
    constexpr const char* const _type_name_GattReadClientCharacteristicConfigurationDescriptorResult = "GattReadClientCharacteristicConfigurationDescriptorResult";

    static PyObject* _new_GattReadClientCharacteristicConfigurationDescriptorResult(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattReadClientCharacteristicConfigurationDescriptorResult);
        return nullptr;
    }

    static void _dealloc_GattReadClientCharacteristicConfigurationDescriptorResult(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadClientCharacteristicConfigurationDescriptorResult* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattReadClientCharacteristicConfigurationDescriptorResult_get_ClientCharacteristicConfigurationDescriptor(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadClientCharacteristicConfigurationDescriptorResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ClientCharacteristicConfigurationDescriptor());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattReadClientCharacteristicConfigurationDescriptorResult_get_Status(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadClientCharacteristicConfigurationDescriptorResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Status());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattReadClientCharacteristicConfigurationDescriptorResult_get_ProtocolError(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadClientCharacteristicConfigurationDescriptorResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ProtocolError());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattReadClientCharacteristicConfigurationDescriptorResult(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadClientCharacteristicConfigurationDescriptorResult>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattReadClientCharacteristicConfigurationDescriptorResult[] = {
        { "_from", (PyCFunction)_from_GattReadClientCharacteristicConfigurationDescriptorResult, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattReadClientCharacteristicConfigurationDescriptorResult[] = {
        { const_cast<char*>("client_characteristic_configuration_descriptor"), (getter)GattReadClientCharacteristicConfigurationDescriptorResult_get_ClientCharacteristicConfigurationDescriptor, nullptr, nullptr, nullptr },
        { const_cast<char*>("status"), (getter)GattReadClientCharacteristicConfigurationDescriptorResult_get_Status, nullptr, nullptr, nullptr },
        { const_cast<char*>("protocol_error"), (getter)GattReadClientCharacteristicConfigurationDescriptorResult_get_ProtocolError, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattReadClientCharacteristicConfigurationDescriptorResult[] = 
    {
        { Py_tp_new, _new_GattReadClientCharacteristicConfigurationDescriptorResult },
        { Py_tp_dealloc, _dealloc_GattReadClientCharacteristicConfigurationDescriptorResult },
        { Py_tp_methods, _methods_GattReadClientCharacteristicConfigurationDescriptorResult },
        { Py_tp_getset, _getset_GattReadClientCharacteristicConfigurationDescriptorResult },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattReadClientCharacteristicConfigurationDescriptorResult =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattReadClientCharacteristicConfigurationDescriptorResult",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadClientCharacteristicConfigurationDescriptorResult),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattReadClientCharacteristicConfigurationDescriptorResult
    };

    // ----- GattReadRequest class --------------------
    constexpr const char* const _type_name_GattReadRequest = "GattReadRequest";

    static PyObject* _new_GattReadRequest(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattReadRequest);
        return nullptr;
    }

    static void _dealloc_GattReadRequest(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequest* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattReadRequest_RespondWithProtocolError(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequest* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<uint8_t>(args, 0);

                self->obj.RespondWithProtocolError(param0);
                Py_RETURN_NONE;
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattReadRequest_RespondWithValue(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequest* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Storage::Streams::IBuffer>(args, 0);

                self->obj.RespondWithValue(param0);
                Py_RETURN_NONE;
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattReadRequest_get_Length(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequest* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Length());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattReadRequest_get_Offset(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequest* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Offset());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattReadRequest_get_State(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequest* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.State());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattReadRequest_add_StateChanged(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequest* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequest, winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattRequestStateChangedEventArgs>>(arg);

            return py::convert(self->obj.StateChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattReadRequest_remove_StateChanged(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequest* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.StateChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattReadRequest(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequest>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattReadRequest[] = {
        { "respond_with_value", (PyCFunction)GattReadRequest_RespondWithValue, METH_VARARGS, nullptr },
        { "respond_with_protocol_error", (PyCFunction)GattReadRequest_RespondWithProtocolError, METH_VARARGS, nullptr },
        { "add_state_changed", (PyCFunction)GattReadRequest_add_StateChanged, METH_O, nullptr },
        { "remove_state_changed", (PyCFunction)GattReadRequest_remove_StateChanged, METH_O, nullptr },
        { "_from", (PyCFunction)_from_GattReadRequest, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattReadRequest[] = {
        { const_cast<char*>("length"), (getter)GattReadRequest_get_Length, nullptr, nullptr, nullptr },
        { const_cast<char*>("offset"), (getter)GattReadRequest_get_Offset, nullptr, nullptr, nullptr },
        { const_cast<char*>("state"), (getter)GattReadRequest_get_State, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattReadRequest[] = 
    {
        { Py_tp_new, _new_GattReadRequest },
        { Py_tp_dealloc, _dealloc_GattReadRequest },
        { Py_tp_methods, _methods_GattReadRequest },
        { Py_tp_getset, _getset_GattReadRequest },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattReadRequest =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattReadRequest",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequest),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattReadRequest
    };

    // ----- GattReadRequestedEventArgs class --------------------
    constexpr const char* const _type_name_GattReadRequestedEventArgs = "GattReadRequestedEventArgs";

    static PyObject* _new_GattReadRequestedEventArgs(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattReadRequestedEventArgs);
        return nullptr;
    }

    static void _dealloc_GattReadRequestedEventArgs(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequestedEventArgs* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattReadRequestedEventArgs_GetDeferral(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequestedEventArgs* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.GetDeferral());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattReadRequestedEventArgs_GetRequestAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequestedEventArgs* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.GetRequestAsync());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattReadRequestedEventArgs_get_Session(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequestedEventArgs* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Session());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattReadRequestedEventArgs(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequestedEventArgs>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattReadRequestedEventArgs[] = {
        { "get_deferral", (PyCFunction)GattReadRequestedEventArgs_GetDeferral, METH_VARARGS, nullptr },
        { "get_request_async", (PyCFunction)GattReadRequestedEventArgs_GetRequestAsync, METH_VARARGS, nullptr },
        { "_from", (PyCFunction)_from_GattReadRequestedEventArgs, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattReadRequestedEventArgs[] = {
        { const_cast<char*>("session"), (getter)GattReadRequestedEventArgs_get_Session, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattReadRequestedEventArgs[] = 
    {
        { Py_tp_new, _new_GattReadRequestedEventArgs },
        { Py_tp_dealloc, _dealloc_GattReadRequestedEventArgs },
        { Py_tp_methods, _methods_GattReadRequestedEventArgs },
        { Py_tp_getset, _getset_GattReadRequestedEventArgs },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattReadRequestedEventArgs =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattReadRequestedEventArgs",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequestedEventArgs),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattReadRequestedEventArgs
    };

    // ----- GattReadResult class --------------------
    constexpr const char* const _type_name_GattReadResult = "GattReadResult";

    static PyObject* _new_GattReadResult(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattReadResult);
        return nullptr;
    }

    static void _dealloc_GattReadResult(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadResult* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattReadResult_get_Status(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Status());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattReadResult_get_Value(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Value());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattReadResult_get_ProtocolError(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ProtocolError());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattReadResult(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadResult>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattReadResult[] = {
        { "_from", (PyCFunction)_from_GattReadResult, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattReadResult[] = {
        { const_cast<char*>("status"), (getter)GattReadResult_get_Status, nullptr, nullptr, nullptr },
        { const_cast<char*>("value"), (getter)GattReadResult_get_Value, nullptr, nullptr, nullptr },
        { const_cast<char*>("protocol_error"), (getter)GattReadResult_get_ProtocolError, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattReadResult[] = 
    {
        { Py_tp_new, _new_GattReadResult },
        { Py_tp_dealloc, _dealloc_GattReadResult },
        { Py_tp_methods, _methods_GattReadResult },
        { Py_tp_getset, _getset_GattReadResult },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattReadResult =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattReadResult",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadResult),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattReadResult
    };

    // ----- GattReliableWriteTransaction class --------------------
    constexpr const char* const _type_name_GattReliableWriteTransaction = "GattReliableWriteTransaction";

    static PyObject* _new_GattReliableWriteTransaction(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        if (kwds != nullptr)
        {
            py::set_invalid_kwd_args_error();
            return nullptr;
        }

        Py_ssize_t arg_count = PyTuple_Size(args);
        if (arg_count == 0)
        {
            try
            {
                winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReliableWriteTransaction instance{  };
                return py::wrap(instance, type);
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static void _dealloc_GattReliableWriteTransaction(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReliableWriteTransaction* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattReliableWriteTransaction_CommitAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReliableWriteTransaction* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.CommitAsync());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattReliableWriteTransaction_CommitWithResultAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReliableWriteTransaction* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.CommitWithResultAsync());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattReliableWriteTransaction_WriteValue(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReliableWriteTransaction* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 2)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic>(args, 0);
                auto param1 = py::convert_to<winrt::Windows::Storage::Streams::IBuffer>(args, 1);

                self->obj.WriteValue(param0, param1);
                Py_RETURN_NONE;
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* _from_GattReliableWriteTransaction(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReliableWriteTransaction>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattReliableWriteTransaction[] = {
        { "write_value", (PyCFunction)GattReliableWriteTransaction_WriteValue, METH_VARARGS, nullptr },
        { "commit_async", (PyCFunction)GattReliableWriteTransaction_CommitAsync, METH_VARARGS, nullptr },
        { "commit_with_result_async", (PyCFunction)GattReliableWriteTransaction_CommitWithResultAsync, METH_VARARGS, nullptr },
        { "_from", (PyCFunction)_from_GattReliableWriteTransaction, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattReliableWriteTransaction[] = {
        { nullptr }
    };

    static PyType_Slot _type_slots_GattReliableWriteTransaction[] = 
    {
        { Py_tp_new, _new_GattReliableWriteTransaction },
        { Py_tp_dealloc, _dealloc_GattReliableWriteTransaction },
        { Py_tp_methods, _methods_GattReliableWriteTransaction },
        { Py_tp_getset, _getset_GattReliableWriteTransaction },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattReliableWriteTransaction =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattReliableWriteTransaction",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReliableWriteTransaction),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattReliableWriteTransaction
    };

    // ----- GattRequestStateChangedEventArgs class --------------------
    constexpr const char* const _type_name_GattRequestStateChangedEventArgs = "GattRequestStateChangedEventArgs";

    static PyObject* _new_GattRequestStateChangedEventArgs(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattRequestStateChangedEventArgs);
        return nullptr;
    }

    static void _dealloc_GattRequestStateChangedEventArgs(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattRequestStateChangedEventArgs* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattRequestStateChangedEventArgs_get_Error(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattRequestStateChangedEventArgs* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Error());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattRequestStateChangedEventArgs_get_State(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattRequestStateChangedEventArgs* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.State());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattRequestStateChangedEventArgs(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattRequestStateChangedEventArgs>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattRequestStateChangedEventArgs[] = {
        { "_from", (PyCFunction)_from_GattRequestStateChangedEventArgs, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattRequestStateChangedEventArgs[] = {
        { const_cast<char*>("error"), (getter)GattRequestStateChangedEventArgs_get_Error, nullptr, nullptr, nullptr },
        { const_cast<char*>("state"), (getter)GattRequestStateChangedEventArgs_get_State, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattRequestStateChangedEventArgs[] = 
    {
        { Py_tp_new, _new_GattRequestStateChangedEventArgs },
        { Py_tp_dealloc, _dealloc_GattRequestStateChangedEventArgs },
        { Py_tp_methods, _methods_GattRequestStateChangedEventArgs },
        { Py_tp_getset, _getset_GattRequestStateChangedEventArgs },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattRequestStateChangedEventArgs =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattRequestStateChangedEventArgs",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattRequestStateChangedEventArgs),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattRequestStateChangedEventArgs
    };

    // ----- GattServiceProvider class --------------------
    constexpr const char* const _type_name_GattServiceProvider = "GattServiceProvider";

    static PyObject* _new_GattServiceProvider(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattServiceProvider);
        return nullptr;
    }

    static void _dealloc_GattServiceProvider(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProvider* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattServiceProvider_CreateAsync(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::guid>(args, 0);

                return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProvider::CreateAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattServiceProvider_StartAdvertising(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProvider* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                self->obj.StartAdvertising();
                Py_RETURN_NONE;
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisingParameters>(args, 0);

                self->obj.StartAdvertising(param0);
                Py_RETURN_NONE;
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattServiceProvider_StopAdvertising(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProvider* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                self->obj.StopAdvertising();
                Py_RETURN_NONE;
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattServiceProvider_get_AdvertisementStatus(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProvider* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.AdvertisementStatus());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceProvider_get_Service(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProvider* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Service());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceProvider_add_AdvertisementStatusChanged(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProvider* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProvider, winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisementStatusChangedEventArgs>>(arg);

            return py::convert(self->obj.AdvertisementStatusChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceProvider_remove_AdvertisementStatusChanged(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProvider* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.AdvertisementStatusChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattServiceProvider(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProvider>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattServiceProvider[] = {
        { "start_advertising", (PyCFunction)GattServiceProvider_StartAdvertising, METH_VARARGS, nullptr },
        { "stop_advertising", (PyCFunction)GattServiceProvider_StopAdvertising, METH_VARARGS, nullptr },
        { "create_async", (PyCFunction)GattServiceProvider_CreateAsync, METH_VARARGS | METH_STATIC, nullptr },
        { "add_advertisement_status_changed", (PyCFunction)GattServiceProvider_add_AdvertisementStatusChanged, METH_O, nullptr },
        { "remove_advertisement_status_changed", (PyCFunction)GattServiceProvider_remove_AdvertisementStatusChanged, METH_O, nullptr },
        { "_from", (PyCFunction)_from_GattServiceProvider, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattServiceProvider[] = {
        { const_cast<char*>("advertisement_status"), (getter)GattServiceProvider_get_AdvertisementStatus, nullptr, nullptr, nullptr },
        { const_cast<char*>("service"), (getter)GattServiceProvider_get_Service, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattServiceProvider[] = 
    {
        { Py_tp_new, _new_GattServiceProvider },
        { Py_tp_dealloc, _dealloc_GattServiceProvider },
        { Py_tp_methods, _methods_GattServiceProvider },
        { Py_tp_getset, _getset_GattServiceProvider },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattServiceProvider =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattServiceProvider",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProvider),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattServiceProvider
    };

    // ----- GattServiceProviderAdvertisementStatusChangedEventArgs class --------------------
    constexpr const char* const _type_name_GattServiceProviderAdvertisementStatusChangedEventArgs = "GattServiceProviderAdvertisementStatusChangedEventArgs";

    static PyObject* _new_GattServiceProviderAdvertisementStatusChangedEventArgs(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattServiceProviderAdvertisementStatusChangedEventArgs);
        return nullptr;
    }

    static void _dealloc_GattServiceProviderAdvertisementStatusChangedEventArgs(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisementStatusChangedEventArgs* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattServiceProviderAdvertisementStatusChangedEventArgs_get_Error(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisementStatusChangedEventArgs* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Error());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceProviderAdvertisementStatusChangedEventArgs_get_Status(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisementStatusChangedEventArgs* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Status());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattServiceProviderAdvertisementStatusChangedEventArgs(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisementStatusChangedEventArgs>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattServiceProviderAdvertisementStatusChangedEventArgs[] = {
        { "_from", (PyCFunction)_from_GattServiceProviderAdvertisementStatusChangedEventArgs, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattServiceProviderAdvertisementStatusChangedEventArgs[] = {
        { const_cast<char*>("error"), (getter)GattServiceProviderAdvertisementStatusChangedEventArgs_get_Error, nullptr, nullptr, nullptr },
        { const_cast<char*>("status"), (getter)GattServiceProviderAdvertisementStatusChangedEventArgs_get_Status, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattServiceProviderAdvertisementStatusChangedEventArgs[] = 
    {
        { Py_tp_new, _new_GattServiceProviderAdvertisementStatusChangedEventArgs },
        { Py_tp_dealloc, _dealloc_GattServiceProviderAdvertisementStatusChangedEventArgs },
        { Py_tp_methods, _methods_GattServiceProviderAdvertisementStatusChangedEventArgs },
        { Py_tp_getset, _getset_GattServiceProviderAdvertisementStatusChangedEventArgs },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattServiceProviderAdvertisementStatusChangedEventArgs =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattServiceProviderAdvertisementStatusChangedEventArgs",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisementStatusChangedEventArgs),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattServiceProviderAdvertisementStatusChangedEventArgs
    };

    // ----- GattServiceProviderAdvertisingParameters class --------------------
    constexpr const char* const _type_name_GattServiceProviderAdvertisingParameters = "GattServiceProviderAdvertisingParameters";

    static PyObject* _new_GattServiceProviderAdvertisingParameters(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        if (kwds != nullptr)
        {
            py::set_invalid_kwd_args_error();
            return nullptr;
        }

        Py_ssize_t arg_count = PyTuple_Size(args);
        if (arg_count == 0)
        {
            try
            {
                winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisingParameters instance{  };
                return py::wrap(instance, type);
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static void _dealloc_GattServiceProviderAdvertisingParameters(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisingParameters* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattServiceProviderAdvertisingParameters_get_IsDiscoverable(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisingParameters* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.IsDiscoverable());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int GattServiceProviderAdvertisingParameters_put_IsDiscoverable(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisingParameters* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            auto param0 = py::convert_to<bool>(arg);

            self->obj.IsDiscoverable(param0);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyObject* GattServiceProviderAdvertisingParameters_get_IsConnectable(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisingParameters* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.IsConnectable());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int GattServiceProviderAdvertisingParameters_put_IsConnectable(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisingParameters* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            auto param0 = py::convert_to<bool>(arg);

            self->obj.IsConnectable(param0);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyObject* GattServiceProviderAdvertisingParameters_get_ServiceData(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisingParameters* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ServiceData());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int GattServiceProviderAdvertisingParameters_put_ServiceData(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisingParameters* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            auto param0 = py::convert_to<winrt::Windows::Storage::Streams::IBuffer>(arg);

            self->obj.ServiceData(param0);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyObject* _from_GattServiceProviderAdvertisingParameters(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisingParameters>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattServiceProviderAdvertisingParameters[] = {
        { "_from", (PyCFunction)_from_GattServiceProviderAdvertisingParameters, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattServiceProviderAdvertisingParameters[] = {
        { const_cast<char*>("is_discoverable"), (getter)GattServiceProviderAdvertisingParameters_get_IsDiscoverable, (setter)GattServiceProviderAdvertisingParameters_put_IsDiscoverable, nullptr, nullptr },
        { const_cast<char*>("is_connectable"), (getter)GattServiceProviderAdvertisingParameters_get_IsConnectable, (setter)GattServiceProviderAdvertisingParameters_put_IsConnectable, nullptr, nullptr },
        { const_cast<char*>("service_data"), (getter)GattServiceProviderAdvertisingParameters_get_ServiceData, (setter)GattServiceProviderAdvertisingParameters_put_ServiceData, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattServiceProviderAdvertisingParameters[] = 
    {
        { Py_tp_new, _new_GattServiceProviderAdvertisingParameters },
        { Py_tp_dealloc, _dealloc_GattServiceProviderAdvertisingParameters },
        { Py_tp_methods, _methods_GattServiceProviderAdvertisingParameters },
        { Py_tp_getset, _getset_GattServiceProviderAdvertisingParameters },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattServiceProviderAdvertisingParameters =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattServiceProviderAdvertisingParameters",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisingParameters),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattServiceProviderAdvertisingParameters
    };

    // ----- GattServiceProviderResult class --------------------
    constexpr const char* const _type_name_GattServiceProviderResult = "GattServiceProviderResult";

    static PyObject* _new_GattServiceProviderResult(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattServiceProviderResult);
        return nullptr;
    }

    static void _dealloc_GattServiceProviderResult(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderResult* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattServiceProviderResult_get_Error(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Error());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceProviderResult_get_ServiceProvider(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ServiceProvider());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattServiceProviderResult(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderResult>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattServiceProviderResult[] = {
        { "_from", (PyCFunction)_from_GattServiceProviderResult, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattServiceProviderResult[] = {
        { const_cast<char*>("error"), (getter)GattServiceProviderResult_get_Error, nullptr, nullptr, nullptr },
        { const_cast<char*>("service_provider"), (getter)GattServiceProviderResult_get_ServiceProvider, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattServiceProviderResult[] = 
    {
        { Py_tp_new, _new_GattServiceProviderResult },
        { Py_tp_dealloc, _dealloc_GattServiceProviderResult },
        { Py_tp_methods, _methods_GattServiceProviderResult },
        { Py_tp_getset, _getset_GattServiceProviderResult },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattServiceProviderResult =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattServiceProviderResult",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderResult),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattServiceProviderResult
    };

    // ----- GattServiceUuids class --------------------
    constexpr const char* const _type_name_GattServiceUuids = "GattServiceUuids";

    static PyObject* _new_GattServiceUuids(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattServiceUuids);
        return nullptr;
    }

    static PyObject* GattServiceUuids_get_Battery(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::Battery());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_BloodPressure(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::BloodPressure());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_CyclingSpeedAndCadence(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::CyclingSpeedAndCadence());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_GenericAccess(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::GenericAccess());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_GenericAttribute(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::GenericAttribute());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_Glucose(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::Glucose());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_HealthThermometer(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::HealthThermometer());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_HeartRate(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::HeartRate());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_RunningSpeedAndCadence(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::RunningSpeedAndCadence());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_AlertNotification(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::AlertNotification());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_CurrentTime(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::CurrentTime());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_CyclingPower(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::CyclingPower());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_DeviceInformation(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::DeviceInformation());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_HumanInterfaceDevice(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::HumanInterfaceDevice());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_ImmediateAlert(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::ImmediateAlert());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_LinkLoss(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::LinkLoss());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_LocationAndNavigation(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::LocationAndNavigation());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_NextDstChange(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::NextDstChange());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_PhoneAlertStatus(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::PhoneAlertStatus());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_ReferenceTimeUpdate(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::ReferenceTimeUpdate());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_ScanParameters(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::ScanParameters());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattServiceUuids_get_TxPower(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids::TxPower());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattServiceUuids[] = {
        { "get_battery", (PyCFunction)GattServiceUuids_get_Battery, METH_NOARGS | METH_STATIC, nullptr },
        { "get_blood_pressure", (PyCFunction)GattServiceUuids_get_BloodPressure, METH_NOARGS | METH_STATIC, nullptr },
        { "get_cycling_speed_and_cadence", (PyCFunction)GattServiceUuids_get_CyclingSpeedAndCadence, METH_NOARGS | METH_STATIC, nullptr },
        { "get_generic_access", (PyCFunction)GattServiceUuids_get_GenericAccess, METH_NOARGS | METH_STATIC, nullptr },
        { "get_generic_attribute", (PyCFunction)GattServiceUuids_get_GenericAttribute, METH_NOARGS | METH_STATIC, nullptr },
        { "get_glucose", (PyCFunction)GattServiceUuids_get_Glucose, METH_NOARGS | METH_STATIC, nullptr },
        { "get_health_thermometer", (PyCFunction)GattServiceUuids_get_HealthThermometer, METH_NOARGS | METH_STATIC, nullptr },
        { "get_heart_rate", (PyCFunction)GattServiceUuids_get_HeartRate, METH_NOARGS | METH_STATIC, nullptr },
        { "get_running_speed_and_cadence", (PyCFunction)GattServiceUuids_get_RunningSpeedAndCadence, METH_NOARGS | METH_STATIC, nullptr },
        { "get_alert_notification", (PyCFunction)GattServiceUuids_get_AlertNotification, METH_NOARGS | METH_STATIC, nullptr },
        { "get_current_time", (PyCFunction)GattServiceUuids_get_CurrentTime, METH_NOARGS | METH_STATIC, nullptr },
        { "get_cycling_power", (PyCFunction)GattServiceUuids_get_CyclingPower, METH_NOARGS | METH_STATIC, nullptr },
        { "get_device_information", (PyCFunction)GattServiceUuids_get_DeviceInformation, METH_NOARGS | METH_STATIC, nullptr },
        { "get_human_interface_device", (PyCFunction)GattServiceUuids_get_HumanInterfaceDevice, METH_NOARGS | METH_STATIC, nullptr },
        { "get_immediate_alert", (PyCFunction)GattServiceUuids_get_ImmediateAlert, METH_NOARGS | METH_STATIC, nullptr },
        { "get_link_loss", (PyCFunction)GattServiceUuids_get_LinkLoss, METH_NOARGS | METH_STATIC, nullptr },
        { "get_location_and_navigation", (PyCFunction)GattServiceUuids_get_LocationAndNavigation, METH_NOARGS | METH_STATIC, nullptr },
        { "get_next_dst_change", (PyCFunction)GattServiceUuids_get_NextDstChange, METH_NOARGS | METH_STATIC, nullptr },
        { "get_phone_alert_status", (PyCFunction)GattServiceUuids_get_PhoneAlertStatus, METH_NOARGS | METH_STATIC, nullptr },
        { "get_reference_time_update", (PyCFunction)GattServiceUuids_get_ReferenceTimeUpdate, METH_NOARGS | METH_STATIC, nullptr },
        { "get_scan_parameters", (PyCFunction)GattServiceUuids_get_ScanParameters, METH_NOARGS | METH_STATIC, nullptr },
        { "get_tx_power", (PyCFunction)GattServiceUuids_get_TxPower, METH_NOARGS | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattServiceUuids[] = {
        { nullptr }
    };

    static PyType_Slot _type_slots_GattServiceUuids[] = 
    {
        { Py_tp_new, _new_GattServiceUuids },
        { Py_tp_methods, _methods_GattServiceUuids },
        { Py_tp_getset, _getset_GattServiceUuids },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattServiceUuids =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattServiceUuids",
        0,
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattServiceUuids
    };

    // ----- GattSession class --------------------
    constexpr const char* const _type_name_GattSession = "GattSession";

    static PyObject* _new_GattSession(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattSession);
        return nullptr;
    }

    static void _dealloc_GattSession(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattSession_Close(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                self->obj.Close();
                Py_RETURN_NONE;
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattSession_FromDeviceIdAsync(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Devices::Bluetooth::BluetoothDeviceId>(args, 0);

                return py::convert(winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession::FromDeviceIdAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattSession_get_MaintainConnection(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.MaintainConnection());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int GattSession_put_MaintainConnection(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            auto param0 = py::convert_to<bool>(arg);

            self->obj.MaintainConnection(param0);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyObject* GattSession_get_CanMaintainConnection(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.CanMaintainConnection());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattSession_get_DeviceId(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.DeviceId());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattSession_get_MaxPduSize(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.MaxPduSize());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattSession_get_SessionStatus(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.SessionStatus());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattSession_add_MaxPduSizeChanged(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession, winrt::Windows::Foundation::IInspectable>>(arg);

            return py::convert(self->obj.MaxPduSizeChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattSession_remove_MaxPduSizeChanged(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.MaxPduSizeChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattSession_add_SessionStatusChanged(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession, winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSessionStatusChangedEventArgs>>(arg);

            return py::convert(self->obj.SessionStatusChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattSession_remove_SessionStatusChanged(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.SessionStatusChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattSession(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _enter_GattSession(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession* self) noexcept
    {
        Py_INCREF(self);
        return (PyObject*)self;
    }

    static PyObject* _exit_GattSession(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession* self) noexcept
    {
        try
        {
            self->obj.Close();
            Py_RETURN_FALSE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattSession[] = {
        { "close", (PyCFunction)GattSession_Close, METH_VARARGS, nullptr },
        { "from_device_id_async", (PyCFunction)GattSession_FromDeviceIdAsync, METH_VARARGS | METH_STATIC, nullptr },
        { "add_max_pdu_size_changed", (PyCFunction)GattSession_add_MaxPduSizeChanged, METH_O, nullptr },
        { "remove_max_pdu_size_changed", (PyCFunction)GattSession_remove_MaxPduSizeChanged, METH_O, nullptr },
        { "add_session_status_changed", (PyCFunction)GattSession_add_SessionStatusChanged, METH_O, nullptr },
        { "remove_session_status_changed", (PyCFunction)GattSession_remove_SessionStatusChanged, METH_O, nullptr },
        { "_from", (PyCFunction)_from_GattSession, METH_O | METH_STATIC, nullptr },
        { "__enter__", (PyCFunction)_enter_GattSession, METH_NOARGS, nullptr },
        { "__exit__",  (PyCFunction)_exit_GattSession, METH_VARARGS, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattSession[] = {
        { const_cast<char*>("maintain_connection"), (getter)GattSession_get_MaintainConnection, (setter)GattSession_put_MaintainConnection, nullptr, nullptr },
        { const_cast<char*>("can_maintain_connection"), (getter)GattSession_get_CanMaintainConnection, nullptr, nullptr, nullptr },
        { const_cast<char*>("device_id"), (getter)GattSession_get_DeviceId, nullptr, nullptr, nullptr },
        { const_cast<char*>("max_pdu_size"), (getter)GattSession_get_MaxPduSize, nullptr, nullptr, nullptr },
        { const_cast<char*>("session_status"), (getter)GattSession_get_SessionStatus, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattSession[] = 
    {
        { Py_tp_new, _new_GattSession },
        { Py_tp_dealloc, _dealloc_GattSession },
        { Py_tp_methods, _methods_GattSession },
        { Py_tp_getset, _getset_GattSession },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattSession =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattSession",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattSession
    };

    // ----- GattSessionStatusChangedEventArgs class --------------------
    constexpr const char* const _type_name_GattSessionStatusChangedEventArgs = "GattSessionStatusChangedEventArgs";

    static PyObject* _new_GattSessionStatusChangedEventArgs(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattSessionStatusChangedEventArgs);
        return nullptr;
    }

    static void _dealloc_GattSessionStatusChangedEventArgs(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSessionStatusChangedEventArgs* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattSessionStatusChangedEventArgs_get_Error(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSessionStatusChangedEventArgs* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Error());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattSessionStatusChangedEventArgs_get_Status(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSessionStatusChangedEventArgs* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Status());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattSessionStatusChangedEventArgs(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSessionStatusChangedEventArgs>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattSessionStatusChangedEventArgs[] = {
        { "_from", (PyCFunction)_from_GattSessionStatusChangedEventArgs, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattSessionStatusChangedEventArgs[] = {
        { const_cast<char*>("error"), (getter)GattSessionStatusChangedEventArgs_get_Error, nullptr, nullptr, nullptr },
        { const_cast<char*>("status"), (getter)GattSessionStatusChangedEventArgs_get_Status, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattSessionStatusChangedEventArgs[] = 
    {
        { Py_tp_new, _new_GattSessionStatusChangedEventArgs },
        { Py_tp_dealloc, _dealloc_GattSessionStatusChangedEventArgs },
        { Py_tp_methods, _methods_GattSessionStatusChangedEventArgs },
        { Py_tp_getset, _getset_GattSessionStatusChangedEventArgs },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattSessionStatusChangedEventArgs =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattSessionStatusChangedEventArgs",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSessionStatusChangedEventArgs),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattSessionStatusChangedEventArgs
    };

    // ----- GattSubscribedClient class --------------------
    constexpr const char* const _type_name_GattSubscribedClient = "GattSubscribedClient";

    static PyObject* _new_GattSubscribedClient(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattSubscribedClient);
        return nullptr;
    }

    static void _dealloc_GattSubscribedClient(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSubscribedClient* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattSubscribedClient_get_MaxNotificationSize(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSubscribedClient* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.MaxNotificationSize());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattSubscribedClient_get_Session(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSubscribedClient* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Session());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattSubscribedClient_add_MaxNotificationSizeChanged(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSubscribedClient* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSubscribedClient, winrt::Windows::Foundation::IInspectable>>(arg);

            return py::convert(self->obj.MaxNotificationSizeChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattSubscribedClient_remove_MaxNotificationSizeChanged(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSubscribedClient* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.MaxNotificationSizeChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattSubscribedClient(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSubscribedClient>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattSubscribedClient[] = {
        { "add_max_notification_size_changed", (PyCFunction)GattSubscribedClient_add_MaxNotificationSizeChanged, METH_O, nullptr },
        { "remove_max_notification_size_changed", (PyCFunction)GattSubscribedClient_remove_MaxNotificationSizeChanged, METH_O, nullptr },
        { "_from", (PyCFunction)_from_GattSubscribedClient, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattSubscribedClient[] = {
        { const_cast<char*>("max_notification_size"), (getter)GattSubscribedClient_get_MaxNotificationSize, nullptr, nullptr, nullptr },
        { const_cast<char*>("session"), (getter)GattSubscribedClient_get_Session, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattSubscribedClient[] = 
    {
        { Py_tp_new, _new_GattSubscribedClient },
        { Py_tp_dealloc, _dealloc_GattSubscribedClient },
        { Py_tp_methods, _methods_GattSubscribedClient },
        { Py_tp_getset, _getset_GattSubscribedClient },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattSubscribedClient =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattSubscribedClient",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSubscribedClient),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattSubscribedClient
    };

    // ----- GattValueChangedEventArgs class --------------------
    constexpr const char* const _type_name_GattValueChangedEventArgs = "GattValueChangedEventArgs";

    static PyObject* _new_GattValueChangedEventArgs(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattValueChangedEventArgs);
        return nullptr;
    }

    static void _dealloc_GattValueChangedEventArgs(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattValueChangedEventArgs* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattValueChangedEventArgs_get_CharacteristicValue(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattValueChangedEventArgs* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.CharacteristicValue());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattValueChangedEventArgs_get_Timestamp(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattValueChangedEventArgs* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Timestamp());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattValueChangedEventArgs(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattValueChangedEventArgs>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattValueChangedEventArgs[] = {
        { "_from", (PyCFunction)_from_GattValueChangedEventArgs, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattValueChangedEventArgs[] = {
        { const_cast<char*>("characteristic_value"), (getter)GattValueChangedEventArgs_get_CharacteristicValue, nullptr, nullptr, nullptr },
        { const_cast<char*>("timestamp"), (getter)GattValueChangedEventArgs_get_Timestamp, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattValueChangedEventArgs[] = 
    {
        { Py_tp_new, _new_GattValueChangedEventArgs },
        { Py_tp_dealloc, _dealloc_GattValueChangedEventArgs },
        { Py_tp_methods, _methods_GattValueChangedEventArgs },
        { Py_tp_getset, _getset_GattValueChangedEventArgs },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattValueChangedEventArgs =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattValueChangedEventArgs",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattValueChangedEventArgs),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattValueChangedEventArgs
    };

    // ----- GattWriteRequest class --------------------
    constexpr const char* const _type_name_GattWriteRequest = "GattWriteRequest";

    static PyObject* _new_GattWriteRequest(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattWriteRequest);
        return nullptr;
    }

    static void _dealloc_GattWriteRequest(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequest* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattWriteRequest_Respond(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequest* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                self->obj.Respond();
                Py_RETURN_NONE;
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattWriteRequest_RespondWithProtocolError(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequest* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<uint8_t>(args, 0);

                self->obj.RespondWithProtocolError(param0);
                Py_RETURN_NONE;
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattWriteRequest_get_Offset(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequest* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Offset());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattWriteRequest_get_Option(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequest* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Option());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattWriteRequest_get_State(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequest* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.State());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattWriteRequest_get_Value(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequest* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Value());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattWriteRequest_add_StateChanged(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequest* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequest, winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattRequestStateChangedEventArgs>>(arg);

            return py::convert(self->obj.StateChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattWriteRequest_remove_StateChanged(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequest* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.StateChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattWriteRequest(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequest>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattWriteRequest[] = {
        { "respond", (PyCFunction)GattWriteRequest_Respond, METH_VARARGS, nullptr },
        { "respond_with_protocol_error", (PyCFunction)GattWriteRequest_RespondWithProtocolError, METH_VARARGS, nullptr },
        { "add_state_changed", (PyCFunction)GattWriteRequest_add_StateChanged, METH_O, nullptr },
        { "remove_state_changed", (PyCFunction)GattWriteRequest_remove_StateChanged, METH_O, nullptr },
        { "_from", (PyCFunction)_from_GattWriteRequest, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattWriteRequest[] = {
        { const_cast<char*>("offset"), (getter)GattWriteRequest_get_Offset, nullptr, nullptr, nullptr },
        { const_cast<char*>("option"), (getter)GattWriteRequest_get_Option, nullptr, nullptr, nullptr },
        { const_cast<char*>("state"), (getter)GattWriteRequest_get_State, nullptr, nullptr, nullptr },
        { const_cast<char*>("value"), (getter)GattWriteRequest_get_Value, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattWriteRequest[] = 
    {
        { Py_tp_new, _new_GattWriteRequest },
        { Py_tp_dealloc, _dealloc_GattWriteRequest },
        { Py_tp_methods, _methods_GattWriteRequest },
        { Py_tp_getset, _getset_GattWriteRequest },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattWriteRequest =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattWriteRequest",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequest),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattWriteRequest
    };

    // ----- GattWriteRequestedEventArgs class --------------------
    constexpr const char* const _type_name_GattWriteRequestedEventArgs = "GattWriteRequestedEventArgs";

    static PyObject* _new_GattWriteRequestedEventArgs(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattWriteRequestedEventArgs);
        return nullptr;
    }

    static void _dealloc_GattWriteRequestedEventArgs(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequestedEventArgs* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattWriteRequestedEventArgs_GetDeferral(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequestedEventArgs* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.GetDeferral());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattWriteRequestedEventArgs_GetRequestAsync(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequestedEventArgs* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.GetRequestAsync());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* GattWriteRequestedEventArgs_get_Session(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequestedEventArgs* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Session());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattWriteRequestedEventArgs(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequestedEventArgs>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattWriteRequestedEventArgs[] = {
        { "get_deferral", (PyCFunction)GattWriteRequestedEventArgs_GetDeferral, METH_VARARGS, nullptr },
        { "get_request_async", (PyCFunction)GattWriteRequestedEventArgs_GetRequestAsync, METH_VARARGS, nullptr },
        { "_from", (PyCFunction)_from_GattWriteRequestedEventArgs, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattWriteRequestedEventArgs[] = {
        { const_cast<char*>("session"), (getter)GattWriteRequestedEventArgs_get_Session, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattWriteRequestedEventArgs[] = 
    {
        { Py_tp_new, _new_GattWriteRequestedEventArgs },
        { Py_tp_dealloc, _dealloc_GattWriteRequestedEventArgs },
        { Py_tp_methods, _methods_GattWriteRequestedEventArgs },
        { Py_tp_getset, _getset_GattWriteRequestedEventArgs },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattWriteRequestedEventArgs =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattWriteRequestedEventArgs",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequestedEventArgs),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattWriteRequestedEventArgs
    };

    // ----- GattWriteResult class --------------------
    constexpr const char* const _type_name_GattWriteResult = "GattWriteResult";

    static PyObject* _new_GattWriteResult(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_GattWriteResult);
        return nullptr;
    }

    static void _dealloc_GattWriteResult(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteResult* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* GattWriteResult_get_ProtocolError(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ProtocolError());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* GattWriteResult_get_Status(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteResult* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Status());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_GattWriteResult(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteResult>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_GattWriteResult[] = {
        { "_from", (PyCFunction)_from_GattWriteResult, METH_O | METH_STATIC, nullptr },
        { nullptr }
    };

    static PyGetSetDef _getset_GattWriteResult[] = {
        { const_cast<char*>("protocol_error"), (getter)GattWriteResult_get_ProtocolError, nullptr, nullptr, nullptr },
        { const_cast<char*>("status"), (getter)GattWriteResult_get_Status, nullptr, nullptr, nullptr },
        { nullptr }
    };

    static PyType_Slot _type_slots_GattWriteResult[] = 
    {
        { Py_tp_new, _new_GattWriteResult },
        { Py_tp_dealloc, _dealloc_GattWriteResult },
        { Py_tp_methods, _methods_GattWriteResult },
        { Py_tp_getset, _getset_GattWriteResult },
        { 0, nullptr },
    };

    static PyType_Spec _type_spec_GattWriteResult =
    {
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile.GattWriteResult",
        sizeof(py::wrapper::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteResult),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_GattWriteResult
    };

    // ----- Windows.Devices.Bluetooth.GenericAttributeProfile Initialization --------------------
    static int module_exec(PyObject* module) noexcept
    {
        try
        {
            py::pyobj_handle bases { PyTuple_Pack(1, py::winrt_type<py::winrt_base>::python_type) };

            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristic>::python_type = py::register_python_type(module, _type_name_GattCharacteristic, &_type_spec_GattCharacteristic, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicUuids>::python_type = py::register_python_type(module, _type_name_GattCharacteristicUuids, &_type_spec_GattCharacteristicUuids, nullptr);
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattCharacteristicsResult>::python_type = py::register_python_type(module, _type_name_GattCharacteristicsResult, &_type_spec_GattCharacteristicsResult, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattClientNotificationResult>::python_type = py::register_python_type(module, _type_name_GattClientNotificationResult, &_type_spec_GattClientNotificationResult, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptor>::python_type = py::register_python_type(module, _type_name_GattDescriptor, &_type_spec_GattDescriptor, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptorUuids>::python_type = py::register_python_type(module, _type_name_GattDescriptorUuids, &_type_spec_GattDescriptorUuids, nullptr);
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDescriptorsResult>::python_type = py::register_python_type(module, _type_name_GattDescriptorsResult, &_type_spec_GattDescriptorsResult, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceService>::python_type = py::register_python_type(module, _type_name_GattDeviceService, &_type_spec_GattDeviceService, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattDeviceServicesResult>::python_type = py::register_python_type(module, _type_name_GattDeviceServicesResult, &_type_spec_GattDeviceServicesResult, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristic>::python_type = py::register_python_type(module, _type_name_GattLocalCharacteristic, &_type_spec_GattLocalCharacteristic, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicParameters>::python_type = py::register_python_type(module, _type_name_GattLocalCharacteristicParameters, &_type_spec_GattLocalCharacteristicParameters, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalCharacteristicResult>::python_type = py::register_python_type(module, _type_name_GattLocalCharacteristicResult, &_type_spec_GattLocalCharacteristicResult, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptor>::python_type = py::register_python_type(module, _type_name_GattLocalDescriptor, &_type_spec_GattLocalDescriptor, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorParameters>::python_type = py::register_python_type(module, _type_name_GattLocalDescriptorParameters, &_type_spec_GattLocalDescriptorParameters, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalDescriptorResult>::python_type = py::register_python_type(module, _type_name_GattLocalDescriptorResult, &_type_spec_GattLocalDescriptorResult, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattLocalService>::python_type = py::register_python_type(module, _type_name_GattLocalService, &_type_spec_GattLocalService, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormat>::python_type = py::register_python_type(module, _type_name_GattPresentationFormat, &_type_spec_GattPresentationFormat, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattPresentationFormatTypes>::python_type = py::register_python_type(module, _type_name_GattPresentationFormatTypes, &_type_spec_GattPresentationFormatTypes, nullptr);
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattProtocolError>::python_type = py::register_python_type(module, _type_name_GattProtocolError, &_type_spec_GattProtocolError, nullptr);
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadClientCharacteristicConfigurationDescriptorResult>::python_type = py::register_python_type(module, _type_name_GattReadClientCharacteristicConfigurationDescriptorResult, &_type_spec_GattReadClientCharacteristicConfigurationDescriptorResult, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequest>::python_type = py::register_python_type(module, _type_name_GattReadRequest, &_type_spec_GattReadRequest, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadRequestedEventArgs>::python_type = py::register_python_type(module, _type_name_GattReadRequestedEventArgs, &_type_spec_GattReadRequestedEventArgs, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReadResult>::python_type = py::register_python_type(module, _type_name_GattReadResult, &_type_spec_GattReadResult, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattReliableWriteTransaction>::python_type = py::register_python_type(module, _type_name_GattReliableWriteTransaction, &_type_spec_GattReliableWriteTransaction, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattRequestStateChangedEventArgs>::python_type = py::register_python_type(module, _type_name_GattRequestStateChangedEventArgs, &_type_spec_GattRequestStateChangedEventArgs, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProvider>::python_type = py::register_python_type(module, _type_name_GattServiceProvider, &_type_spec_GattServiceProvider, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisementStatusChangedEventArgs>::python_type = py::register_python_type(module, _type_name_GattServiceProviderAdvertisementStatusChangedEventArgs, &_type_spec_GattServiceProviderAdvertisementStatusChangedEventArgs, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderAdvertisingParameters>::python_type = py::register_python_type(module, _type_name_GattServiceProviderAdvertisingParameters, &_type_spec_GattServiceProviderAdvertisingParameters, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceProviderResult>::python_type = py::register_python_type(module, _type_name_GattServiceProviderResult, &_type_spec_GattServiceProviderResult, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattServiceUuids>::python_type = py::register_python_type(module, _type_name_GattServiceUuids, &_type_spec_GattServiceUuids, nullptr);
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSession>::python_type = py::register_python_type(module, _type_name_GattSession, &_type_spec_GattSession, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSessionStatusChangedEventArgs>::python_type = py::register_python_type(module, _type_name_GattSessionStatusChangedEventArgs, &_type_spec_GattSessionStatusChangedEventArgs, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattSubscribedClient>::python_type = py::register_python_type(module, _type_name_GattSubscribedClient, &_type_spec_GattSubscribedClient, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattValueChangedEventArgs>::python_type = py::register_python_type(module, _type_name_GattValueChangedEventArgs, &_type_spec_GattValueChangedEventArgs, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequest>::python_type = py::register_python_type(module, _type_name_GattWriteRequest, &_type_spec_GattWriteRequest, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteRequestedEventArgs>::python_type = py::register_python_type(module, _type_name_GattWriteRequestedEventArgs, &_type_spec_GattWriteRequestedEventArgs, bases.get());
            py::winrt_type<winrt::Windows::Devices::Bluetooth::GenericAttributeProfile::GattWriteResult>::python_type = py::register_python_type(module, _type_name_GattWriteResult, &_type_spec_GattWriteResult, bases.get());

            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyModuleDef_Slot module_slots[] = {
        {Py_mod_exec, module_exec},
        {0, nullptr}
    };

    PyDoc_STRVAR(module_doc, "Windows.Devices.Bluetooth.GenericAttributeProfile");

    static PyModuleDef module_def = {
        PyModuleDef_HEAD_INIT,
        "_bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile",
        module_doc,
        0,
        nullptr,
        module_slots,
        nullptr,
        nullptr,
        nullptr
    };
} // py::cpp::Windows::Devices::Bluetooth::GenericAttributeProfile

PyMODINIT_FUNC
PyInit__bleak_winrt_Windows_Devices_Bluetooth_GenericAttributeProfile (void) noexcept
{
    return PyModuleDef_Init(&py::cpp::Windows::Devices::Bluetooth::GenericAttributeProfile::module_def);
}
