Copyright | (c) 2015-2016 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Language | Haskell2010 |
Update the data associated with the input key if and only if the passed version matches the currently stored version. This method is safe in the face of concurrent writes. Maximum per-key size is 128KB.
See: Google App State API Reference for appstate.states.update
.
Synopsis
- type StatesUpdateResource = "appstate" :> ("v1" :> ("states" :> (Capture "stateKey" (Textual Int32) :> (QueryParam "currentStateVersion" Text :> (QueryParam "alt" AltJSON :> (ReqBody '[JSON] UpdateRequest :> Put '[JSON] WriteResult))))))
- statesUpdate :: Int32 -> UpdateRequest -> StatesUpdate
- data StatesUpdate
- suCurrentStateVersion :: Lens' StatesUpdate (Maybe Text)
- suStateKey :: Lens' StatesUpdate Int32
- suPayload :: Lens' StatesUpdate UpdateRequest
REST Resource
type StatesUpdateResource = "appstate" :> ("v1" :> ("states" :> (Capture "stateKey" (Textual Int32) :> (QueryParam "currentStateVersion" Text :> (QueryParam "alt" AltJSON :> (ReqBody '[JSON] UpdateRequest :> Put '[JSON] WriteResult)))))) Source #
A resource alias for appstate.states.update
method which the
StatesUpdate
request conforms to.
Creating a Request
Creates a value of StatesUpdate
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
data StatesUpdate Source #
Update the data associated with the input key if and only if the passed version matches the currently stored version. This method is safe in the face of concurrent writes. Maximum per-key size is 128KB.
See: statesUpdate
smart constructor.
Instances
Request Lenses
suCurrentStateVersion :: Lens' StatesUpdate (Maybe Text) Source #
The version of the app state your application is attempting to update. If this does not match the current version, this method will return a conflict error. If there is no data stored on the server for this key, the update will succeed irrespective of the value of this parameter.
suStateKey :: Lens' StatesUpdate Int32 Source #
The key for the data to be retrieved.
suPayload :: Lens' StatesUpdate UpdateRequest Source #
Multipart request metadata.