Copyright | (c) 2013-2018 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Language | Haskell2010 |
Grants a temporary extension to the remaining quota of a usage plan associated with a specified API key.
Synopsis
- updateUsage :: Text -> Text -> UpdateUsage
- data UpdateUsage
- uuPatchOperations :: Lens' UpdateUsage [PatchOperation]
- uuUsagePlanId :: Lens' UpdateUsage Text
- uuKeyId :: Lens' UpdateUsage Text
- usage :: Usage
- data Usage
- uUsagePlanId :: Lens' Usage (Maybe Text)
- uEndDate :: Lens' Usage (Maybe Text)
- uItems :: Lens' Usage (HashMap Text [[Integer]])
- uStartDate :: Lens' Usage (Maybe Text)
- uPosition :: Lens' Usage (Maybe Text)
Creating a Request
Creates a value of UpdateUsage
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
uuPatchOperations
- A list of update operations to be applied to the specified resource and in the order specified in this list.uuUsagePlanId
- [Required] The Id of the usage plan associated with the usage data.uuKeyId
- [Required] The identifier of the API key associated with the usage plan in which a temporary extension is granted to the remaining quota.
data UpdateUsage Source #
The PATCH request to grant a temporary extension to the remaining quota of a usage plan associated with a specified API key.
See: updateUsage
smart constructor.
Instances
Request Lenses
uuPatchOperations :: Lens' UpdateUsage [PatchOperation] Source #
A list of update operations to be applied to the specified resource and in the order specified in this list.
uuUsagePlanId :: Lens' UpdateUsage Text Source #
- Required
- The Id of the usage plan associated with the usage data.
uuKeyId :: Lens' UpdateUsage Text Source #
- Required
- The identifier of the API key associated with the usage plan in which a temporary extension is granted to the remaining quota.
Destructuring the Response
Creates a value of Usage
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
uUsagePlanId
- The plan Id associated with this usage data.uEndDate
- The ending date of the usage data.uItems
- The usage data, as daily logs of used and remaining quotas, over the specified time interval indexed over the API keys in a usage plan. For example,{..., "values" : { "{api_key}" : [ [0, 100], [10, 90], [100, 10]]}
, where{api_key}
stands for an API key value and the daily log entry is of the format[used quota, remaining quota]
.uStartDate
- The starting date of the usage data.uPosition
- Undocumented member.
Represents the usage data of a usage plan.
Create and Use Usage Plans , Manage Usage in a Usage Plan
See: usage
smart constructor.
Instances
Eq Usage Source # | |
Data Usage Source # | |
Defined in Network.AWS.APIGateway.Types.Product gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Usage -> c Usage # gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Usage # dataTypeOf :: Usage -> DataType # dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Usage) # dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Usage) # gmapT :: (forall b. Data b => b -> b) -> Usage -> Usage # gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Usage -> r # gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Usage -> r # gmapQ :: (forall d. Data d => d -> u) -> Usage -> [u] # gmapQi :: Int -> (forall d. Data d => d -> u) -> Usage -> u # gmapM :: Monad m => (forall d. Data d => d -> m d) -> Usage -> m Usage # gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Usage -> m Usage # gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Usage -> m Usage # | |
Read Usage Source # | |
Show Usage Source # | |
Generic Usage Source # | |
Hashable Usage Source # | |
Defined in Network.AWS.APIGateway.Types.Product | |
FromJSON Usage Source # | |
NFData Usage Source # | |
Defined in Network.AWS.APIGateway.Types.Product | |
type Rep Usage Source # | |
Defined in Network.AWS.APIGateway.Types.Product type Rep Usage = D1 (MetaData "Usage" "Network.AWS.APIGateway.Types.Product" "amazonka-apigateway-1.6.1-BCCM2RP3l9Q2ENgHvKrj59" False) (C1 (MetaCons "Usage'" PrefixI True) ((S1 (MetaSel (Just "_uUsagePlanId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Text)) :*: S1 (MetaSel (Just "_uEndDate") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Text))) :*: (S1 (MetaSel (Just "_uItems") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe (Map Text [[Integer]]))) :*: (S1 (MetaSel (Just "_uStartDate") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Text)) :*: S1 (MetaSel (Just "_uPosition") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Text)))))) |
Response Lenses
uItems :: Lens' Usage (HashMap Text [[Integer]]) Source #
The usage data, as daily logs of used and remaining quotas, over the specified time interval indexed over the API keys in a usage plan. For example, {..., "values" : { "{api_key}" : [ [0, 100], [10, 90], [100, 10]]}
, where {api_key}
stands for an API key value and the daily log entry is of the format [used quota, remaining quota]
.