amazonka-iot-1.4.5: Amazon IoT SDK.

Copyright(c) 2013-2016 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone
LanguageHaskell2010

Network.AWS.IoT.UpdateThing

Contents

Description

Updates the data for a thing.

Synopsis

Creating a Request

updateThing #

Creates a value of UpdateThing with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

  • utRemoveThingType - Remove a thing type association. If true , the assocation is removed.
  • utThingTypeName - The name of the thing type.
  • utExpectedVersion - The expected version of the thing record in the registry. If the version of the record in the registry does not match the expected version specified in the request, the UpdateThing request is rejected with a VersionConflictException .
  • utAttributePayload - A list of thing attributes, a JSON string containing name-value pairs. For example: {"attributes":{"name1":"value2"}}) This data is used to add new attributes or update existing attributes.
  • utThingName - The name of the thing to update.

data UpdateThing #

The input for the UpdateThing operation.

See: updateThing smart constructor.

Instances

Eq UpdateThing # 
Data UpdateThing # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> UpdateThing -> c UpdateThing #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c UpdateThing #

toConstr :: UpdateThing -> Constr #

dataTypeOf :: UpdateThing -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c UpdateThing) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c UpdateThing) #

gmapT :: (forall b. Data b => b -> b) -> UpdateThing -> UpdateThing #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> UpdateThing -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> UpdateThing -> r #

gmapQ :: (forall d. Data d => d -> u) -> UpdateThing -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> UpdateThing -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> UpdateThing -> m UpdateThing #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> UpdateThing -> m UpdateThing #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> UpdateThing -> m UpdateThing #

Read UpdateThing # 
Show UpdateThing # 
Generic UpdateThing # 

Associated Types

type Rep UpdateThing :: * -> * #

Hashable UpdateThing # 
ToJSON UpdateThing # 
NFData UpdateThing # 

Methods

rnf :: UpdateThing -> () #

AWSRequest UpdateThing # 
ToQuery UpdateThing # 
ToPath UpdateThing # 
ToHeaders UpdateThing # 

Methods

toHeaders :: UpdateThing -> [Header] #

type Rep UpdateThing # 
type Rep UpdateThing = D1 (MetaData "UpdateThing" "Network.AWS.IoT.UpdateThing" "amazonka-iot-1.4.5-HnBhW38Gbiq1QAd2zPEJmJ" False) (C1 (MetaCons "UpdateThing'" PrefixI True) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "_utRemoveThingType") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Bool))) (S1 (MetaSel (Just Symbol "_utThingTypeName") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Text)))) ((:*:) (S1 (MetaSel (Just Symbol "_utExpectedVersion") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Integer))) ((:*:) (S1 (MetaSel (Just Symbol "_utAttributePayload") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe AttributePayload))) (S1 (MetaSel (Just Symbol "_utThingName") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text))))))
type Rs UpdateThing # 

Request Lenses

utRemoveThingType :: Lens' UpdateThing (Maybe Bool) #

Remove a thing type association. If true , the assocation is removed.

utThingTypeName :: Lens' UpdateThing (Maybe Text) #

The name of the thing type.

utExpectedVersion :: Lens' UpdateThing (Maybe Integer) #

The expected version of the thing record in the registry. If the version of the record in the registry does not match the expected version specified in the request, the UpdateThing request is rejected with a VersionConflictException .

utAttributePayload :: Lens' UpdateThing (Maybe AttributePayload) #

A list of thing attributes, a JSON string containing name-value pairs. For example: {"attributes":{"name1":"value2"}}) This data is used to add new attributes or update existing attributes.

utThingName :: Lens' UpdateThing Text #

The name of the thing to update.

Destructuring the Response

updateThingResponse #

Creates a value of UpdateThingResponse with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

data UpdateThingResponse #

The output from the UpdateThing operation.

See: updateThingResponse smart constructor.

Instances

Eq UpdateThingResponse # 
Data UpdateThingResponse # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> UpdateThingResponse -> c UpdateThingResponse #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c UpdateThingResponse #

toConstr :: UpdateThingResponse -> Constr #

dataTypeOf :: UpdateThingResponse -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c UpdateThingResponse) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c UpdateThingResponse) #

gmapT :: (forall b. Data b => b -> b) -> UpdateThingResponse -> UpdateThingResponse #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> UpdateThingResponse -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> UpdateThingResponse -> r #

gmapQ :: (forall d. Data d => d -> u) -> UpdateThingResponse -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> UpdateThingResponse -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> UpdateThingResponse -> m UpdateThingResponse #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> UpdateThingResponse -> m UpdateThingResponse #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> UpdateThingResponse -> m UpdateThingResponse #

Read UpdateThingResponse # 
Show UpdateThingResponse # 
Generic UpdateThingResponse # 
NFData UpdateThingResponse # 

Methods

rnf :: UpdateThingResponse -> () #

type Rep UpdateThingResponse # 
type Rep UpdateThingResponse = D1 (MetaData "UpdateThingResponse" "Network.AWS.IoT.UpdateThing" "amazonka-iot-1.4.5-HnBhW38Gbiq1QAd2zPEJmJ" True) (C1 (MetaCons "UpdateThingResponse'" PrefixI True) (S1 (MetaSel (Just Symbol "_utrsResponseStatus") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Int)))

Response Lenses

utrsResponseStatus :: Lens' UpdateThingResponse Int #

  • - | The response status code.