m2x/v2/metadata.py
def update_metadata_field(self, field, value):
    """ Generic method for a resource's Update Metadata Field endpoint.

    Example endpoints:

    * `Update Device Metadata Field <https://m2x.att.com/developer/documentation/v2/device#Update-Device-Metadata-Field>`_
    * `Update Distribution Metadata Field <https://m2x.att.com/developer/documentation/v2/distribution#Update-Distribution-Metadata-Field>`_
    * `Update Collection Metadata Field <https://m2x.att.com/developer/documentation/v2/collections#Update-Collection-Metadata-Field>`_

    :param field: The metadata field to be updated
    :param value: The value to update

    :return: The API response, see M2X API docs for details
    :rtype: dict

    :raises: :class:`~requests.exceptions.HTTPError` if an error occurs when sending the HTTP request
    """
    return self.api.put(self.metadata_field_path(field), data={ "value": value })
def update_metadata_field(self, field, value):
    """ Generic method for a resource's Update Metadata Field endpoint.

    Example endpoints:

    * `Update Device Metadata Field <https://m2x.att.com/developer/documentation/v2/device#Update-Device-Metadata-Field>`_
    * `Update Distribution Metadata Field <https://m2x.att.com/developer/documentation/v2/distribution#Update-Distribution-Metadata-Field>`_
    * `Update Collection Metadata Field <https://m2x.att.com/developer/documentation/v2/collections#Update-Collection-Metadata-Field>`_

    :param field: The metadata field to be updated
    :param value: The value to update

    :return: The API response, see M2X API docs for details
    :rtype: dict

    :raises: :class:`~requests.exceptions.HTTPError` if an error occurs when sending the HTTP request
    """
    return self.api.put(self.metadata_field_path(field), data={ "value": value })
Generic method for a resource's Update Metadata Field endpoint.

    Example endpoints:

    * `Update Device Metadata Field <https://m2x.att.com/developer/documentation/v2/device#Update-Device-Metadata-Field>`_
    * `Update Distribution Metadata Field <https://m2x.att.com/developer/documentation/v2/distribution#Update-Distribution-Metadata-Field>`_
    * `Update Collection Metadata Field <https://m2x.att.com/developer/documentation/v2/collections#Update-Collection-Metadata-Field>`_

    :param field: The metadata field to be updated
    :param value: The value to update

    :return: The API response, see M2X API docs for details
    :rtype: dict

    :raises: :class:`~requests.exceptions.HTTPError` if an error occurs when sending the HTTP request