amazonka-apigateway-2.0: Amazon API Gateway SDK.
Copyright(c) 2013-2023 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellSafe-Inferred
LanguageHaskell2010

Amazonka.APIGateway.UpdateUsage

Description

Grants a temporary extension to the remaining quota of a usage plan associated with a specified API key.

Synopsis

Creating a Request

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: newUpdateUsage smart constructor.

Constructors

UpdateUsage' 

Fields

Instances

Instances details
ToJSON UpdateUsage Source # 
Instance details

Defined in Amazonka.APIGateway.UpdateUsage

ToHeaders UpdateUsage Source # 
Instance details

Defined in Amazonka.APIGateway.UpdateUsage

Methods

toHeaders :: UpdateUsage -> [Header] #

ToPath UpdateUsage Source # 
Instance details

Defined in Amazonka.APIGateway.UpdateUsage

ToQuery UpdateUsage Source # 
Instance details

Defined in Amazonka.APIGateway.UpdateUsage

AWSRequest UpdateUsage Source # 
Instance details

Defined in Amazonka.APIGateway.UpdateUsage

Associated Types

type AWSResponse UpdateUsage #

Generic UpdateUsage Source # 
Instance details

Defined in Amazonka.APIGateway.UpdateUsage

Associated Types

type Rep UpdateUsage :: Type -> Type #

Read UpdateUsage Source # 
Instance details

Defined in Amazonka.APIGateway.UpdateUsage

Show UpdateUsage Source # 
Instance details

Defined in Amazonka.APIGateway.UpdateUsage

NFData UpdateUsage Source # 
Instance details

Defined in Amazonka.APIGateway.UpdateUsage

Methods

rnf :: UpdateUsage -> () #

Eq UpdateUsage Source # 
Instance details

Defined in Amazonka.APIGateway.UpdateUsage

Hashable UpdateUsage Source # 
Instance details

Defined in Amazonka.APIGateway.UpdateUsage

type AWSResponse UpdateUsage Source # 
Instance details

Defined in Amazonka.APIGateway.UpdateUsage

type Rep UpdateUsage Source # 
Instance details

Defined in Amazonka.APIGateway.UpdateUsage

type Rep UpdateUsage = D1 ('MetaData "UpdateUsage" "Amazonka.APIGateway.UpdateUsage" "amazonka-apigateway-2.0-zw0Lbt4rUGxZBjJ4Rpfi" 'False) (C1 ('MetaCons "UpdateUsage'" 'PrefixI 'True) (S1 ('MetaSel ('Just "patchOperations") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe [PatchOperation])) :*: (S1 ('MetaSel ('Just "usagePlanId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text) :*: S1 ('MetaSel ('Just "keyId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text))))

newUpdateUsage Source #

Create a value of UpdateUsage with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:patchOperations:UpdateUsage', updateUsage_patchOperations - For more information about supported patch operations, see Patch Operations.

UpdateUsage, updateUsage_usagePlanId - The Id of the usage plan associated with the usage data.

$sel:keyId:UpdateUsage', updateUsage_keyId - The identifier of the API key associated with the usage plan in which a temporary extension is granted to the remaining quota.

Request Lenses

updateUsage_patchOperations :: Lens' UpdateUsage (Maybe [PatchOperation]) Source #

For more information about supported patch operations, see Patch Operations.

updateUsage_usagePlanId :: Lens' UpdateUsage Text Source #

The Id of the usage plan associated with the usage data.

updateUsage_keyId :: Lens' UpdateUsage Text Source #

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

data Usage Source #

Represents the usage data of a usage plan.

See: newUsage smart constructor.

Constructors

Usage' 

Fields

  • endDate :: Maybe Text

    The ending date of the usage data.

  • items :: Maybe (HashMap Text [[Integer]])

    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].

  • position :: Maybe Text
     
  • startDate :: Maybe Text

    The starting date of the usage data.

  • usagePlanId :: Maybe Text

    The plan Id associated with this usage data.

Instances

Instances details
FromJSON Usage Source # 
Instance details

Defined in Amazonka.APIGateway.Types.Usage

Generic Usage Source # 
Instance details

Defined in Amazonka.APIGateway.Types.Usage

Associated Types

type Rep Usage :: Type -> Type #

Methods

from :: Usage -> Rep Usage x #

to :: Rep Usage x -> Usage #

Read Usage Source # 
Instance details

Defined in Amazonka.APIGateway.Types.Usage

Show Usage Source # 
Instance details

Defined in Amazonka.APIGateway.Types.Usage

Methods

showsPrec :: Int -> Usage -> ShowS #

show :: Usage -> String #

showList :: [Usage] -> ShowS #

NFData Usage Source # 
Instance details

Defined in Amazonka.APIGateway.Types.Usage

Methods

rnf :: Usage -> () #

Eq Usage Source # 
Instance details

Defined in Amazonka.APIGateway.Types.Usage

Methods

(==) :: Usage -> Usage -> Bool #

(/=) :: Usage -> Usage -> Bool #

Hashable Usage Source # 
Instance details

Defined in Amazonka.APIGateway.Types.Usage

Methods

hashWithSalt :: Int -> Usage -> Int #

hash :: Usage -> Int #

type Rep Usage Source # 
Instance details

Defined in Amazonka.APIGateway.Types.Usage

type Rep Usage = D1 ('MetaData "Usage" "Amazonka.APIGateway.Types.Usage" "amazonka-apigateway-2.0-zw0Lbt4rUGxZBjJ4Rpfi" 'False) (C1 ('MetaCons "Usage'" 'PrefixI 'True) ((S1 ('MetaSel ('Just "endDate") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "items") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe (HashMap Text [[Integer]])))) :*: (S1 ('MetaSel ('Just "position") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: (S1 ('MetaSel ('Just "startDate") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "usagePlanId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text))))))

newUsage :: Usage Source #

Create a value of Usage with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:endDate:Usage', usage_endDate - The ending date of the usage data.

$sel:items:Usage', usage_items - 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].

$sel:position:Usage', usage_position - Undocumented member.

$sel:startDate:Usage', usage_startDate - The starting date of the usage data.

$sel:usagePlanId:Usage', usage_usagePlanId - The plan Id associated with this usage data.

Response Lenses

usage_endDate :: Lens' Usage (Maybe Text) Source #

The ending date of the usage data.

usage_items :: Lens' Usage (Maybe (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].

usage_position :: Lens' Usage (Maybe Text) Source #

Undocumented member.

usage_startDate :: Lens' Usage (Maybe Text) Source #

The starting date of the usage data.

usage_usagePlanId :: Lens' Usage (Maybe Text) Source #

The plan Id associated with this usage data.