Regenerating all services

This commit is contained in:
Brendan Hay 2015-09-30 11:55:11 +02:00
parent 95f53ae09c
commit 79016936a6
2775 changed files with 643812 additions and 0 deletions

View File

@ -0,0 +1,373 @@
Mozilla Public License Version 2.0
==================================
1. Definitions
--------------
1.1. "Contributor"
means each individual or legal entity that creates, contributes to
the creation of, or owns Covered Software.
1.2. "Contributor Version"
means the combination of the Contributions of others (if any) used
by a Contributor and that particular Contributor's Contribution.
1.3. "Contribution"
means Covered Software of a particular Contributor.
1.4. "Covered Software"
means Source Code Form to which the initial Contributor has attached
the notice in Exhibit A, the Executable Form of such Source Code
Form, and Modifications of such Source Code Form, in each case
including portions thereof.
1.5. "Incompatible With Secondary Licenses"
means
(a) that the initial Contributor has attached the notice described
in Exhibit B to the Covered Software; or
(b) that the Covered Software was made available under the terms of
version 1.1 or earlier of the License, but not also under the
terms of a Secondary License.
1.6. "Executable Form"
means any form of the work other than Source Code Form.
1.7. "Larger Work"
means a work that combines Covered Software with other material, in
a separate file or files, that is not Covered Software.
1.8. "License"
means this document.
1.9. "Licensable"
means having the right to grant, to the maximum extent possible,
whether at the time of the initial grant or subsequently, any and
all of the rights conveyed by this License.
1.10. "Modifications"
means any of the following:
(a) any file in Source Code Form that results from an addition to,
deletion from, or modification of the contents of Covered
Software; or
(b) any new file in Source Code Form that contains any Covered
Software.
1.11. "Patent Claims" of a Contributor
means any patent claim(s), including without limitation, method,
process, and apparatus claims, in any patent Licensable by such
Contributor that would be infringed, but for the grant of the
License, by the making, using, selling, offering for sale, having
made, import, or transfer of either its Contributions or its
Contributor Version.
1.12. "Secondary License"
means either the GNU General Public License, Version 2.0, the GNU
Lesser General Public License, Version 2.1, the GNU Affero General
Public License, Version 3.0, or any later versions of those
licenses.
1.13. "Source Code Form"
means the form of the work preferred for making modifications.
1.14. "You" (or "Your")
means an individual or a legal entity exercising rights under this
License. For legal entities, "You" includes any entity that
controls, is controlled by, or is under common control with You. For
purposes of this definition, "control" means (a) the power, direct
or indirect, to cause the direction or management of such entity,
whether by contract or otherwise, or (b) ownership of more than
fifty percent (50%) of the outstanding shares or beneficial
ownership of such entity.
2. License Grants and Conditions
--------------------------------
2.1. Grants
Each Contributor hereby grants You a world-wide, royalty-free,
non-exclusive license:
(a) under intellectual property rights (other than patent or trademark)
Licensable by such Contributor to use, reproduce, make available,
modify, display, perform, distribute, and otherwise exploit its
Contributions, either on an unmodified basis, with Modifications, or
as part of a Larger Work; and
(b) under Patent Claims of such Contributor to make, use, sell, offer
for sale, have made, import, and otherwise transfer either its
Contributions or its Contributor Version.
2.2. Effective Date
The licenses granted in Section 2.1 with respect to any Contribution
become effective for each Contribution on the date the Contributor first
distributes such Contribution.
2.3. Limitations on Grant Scope
The licenses granted in this Section 2 are the only rights granted under
this License. No additional rights or licenses will be implied from the
distribution or licensing of Covered Software under this License.
Notwithstanding Section 2.1(b) above, no patent license is granted by a
Contributor:
(a) for any code that a Contributor has removed from Covered Software;
or
(b) for infringements caused by: (i) Your and any other third party's
modifications of Covered Software, or (ii) the combination of its
Contributions with other software (except as part of its Contributor
Version); or
(c) under Patent Claims infringed by Covered Software in the absence of
its Contributions.
This License does not grant any rights in the trademarks, service marks,
or logos of any Contributor (except as may be necessary to comply with
the notice requirements in Section 3.4).
2.4. Subsequent Licenses
No Contributor makes additional grants as a result of Your choice to
distribute the Covered Software under a subsequent version of this
License (see Section 10.2) or under the terms of a Secondary License (if
permitted under the terms of Section 3.3).
2.5. Representation
Each Contributor represents that the Contributor believes its
Contributions are its original creation(s) or it has sufficient rights
to grant the rights to its Contributions conveyed by this License.
2.6. Fair Use
This License is not intended to limit any rights You have under
applicable copyright doctrines of fair use, fair dealing, or other
equivalents.
2.7. Conditions
Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted
in Section 2.1.
3. Responsibilities
-------------------
3.1. Distribution of Source Form
All distribution of Covered Software in Source Code Form, including any
Modifications that You create or to which You contribute, must be under
the terms of this License. You must inform recipients that the Source
Code Form of the Covered Software is governed by the terms of this
License, and how they can obtain a copy of this License. You may not
attempt to alter or restrict the recipients' rights in the Source Code
Form.
3.2. Distribution of Executable Form
If You distribute Covered Software in Executable Form then:
(a) such Covered Software must also be made available in Source Code
Form, as described in Section 3.1, and You must inform recipients of
the Executable Form how they can obtain a copy of such Source Code
Form by reasonable means in a timely manner, at a charge no more
than the cost of distribution to the recipient; and
(b) You may distribute such Executable Form under the terms of this
License, or sublicense it under different terms, provided that the
license for the Executable Form does not attempt to limit or alter
the recipients' rights in the Source Code Form under this License.
3.3. Distribution of a Larger Work
You may create and distribute a Larger Work under terms of Your choice,
provided that You also comply with the requirements of this License for
the Covered Software. If the Larger Work is a combination of Covered
Software with a work governed by one or more Secondary Licenses, and the
Covered Software is not Incompatible With Secondary Licenses, this
License permits You to additionally distribute such Covered Software
under the terms of such Secondary License(s), so that the recipient of
the Larger Work may, at their option, further distribute the Covered
Software under the terms of either this License or such Secondary
License(s).
3.4. Notices
You may not remove or alter the substance of any license notices
(including copyright notices, patent notices, disclaimers of warranty,
or limitations of liability) contained within the Source Code Form of
the Covered Software, except that You may alter any license notices to
the extent required to remedy known factual inaccuracies.
3.5. Application of Additional Terms
You may choose to offer, and to charge a fee for, warranty, support,
indemnity or liability obligations to one or more recipients of Covered
Software. However, You may do so only on Your own behalf, and not on
behalf of any Contributor. You must make it absolutely clear that any
such warranty, support, indemnity, or liability obligation is offered by
You alone, and You hereby agree to indemnify every Contributor for any
liability incurred by such Contributor as a result of warranty, support,
indemnity or liability terms You offer. You may include additional
disclaimers of warranty and limitations of liability specific to any
jurisdiction.
4. Inability to Comply Due to Statute or Regulation
---------------------------------------------------
If it is impossible for You to comply with any of the terms of this
License with respect to some or all of the Covered Software due to
statute, judicial order, or regulation then You must: (a) comply with
the terms of this License to the maximum extent possible; and (b)
describe the limitations and the code they affect. Such description must
be placed in a text file included with all distributions of the Covered
Software under this License. Except to the extent prohibited by statute
or regulation, such description must be sufficiently detailed for a
recipient of ordinary skill to be able to understand it.
5. Termination
--------------
5.1. The rights granted under this License will terminate automatically
if You fail to comply with any of its terms. However, if You become
compliant, then the rights granted under this License from a particular
Contributor are reinstated (a) provisionally, unless and until such
Contributor explicitly and finally terminates Your grants, and (b) on an
ongoing basis, if such Contributor fails to notify You of the
non-compliance by some reasonable means prior to 60 days after You have
come back into compliance. Moreover, Your grants from a particular
Contributor are reinstated on an ongoing basis if such Contributor
notifies You of the non-compliance by some reasonable means, this is the
first time You have received notice of non-compliance with this License
from such Contributor, and You become compliant prior to 30 days after
Your receipt of the notice.
5.2. If You initiate litigation against any entity by asserting a patent
infringement claim (excluding declaratory judgment actions,
counter-claims, and cross-claims) alleging that a Contributor Version
directly or indirectly infringes any patent, then the rights granted to
You by any and all Contributors for the Covered Software under Section
2.1 of this License shall terminate.
5.3. In the event of termination under Sections 5.1 or 5.2 above, all
end user license agreements (excluding distributors and resellers) which
have been validly granted by You or Your distributors under this License
prior to termination shall survive termination.
************************************************************************
* *
* 6. Disclaimer of Warranty *
* ------------------------- *
* *
* Covered Software is provided under this License on an "as is" *
* basis, without warranty of any kind, either expressed, implied, or *
* statutory, including, without limitation, warranties that the *
* Covered Software is free of defects, merchantable, fit for a *
* particular purpose or non-infringing. The entire risk as to the *
* quality and performance of the Covered Software is with You. *
* Should any Covered Software prove defective in any respect, You *
* (not any Contributor) assume the cost of any necessary servicing, *
* repair, or correction. This disclaimer of warranty constitutes an *
* essential part of this License. No use of any Covered Software is *
* authorized under this License except under this disclaimer. *
* *
************************************************************************
************************************************************************
* *
* 7. Limitation of Liability *
* -------------------------- *
* *
* Under no circumstances and under no legal theory, whether tort *
* (including negligence), contract, or otherwise, shall any *
* Contributor, or anyone who distributes Covered Software as *
* permitted above, be liable to You for any direct, indirect, *
* special, incidental, or consequential damages of any character *
* including, without limitation, damages for lost profits, loss of *
* goodwill, work stoppage, computer failure or malfunction, or any *
* and all other commercial damages or losses, even if such party *
* shall have been informed of the possibility of such damages. This *
* limitation of liability shall not apply to liability for death or *
* personal injury resulting from such party's negligence to the *
* extent applicable law prohibits such limitation. Some *
* jurisdictions do not allow the exclusion or limitation of *
* incidental or consequential damages, so this exclusion and *
* limitation may not apply to You. *
* *
************************************************************************
8. Litigation
-------------
Any litigation relating to this License may be brought only in the
courts of a jurisdiction where the defendant maintains its principal
place of business and such litigation shall be governed by laws of that
jurisdiction, without reference to its conflict-of-law provisions.
Nothing in this Section shall prevent a party's ability to bring
cross-claims or counter-claims.
9. Miscellaneous
----------------
This License represents the complete agreement concerning the subject
matter hereof. If any provision of this License is held to be
unenforceable, such provision shall be reformed only to the extent
necessary to make it enforceable. Any law or regulation which provides
that the language of a contract shall be construed against the drafter
shall not be used to construe this License against a Contributor.
10. Versions of the License
---------------------------
10.1. New Versions
Mozilla Foundation is the license steward. Except as provided in Section
10.3, no one other than the license steward has the right to modify or
publish new versions of this License. Each version will be given a
distinguishing version number.
10.2. Effect of New Versions
You may distribute the Covered Software under the terms of the version
of the License under which You originally received the Covered Software,
or under the terms of any subsequent version published by the license
steward.
10.3. Modified Versions
If you create software not governed by this License, and you want to
create a new license for such software, you may create and use a
modified version of this License if you rename the license and remove
any references to the name of the license steward (except to note that
such modified license differs from this License).
10.4. Distributing Source Code Form that is Incompatible With Secondary
Licenses
If You choose to distribute Source Code Form that is Incompatible With
Secondary Licenses under the terms of this version of the License, the
notice described in Exhibit B of this License must be attached.
Exhibit A - Source Code Form License Notice
-------------------------------------------
This Source Code Form is subject to the terms of the Mozilla Public
License, v. 2.0. If a copy of the MPL was not distributed with this
file, You can obtain one at http://mozilla.org/MPL/2.0/.
If it is not possible or desirable to put the notice in a particular
file, then You may include the notice in a location (such as a LICENSE
file in a relevant directory) where a recipient would be likely to look
for such a notice.
You may add additional accurate notices of copyright ownership.
Exhibit B - "Incompatible With Secondary Licenses" Notice
---------------------------------------------------------
This Source Code Form is "Incompatible With Secondary Licenses", as
defined by the Mozilla Public License, v. 2.0.

View File

@ -0,0 +1 @@
include ../share/library.mk

View File

@ -0,0 +1,28 @@
# gogol-adexchange-buyer
* [Version](#version)
* [Description](#description)
* [Contribute](#contribute)
* [Licence](#licence)
## Version
`0.0.1`
## Description
A client library for the Ad Exchange Buyer API.
## Contribute
For any problems, comments, or feedback please create an issue [here on GitHub](https://github.com/brendanhay/amazonka/issues).
> _Note:_ this library is an auto-generated Haskell package. Please see `amazonka-gen` for more information.
## Licence
`gogol-adexchange-buyer` is released under the [Mozilla Public License Version 2.0](http://www.mozilla.org/MPL/).

View File

@ -0,0 +1,2 @@
import Distribution.Simple
main = defaultMain

View File

@ -0,0 +1,957 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.AdExchangeBuyer
-- Copyright : (c) 2015 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)
--
-- -- | Accesses your bidding-account information, submits creatives for
-- validation, finds available direct deals, and retrieves performance
-- reports.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference>
module Network.Google.AdExchangeBuyer
(
-- * API
AdExchangeBuyerAPI
, adExchangeBuyerAPI
, adExchangeBuyerURL
-- * Service Methods
-- * REST Resources
-- ** AdexchangebuyerAccountsGet
, module AdExchangeBuyer.Accounts.Get
-- ** AdexchangebuyerAccountsList
, module AdExchangeBuyer.Accounts.List
-- ** AdexchangebuyerAccountsPatch
, module AdExchangeBuyer.Accounts.Patch
-- ** AdexchangebuyerAccountsUpdate
, module AdExchangeBuyer.Accounts.Update
-- ** AdexchangebuyerBillingInfoGet
, module AdExchangeBuyer.BillingInfo.Get
-- ** AdexchangebuyerBillingInfoList
, module AdExchangeBuyer.BillingInfo.List
-- ** AdexchangebuyerBudgetGet
, module AdExchangeBuyer.Budget.Get
-- ** AdexchangebuyerBudgetPatch
, module AdExchangeBuyer.Budget.Patch
-- ** AdexchangebuyerBudgetUpdate
, module AdExchangeBuyer.Budget.Update
-- ** AdexchangebuyerClientaccessDelete
, module AdExchangeBuyer.Clientaccess.Delete
-- ** AdexchangebuyerClientaccessGet
, module AdExchangeBuyer.Clientaccess.Get
-- ** AdexchangebuyerClientaccessInsert
, module AdExchangeBuyer.Clientaccess.Insert
-- ** AdexchangebuyerClientaccessList
, module AdExchangeBuyer.Clientaccess.List
-- ** AdexchangebuyerClientaccessPatch
, module AdExchangeBuyer.Clientaccess.Patch
-- ** AdexchangebuyerClientaccessUpdate
, module AdExchangeBuyer.Clientaccess.Update
-- ** AdexchangebuyerCreativesGet
, module AdExchangeBuyer.Creatives.Get
-- ** AdexchangebuyerCreativesInsert
, module AdExchangeBuyer.Creatives.Insert
-- ** AdexchangebuyerCreativesList
, module AdExchangeBuyer.Creatives.List
-- ** AdexchangebuyerDealsGet
, module AdExchangeBuyer.Deals.Get
-- ** AdexchangebuyerMarketplacedealsDelete
, module AdExchangeBuyer.Marketplacedeals.Delete
-- ** AdexchangebuyerMarketplacedealsInsert
, module AdExchangeBuyer.Marketplacedeals.Insert
-- ** AdexchangebuyerMarketplacedealsList
, module AdExchangeBuyer.Marketplacedeals.List
-- ** AdexchangebuyerMarketplacedealsUpdate
, module AdExchangeBuyer.Marketplacedeals.Update
-- ** AdexchangebuyerMarketplacenotesInsert
, module AdExchangeBuyer.Marketplacenotes.Insert
-- ** AdexchangebuyerMarketplacenotesList
, module AdExchangeBuyer.Marketplacenotes.List
-- ** AdexchangebuyerMarketplaceoffersGet
, module AdExchangeBuyer.Marketplaceoffers.Get
-- ** AdexchangebuyerMarketplaceoffersSearch
, module AdExchangeBuyer.Marketplaceoffers.Search
-- ** AdexchangebuyerMarketplaceordersGet
, module AdExchangeBuyer.Marketplaceorders.Get
-- ** AdexchangebuyerMarketplaceordersInsert
, module AdExchangeBuyer.Marketplaceorders.Insert
-- ** AdexchangebuyerMarketplaceordersPatch
, module AdExchangeBuyer.Marketplaceorders.Patch
-- ** AdexchangebuyerMarketplaceordersSearch
, module AdExchangeBuyer.Marketplaceorders.Search
-- ** AdexchangebuyerMarketplaceordersUpdate
, module AdExchangeBuyer.Marketplaceorders.Update
-- ** AdexchangebuyerNegotiationroundsInsert
, module AdExchangeBuyer.Negotiationrounds.Insert
-- ** AdexchangebuyerNegotiationsGet
, module AdExchangeBuyer.Negotiations.Get
-- ** AdexchangebuyerNegotiationsInsert
, module AdExchangeBuyer.Negotiations.Insert
-- ** AdexchangebuyerNegotiationsList
, module AdExchangeBuyer.Negotiations.List
-- ** AdexchangebuyerOffersGet
, module AdExchangeBuyer.Offers.Get
-- ** AdexchangebuyerOffersInsert
, module AdExchangeBuyer.Offers.Insert
-- ** AdexchangebuyerOffersList
, module AdExchangeBuyer.Offers.List
-- ** AdexchangebuyerPerformanceReportList
, module AdExchangeBuyer.PerformanceReport.List
-- ** AdexchangebuyerPretargetingConfigDelete
, module AdExchangeBuyer.PretargetingConfig.Delete
-- ** AdexchangebuyerPretargetingConfigGet
, module AdExchangeBuyer.PretargetingConfig.Get
-- ** AdexchangebuyerPretargetingConfigInsert
, module AdExchangeBuyer.PretargetingConfig.Insert
-- ** AdexchangebuyerPretargetingConfigList
, module AdExchangeBuyer.PretargetingConfig.List
-- ** AdexchangebuyerPretargetingConfigPatch
, module AdExchangeBuyer.PretargetingConfig.Patch
-- ** AdexchangebuyerPretargetingConfigUpdate
, module AdExchangeBuyer.PretargetingConfig.Update
-- * Types
-- ** BrandDto
, BrandDto
, brandDto
, bdAdvertiserId
, bdName
, bdId
-- ** EditAllOrderDealsResponse
, EditAllOrderDealsResponse
, editAllOrderDealsResponse
, eaodrDeals
-- ** MarketplaceNote
, MarketplaceNote
, marketplaceNote
, mnNote
, mnKind
, mnTimestampMs
, mnDealId
, mnNoteId
, mnCreatorRole
, mnOrderId
, mnOrderRevisionNumber
-- ** TermsDto
, TermsDto
, termsDto
, tdFinalizeAutomatically
, tdBuyerBillingType
, tdTargetingAllAdSlots
, tdUrls
, tdEndDate
, tdCpm
, tdEstimatedSpend
, tdAdvertisers
, tdEstimatedImpressionsPerDay
, tdMonetizerType
, tdAudienceSegmentDescription
, tdCreativeReviewPolicy
, tdMinimumTrueLooks
, tdStartDate
, tdCreativeBlockingLevel
, tdSemiTransparent
, tdAudienceSegment
, tdDealPremium
, tdIsReservation
, tdAdSlots
, tdTermsAttributes
, tdInventorySegmentTargeting
, tdDescriptiveName
, tdMinimumSpendMicros
, tdTargetByDealId
, tdBillingTerms
, tdDescription
-- ** CreativesList
, CreativesList
, creativesList
, clNextPageToken
, clKind
, clItems
-- ** CreateOrdersResponse
, CreateOrdersResponse
, createOrdersResponse
, corOrders
-- ** AddOrderNotesRequest
, AddOrderNotesRequest
, addOrderNotesRequest
, aonrNotes
-- ** MarketplaceDealParty
, MarketplaceDealParty
, marketplaceDealParty
, mdpSeller
, mdpBuyer
-- ** DealPartyDto
, DealPartyDto
, dealPartyDto
, dpdBuyerSellerRole
, dpdCustomerId
, dpdName
, dpdWebProperty
, dpdBuyer
-- ** DeliveryControlFrequencyCap
, DeliveryControlFrequencyCap
, deliveryControlFrequencyCap
, dcfcMaxImpressions
, dcfcNumTimeUnits
, dcfcTimeUnitType
-- ** GetNegotiationsResponse
, GetNegotiationsResponse
, getNegotiationsResponse
, gnrKind
, gnrNegotiations
-- ** Budget
, Budget
, budget
, bCurrencyCode
, bKind
, bBudgetAmount
, bAccountId
, bId
, bBillingId
-- ** GetFinalizedNegotiationByExternalDealIdRequest
, GetFinalizedNegotiationByExternalDealIdRequest
, getFinalizedNegotiationByExternalDealIdRequest
, gfnbedirIncludePrivateAuctions
-- ** PrivateData
, PrivateData
, privateData
, pdReferencePayload
, pdReferenceId
-- ** AdSize
, AdSize
, adSize
, asHeight
, asWidth
-- ** RuleKeyValuePair
, RuleKeyValuePair
, ruleKeyValuePair
, rkvpKeyName
, rkvpValue
-- ** GetOrdersResponse
, GetOrdersResponse
, getOrdersResponse
, gorOrders
-- ** AccountsList
, AccountsList
, accountsList
, alKind
, alItems
-- ** GetOrderNotesResponse
, GetOrderNotesResponse
, getOrderNotesResponse
, gonrNotes
-- ** CreateOrdersRequest
, CreateOrdersRequest
, createOrdersRequest
, cWebPropertyCode
, cOrders
-- ** PricePerBuyer
, PricePerBuyer
, pricePerBuyer
, ppbPrice
, ppbBuyer
-- ** TargetingValueDayPartTargetingDayPart
, TargetingValueDayPartTargetingDayPart
, targetingValueDayPartTargetingDayPart
, tvdptdpEndHour
, tvdptdpStartHour
, tvdptdpStartMinute
, tvdptdpDayOfWeek
, tvdptdpEndMinute
-- ** DeliveryControl
, DeliveryControl
, deliveryControl
, dcFrequencyCaps
, dcDeliveryRateType
-- ** Creative
, Creative
, creative
, cAttribute
, cNativeAd
, cHeight
, cBuyerCreativeId
, cAdvertiserName
, cAgencyId
, cCorrections
, cProductCategories
, cKind
, cHTMLSnippet
, cAdvertiserId
, cRestrictedCategories
, cDealsStatus
, cWidth
, cClickThroughUrl
, cVendorType
, cAccountId
, cImpressionTrackingUrl
, cFilteringReasons
, cVersion
, cSensitiveCategories
, cVideoURL
, cApiUploadTimestamp
, cServingRestrictions
, cOpenAuctionStatus
-- ** AddOrderDealsResponse
, AddOrderDealsResponse
, addOrderDealsResponse
, aodrDeals
, aodrOrderRevisionNumber
-- ** PretargetingConfigList
, PretargetingConfigList
, pretargetingConfigList
, pclKind
, pclItems
-- ** BuyerDto
, BuyerDto
, buyerDto
, buySponsorAccountId
, buyEnabledForInterestTargetingDeals
, buyCustomerId
, buyEnabledForPreferredDeals
, buyAccountId
, buyDisplayName
, buyId
-- ** DealTermsNonGuaranteedFixedPriceTerms
, DealTermsNonGuaranteedFixedPriceTerms
, dealTermsNonGuaranteedFixedPriceTerms
, dtngfptFixedPrices
-- ** AdSlotDto
, AdSlotDto
, adSlotDto
, asdWebPropertyId
, asdSize
, asdChannelCode
, asdChannelId
, asdName
, asdDescription
-- ** PerformanceReport
, PerformanceReport
, performanceReport
, prFilteredBidRate
, prKind
, prLatency95thPercentile
, prCookieMatcherStatusRate
, prHostedMatchStatusRate
, prUnsuccessfulRequestRate
, prBidRequestRate
, prQuotaThrottledLimit
, prQuotaConfiguredLimit
, prSuccessfulRequestRate
, prLatency85thPercentile
, prCalloutStatusRate
, prLatency50thPercentile
, prBidRate
, prCreativeStatusRate
, prNoQuotaInRegion
, prRegion
, prInventoryMatchRate
, prPixelMatchResponses
, prTimestamp
, prPixelMatchRequests
, prOutOfQuota
-- ** Account
, Account
, account
, aMaximumTotalQps
, aKind
, aCookieMatchingUrl
, aMaximumActiveCreatives
, aCookieMatchingNid
, aNumberActiveCreatives
, aId
, aBidderLocation
-- ** Seller
, Seller
, seller
, sAccountId
, sSubAccountId
-- ** DeleteOrderDealsRequest
, DeleteOrderDealsRequest
, deleteOrderDealsRequest
, dodrUpdateAction
, dodrDealIds
, dodrOrderRevisionNumber
-- ** GetOrderDealsResponse
, GetOrderDealsResponse
, getOrderDealsResponse
, godrDeals
-- ** ContactInformation
, ContactInformation
, contactInformation
, ciEmail
, ciName
-- ** TargetingValueCreativeSize
, TargetingValueCreativeSize
, targetingValueCreativeSize
, tvcsSize
, tvcsCompanionSizes
, tvcsCreativeSizeType
-- ** PretargetingConfig
, PretargetingConfig
, pretargetingConfig
, pcPlatforms
, pcMobileCarriers
, pcVendorTypes
, pcExcludedGeoCriteriaIds
, pcSupportedCreativeAttributes
, pcUserLists
, pcKind
, pcExcludedPlacements
, pcMobileDevices
, pcLanguages
, pcVerticals
, pcConfigId
, pcPlacements
, pcExcludedUserLists
, pcConfigName
, pcGeoCriteriaIds
, pcDimensions
, pcExcludedVerticals
, pcCreativeType
, pcIsActive
, pcExcludedContentLabels
, pcBillingId
, pcMobileOperatingSystemVersions
-- ** PerformanceReportList
, PerformanceReportList
, performanceReportList
, prlKind
, prlPerformanceReport
-- ** NegotiationDto
, NegotiationDto
, negotiationDto
, ndNegotiationState
, ndExternalDealId
, ndStatus
, ndDealType
, ndNegotiationRounds
, ndKind
, ndBilledBuyer
, ndBuyerEmailContacts
, ndStats
, ndSeller
, ndLabelNames
, ndOfferId
, ndNegotiationId
, ndSellerEmailContacts
, ndBuyer
-- ** AudienceSegment
, AudienceSegment
, audienceSegment
, asNumCookies
, asName
, asId
, asDescription
-- ** OfferDto
, OfferDto
, offerDto
, odCreator
, odStatus
, odOfferState
, odPointOfContact
, odTerms
, odKind
, odBilledBuyer
, odOpenToDealParties
, odEmailContacts
, odLabelNames
, odOfferId
, odClosedToDealParties
, odAnonymous
, odIsOpen
-- ** TargetingValueSize
, TargetingValueSize
, targetingValueSize
, tvsHeight
, tvsWidth
-- ** MarketplaceOffer
, MarketplaceOffer
, marketplaceOffer
, moState
, moWebPropertyCode
, moCreationTimeMs
, moTerms
, moLastUpdateTimeMs
, moKind
, moRevisionNumber
, moHasCreatorSignedOff
, moFlightStartTimeMs
, moSharedTargetings
, moSeller
, moSyndicationProduct
, moFlightEndTimeMs
, moName
, moCreatorContacts
, moOfferId
, moLabels
-- ** GetNegotiationsRequest
, GetNegotiationsRequest
, getNegotiationsRequest
, gnrSinceTimestampMillis
, gnrFinalized
, gnrIncludePrivateAuctions
-- ** BillingInfoList
, BillingInfoList
, billingInfoList
, bilKind
, bilItems
-- ** AddOrderNotesResponse
, AddOrderNotesResponse
, addOrderNotesResponse
, aNotes
-- ** MoneyDto
, MoneyDto
, moneyDto
, mdCurrencyCode
, mdMicros
-- ** ListClientAccessCapabilitiesResponse
, ListClientAccessCapabilitiesResponse
, listClientAccessCapabilitiesResponse
, lcacrClientAccessPermissions
-- ** GetNegotiationByIdRequest
, GetNegotiationByIdRequest
, getNegotiationByIdRequest
, gnbirIncludePrivateAuctions
-- ** ListOffersResponse
, ListOffersResponse
, listOffersResponse
, lorKind
, lorOffers
-- ** AdvertiserDto
, AdvertiserDto
, advertiserDto
, adStatus
, adBrands
, adName
, adId
-- ** TargetingValue
, TargetingValue
, targetingValue
, tvCreativeSizeValue
, tvStringValue
, tvLongValue
, tvDayPartTargetingValue
-- ** Price
, Price
, price
, pCurrencyCode
, pAmountMicros
-- ** EditAllOrderDealsRequest
, EditAllOrderDealsRequest
, editAllOrderDealsRequest
, eUpdateAction
, eDeals
, eOrder
, eOrderRevisionNumber
-- ** BillingInfo
, BillingInfo
, billingInfo
, biKind
, biAccountName
, biAccountId
, biBillingId
-- ** WebPropertyDto
, WebPropertyDto
, webPropertyDto
, wpdEnabledForPreferredDeals
, wpdSyndicationProduct
, wpdName
, wpdPropertyCode
, wpdId
, wpdSiteUrls
, wpdAllowInterestTargetedAds
-- ** TargetingValueDayPartTargeting
, TargetingValueDayPartTargeting
, targetingValueDayPartTargeting
, tvdptTimeZoneType
, tvdptDayParts
-- ** ListOffersRequest
, ListOffersRequest
, listOffersRequest
, lorSinceTimestampMillis
-- ** ListClientAccessCapabilitiesRequest
, ListClientAccessCapabilitiesRequest
, listClientAccessCapabilitiesRequest
, lcacrSponsorAccountId
-- ** InventorySegmentTargeting
, InventorySegmentTargeting
, inventorySegmentTargeting
, istNegativeVideoDurationSegments
, istNegativeIcmBrands
, istNegativeKeyValues
, istPositiveAudienceSegments
, istPositiveXfpPlacements
, istNegativeXfpAdSlots
, istPositiveOperatingSystemVersions
, istPositiveSizes
, istPositiveDeviceCategories
, istPositiveLocations
, istNegativeAdSizes
, istPositiveOperatingSystems
, istPositiveSiteUrls
, istNegativeInventorySlots
, istNegativeVideoAdPositionSegments
, istPositiveAdTypeSegments
, istPositiveIcmInterests
, istPositiveMobileApps
, istPositiveKeyValues
, istPositiveIcmBrands
, istPositiveVideoDurationSegments
, istNegativeAudienceSegments
, istNegativeXfpPlacements
, istPositiveXfpAdSlots
, istNegativeOperatingSystemVersions
, istNegativeSizes
, istNegativeLocations
, istNegativeDeviceCategories
, istNegativeOperatingSystems
, istPositiveAdSizes
, istNegativeSiteUrls
, istNegativeAdTypeSegments
, istPositiveVideoAdPositionSegments
, istPositiveInventorySlots
, istNegativeMobileApps
, istNegativeIcmInterests
-- ** SharedTargeting
, SharedTargeting
, sharedTargeting
, stKey
, stExclusions
, stInclusions
-- ** ClientAccessCapabilities
, ClientAccessCapabilities
, clientAccessCapabilities
, cacClientAccountId
, cacCapabilities
-- ** DeleteOrderDealsResponse
, DeleteOrderDealsResponse
, deleteOrderDealsResponse
, dDeals
, dOrderRevisionNumber
-- ** MarketplaceDeal
, MarketplaceDeal
, marketplaceDeal
, mdExternalDealId
, mdBuyerPrivateData
, mdWebPropertyCode
, mdCreationTimeMs
, mdTerms
, mdOfferRevisionNumber
, mdLastUpdateTimeMs
, mdKind
, mdDeliveryControl
, mdFlightStartTimeMs
, mdSharedTargetings
, mdDealId
, mdInventoryDescription
, mdSyndicationProduct
, mdFlightEndTimeMs
, mdName
, mdSellerContacts
, mdOfferId
, mdOrderId
-- ** NegotiationRoundDto
, NegotiationRoundDto
, negotiationRoundDto
, nrdTerms
, nrdKind
, nrdOriginatorRole
, nrdAction
, nrdDbmPartnerId
, nrdNotes
, nrdNegotiationId
, nrdEditHistory
, nrdRoundNumber
-- ** StatsDto
, StatsDto
, statsDto
, sdBids
, sdSpend
, sdImpressions
, sdGoodBids
, sdRevenue
, sdRequests
-- ** GetOffersResponse
, GetOffersResponse
, getOffersResponse
, gorOffers
-- ** DealTermsNonGuaranteedAuctionTerms
, DealTermsNonGuaranteedAuctionTerms
, dealTermsNonGuaranteedAuctionTerms
, dtngatReservePricePerBuyers
, dtngatPrivateAuctionId
-- ** Buyer
, Buyer
, buyer
, bbAccountId
-- ** MarketplaceLabel
, MarketplaceLabel
, marketplaceLabel
, mlDeprecatedMarketplaceDealParty
, mlAccountId
, mlCreateTimeMs
, mlLabel
-- ** DateTime
, DateTime
, dateTime
, dtSecond
, dtDay
, dtYear
, dtHour
, dtMonth
, dtMinute
, dtTimeZoneId
-- ** DealTermsGuaranteedFixedPriceTerms
, DealTermsGuaranteedFixedPriceTerms
, dealTermsGuaranteedFixedPriceTerms
, dtgfptGuaranteedLooks
, dtgfptGuaranteedImpressions
, dtgfptFixedPrices
-- ** MarketplaceOrder
, MarketplaceOrder
, marketplaceOrder
, mBuyerPrivateData
, mIsSetupComplete
, mBuyerContacts
, mKind
, mOriginatorRole
, mRevisionNumber
, mBilledBuyer
, mIsRenegotiating
, mHasSellerSignedOff
, mSeller
, mOrderState
, mName
, mSellerContacts
, mLastUpdaterRole
, mLabels
, mRevisionTimeMs
, mOrderId
, mLastUpdaterOrCommentorRole
, mHasBuyerSignedOff
, mBuyer
-- ** AddOrderDealsRequest
, AddOrderDealsRequest
, addOrderDealsRequest
, aUpdateAction
, aDeals
, aOrderRevisionNumber
-- ** DealTerms
, DealTerms
, dealTerms
, dtNonGuaranteedFixedPriceTerms
, dtNonGuaranteedAuctionTerms
, dtGuaranteedFixedPriceTerms
, dtDescription
-- ** EditHistoryDto
, EditHistoryDto
, editHistoryDto
, ehdLastUpdatedByLoginName
, ehdCreatedByLoginName
, ehdLastUpdateTimeStamp
, ehdCreatedTimeStamp
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
import Network.Google.Resource.AdExchangeBuyer.Accounts.Get
import Network.Google.Resource.AdExchangeBuyer.Accounts.List
import Network.Google.Resource.AdExchangeBuyer.Accounts.Patch
import Network.Google.Resource.AdExchangeBuyer.Accounts.Update
import Network.Google.Resource.AdExchangeBuyer.BillingInfo.Get
import Network.Google.Resource.AdExchangeBuyer.BillingInfo.List
import Network.Google.Resource.AdExchangeBuyer.Budget.Get
import Network.Google.Resource.AdExchangeBuyer.Budget.Patch
import Network.Google.Resource.AdExchangeBuyer.Budget.Update
import Network.Google.Resource.AdExchangeBuyer.Clientaccess.Delete
import Network.Google.Resource.AdExchangeBuyer.Clientaccess.Get
import Network.Google.Resource.AdExchangeBuyer.Clientaccess.Insert
import Network.Google.Resource.AdExchangeBuyer.Clientaccess.List
import Network.Google.Resource.AdExchangeBuyer.Clientaccess.Patch
import Network.Google.Resource.AdExchangeBuyer.Clientaccess.Update
import Network.Google.Resource.AdExchangeBuyer.Creatives.Get
import Network.Google.Resource.AdExchangeBuyer.Creatives.Insert
import Network.Google.Resource.AdExchangeBuyer.Creatives.List
import Network.Google.Resource.AdExchangeBuyer.Deals.Get
import Network.Google.Resource.AdExchangeBuyer.Marketplacedeals.Delete
import Network.Google.Resource.AdExchangeBuyer.Marketplacedeals.Insert
import Network.Google.Resource.AdExchangeBuyer.Marketplacedeals.List
import Network.Google.Resource.AdExchangeBuyer.Marketplacedeals.Update
import Network.Google.Resource.AdExchangeBuyer.Marketplacenotes.Insert
import Network.Google.Resource.AdExchangeBuyer.Marketplacenotes.List
import Network.Google.Resource.AdExchangeBuyer.Marketplaceoffers.Get
import Network.Google.Resource.AdExchangeBuyer.Marketplaceoffers.Search
import Network.Google.Resource.AdExchangeBuyer.Marketplaceorders.Get
import Network.Google.Resource.AdExchangeBuyer.Marketplaceorders.Insert
import Network.Google.Resource.AdExchangeBuyer.Marketplaceorders.Patch
import Network.Google.Resource.AdExchangeBuyer.Marketplaceorders.Search
import Network.Google.Resource.AdExchangeBuyer.Marketplaceorders.Update
import Network.Google.Resource.AdExchangeBuyer.Negotiationrounds.Insert
import Network.Google.Resource.AdExchangeBuyer.Negotiations.Get
import Network.Google.Resource.AdExchangeBuyer.Negotiations.Insert
import Network.Google.Resource.AdExchangeBuyer.Negotiations.List
import Network.Google.Resource.AdExchangeBuyer.Offers.Get
import Network.Google.Resource.AdExchangeBuyer.Offers.Insert
import Network.Google.Resource.AdExchangeBuyer.Offers.List
import Network.Google.Resource.AdExchangeBuyer.PerformanceReport.List
import Network.Google.Resource.AdExchangeBuyer.PretargetingConfig.Delete
import Network.Google.Resource.AdExchangeBuyer.PretargetingConfig.Get
import Network.Google.Resource.AdExchangeBuyer.PretargetingConfig.Insert
import Network.Google.Resource.AdExchangeBuyer.PretargetingConfig.List
import Network.Google.Resource.AdExchangeBuyer.PretargetingConfig.Patch
import Network.Google.Resource.AdExchangeBuyer.PretargetingConfig.Update
{- $resources
TODO
-}
type AdExchangeBuyerAPI =
Marketplacenotes :<|> Deals :<|> Negotiationrounds
:<|> Accounts
:<|> Budget
:<|> Creatives
:<|> PerformanceReport
:<|> Marketplaceoffers
:<|> PretargetingConfig
:<|> Marketplaceorders
:<|> Clientaccess
:<|> BillingInfo
:<|> Marketplacedeals
:<|> Negotiations
:<|> Offers
adExchangeBuyerAPI :: Proxy AdExchangeBuyerAPI
adExchangeBuyerAPI = Proxy

View File

@ -0,0 +1,746 @@
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE OverloadedStrings #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
-- |
-- Module : Network.Google.AdExchangeBuyer.Types
-- Copyright : (c) 2015 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)
--
module Network.Google.AdExchangeBuyer.Types
(
-- * Service URL
adExchangeBuyerURL
-- * BrandDto
, BrandDto
, brandDto
, bdAdvertiserId
, bdName
, bdId
-- * EditAllOrderDealsResponse
, EditAllOrderDealsResponse
, editAllOrderDealsResponse
, eaodrDeals
-- * MarketplaceNote
, MarketplaceNote
, marketplaceNote
, mnNote
, mnKind
, mnTimestampMs
, mnDealId
, mnNoteId
, mnCreatorRole
, mnOrderId
, mnOrderRevisionNumber
-- * TermsDto
, TermsDto
, termsDto
, tdFinalizeAutomatically
, tdBuyerBillingType
, tdTargetingAllAdSlots
, tdUrls
, tdEndDate
, tdCpm
, tdEstimatedSpend
, tdAdvertisers
, tdEstimatedImpressionsPerDay
, tdMonetizerType
, tdAudienceSegmentDescription
, tdCreativeReviewPolicy
, tdMinimumTrueLooks
, tdStartDate
, tdCreativeBlockingLevel
, tdSemiTransparent
, tdAudienceSegment
, tdDealPremium
, tdIsReservation
, tdAdSlots
, tdTermsAttributes
, tdInventorySegmentTargeting
, tdDescriptiveName
, tdMinimumSpendMicros
, tdTargetByDealId
, tdBillingTerms
, tdDescription
-- * CreativesList
, CreativesList
, creativesList
, clNextPageToken
, clKind
, clItems
-- * CreateOrdersResponse
, CreateOrdersResponse
, createOrdersResponse
, corOrders
-- * AddOrderNotesRequest
, AddOrderNotesRequest
, addOrderNotesRequest
, aonrNotes
-- * MarketplaceDealParty
, MarketplaceDealParty
, marketplaceDealParty
, mdpSeller
, mdpBuyer
-- * DealPartyDto
, DealPartyDto
, dealPartyDto
, dpdBuyerSellerRole
, dpdCustomerId
, dpdName
, dpdWebProperty
, dpdBuyer
-- * DeliveryControlFrequencyCap
, DeliveryControlFrequencyCap
, deliveryControlFrequencyCap
, dcfcMaxImpressions
, dcfcNumTimeUnits
, dcfcTimeUnitType
-- * GetNegotiationsResponse
, GetNegotiationsResponse
, getNegotiationsResponse
, gnrKind
, gnrNegotiations
-- * Budget
, Budget
, budget
, bCurrencyCode
, bKind
, bBudgetAmount
, bAccountId
, bId
, bBillingId
-- * GetFinalizedNegotiationByExternalDealIdRequest
, GetFinalizedNegotiationByExternalDealIdRequest
, getFinalizedNegotiationByExternalDealIdRequest
, gfnbedirIncludePrivateAuctions
-- * PrivateData
, PrivateData
, privateData
, pdReferencePayload
, pdReferenceId
-- * AdSize
, AdSize
, adSize
, asHeight
, asWidth
-- * RuleKeyValuePair
, RuleKeyValuePair
, ruleKeyValuePair
, rkvpKeyName
, rkvpValue
-- * GetOrdersResponse
, GetOrdersResponse
, getOrdersResponse
, gorOrders
-- * AccountsList
, AccountsList
, accountsList
, alKind
, alItems
-- * GetOrderNotesResponse
, GetOrderNotesResponse
, getOrderNotesResponse
, gonrNotes
-- * CreateOrdersRequest
, CreateOrdersRequest
, createOrdersRequest
, cWebPropertyCode
, cOrders
-- * PricePerBuyer
, PricePerBuyer
, pricePerBuyer
, ppbPrice
, ppbBuyer
-- * TargetingValueDayPartTargetingDayPart
, TargetingValueDayPartTargetingDayPart
, targetingValueDayPartTargetingDayPart
, tvdptdpEndHour
, tvdptdpStartHour
, tvdptdpStartMinute
, tvdptdpDayOfWeek
, tvdptdpEndMinute
-- * DeliveryControl
, DeliveryControl
, deliveryControl
, dcFrequencyCaps
, dcDeliveryRateType
-- * Creative
, Creative
, creative
, cAttribute
, cNativeAd
, cHeight
, cBuyerCreativeId
, cAdvertiserName
, cAgencyId
, cCorrections
, cProductCategories
, cKind
, cHTMLSnippet
, cAdvertiserId
, cRestrictedCategories
, cDealsStatus
, cWidth
, cClickThroughUrl
, cVendorType
, cAccountId
, cImpressionTrackingUrl
, cFilteringReasons
, cVersion
, cSensitiveCategories
, cVideoURL
, cApiUploadTimestamp
, cServingRestrictions
, cOpenAuctionStatus
-- * AddOrderDealsResponse
, AddOrderDealsResponse
, addOrderDealsResponse
, aodrDeals
, aodrOrderRevisionNumber
-- * PretargetingConfigList
, PretargetingConfigList
, pretargetingConfigList
, pclKind
, pclItems
-- * BuyerDto
, BuyerDto
, buyerDto
, buySponsorAccountId
, buyEnabledForInterestTargetingDeals
, buyCustomerId
, buyEnabledForPreferredDeals
, buyAccountId
, buyDisplayName
, buyId
-- * DealTermsNonGuaranteedFixedPriceTerms
, DealTermsNonGuaranteedFixedPriceTerms
, dealTermsNonGuaranteedFixedPriceTerms
, dtngfptFixedPrices
-- * AdSlotDto
, AdSlotDto
, adSlotDto
, asdWebPropertyId
, asdSize
, asdChannelCode
, asdChannelId
, asdName
, asdDescription
-- * PerformanceReport
, PerformanceReport
, performanceReport
, prFilteredBidRate
, prKind
, prLatency95thPercentile
, prCookieMatcherStatusRate
, prHostedMatchStatusRate
, prUnsuccessfulRequestRate
, prBidRequestRate
, prQuotaThrottledLimit
, prQuotaConfiguredLimit
, prSuccessfulRequestRate
, prLatency85thPercentile
, prCalloutStatusRate
, prLatency50thPercentile
, prBidRate
, prCreativeStatusRate
, prNoQuotaInRegion
, prRegion
, prInventoryMatchRate
, prPixelMatchResponses
, prTimestamp
, prPixelMatchRequests
, prOutOfQuota
-- * Account
, Account
, account
, aMaximumTotalQps
, aKind
, aCookieMatchingUrl
, aMaximumActiveCreatives
, aCookieMatchingNid
, aNumberActiveCreatives
, aId
, aBidderLocation
-- * Seller
, Seller
, seller
, sAccountId
, sSubAccountId
-- * DeleteOrderDealsRequest
, DeleteOrderDealsRequest
, deleteOrderDealsRequest
, dodrUpdateAction
, dodrDealIds
, dodrOrderRevisionNumber
-- * GetOrderDealsResponse
, GetOrderDealsResponse
, getOrderDealsResponse
, godrDeals
-- * ContactInformation
, ContactInformation
, contactInformation
, ciEmail
, ciName
-- * TargetingValueCreativeSize
, TargetingValueCreativeSize
, targetingValueCreativeSize
, tvcsSize
, tvcsCompanionSizes
, tvcsCreativeSizeType
-- * PretargetingConfig
, PretargetingConfig
, pretargetingConfig
, pcPlatforms
, pcMobileCarriers
, pcVendorTypes
, pcExcludedGeoCriteriaIds
, pcSupportedCreativeAttributes
, pcUserLists
, pcKind
, pcExcludedPlacements
, pcMobileDevices
, pcLanguages
, pcVerticals
, pcConfigId
, pcPlacements
, pcExcludedUserLists
, pcConfigName
, pcGeoCriteriaIds
, pcDimensions
, pcExcludedVerticals
, pcCreativeType
, pcIsActive
, pcExcludedContentLabels
, pcBillingId
, pcMobileOperatingSystemVersions
-- * PerformanceReportList
, PerformanceReportList
, performanceReportList
, prlKind
, prlPerformanceReport
-- * NegotiationDto
, NegotiationDto
, negotiationDto
, ndNegotiationState
, ndExternalDealId
, ndStatus
, ndDealType
, ndNegotiationRounds
, ndKind
, ndBilledBuyer
, ndBuyerEmailContacts
, ndStats
, ndSeller
, ndLabelNames
, ndOfferId
, ndNegotiationId
, ndSellerEmailContacts
, ndBuyer
-- * AudienceSegment
, AudienceSegment
, audienceSegment
, asNumCookies
, asName
, asId
, asDescription
-- * OfferDto
, OfferDto
, offerDto
, odCreator
, odStatus
, odOfferState
, odPointOfContact
, odTerms
, odKind
, odBilledBuyer
, odOpenToDealParties
, odEmailContacts
, odLabelNames
, odOfferId
, odClosedToDealParties
, odAnonymous
, odIsOpen
-- * TargetingValueSize
, TargetingValueSize
, targetingValueSize
, tvsHeight
, tvsWidth
-- * MarketplaceOffer
, MarketplaceOffer
, marketplaceOffer
, moState
, moWebPropertyCode
, moCreationTimeMs
, moTerms
, moLastUpdateTimeMs
, moKind
, moRevisionNumber
, moHasCreatorSignedOff
, moFlightStartTimeMs
, moSharedTargetings
, moSeller
, moSyndicationProduct
, moFlightEndTimeMs
, moName
, moCreatorContacts
, moOfferId
, moLabels
-- * GetNegotiationsRequest
, GetNegotiationsRequest
, getNegotiationsRequest
, gnrSinceTimestampMillis
, gnrFinalized
, gnrIncludePrivateAuctions
-- * BillingInfoList
, BillingInfoList
, billingInfoList
, bilKind
, bilItems
-- * AddOrderNotesResponse
, AddOrderNotesResponse
, addOrderNotesResponse
, aNotes
-- * MoneyDto
, MoneyDto
, moneyDto
, mdCurrencyCode
, mdMicros
-- * ListClientAccessCapabilitiesResponse
, ListClientAccessCapabilitiesResponse
, listClientAccessCapabilitiesResponse
, lcacrClientAccessPermissions
-- * GetNegotiationByIdRequest
, GetNegotiationByIdRequest
, getNegotiationByIdRequest
, gnbirIncludePrivateAuctions
-- * ListOffersResponse
, ListOffersResponse
, listOffersResponse
, lorKind
, lorOffers
-- * AdvertiserDto
, AdvertiserDto
, advertiserDto
, adStatus
, adBrands
, adName
, adId
-- * TargetingValue
, TargetingValue
, targetingValue
, tvCreativeSizeValue
, tvStringValue
, tvLongValue
, tvDayPartTargetingValue
-- * Price
, Price
, price
, pCurrencyCode
, pAmountMicros
-- * EditAllOrderDealsRequest
, EditAllOrderDealsRequest
, editAllOrderDealsRequest
, eUpdateAction
, eDeals
, eOrder
, eOrderRevisionNumber
-- * BillingInfo
, BillingInfo
, billingInfo
, biKind
, biAccountName
, biAccountId
, biBillingId
-- * WebPropertyDto
, WebPropertyDto
, webPropertyDto
, wpdEnabledForPreferredDeals
, wpdSyndicationProduct
, wpdName
, wpdPropertyCode
, wpdId
, wpdSiteUrls
, wpdAllowInterestTargetedAds
-- * TargetingValueDayPartTargeting
, TargetingValueDayPartTargeting
, targetingValueDayPartTargeting
, tvdptTimeZoneType
, tvdptDayParts
-- * ListOffersRequest
, ListOffersRequest
, listOffersRequest
, lorSinceTimestampMillis
-- * ListClientAccessCapabilitiesRequest
, ListClientAccessCapabilitiesRequest
, listClientAccessCapabilitiesRequest
, lcacrSponsorAccountId
-- * InventorySegmentTargeting
, InventorySegmentTargeting
, inventorySegmentTargeting
, istNegativeVideoDurationSegments
, istNegativeIcmBrands
, istNegativeKeyValues
, istPositiveAudienceSegments
, istPositiveXfpPlacements
, istNegativeXfpAdSlots
, istPositiveOperatingSystemVersions
, istPositiveSizes
, istPositiveDeviceCategories
, istPositiveLocations
, istNegativeAdSizes
, istPositiveOperatingSystems
, istPositiveSiteUrls
, istNegativeInventorySlots
, istNegativeVideoAdPositionSegments
, istPositiveAdTypeSegments
, istPositiveIcmInterests
, istPositiveMobileApps
, istPositiveKeyValues
, istPositiveIcmBrands
, istPositiveVideoDurationSegments
, istNegativeAudienceSegments
, istNegativeXfpPlacements
, istPositiveXfpAdSlots
, istNegativeOperatingSystemVersions
, istNegativeSizes
, istNegativeLocations
, istNegativeDeviceCategories
, istNegativeOperatingSystems
, istPositiveAdSizes
, istNegativeSiteUrls
, istNegativeAdTypeSegments
, istPositiveVideoAdPositionSegments
, istPositiveInventorySlots
, istNegativeMobileApps
, istNegativeIcmInterests
-- * SharedTargeting
, SharedTargeting
, sharedTargeting
, stKey
, stExclusions
, stInclusions
-- * ClientAccessCapabilities
, ClientAccessCapabilities
, clientAccessCapabilities
, cacClientAccountId
, cacCapabilities
-- * DeleteOrderDealsResponse
, DeleteOrderDealsResponse
, deleteOrderDealsResponse
, dDeals
, dOrderRevisionNumber
-- * MarketplaceDeal
, MarketplaceDeal
, marketplaceDeal
, mdExternalDealId
, mdBuyerPrivateData
, mdWebPropertyCode
, mdCreationTimeMs
, mdTerms
, mdOfferRevisionNumber
, mdLastUpdateTimeMs
, mdKind
, mdDeliveryControl
, mdFlightStartTimeMs
, mdSharedTargetings
, mdDealId
, mdInventoryDescription
, mdSyndicationProduct
, mdFlightEndTimeMs
, mdName
, mdSellerContacts
, mdOfferId
, mdOrderId
-- * NegotiationRoundDto
, NegotiationRoundDto
, negotiationRoundDto
, nrdTerms
, nrdKind
, nrdOriginatorRole
, nrdAction
, nrdDbmPartnerId
, nrdNotes
, nrdNegotiationId
, nrdEditHistory
, nrdRoundNumber
-- * StatsDto
, StatsDto
, statsDto
, sdBids
, sdSpend
, sdImpressions
, sdGoodBids
, sdRevenue
, sdRequests
-- * GetOffersResponse
, GetOffersResponse
, getOffersResponse
, gorOffers
-- * DealTermsNonGuaranteedAuctionTerms
, DealTermsNonGuaranteedAuctionTerms
, dealTermsNonGuaranteedAuctionTerms
, dtngatReservePricePerBuyers
, dtngatPrivateAuctionId
-- * Buyer
, Buyer
, buyer
, bbAccountId
-- * MarketplaceLabel
, MarketplaceLabel
, marketplaceLabel
, mlDeprecatedMarketplaceDealParty
, mlAccountId
, mlCreateTimeMs
, mlLabel
-- * DateTime
, DateTime
, dateTime
, dtSecond
, dtDay
, dtYear
, dtHour
, dtMonth
, dtMinute
, dtTimeZoneId
-- * DealTermsGuaranteedFixedPriceTerms
, DealTermsGuaranteedFixedPriceTerms
, dealTermsGuaranteedFixedPriceTerms
, dtgfptGuaranteedLooks
, dtgfptGuaranteedImpressions
, dtgfptFixedPrices
-- * MarketplaceOrder
, MarketplaceOrder
, marketplaceOrder
, mBuyerPrivateData
, mIsSetupComplete
, mBuyerContacts
, mKind
, mOriginatorRole
, mRevisionNumber
, mBilledBuyer
, mIsRenegotiating
, mHasSellerSignedOff
, mSeller
, mOrderState
, mName
, mSellerContacts
, mLastUpdaterRole
, mLabels
, mRevisionTimeMs
, mOrderId
, mLastUpdaterOrCommentorRole
, mHasBuyerSignedOff
, mBuyer
-- * AddOrderDealsRequest
, AddOrderDealsRequest
, addOrderDealsRequest
, aUpdateAction
, aDeals
, aOrderRevisionNumber
-- * DealTerms
, DealTerms
, dealTerms
, dtNonGuaranteedFixedPriceTerms
, dtNonGuaranteedAuctionTerms
, dtGuaranteedFixedPriceTerms
, dtDescription
-- * EditHistoryDto
, EditHistoryDto
, editHistoryDto
, ehdLastUpdatedByLoginName
, ehdCreatedByLoginName
, ehdLastUpdateTimeStamp
, ehdCreatedTimeStamp
) where
import Network.Google.AdExchangeBuyer.Types.Product
import Network.Google.AdExchangeBuyer.Types.Sum
import Network.Google.Prelude
-- | URL referring to version 'v1.4' of the Ad Exchange Buyer API.
adExchangeBuyerURL :: BaseURL
adExchangeBuyerURL
= BaseUrl Https
"https://www.googleapis.com/adexchangebuyer/v1.4/"
443

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,18 @@
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE OverloadedStrings #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
-- |
-- Module : Network.Google.AdExchangeBuyer.Types.Sum
-- Copyright : (c) 2015 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)
--
module Network.Google.AdExchangeBuyer.Types.Sum where
import Network.Google.Prelude

View File

@ -0,0 +1,150 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Accounts.Get
-- Copyright : (c) 2015 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)
--
-- | Gets one account by ID.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerAccountsGet@.
module AdExchangeBuyer.Accounts.Get
(
-- * REST Resource
AccountsGetAPI
-- * Creating a Request
, accountsGet
, AccountsGet
-- * Request Lenses
, agQuotaUser
, agPrettyPrint
, agUserIp
, agKey
, agId
, agOauthToken
, agFields
, agAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerAccountsGet@ which the
-- 'AccountsGet' request conforms to.
type AccountsGetAPI =
"accounts" :>
Capture "id" Int32 :> Get '[JSON] Account
-- | Gets one account by ID.
--
-- /See:/ 'accountsGet' smart constructor.
data AccountsGet = AccountsGet
{ _agQuotaUser :: !(Maybe Text)
, _agPrettyPrint :: !Bool
, _agUserIp :: !(Maybe Text)
, _agKey :: !(Maybe Text)
, _agId :: !Int32
, _agOauthToken :: !(Maybe Text)
, _agFields :: !(Maybe Text)
, _agAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'AccountsGet'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'agQuotaUser'
--
-- * 'agPrettyPrint'
--
-- * 'agUserIp'
--
-- * 'agKey'
--
-- * 'agId'
--
-- * 'agOauthToken'
--
-- * 'agFields'
--
-- * 'agAlt'
accountsGet
:: Int32 -- ^ 'id'
-> AccountsGet
accountsGet pAgId_ =
AccountsGet
{ _agQuotaUser = Nothing
, _agPrettyPrint = True
, _agUserIp = Nothing
, _agKey = Nothing
, _agId = pAgId_
, _agOauthToken = Nothing
, _agFields = Nothing
, _agAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
agQuotaUser :: Lens' AccountsGet' (Maybe Text)
agQuotaUser
= lens _agQuotaUser (\ s a -> s{_agQuotaUser = a})
-- | Returns response with indentations and line breaks.
agPrettyPrint :: Lens' AccountsGet' Bool
agPrettyPrint
= lens _agPrettyPrint
(\ s a -> s{_agPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
agUserIp :: Lens' AccountsGet' (Maybe Text)
agUserIp = lens _agUserIp (\ s a -> s{_agUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
agKey :: Lens' AccountsGet' (Maybe Text)
agKey = lens _agKey (\ s a -> s{_agKey = a})
-- | The account id
agId :: Lens' AccountsGet' Int32
agId = lens _agId (\ s a -> s{_agId = a})
-- | OAuth 2.0 token for the current user.
agOauthToken :: Lens' AccountsGet' (Maybe Text)
agOauthToken
= lens _agOauthToken (\ s a -> s{_agOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
agFields :: Lens' AccountsGet' (Maybe Text)
agFields = lens _agFields (\ s a -> s{_agFields = a})
-- | Data format for the response.
agAlt :: Lens' AccountsGet' Text
agAlt = lens _agAlt (\ s a -> s{_agAlt = a})
instance GoogleRequest AccountsGet' where
type Rs AccountsGet' = Account
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u AccountsGet{..}
= go _agQuotaUser _agPrettyPrint _agUserIp _agKey
_agId
_agOauthToken
_agFields
_agAlt
where go
= clientWithRoute (Proxy :: Proxy AccountsGetAPI) r u

View File

@ -0,0 +1,139 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Accounts.List
-- Copyright : (c) 2015 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)
--
-- | Retrieves the authenticated user\'s list of accounts.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerAccountsList@.
module AdExchangeBuyer.Accounts.List
(
-- * REST Resource
AccountsListAPI
-- * Creating a Request
, accountsList
, AccountsList
-- * Request Lenses
, alQuotaUser
, alPrettyPrint
, alUserIp
, alKey
, alOauthToken
, alFields
, alAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerAccountsList@ which the
-- 'AccountsList' request conforms to.
type AccountsListAPI =
"accounts" :> Get '[JSON] AccountsList
-- | Retrieves the authenticated user\'s list of accounts.
--
-- /See:/ 'accountsList' smart constructor.
data AccountsList = AccountsList
{ _alQuotaUser :: !(Maybe Text)
, _alPrettyPrint :: !Bool
, _alUserIp :: !(Maybe Text)
, _alKey :: !(Maybe Text)
, _alOauthToken :: !(Maybe Text)
, _alFields :: !(Maybe Text)
, _alAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'AccountsList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'alQuotaUser'
--
-- * 'alPrettyPrint'
--
-- * 'alUserIp'
--
-- * 'alKey'
--
-- * 'alOauthToken'
--
-- * 'alFields'
--
-- * 'alAlt'
accountsList
:: AccountsList
accountsList =
AccountsList
{ _alQuotaUser = Nothing
, _alPrettyPrint = True
, _alUserIp = Nothing
, _alKey = Nothing
, _alOauthToken = Nothing
, _alFields = Nothing
, _alAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
alQuotaUser :: Lens' AccountsList' (Maybe Text)
alQuotaUser
= lens _alQuotaUser (\ s a -> s{_alQuotaUser = a})
-- | Returns response with indentations and line breaks.
alPrettyPrint :: Lens' AccountsList' Bool
alPrettyPrint
= lens _alPrettyPrint
(\ s a -> s{_alPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
alUserIp :: Lens' AccountsList' (Maybe Text)
alUserIp = lens _alUserIp (\ s a -> s{_alUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
alKey :: Lens' AccountsList' (Maybe Text)
alKey = lens _alKey (\ s a -> s{_alKey = a})
-- | OAuth 2.0 token for the current user.
alOauthToken :: Lens' AccountsList' (Maybe Text)
alOauthToken
= lens _alOauthToken (\ s a -> s{_alOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
alFields :: Lens' AccountsList' (Maybe Text)
alFields = lens _alFields (\ s a -> s{_alFields = a})
-- | Data format for the response.
alAlt :: Lens' AccountsList' Text
alAlt = lens _alAlt (\ s a -> s{_alAlt = a})
instance GoogleRequest AccountsList' where
type Rs AccountsList' = AccountsList
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u AccountsList{..}
= go _alQuotaUser _alPrettyPrint _alUserIp _alKey
_alOauthToken
_alFields
_alAlt
where go
= clientWithRoute (Proxy :: Proxy AccountsListAPI) r
u

View File

@ -0,0 +1,151 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Accounts.Patch
-- Copyright : (c) 2015 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)
--
-- | Updates an existing account. This method supports patch semantics.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerAccountsPatch@.
module AdExchangeBuyer.Accounts.Patch
(
-- * REST Resource
AccountsPatchAPI
-- * Creating a Request
, accountsPatch
, AccountsPatch
-- * Request Lenses
, apQuotaUser
, apPrettyPrint
, apUserIp
, apKey
, apId
, apOauthToken
, apFields
, apAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerAccountsPatch@ which the
-- 'AccountsPatch' request conforms to.
type AccountsPatchAPI =
"accounts" :>
Capture "id" Int32 :> Patch '[JSON] Account
-- | Updates an existing account. This method supports patch semantics.
--
-- /See:/ 'accountsPatch' smart constructor.
data AccountsPatch = AccountsPatch
{ _apQuotaUser :: !(Maybe Text)
, _apPrettyPrint :: !Bool
, _apUserIp :: !(Maybe Text)
, _apKey :: !(Maybe Text)
, _apId :: !Int32
, _apOauthToken :: !(Maybe Text)
, _apFields :: !(Maybe Text)
, _apAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'AccountsPatch'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'apQuotaUser'
--
-- * 'apPrettyPrint'
--
-- * 'apUserIp'
--
-- * 'apKey'
--
-- * 'apId'
--
-- * 'apOauthToken'
--
-- * 'apFields'
--
-- * 'apAlt'
accountsPatch
:: Int32 -- ^ 'id'
-> AccountsPatch
accountsPatch pApId_ =
AccountsPatch
{ _apQuotaUser = Nothing
, _apPrettyPrint = True
, _apUserIp = Nothing
, _apKey = Nothing
, _apId = pApId_
, _apOauthToken = Nothing
, _apFields = Nothing
, _apAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
apQuotaUser :: Lens' AccountsPatch' (Maybe Text)
apQuotaUser
= lens _apQuotaUser (\ s a -> s{_apQuotaUser = a})
-- | Returns response with indentations and line breaks.
apPrettyPrint :: Lens' AccountsPatch' Bool
apPrettyPrint
= lens _apPrettyPrint
(\ s a -> s{_apPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
apUserIp :: Lens' AccountsPatch' (Maybe Text)
apUserIp = lens _apUserIp (\ s a -> s{_apUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
apKey :: Lens' AccountsPatch' (Maybe Text)
apKey = lens _apKey (\ s a -> s{_apKey = a})
-- | The account id
apId :: Lens' AccountsPatch' Int32
apId = lens _apId (\ s a -> s{_apId = a})
-- | OAuth 2.0 token for the current user.
apOauthToken :: Lens' AccountsPatch' (Maybe Text)
apOauthToken
= lens _apOauthToken (\ s a -> s{_apOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
apFields :: Lens' AccountsPatch' (Maybe Text)
apFields = lens _apFields (\ s a -> s{_apFields = a})
-- | Data format for the response.
apAlt :: Lens' AccountsPatch' Text
apAlt = lens _apAlt (\ s a -> s{_apAlt = a})
instance GoogleRequest AccountsPatch' where
type Rs AccountsPatch' = Account
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u AccountsPatch{..}
= go _apQuotaUser _apPrettyPrint _apUserIp _apKey
_apId
_apOauthToken
_apFields
_apAlt
where go
= clientWithRoute (Proxy :: Proxy AccountsPatchAPI) r
u

View File

@ -0,0 +1,152 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Accounts.Update
-- Copyright : (c) 2015 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)
--
-- | Updates an existing account.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerAccountsUpdate@.
module AdExchangeBuyer.Accounts.Update
(
-- * REST Resource
AccountsUpdateAPI
-- * Creating a Request
, accountsUpdate
, AccountsUpdate
-- * Request Lenses
, auQuotaUser
, auPrettyPrint
, auUserIp
, auKey
, auId
, auOauthToken
, auFields
, auAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerAccountsUpdate@ which the
-- 'AccountsUpdate' request conforms to.
type AccountsUpdateAPI =
"accounts" :>
Capture "id" Int32 :> Put '[JSON] Account
-- | Updates an existing account.
--
-- /See:/ 'accountsUpdate' smart constructor.
data AccountsUpdate = AccountsUpdate
{ _auQuotaUser :: !(Maybe Text)
, _auPrettyPrint :: !Bool
, _auUserIp :: !(Maybe Text)
, _auKey :: !(Maybe Text)
, _auId :: !Int32
, _auOauthToken :: !(Maybe Text)
, _auFields :: !(Maybe Text)
, _auAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'AccountsUpdate'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'auQuotaUser'
--
-- * 'auPrettyPrint'
--
-- * 'auUserIp'
--
-- * 'auKey'
--
-- * 'auId'
--
-- * 'auOauthToken'
--
-- * 'auFields'
--
-- * 'auAlt'
accountsUpdate
:: Int32 -- ^ 'id'
-> AccountsUpdate
accountsUpdate pAuId_ =
AccountsUpdate
{ _auQuotaUser = Nothing
, _auPrettyPrint = True
, _auUserIp = Nothing
, _auKey = Nothing
, _auId = pAuId_
, _auOauthToken = Nothing
, _auFields = Nothing
, _auAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
auQuotaUser :: Lens' AccountsUpdate' (Maybe Text)
auQuotaUser
= lens _auQuotaUser (\ s a -> s{_auQuotaUser = a})
-- | Returns response with indentations and line breaks.
auPrettyPrint :: Lens' AccountsUpdate' Bool
auPrettyPrint
= lens _auPrettyPrint
(\ s a -> s{_auPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
auUserIp :: Lens' AccountsUpdate' (Maybe Text)
auUserIp = lens _auUserIp (\ s a -> s{_auUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
auKey :: Lens' AccountsUpdate' (Maybe Text)
auKey = lens _auKey (\ s a -> s{_auKey = a})
-- | The account id
auId :: Lens' AccountsUpdate' Int32
auId = lens _auId (\ s a -> s{_auId = a})
-- | OAuth 2.0 token for the current user.
auOauthToken :: Lens' AccountsUpdate' (Maybe Text)
auOauthToken
= lens _auOauthToken (\ s a -> s{_auOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
auFields :: Lens' AccountsUpdate' (Maybe Text)
auFields = lens _auFields (\ s a -> s{_auFields = a})
-- | Data format for the response.
auAlt :: Lens' AccountsUpdate' Text
auAlt = lens _auAlt (\ s a -> s{_auAlt = a})
instance GoogleRequest AccountsUpdate' where
type Rs AccountsUpdate' = Account
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u AccountsUpdate{..}
= go _auQuotaUser _auPrettyPrint _auUserIp _auKey
_auId
_auOauthToken
_auFields
_auAlt
where go
= clientWithRoute (Proxy :: Proxy AccountsUpdateAPI)
r
u

View File

@ -0,0 +1,157 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.BillingInfo.Get
-- Copyright : (c) 2015 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)
--
-- | Returns the billing information for one account specified by account ID.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerBillingInfoGet@.
module AdExchangeBuyer.BillingInfo.Get
(
-- * REST Resource
BillingInfoGetAPI
-- * Creating a Request
, billingInfoGet
, BillingInfoGet
-- * Request Lenses
, bigQuotaUser
, bigPrettyPrint
, bigUserIp
, bigAccountId
, bigKey
, bigOauthToken
, bigFields
, bigAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerBillingInfoGet@ which the
-- 'BillingInfoGet' request conforms to.
type BillingInfoGetAPI =
"billinginfo" :>
Capture "accountId" Int32 :> Get '[JSON] BillingInfo
-- | Returns the billing information for one account specified by account ID.
--
-- /See:/ 'billingInfoGet' smart constructor.
data BillingInfoGet = BillingInfoGet
{ _bigQuotaUser :: !(Maybe Text)
, _bigPrettyPrint :: !Bool
, _bigUserIp :: !(Maybe Text)
, _bigAccountId :: !Int32
, _bigKey :: !(Maybe Text)
, _bigOauthToken :: !(Maybe Text)
, _bigFields :: !(Maybe Text)
, _bigAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'BillingInfoGet'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'bigQuotaUser'
--
-- * 'bigPrettyPrint'
--
-- * 'bigUserIp'
--
-- * 'bigAccountId'
--
-- * 'bigKey'
--
-- * 'bigOauthToken'
--
-- * 'bigFields'
--
-- * 'bigAlt'
billingInfoGet
:: Int32 -- ^ 'accountId'
-> BillingInfoGet
billingInfoGet pBigAccountId_ =
BillingInfoGet
{ _bigQuotaUser = Nothing
, _bigPrettyPrint = True
, _bigUserIp = Nothing
, _bigAccountId = pBigAccountId_
, _bigKey = Nothing
, _bigOauthToken = Nothing
, _bigFields = Nothing
, _bigAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
bigQuotaUser :: Lens' BillingInfoGet' (Maybe Text)
bigQuotaUser
= lens _bigQuotaUser (\ s a -> s{_bigQuotaUser = a})
-- | Returns response with indentations and line breaks.
bigPrettyPrint :: Lens' BillingInfoGet' Bool
bigPrettyPrint
= lens _bigPrettyPrint
(\ s a -> s{_bigPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
bigUserIp :: Lens' BillingInfoGet' (Maybe Text)
bigUserIp
= lens _bigUserIp (\ s a -> s{_bigUserIp = a})
-- | The account id.
bigAccountId :: Lens' BillingInfoGet' Int32
bigAccountId
= lens _bigAccountId (\ s a -> s{_bigAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
bigKey :: Lens' BillingInfoGet' (Maybe Text)
bigKey = lens _bigKey (\ s a -> s{_bigKey = a})
-- | OAuth 2.0 token for the current user.
bigOauthToken :: Lens' BillingInfoGet' (Maybe Text)
bigOauthToken
= lens _bigOauthToken
(\ s a -> s{_bigOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
bigFields :: Lens' BillingInfoGet' (Maybe Text)
bigFields
= lens _bigFields (\ s a -> s{_bigFields = a})
-- | Data format for the response.
bigAlt :: Lens' BillingInfoGet' Text
bigAlt = lens _bigAlt (\ s a -> s{_bigAlt = a})
instance GoogleRequest BillingInfoGet' where
type Rs BillingInfoGet' = BillingInfo
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u BillingInfoGet{..}
= go _bigQuotaUser _bigPrettyPrint _bigUserIp
_bigAccountId
_bigKey
_bigOauthToken
_bigFields
_bigAlt
where go
= clientWithRoute (Proxy :: Proxy BillingInfoGetAPI)
r
u

View File

@ -0,0 +1,145 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.BillingInfo.List
-- Copyright : (c) 2015 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)
--
-- | Retrieves a list of billing information for all accounts of the
-- authenticated user.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerBillingInfoList@.
module AdExchangeBuyer.BillingInfo.List
(
-- * REST Resource
BillingInfoListAPI
-- * Creating a Request
, billingInfoList
, BillingInfoList
-- * Request Lenses
, bilQuotaUser
, bilPrettyPrint
, bilUserIp
, bilKey
, bilOauthToken
, bilFields
, bilAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerBillingInfoList@ which the
-- 'BillingInfoList' request conforms to.
type BillingInfoListAPI =
"billinginfo" :> Get '[JSON] BillingInfoList
-- | Retrieves a list of billing information for all accounts of the
-- authenticated user.
--
-- /See:/ 'billingInfoList' smart constructor.
data BillingInfoList = BillingInfoList
{ _bilQuotaUser :: !(Maybe Text)
, _bilPrettyPrint :: !Bool
, _bilUserIp :: !(Maybe Text)
, _bilKey :: !(Maybe Text)
, _bilOauthToken :: !(Maybe Text)
, _bilFields :: !(Maybe Text)
, _bilAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'BillingInfoList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'bilQuotaUser'
--
-- * 'bilPrettyPrint'
--
-- * 'bilUserIp'
--
-- * 'bilKey'
--
-- * 'bilOauthToken'
--
-- * 'bilFields'
--
-- * 'bilAlt'
billingInfoList
:: BillingInfoList
billingInfoList =
BillingInfoList
{ _bilQuotaUser = Nothing
, _bilPrettyPrint = True
, _bilUserIp = Nothing
, _bilKey = Nothing
, _bilOauthToken = Nothing
, _bilFields = Nothing
, _bilAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
bilQuotaUser :: Lens' BillingInfoList' (Maybe Text)
bilQuotaUser
= lens _bilQuotaUser (\ s a -> s{_bilQuotaUser = a})
-- | Returns response with indentations and line breaks.
bilPrettyPrint :: Lens' BillingInfoList' Bool
bilPrettyPrint
= lens _bilPrettyPrint
(\ s a -> s{_bilPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
bilUserIp :: Lens' BillingInfoList' (Maybe Text)
bilUserIp
= lens _bilUserIp (\ s a -> s{_bilUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
bilKey :: Lens' BillingInfoList' (Maybe Text)
bilKey = lens _bilKey (\ s a -> s{_bilKey = a})
-- | OAuth 2.0 token for the current user.
bilOauthToken :: Lens' BillingInfoList' (Maybe Text)
bilOauthToken
= lens _bilOauthToken
(\ s a -> s{_bilOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
bilFields :: Lens' BillingInfoList' (Maybe Text)
bilFields
= lens _bilFields (\ s a -> s{_bilFields = a})
-- | Data format for the response.
bilAlt :: Lens' BillingInfoList' Text
bilAlt = lens _bilAlt (\ s a -> s{_bilAlt = a})
instance GoogleRequest BillingInfoList' where
type Rs BillingInfoList' = BillingInfoList
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u BillingInfoList{..}
= go _bilQuotaUser _bilPrettyPrint _bilUserIp _bilKey
_bilOauthToken
_bilFields
_bilAlt
where go
= clientWithRoute (Proxy :: Proxy BillingInfoListAPI)
r
u

View File

@ -0,0 +1,167 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Budget.Get
-- Copyright : (c) 2015 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)
--
-- | Returns the budget information for the adgroup specified by the
-- accountId and billingId.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerBudgetGet@.
module AdExchangeBuyer.Budget.Get
(
-- * REST Resource
BudgetGetAPI
-- * Creating a Request
, budgetGet
, BudgetGet
-- * Request Lenses
, bgQuotaUser
, bgPrettyPrint
, bgUserIp
, bgAccountId
, bgKey
, bgOauthToken
, bgBillingId
, bgFields
, bgAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerBudgetGet@ which the
-- 'BudgetGet' request conforms to.
type BudgetGetAPI =
"billinginfo" :>
Capture "accountId" Int64 :>
Capture "billingId" Int64 :> Get '[JSON] Budget
-- | Returns the budget information for the adgroup specified by the
-- accountId and billingId.
--
-- /See:/ 'budgetGet' smart constructor.
data BudgetGet = BudgetGet
{ _bgQuotaUser :: !(Maybe Text)
, _bgPrettyPrint :: !Bool
, _bgUserIp :: !(Maybe Text)
, _bgAccountId :: !Int64
, _bgKey :: !(Maybe Text)
, _bgOauthToken :: !(Maybe Text)
, _bgBillingId :: !Int64
, _bgFields :: !(Maybe Text)
, _bgAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'BudgetGet'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'bgQuotaUser'
--
-- * 'bgPrettyPrint'
--
-- * 'bgUserIp'
--
-- * 'bgAccountId'
--
-- * 'bgKey'
--
-- * 'bgOauthToken'
--
-- * 'bgBillingId'
--
-- * 'bgFields'
--
-- * 'bgAlt'
budgetGet
:: Int64 -- ^ 'accountId'
-> Int64 -- ^ 'billingId'
-> BudgetGet
budgetGet pBgAccountId_ pBgBillingId_ =
BudgetGet
{ _bgQuotaUser = Nothing
, _bgPrettyPrint = True
, _bgUserIp = Nothing
, _bgAccountId = pBgAccountId_
, _bgKey = Nothing
, _bgOauthToken = Nothing
, _bgBillingId = pBgBillingId_
, _bgFields = Nothing
, _bgAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
bgQuotaUser :: Lens' BudgetGet' (Maybe Text)
bgQuotaUser
= lens _bgQuotaUser (\ s a -> s{_bgQuotaUser = a})
-- | Returns response with indentations and line breaks.
bgPrettyPrint :: Lens' BudgetGet' Bool
bgPrettyPrint
= lens _bgPrettyPrint
(\ s a -> s{_bgPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
bgUserIp :: Lens' BudgetGet' (Maybe Text)
bgUserIp = lens _bgUserIp (\ s a -> s{_bgUserIp = a})
-- | The account id to get the budget information for.
bgAccountId :: Lens' BudgetGet' Int64
bgAccountId
= lens _bgAccountId (\ s a -> s{_bgAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
bgKey :: Lens' BudgetGet' (Maybe Text)
bgKey = lens _bgKey (\ s a -> s{_bgKey = a})
-- | OAuth 2.0 token for the current user.
bgOauthToken :: Lens' BudgetGet' (Maybe Text)
bgOauthToken
= lens _bgOauthToken (\ s a -> s{_bgOauthToken = a})
-- | The billing id to get the budget information for.
bgBillingId :: Lens' BudgetGet' Int64
bgBillingId
= lens _bgBillingId (\ s a -> s{_bgBillingId = a})
-- | Selector specifying which fields to include in a partial response.
bgFields :: Lens' BudgetGet' (Maybe Text)
bgFields = lens _bgFields (\ s a -> s{_bgFields = a})
-- | Data format for the response.
bgAlt :: Lens' BudgetGet' Text
bgAlt = lens _bgAlt (\ s a -> s{_bgAlt = a})
instance GoogleRequest BudgetGet' where
type Rs BudgetGet' = Budget
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u BudgetGet{..}
= go _bgQuotaUser _bgPrettyPrint _bgUserIp
_bgAccountId
_bgKey
_bgOauthToken
_bgBillingId
_bgFields
_bgAlt
where go
= clientWithRoute (Proxy :: Proxy BudgetGetAPI) r u

View File

@ -0,0 +1,169 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Budget.Patch
-- Copyright : (c) 2015 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)
--
-- | Updates the budget amount for the budget of the adgroup specified by the
-- accountId and billingId, with the budget amount in the request. This
-- method supports patch semantics.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerBudgetPatch@.
module AdExchangeBuyer.Budget.Patch
(
-- * REST Resource
BudgetPatchAPI
-- * Creating a Request
, budgetPatch
, BudgetPatch
-- * Request Lenses
, bpQuotaUser
, bpPrettyPrint
, bpUserIp
, bpAccountId
, bpKey
, bpOauthToken
, bpBillingId
, bpFields
, bpAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerBudgetPatch@ which the
-- 'BudgetPatch' request conforms to.
type BudgetPatchAPI =
"billinginfo" :>
Capture "accountId" Int64 :>
Capture "billingId" Int64 :> Patch '[JSON] Budget
-- | Updates the budget amount for the budget of the adgroup specified by the
-- accountId and billingId, with the budget amount in the request. This
-- method supports patch semantics.
--
-- /See:/ 'budgetPatch' smart constructor.
data BudgetPatch = BudgetPatch
{ _bpQuotaUser :: !(Maybe Text)
, _bpPrettyPrint :: !Bool
, _bpUserIp :: !(Maybe Text)
, _bpAccountId :: !Int64
, _bpKey :: !(Maybe Text)
, _bpOauthToken :: !(Maybe Text)
, _bpBillingId :: !Int64
, _bpFields :: !(Maybe Text)
, _bpAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'BudgetPatch'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'bpQuotaUser'
--
-- * 'bpPrettyPrint'
--
-- * 'bpUserIp'
--
-- * 'bpAccountId'
--
-- * 'bpKey'
--
-- * 'bpOauthToken'
--
-- * 'bpBillingId'
--
-- * 'bpFields'
--
-- * 'bpAlt'
budgetPatch
:: Int64 -- ^ 'accountId'
-> Int64 -- ^ 'billingId'
-> BudgetPatch
budgetPatch pBpAccountId_ pBpBillingId_ =
BudgetPatch
{ _bpQuotaUser = Nothing
, _bpPrettyPrint = True
, _bpUserIp = Nothing
, _bpAccountId = pBpAccountId_
, _bpKey = Nothing
, _bpOauthToken = Nothing
, _bpBillingId = pBpBillingId_
, _bpFields = Nothing
, _bpAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
bpQuotaUser :: Lens' BudgetPatch' (Maybe Text)
bpQuotaUser
= lens _bpQuotaUser (\ s a -> s{_bpQuotaUser = a})
-- | Returns response with indentations and line breaks.
bpPrettyPrint :: Lens' BudgetPatch' Bool
bpPrettyPrint
= lens _bpPrettyPrint
(\ s a -> s{_bpPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
bpUserIp :: Lens' BudgetPatch' (Maybe Text)
bpUserIp = lens _bpUserIp (\ s a -> s{_bpUserIp = a})
-- | The account id associated with the budget being updated.
bpAccountId :: Lens' BudgetPatch' Int64
bpAccountId
= lens _bpAccountId (\ s a -> s{_bpAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
bpKey :: Lens' BudgetPatch' (Maybe Text)
bpKey = lens _bpKey (\ s a -> s{_bpKey = a})
-- | OAuth 2.0 token for the current user.
bpOauthToken :: Lens' BudgetPatch' (Maybe Text)
bpOauthToken
= lens _bpOauthToken (\ s a -> s{_bpOauthToken = a})
-- | The billing id associated with the budget being updated.
bpBillingId :: Lens' BudgetPatch' Int64
bpBillingId
= lens _bpBillingId (\ s a -> s{_bpBillingId = a})
-- | Selector specifying which fields to include in a partial response.
bpFields :: Lens' BudgetPatch' (Maybe Text)
bpFields = lens _bpFields (\ s a -> s{_bpFields = a})
-- | Data format for the response.
bpAlt :: Lens' BudgetPatch' Text
bpAlt = lens _bpAlt (\ s a -> s{_bpAlt = a})
instance GoogleRequest BudgetPatch' where
type Rs BudgetPatch' = Budget
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u BudgetPatch{..}
= go _bpQuotaUser _bpPrettyPrint _bpUserIp
_bpAccountId
_bpKey
_bpOauthToken
_bpBillingId
_bpFields
_bpAlt
where go
= clientWithRoute (Proxy :: Proxy BudgetPatchAPI) r u

View File

@ -0,0 +1,168 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Budget.Update
-- Copyright : (c) 2015 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)
--
-- | Updates the budget amount for the budget of the adgroup specified by the
-- accountId and billingId, with the budget amount in the request.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerBudgetUpdate@.
module AdExchangeBuyer.Budget.Update
(
-- * REST Resource
BudgetUpdateAPI
-- * Creating a Request
, budgetUpdate
, BudgetUpdate
-- * Request Lenses
, buQuotaUser
, buPrettyPrint
, buUserIp
, buAccountId
, buKey
, buOauthToken
, buBillingId
, buFields
, buAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerBudgetUpdate@ which the
-- 'BudgetUpdate' request conforms to.
type BudgetUpdateAPI =
"billinginfo" :>
Capture "accountId" Int64 :>
Capture "billingId" Int64 :> Put '[JSON] Budget
-- | Updates the budget amount for the budget of the adgroup specified by the
-- accountId and billingId, with the budget amount in the request.
--
-- /See:/ 'budgetUpdate' smart constructor.
data BudgetUpdate = BudgetUpdate
{ _buQuotaUser :: !(Maybe Text)
, _buPrettyPrint :: !Bool
, _buUserIp :: !(Maybe Text)
, _buAccountId :: !Int64
, _buKey :: !(Maybe Text)
, _buOauthToken :: !(Maybe Text)
, _buBillingId :: !Int64
, _buFields :: !(Maybe Text)
, _buAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'BudgetUpdate'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'buQuotaUser'
--
-- * 'buPrettyPrint'
--
-- * 'buUserIp'
--
-- * 'buAccountId'
--
-- * 'buKey'
--
-- * 'buOauthToken'
--
-- * 'buBillingId'
--
-- * 'buFields'
--
-- * 'buAlt'
budgetUpdate
:: Int64 -- ^ 'accountId'
-> Int64 -- ^ 'billingId'
-> BudgetUpdate
budgetUpdate pBuAccountId_ pBuBillingId_ =
BudgetUpdate
{ _buQuotaUser = Nothing
, _buPrettyPrint = True
, _buUserIp = Nothing
, _buAccountId = pBuAccountId_
, _buKey = Nothing
, _buOauthToken = Nothing
, _buBillingId = pBuBillingId_
, _buFields = Nothing
, _buAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
buQuotaUser :: Lens' BudgetUpdate' (Maybe Text)
buQuotaUser
= lens _buQuotaUser (\ s a -> s{_buQuotaUser = a})
-- | Returns response with indentations and line breaks.
buPrettyPrint :: Lens' BudgetUpdate' Bool
buPrettyPrint
= lens _buPrettyPrint
(\ s a -> s{_buPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
buUserIp :: Lens' BudgetUpdate' (Maybe Text)
buUserIp = lens _buUserIp (\ s a -> s{_buUserIp = a})
-- | The account id associated with the budget being updated.
buAccountId :: Lens' BudgetUpdate' Int64
buAccountId
= lens _buAccountId (\ s a -> s{_buAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
buKey :: Lens' BudgetUpdate' (Maybe Text)
buKey = lens _buKey (\ s a -> s{_buKey = a})
-- | OAuth 2.0 token for the current user.
buOauthToken :: Lens' BudgetUpdate' (Maybe Text)
buOauthToken
= lens _buOauthToken (\ s a -> s{_buOauthToken = a})
-- | The billing id associated with the budget being updated.
buBillingId :: Lens' BudgetUpdate' Int64
buBillingId
= lens _buBillingId (\ s a -> s{_buBillingId = a})
-- | Selector specifying which fields to include in a partial response.
buFields :: Lens' BudgetUpdate' (Maybe Text)
buFields = lens _buFields (\ s a -> s{_buFields = a})
-- | Data format for the response.
buAlt :: Lens' BudgetUpdate' Text
buAlt = lens _buAlt (\ s a -> s{_buAlt = a})
instance GoogleRequest BudgetUpdate' where
type Rs BudgetUpdate' = Budget
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u BudgetUpdate{..}
= go _buQuotaUser _buPrettyPrint _buUserIp
_buAccountId
_buKey
_buOauthToken
_buBillingId
_buFields
_buAlt
where go
= clientWithRoute (Proxy :: Proxy BudgetUpdateAPI) r
u

View File

@ -0,0 +1,168 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Clientaccess.Delete
-- Copyright : (c) 2015 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)
--
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerClientaccessDelete@.
module AdExchangeBuyer.Clientaccess.Delete
(
-- * REST Resource
ClientaccessDeleteAPI
-- * Creating a Request
, clientaccessDelete
, ClientaccessDelete
-- * Request Lenses
, cdQuotaUser
, cdPrettyPrint
, cdUserIp
, cdSponsorAccountId
, cdKey
, cdClientAccountId
, cdOauthToken
, cdFields
, cdAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerClientaccessDelete@ which the
-- 'ClientaccessDelete' request conforms to.
type ClientaccessDeleteAPI =
"clientAccess" :>
Capture "clientAccountId" Int64 :>
QueryParam "sponsorAccountId" Int32 :>
Delete '[JSON] ()
--
-- /See:/ 'clientaccessDelete' smart constructor.
data ClientaccessDelete = ClientaccessDelete
{ _cdQuotaUser :: !(Maybe Text)
, _cdPrettyPrint :: !Bool
, _cdUserIp :: !(Maybe Text)
, _cdSponsorAccountId :: !Int32
, _cdKey :: !(Maybe Text)
, _cdClientAccountId :: !Int64
, _cdOauthToken :: !(Maybe Text)
, _cdFields :: !(Maybe Text)
, _cdAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'ClientaccessDelete'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'cdQuotaUser'
--
-- * 'cdPrettyPrint'
--
-- * 'cdUserIp'
--
-- * 'cdSponsorAccountId'
--
-- * 'cdKey'
--
-- * 'cdClientAccountId'
--
-- * 'cdOauthToken'
--
-- * 'cdFields'
--
-- * 'cdAlt'
clientaccessDelete
:: Int32 -- ^ 'sponsorAccountId'
-> Int64 -- ^ 'clientAccountId'
-> ClientaccessDelete
clientaccessDelete pCdSponsorAccountId_ pCdClientAccountId_ =
ClientaccessDelete
{ _cdQuotaUser = Nothing
, _cdPrettyPrint = True
, _cdUserIp = Nothing
, _cdSponsorAccountId = pCdSponsorAccountId_
, _cdKey = Nothing
, _cdClientAccountId = pCdClientAccountId_
, _cdOauthToken = Nothing
, _cdFields = Nothing
, _cdAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
cdQuotaUser :: Lens' ClientaccessDelete' (Maybe Text)
cdQuotaUser
= lens _cdQuotaUser (\ s a -> s{_cdQuotaUser = a})
-- | Returns response with indentations and line breaks.
cdPrettyPrint :: Lens' ClientaccessDelete' Bool
cdPrettyPrint
= lens _cdPrettyPrint
(\ s a -> s{_cdPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
cdUserIp :: Lens' ClientaccessDelete' (Maybe Text)
cdUserIp = lens _cdUserIp (\ s a -> s{_cdUserIp = a})
cdSponsorAccountId :: Lens' ClientaccessDelete' Int32
cdSponsorAccountId
= lens _cdSponsorAccountId
(\ s a -> s{_cdSponsorAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
cdKey :: Lens' ClientaccessDelete' (Maybe Text)
cdKey = lens _cdKey (\ s a -> s{_cdKey = a})
cdClientAccountId :: Lens' ClientaccessDelete' Int64
cdClientAccountId
= lens _cdClientAccountId
(\ s a -> s{_cdClientAccountId = a})
-- | OAuth 2.0 token for the current user.
cdOauthToken :: Lens' ClientaccessDelete' (Maybe Text)
cdOauthToken
= lens _cdOauthToken (\ s a -> s{_cdOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
cdFields :: Lens' ClientaccessDelete' (Maybe Text)
cdFields = lens _cdFields (\ s a -> s{_cdFields = a})
-- | Data format for the response.
cdAlt :: Lens' ClientaccessDelete' Text
cdAlt = lens _cdAlt (\ s a -> s{_cdAlt = a})
instance GoogleRequest ClientaccessDelete' where
type Rs ClientaccessDelete' = ()
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u ClientaccessDelete{..}
= go _cdQuotaUser _cdPrettyPrint _cdUserIp
(Just _cdSponsorAccountId)
_cdKey
_cdClientAccountId
_cdOauthToken
_cdFields
_cdAlt
where go
= clientWithRoute
(Proxy :: Proxy ClientaccessDeleteAPI)
r
u

View File

@ -0,0 +1,170 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Clientaccess.Get
-- Copyright : (c) 2015 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)
--
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerClientaccessGet@.
module AdExchangeBuyer.Clientaccess.Get
(
-- * REST Resource
ClientaccessGetAPI
-- * Creating a Request
, clientaccessGet
, ClientaccessGet
-- * Request Lenses
, cggQuotaUser
, cggPrettyPrint
, cggUserIp
, cggSponsorAccountId
, cggKey
, cggClientAccountId
, cggOauthToken
, cggFields
, cggAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerClientaccessGet@ which the
-- 'ClientaccessGet' request conforms to.
type ClientaccessGetAPI =
"clientAccess" :>
Capture "clientAccountId" Int64 :>
QueryParam "sponsorAccountId" Int32 :>
Get '[JSON] ClientAccessCapabilities
--
-- /See:/ 'clientaccessGet' smart constructor.
data ClientaccessGet = ClientaccessGet
{ _cggQuotaUser :: !(Maybe Text)
, _cggPrettyPrint :: !Bool
, _cggUserIp :: !(Maybe Text)
, _cggSponsorAccountId :: !Int32
, _cggKey :: !(Maybe Text)
, _cggClientAccountId :: !Int64
, _cggOauthToken :: !(Maybe Text)
, _cggFields :: !(Maybe Text)
, _cggAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'ClientaccessGet'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'cggQuotaUser'
--
-- * 'cggPrettyPrint'
--
-- * 'cggUserIp'
--
-- * 'cggSponsorAccountId'
--
-- * 'cggKey'
--
-- * 'cggClientAccountId'
--
-- * 'cggOauthToken'
--
-- * 'cggFields'
--
-- * 'cggAlt'
clientaccessGet
:: Int32 -- ^ 'sponsorAccountId'
-> Int64 -- ^ 'clientAccountId'
-> ClientaccessGet
clientaccessGet pCggSponsorAccountId_ pCggClientAccountId_ =
ClientaccessGet
{ _cggQuotaUser = Nothing
, _cggPrettyPrint = True
, _cggUserIp = Nothing
, _cggSponsorAccountId = pCggSponsorAccountId_
, _cggKey = Nothing
, _cggClientAccountId = pCggClientAccountId_
, _cggOauthToken = Nothing
, _cggFields = Nothing
, _cggAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
cggQuotaUser :: Lens' ClientaccessGet' (Maybe Text)
cggQuotaUser
= lens _cggQuotaUser (\ s a -> s{_cggQuotaUser = a})
-- | Returns response with indentations and line breaks.
cggPrettyPrint :: Lens' ClientaccessGet' Bool
cggPrettyPrint
= lens _cggPrettyPrint
(\ s a -> s{_cggPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
cggUserIp :: Lens' ClientaccessGet' (Maybe Text)
cggUserIp
= lens _cggUserIp (\ s a -> s{_cggUserIp = a})
cggSponsorAccountId :: Lens' ClientaccessGet' Int32
cggSponsorAccountId
= lens _cggSponsorAccountId
(\ s a -> s{_cggSponsorAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
cggKey :: Lens' ClientaccessGet' (Maybe Text)
cggKey = lens _cggKey (\ s a -> s{_cggKey = a})
cggClientAccountId :: Lens' ClientaccessGet' Int64
cggClientAccountId
= lens _cggClientAccountId
(\ s a -> s{_cggClientAccountId = a})
-- | OAuth 2.0 token for the current user.
cggOauthToken :: Lens' ClientaccessGet' (Maybe Text)
cggOauthToken
= lens _cggOauthToken
(\ s a -> s{_cggOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
cggFields :: Lens' ClientaccessGet' (Maybe Text)
cggFields
= lens _cggFields (\ s a -> s{_cggFields = a})
-- | Data format for the response.
cggAlt :: Lens' ClientaccessGet' Text
cggAlt = lens _cggAlt (\ s a -> s{_cggAlt = a})
instance GoogleRequest ClientaccessGet' where
type Rs ClientaccessGet' = ClientAccessCapabilities
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u ClientaccessGet{..}
= go _cggQuotaUser _cggPrettyPrint _cggUserIp
(Just _cggSponsorAccountId)
_cggKey
_cggClientAccountId
_cggOauthToken
_cggFields
_cggAlt
where go
= clientWithRoute (Proxy :: Proxy ClientaccessGetAPI)
r
u

View File

@ -0,0 +1,166 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Clientaccess.Insert
-- Copyright : (c) 2015 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)
--
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerClientaccessInsert@.
module AdExchangeBuyer.Clientaccess.Insert
(
-- * REST Resource
ClientaccessInsertAPI
-- * Creating a Request
, clientaccessInsert
, ClientaccessInsert
-- * Request Lenses
, cQuotaUser
, cPrettyPrint
, cUserIp
, cSponsorAccountId
, cKey
, cClientAccountId
, cOauthToken
, cFields
, cAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerClientaccessInsert@ which the
-- 'ClientaccessInsert' request conforms to.
type ClientaccessInsertAPI =
"clientAccess" :>
QueryParam "sponsorAccountId" Int32 :>
QueryParam "clientAccountId" Int64 :>
Post '[JSON] ClientAccessCapabilities
--
-- /See:/ 'clientaccessInsert' smart constructor.
data ClientaccessInsert = ClientaccessInsert
{ _cQuotaUser :: !(Maybe Text)
, _cPrettyPrint :: !Bool
, _cUserIp :: !(Maybe Text)
, _cSponsorAccountId :: !(Maybe Int32)
, _cKey :: !(Maybe Text)
, _cClientAccountId :: !(Maybe Int64)
, _cOauthToken :: !(Maybe Text)
, _cFields :: !(Maybe Text)
, _cAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'ClientaccessInsert'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'cQuotaUser'
--
-- * 'cPrettyPrint'
--
-- * 'cUserIp'
--
-- * 'cSponsorAccountId'
--
-- * 'cKey'
--
-- * 'cClientAccountId'
--
-- * 'cOauthToken'
--
-- * 'cFields'
--
-- * 'cAlt'
clientaccessInsert
:: ClientaccessInsert
clientaccessInsert =
ClientaccessInsert
{ _cQuotaUser = Nothing
, _cPrettyPrint = True
, _cUserIp = Nothing
, _cSponsorAccountId = Nothing
, _cKey = Nothing
, _cClientAccountId = Nothing
, _cOauthToken = Nothing
, _cFields = Nothing
, _cAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
cQuotaUser :: Lens' ClientaccessInsert' (Maybe Text)
cQuotaUser
= lens _cQuotaUser (\ s a -> s{_cQuotaUser = a})
-- | Returns response with indentations and line breaks.
cPrettyPrint :: Lens' ClientaccessInsert' Bool
cPrettyPrint
= lens _cPrettyPrint (\ s a -> s{_cPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
cUserIp :: Lens' ClientaccessInsert' (Maybe Text)
cUserIp = lens _cUserIp (\ s a -> s{_cUserIp = a})
cSponsorAccountId :: Lens' ClientaccessInsert' (Maybe Int32)
cSponsorAccountId
= lens _cSponsorAccountId
(\ s a -> s{_cSponsorAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
cKey :: Lens' ClientaccessInsert' (Maybe Text)
cKey = lens _cKey (\ s a -> s{_cKey = a})
cClientAccountId :: Lens' ClientaccessInsert' (Maybe Int64)
cClientAccountId
= lens _cClientAccountId
(\ s a -> s{_cClientAccountId = a})
-- | OAuth 2.0 token for the current user.
cOauthToken :: Lens' ClientaccessInsert' (Maybe Text)
cOauthToken
= lens _cOauthToken (\ s a -> s{_cOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
cFields :: Lens' ClientaccessInsert' (Maybe Text)
cFields = lens _cFields (\ s a -> s{_cFields = a})
-- | Data format for the response.
cAlt :: Lens' ClientaccessInsert' Text
cAlt = lens _cAlt (\ s a -> s{_cAlt = a})
instance GoogleRequest ClientaccessInsert' where
type Rs ClientaccessInsert' =
ClientAccessCapabilities
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u ClientaccessInsert{..}
= go _cQuotaUser _cPrettyPrint _cUserIp
_cSponsorAccountId
_cKey
_cClientAccountId
_cOauthToken
_cFields
_cAlt
where go
= clientWithRoute
(Proxy :: Proxy ClientaccessInsertAPI)
r
u

View File

@ -0,0 +1,145 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Clientaccess.List
-- Copyright : (c) 2015 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)
--
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerClientaccessList@.
module AdExchangeBuyer.Clientaccess.List
(
-- * REST Resource
ClientaccessListAPI
-- * Creating a Request
, clientaccessList
, ClientaccessList
-- * Request Lenses
, cliQuotaUser
, cliPrettyPrint
, cliUserIp
, cliKey
, cliOauthToken
, cliFields
, cliAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerClientaccessList@ which the
-- 'ClientaccessList' request conforms to.
type ClientaccessListAPI =
"clientAccess" :>
Get '[JSON] ListClientAccessCapabilitiesResponse
--
-- /See:/ 'clientaccessList' smart constructor.
data ClientaccessList = ClientaccessList
{ _cliQuotaUser :: !(Maybe Text)
, _cliPrettyPrint :: !Bool
, _cliUserIp :: !(Maybe Text)
, _cliKey :: !(Maybe Text)
, _cliOauthToken :: !(Maybe Text)
, _cliFields :: !(Maybe Text)
, _cliAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'ClientaccessList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'cliQuotaUser'
--
-- * 'cliPrettyPrint'
--
-- * 'cliUserIp'
--
-- * 'cliKey'
--
-- * 'cliOauthToken'
--
-- * 'cliFields'
--
-- * 'cliAlt'
clientaccessList
:: ClientaccessList
clientaccessList =
ClientaccessList
{ _cliQuotaUser = Nothing
, _cliPrettyPrint = True
, _cliUserIp = Nothing
, _cliKey = Nothing
, _cliOauthToken = Nothing
, _cliFields = Nothing
, _cliAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
cliQuotaUser :: Lens' ClientaccessList' (Maybe Text)
cliQuotaUser
= lens _cliQuotaUser (\ s a -> s{_cliQuotaUser = a})
-- | Returns response with indentations and line breaks.
cliPrettyPrint :: Lens' ClientaccessList' Bool
cliPrettyPrint
= lens _cliPrettyPrint
(\ s a -> s{_cliPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
cliUserIp :: Lens' ClientaccessList' (Maybe Text)
cliUserIp
= lens _cliUserIp (\ s a -> s{_cliUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
cliKey :: Lens' ClientaccessList' (Maybe Text)
cliKey = lens _cliKey (\ s a -> s{_cliKey = a})
-- | OAuth 2.0 token for the current user.
cliOauthToken :: Lens' ClientaccessList' (Maybe Text)
cliOauthToken
= lens _cliOauthToken
(\ s a -> s{_cliOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
cliFields :: Lens' ClientaccessList' (Maybe Text)
cliFields
= lens _cliFields (\ s a -> s{_cliFields = a})
-- | Data format for the response.
cliAlt :: Lens' ClientaccessList' Text
cliAlt = lens _cliAlt (\ s a -> s{_cliAlt = a})
instance GoogleRequest ClientaccessList' where
type Rs ClientaccessList' =
ListClientAccessCapabilitiesResponse
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u ClientaccessList{..}
= go _cliQuotaUser _cliPrettyPrint _cliUserIp _cliKey
_cliOauthToken
_cliFields
_cliAlt
where go
= clientWithRoute
(Proxy :: Proxy ClientaccessListAPI)
r
u

View File

@ -0,0 +1,168 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Clientaccess.Patch
-- Copyright : (c) 2015 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)
--
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerClientaccessPatch@.
module AdExchangeBuyer.Clientaccess.Patch
(
-- * REST Resource
ClientaccessPatchAPI
-- * Creating a Request
, clientaccessPatch
, ClientaccessPatch
-- * Request Lenses
, cpQuotaUser
, cpPrettyPrint
, cpUserIp
, cpSponsorAccountId
, cpKey
, cpClientAccountId
, cpOauthToken
, cpFields
, cpAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerClientaccessPatch@ which the
-- 'ClientaccessPatch' request conforms to.
type ClientaccessPatchAPI =
"clientAccess" :>
Capture "clientAccountId" Int64 :>
QueryParam "sponsorAccountId" Int32 :>
Patch '[JSON] ClientAccessCapabilities
--
-- /See:/ 'clientaccessPatch' smart constructor.
data ClientaccessPatch = ClientaccessPatch
{ _cpQuotaUser :: !(Maybe Text)
, _cpPrettyPrint :: !Bool
, _cpUserIp :: !(Maybe Text)
, _cpSponsorAccountId :: !Int32
, _cpKey :: !(Maybe Text)
, _cpClientAccountId :: !Int64
, _cpOauthToken :: !(Maybe Text)
, _cpFields :: !(Maybe Text)
, _cpAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'ClientaccessPatch'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'cpQuotaUser'
--
-- * 'cpPrettyPrint'
--
-- * 'cpUserIp'
--
-- * 'cpSponsorAccountId'
--
-- * 'cpKey'
--
-- * 'cpClientAccountId'
--
-- * 'cpOauthToken'
--
-- * 'cpFields'
--
-- * 'cpAlt'
clientaccessPatch
:: Int32 -- ^ 'sponsorAccountId'
-> Int64 -- ^ 'clientAccountId'
-> ClientaccessPatch
clientaccessPatch pCpSponsorAccountId_ pCpClientAccountId_ =
ClientaccessPatch
{ _cpQuotaUser = Nothing
, _cpPrettyPrint = True
, _cpUserIp = Nothing
, _cpSponsorAccountId = pCpSponsorAccountId_
, _cpKey = Nothing
, _cpClientAccountId = pCpClientAccountId_
, _cpOauthToken = Nothing
, _cpFields = Nothing
, _cpAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
cpQuotaUser :: Lens' ClientaccessPatch' (Maybe Text)
cpQuotaUser
= lens _cpQuotaUser (\ s a -> s{_cpQuotaUser = a})
-- | Returns response with indentations and line breaks.
cpPrettyPrint :: Lens' ClientaccessPatch' Bool
cpPrettyPrint
= lens _cpPrettyPrint
(\ s a -> s{_cpPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
cpUserIp :: Lens' ClientaccessPatch' (Maybe Text)
cpUserIp = lens _cpUserIp (\ s a -> s{_cpUserIp = a})
cpSponsorAccountId :: Lens' ClientaccessPatch' Int32
cpSponsorAccountId
= lens _cpSponsorAccountId
(\ s a -> s{_cpSponsorAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
cpKey :: Lens' ClientaccessPatch' (Maybe Text)
cpKey = lens _cpKey (\ s a -> s{_cpKey = a})
cpClientAccountId :: Lens' ClientaccessPatch' Int64
cpClientAccountId
= lens _cpClientAccountId
(\ s a -> s{_cpClientAccountId = a})
-- | OAuth 2.0 token for the current user.
cpOauthToken :: Lens' ClientaccessPatch' (Maybe Text)
cpOauthToken
= lens _cpOauthToken (\ s a -> s{_cpOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
cpFields :: Lens' ClientaccessPatch' (Maybe Text)
cpFields = lens _cpFields (\ s a -> s{_cpFields = a})
-- | Data format for the response.
cpAlt :: Lens' ClientaccessPatch' Text
cpAlt = lens _cpAlt (\ s a -> s{_cpAlt = a})
instance GoogleRequest ClientaccessPatch' where
type Rs ClientaccessPatch' = ClientAccessCapabilities
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u ClientaccessPatch{..}
= go _cpQuotaUser _cpPrettyPrint _cpUserIp
(Just _cpSponsorAccountId)
_cpKey
_cpClientAccountId
_cpOauthToken
_cpFields
_cpAlt
where go
= clientWithRoute
(Proxy :: Proxy ClientaccessPatchAPI)
r
u

View File

@ -0,0 +1,169 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Clientaccess.Update
-- Copyright : (c) 2015 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)
--
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerClientaccessUpdate@.
module AdExchangeBuyer.Clientaccess.Update
(
-- * REST Resource
ClientaccessUpdateAPI
-- * Creating a Request
, clientaccessUpdate
, ClientaccessUpdate
-- * Request Lenses
, cuQuotaUser
, cuPrettyPrint
, cuUserIp
, cuSponsorAccountId
, cuKey
, cuClientAccountId
, cuOauthToken
, cuFields
, cuAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerClientaccessUpdate@ which the
-- 'ClientaccessUpdate' request conforms to.
type ClientaccessUpdateAPI =
"clientAccess" :>
Capture "clientAccountId" Int64 :>
QueryParam "sponsorAccountId" Int32 :>
Put '[JSON] ClientAccessCapabilities
--
-- /See:/ 'clientaccessUpdate' smart constructor.
data ClientaccessUpdate = ClientaccessUpdate
{ _cuQuotaUser :: !(Maybe Text)
, _cuPrettyPrint :: !Bool
, _cuUserIp :: !(Maybe Text)
, _cuSponsorAccountId :: !Int32
, _cuKey :: !(Maybe Text)
, _cuClientAccountId :: !Int64
, _cuOauthToken :: !(Maybe Text)
, _cuFields :: !(Maybe Text)
, _cuAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'ClientaccessUpdate'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'cuQuotaUser'
--
-- * 'cuPrettyPrint'
--
-- * 'cuUserIp'
--
-- * 'cuSponsorAccountId'
--
-- * 'cuKey'
--
-- * 'cuClientAccountId'
--
-- * 'cuOauthToken'
--
-- * 'cuFields'
--
-- * 'cuAlt'
clientaccessUpdate
:: Int32 -- ^ 'sponsorAccountId'
-> Int64 -- ^ 'clientAccountId'
-> ClientaccessUpdate
clientaccessUpdate pCuSponsorAccountId_ pCuClientAccountId_ =
ClientaccessUpdate
{ _cuQuotaUser = Nothing
, _cuPrettyPrint = True
, _cuUserIp = Nothing
, _cuSponsorAccountId = pCuSponsorAccountId_
, _cuKey = Nothing
, _cuClientAccountId = pCuClientAccountId_
, _cuOauthToken = Nothing
, _cuFields = Nothing
, _cuAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
cuQuotaUser :: Lens' ClientaccessUpdate' (Maybe Text)
cuQuotaUser
= lens _cuQuotaUser (\ s a -> s{_cuQuotaUser = a})
-- | Returns response with indentations and line breaks.
cuPrettyPrint :: Lens' ClientaccessUpdate' Bool
cuPrettyPrint
= lens _cuPrettyPrint
(\ s a -> s{_cuPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
cuUserIp :: Lens' ClientaccessUpdate' (Maybe Text)
cuUserIp = lens _cuUserIp (\ s a -> s{_cuUserIp = a})
cuSponsorAccountId :: Lens' ClientaccessUpdate' Int32
cuSponsorAccountId
= lens _cuSponsorAccountId
(\ s a -> s{_cuSponsorAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
cuKey :: Lens' ClientaccessUpdate' (Maybe Text)
cuKey = lens _cuKey (\ s a -> s{_cuKey = a})
cuClientAccountId :: Lens' ClientaccessUpdate' Int64
cuClientAccountId
= lens _cuClientAccountId
(\ s a -> s{_cuClientAccountId = a})
-- | OAuth 2.0 token for the current user.
cuOauthToken :: Lens' ClientaccessUpdate' (Maybe Text)
cuOauthToken
= lens _cuOauthToken (\ s a -> s{_cuOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
cuFields :: Lens' ClientaccessUpdate' (Maybe Text)
cuFields = lens _cuFields (\ s a -> s{_cuFields = a})
-- | Data format for the response.
cuAlt :: Lens' ClientaccessUpdate' Text
cuAlt = lens _cuAlt (\ s a -> s{_cuAlt = a})
instance GoogleRequest ClientaccessUpdate' where
type Rs ClientaccessUpdate' =
ClientAccessCapabilities
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u ClientaccessUpdate{..}
= go _cuQuotaUser _cuPrettyPrint _cuUserIp
(Just _cuSponsorAccountId)
_cuKey
_cuClientAccountId
_cuOauthToken
_cuFields
_cuAlt
where go
= clientWithRoute
(Proxy :: Proxy ClientaccessUpdateAPI)
r
u

View File

@ -0,0 +1,170 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Creatives.Get
-- Copyright : (c) 2015 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)
--
-- | Gets the status for a single creative. A creative will be available
-- 30-40 minutes after submission.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerCreativesGet@.
module AdExchangeBuyer.Creatives.Get
(
-- * REST Resource
CreativesGetAPI
-- * Creating a Request
, creativesGet
, CreativesGet
-- * Request Lenses
, cgQuotaUser
, cgPrettyPrint
, cgBuyerCreativeId
, cgUserIp
, cgAccountId
, cgKey
, cgOauthToken
, cgFields
, cgAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerCreativesGet@ which the
-- 'CreativesGet' request conforms to.
type CreativesGetAPI =
"creatives" :>
Capture "accountId" Int32 :>
Capture "buyerCreativeId" Text :>
Get '[JSON] Creative
-- | Gets the status for a single creative. A creative will be available
-- 30-40 minutes after submission.
--
-- /See:/ 'creativesGet' smart constructor.
data CreativesGet = CreativesGet
{ _cgQuotaUser :: !(Maybe Text)
, _cgPrettyPrint :: !Bool
, _cgBuyerCreativeId :: !Text
, _cgUserIp :: !(Maybe Text)
, _cgAccountId :: !Int32
, _cgKey :: !(Maybe Text)
, _cgOauthToken :: !(Maybe Text)
, _cgFields :: !(Maybe Text)
, _cgAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'CreativesGet'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'cgQuotaUser'
--
-- * 'cgPrettyPrint'
--
-- * 'cgBuyerCreativeId'
--
-- * 'cgUserIp'
--
-- * 'cgAccountId'
--
-- * 'cgKey'
--
-- * 'cgOauthToken'
--
-- * 'cgFields'
--
-- * 'cgAlt'
creativesGet
:: Text -- ^ 'buyerCreativeId'
-> Int32 -- ^ 'accountId'
-> CreativesGet
creativesGet pCgBuyerCreativeId_ pCgAccountId_ =
CreativesGet
{ _cgQuotaUser = Nothing
, _cgPrettyPrint = True
, _cgBuyerCreativeId = pCgBuyerCreativeId_
, _cgUserIp = Nothing
, _cgAccountId = pCgAccountId_
, _cgKey = Nothing
, _cgOauthToken = Nothing
, _cgFields = Nothing
, _cgAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
cgQuotaUser :: Lens' CreativesGet' (Maybe Text)
cgQuotaUser
= lens _cgQuotaUser (\ s a -> s{_cgQuotaUser = a})
-- | Returns response with indentations and line breaks.
cgPrettyPrint :: Lens' CreativesGet' Bool
cgPrettyPrint
= lens _cgPrettyPrint
(\ s a -> s{_cgPrettyPrint = a})
-- | The buyer-specific id for this creative.
cgBuyerCreativeId :: Lens' CreativesGet' Text
cgBuyerCreativeId
= lens _cgBuyerCreativeId
(\ s a -> s{_cgBuyerCreativeId = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
cgUserIp :: Lens' CreativesGet' (Maybe Text)
cgUserIp = lens _cgUserIp (\ s a -> s{_cgUserIp = a})
-- | The id for the account that will serve this creative.
cgAccountId :: Lens' CreativesGet' Int32
cgAccountId
= lens _cgAccountId (\ s a -> s{_cgAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
cgKey :: Lens' CreativesGet' (Maybe Text)
cgKey = lens _cgKey (\ s a -> s{_cgKey = a})
-- | OAuth 2.0 token for the current user.
cgOauthToken :: Lens' CreativesGet' (Maybe Text)
cgOauthToken
= lens _cgOauthToken (\ s a -> s{_cgOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
cgFields :: Lens' CreativesGet' (Maybe Text)
cgFields = lens _cgFields (\ s a -> s{_cgFields = a})
-- | Data format for the response.
cgAlt :: Lens' CreativesGet' Text
cgAlt = lens _cgAlt (\ s a -> s{_cgAlt = a})
instance GoogleRequest CreativesGet' where
type Rs CreativesGet' = Creative
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u CreativesGet{..}
= go _cgQuotaUser _cgPrettyPrint _cgBuyerCreativeId
_cgUserIp
_cgAccountId
_cgKey
_cgOauthToken
_cgFields
_cgAlt
where go
= clientWithRoute (Proxy :: Proxy CreativesGetAPI) r
u

View File

@ -0,0 +1,140 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Creatives.Insert
-- Copyright : (c) 2015 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)
--
-- | Submit a new creative.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerCreativesInsert@.
module AdExchangeBuyer.Creatives.Insert
(
-- * REST Resource
CreativesInsertAPI
-- * Creating a Request
, creativesInsert
, CreativesInsert
-- * Request Lenses
, ciQuotaUser
, ciPrettyPrint
, ciUserIp
, ciKey
, ciOauthToken
, ciFields
, ciAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerCreativesInsert@ which the
-- 'CreativesInsert' request conforms to.
type CreativesInsertAPI =
"creatives" :> Post '[JSON] Creative
-- | Submit a new creative.
--
-- /See:/ 'creativesInsert' smart constructor.
data CreativesInsert = CreativesInsert
{ _ciQuotaUser :: !(Maybe Text)
, _ciPrettyPrint :: !Bool
, _ciUserIp :: !(Maybe Text)
, _ciKey :: !(Maybe Text)
, _ciOauthToken :: !(Maybe Text)
, _ciFields :: !(Maybe Text)
, _ciAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'CreativesInsert'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'ciQuotaUser'
--
-- * 'ciPrettyPrint'
--
-- * 'ciUserIp'
--
-- * 'ciKey'
--
-- * 'ciOauthToken'
--
-- * 'ciFields'
--
-- * 'ciAlt'
creativesInsert
:: CreativesInsert
creativesInsert =
CreativesInsert
{ _ciQuotaUser = Nothing
, _ciPrettyPrint = True
, _ciUserIp = Nothing
, _ciKey = Nothing
, _ciOauthToken = Nothing
, _ciFields = Nothing
, _ciAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
ciQuotaUser :: Lens' CreativesInsert' (Maybe Text)
ciQuotaUser
= lens _ciQuotaUser (\ s a -> s{_ciQuotaUser = a})
-- | Returns response with indentations and line breaks.
ciPrettyPrint :: Lens' CreativesInsert' Bool
ciPrettyPrint
= lens _ciPrettyPrint
(\ s a -> s{_ciPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
ciUserIp :: Lens' CreativesInsert' (Maybe Text)
ciUserIp = lens _ciUserIp (\ s a -> s{_ciUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
ciKey :: Lens' CreativesInsert' (Maybe Text)
ciKey = lens _ciKey (\ s a -> s{_ciKey = a})
-- | OAuth 2.0 token for the current user.
ciOauthToken :: Lens' CreativesInsert' (Maybe Text)
ciOauthToken
= lens _ciOauthToken (\ s a -> s{_ciOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
ciFields :: Lens' CreativesInsert' (Maybe Text)
ciFields = lens _ciFields (\ s a -> s{_ciFields = a})
-- | Data format for the response.
ciAlt :: Lens' CreativesInsert' Text
ciAlt = lens _ciAlt (\ s a -> s{_ciAlt = a})
instance GoogleRequest CreativesInsert' where
type Rs CreativesInsert' = Creative
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u CreativesInsert{..}
= go _ciQuotaUser _ciPrettyPrint _ciUserIp _ciKey
_ciOauthToken
_ciFields
_ciAlt
where go
= clientWithRoute (Proxy :: Proxy CreativesInsertAPI)
r
u

View File

@ -0,0 +1,224 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Creatives.List
-- Copyright : (c) 2015 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)
--
-- | Retrieves a list of the authenticated user\'s active creatives. A
-- creative will be available 30-40 minutes after submission.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerCreativesList@.
module AdExchangeBuyer.Creatives.List
(
-- * REST Resource
CreativesListAPI
-- * Creating a Request
, creativesList
, CreativesList
-- * Request Lenses
, clQuotaUser
, clPrettyPrint
, clBuyerCreativeId
, clUserIp
, clOpenAuctionStatusFilter
, clAccountId
, clKey
, clPageToken
, clDealsStatusFilter
, clOauthToken
, clMaxResults
, clFields
, clAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerCreativesList@ which the
-- 'CreativesList' request conforms to.
type CreativesListAPI =
"creatives" :>
QueryParams "buyerCreativeId" Text :>
QueryParam "openAuctionStatusFilter" Text :>
QueryParams "accountId" Int32 :>
QueryParam "pageToken" Text :>
QueryParam "dealsStatusFilter" Text :>
QueryParam "maxResults" Word32 :>
Get '[JSON] CreativesList
-- | Retrieves a list of the authenticated user\'s active creatives. A
-- creative will be available 30-40 minutes after submission.
--
-- /See:/ 'creativesList' smart constructor.
data CreativesList = CreativesList
{ _clQuotaUser :: !(Maybe Text)
, _clPrettyPrint :: !Bool
, _clBuyerCreativeId :: !(Maybe Text)
, _clUserIp :: !(Maybe Text)
, _clOpenAuctionStatusFilter :: !(Maybe Text)
, _clAccountId :: !(Maybe Int32)
, _clKey :: !(Maybe Text)
, _clPageToken :: !(Maybe Text)
, _clDealsStatusFilter :: !(Maybe Text)
, _clOauthToken :: !(Maybe Text)
, _clMaxResults :: !(Maybe Word32)
, _clFields :: !(Maybe Text)
, _clAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'CreativesList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'clQuotaUser'
--
-- * 'clPrettyPrint'
--
-- * 'clBuyerCreativeId'
--
-- * 'clUserIp'
--
-- * 'clOpenAuctionStatusFilter'
--
-- * 'clAccountId'
--
-- * 'clKey'
--
-- * 'clPageToken'
--
-- * 'clDealsStatusFilter'
--
-- * 'clOauthToken'
--
-- * 'clMaxResults'
--
-- * 'clFields'
--
-- * 'clAlt'
creativesList
:: CreativesList
creativesList =
CreativesList
{ _clQuotaUser = Nothing
, _clPrettyPrint = True
, _clBuyerCreativeId = Nothing
, _clUserIp = Nothing
, _clOpenAuctionStatusFilter = Nothing
, _clAccountId = Nothing
, _clKey = Nothing
, _clPageToken = Nothing
, _clDealsStatusFilter = Nothing
, _clOauthToken = Nothing
, _clMaxResults = Nothing
, _clFields = Nothing
, _clAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
clQuotaUser :: Lens' CreativesList' (Maybe Text)
clQuotaUser
= lens _clQuotaUser (\ s a -> s{_clQuotaUser = a})
-- | Returns response with indentations and line breaks.
clPrettyPrint :: Lens' CreativesList' Bool
clPrettyPrint
= lens _clPrettyPrint
(\ s a -> s{_clPrettyPrint = a})
-- | When specified, only creatives for the given buyer creative ids are
-- returned.
clBuyerCreativeId :: Lens' CreativesList' (Maybe Text)
clBuyerCreativeId
= lens _clBuyerCreativeId
(\ s a -> s{_clBuyerCreativeId = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
clUserIp :: Lens' CreativesList' (Maybe Text)
clUserIp = lens _clUserIp (\ s a -> s{_clUserIp = a})
-- | When specified, only creatives having the given open auction status are
-- returned.
clOpenAuctionStatusFilter :: Lens' CreativesList' (Maybe Text)
clOpenAuctionStatusFilter
= lens _clOpenAuctionStatusFilter
(\ s a -> s{_clOpenAuctionStatusFilter = a})
-- | When specified, only creatives for the given account ids are returned.
clAccountId :: Lens' CreativesList' (Maybe Int32)
clAccountId
= lens _clAccountId (\ s a -> s{_clAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
clKey :: Lens' CreativesList' (Maybe Text)
clKey = lens _clKey (\ s a -> s{_clKey = a})
-- | A continuation token, used to page through ad clients. To retrieve the
-- next page, set this parameter to the value of \"nextPageToken\" from the
-- previous response. Optional.
clPageToken :: Lens' CreativesList' (Maybe Text)
clPageToken
= lens _clPageToken (\ s a -> s{_clPageToken = a})
-- | When specified, only creatives having the given direct deals status are
-- returned.
clDealsStatusFilter :: Lens' CreativesList' (Maybe Text)
clDealsStatusFilter
= lens _clDealsStatusFilter
(\ s a -> s{_clDealsStatusFilter = a})
-- | OAuth 2.0 token for the current user.
clOauthToken :: Lens' CreativesList' (Maybe Text)
clOauthToken
= lens _clOauthToken (\ s a -> s{_clOauthToken = a})
-- | Maximum number of entries returned on one result page. If not set, the
-- default is 100. Optional.
clMaxResults :: Lens' CreativesList' (Maybe Word32)
clMaxResults
= lens _clMaxResults (\ s a -> s{_clMaxResults = a})
-- | Selector specifying which fields to include in a partial response.
clFields :: Lens' CreativesList' (Maybe Text)
clFields = lens _clFields (\ s a -> s{_clFields = a})
-- | Data format for the response.
clAlt :: Lens' CreativesList' Text
clAlt = lens _clAlt (\ s a -> s{_clAlt = a})
instance GoogleRequest CreativesList' where
type Rs CreativesList' = CreativesList
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u CreativesList{..}
= go _clQuotaUser _clPrettyPrint _clBuyerCreativeId
_clUserIp
_clOpenAuctionStatusFilter
_clAccountId
_clKey
_clPageToken
_clDealsStatusFilter
_clOauthToken
_clMaxResults
_clFields
_clAlt
where go
= clientWithRoute (Proxy :: Proxy CreativesListAPI) r
u

View File

@ -0,0 +1,149 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Deals.Get
-- Copyright : (c) 2015 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)
--
-- | Gets the requested deal.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerDealsGet@.
module AdExchangeBuyer.Deals.Get
(
-- * REST Resource
DealsGetAPI
-- * Creating a Request
, dealsGet
, DealsGet
-- * Request Lenses
, dgQuotaUser
, dgPrettyPrint
, dgUserIp
, dgDealId
, dgKey
, dgOauthToken
, dgFields
, dgAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerDealsGet@ which the
-- 'DealsGet' request conforms to.
type DealsGetAPI =
"deals" :>
Capture "dealId" Int64 :> Get '[JSON] NegotiationDto
-- | Gets the requested deal.
--
-- /See:/ 'dealsGet' smart constructor.
data DealsGet = DealsGet
{ _dgQuotaUser :: !(Maybe Text)
, _dgPrettyPrint :: !Bool
, _dgUserIp :: !(Maybe Text)
, _dgDealId :: !Int64
, _dgKey :: !(Maybe Text)
, _dgOauthToken :: !(Maybe Text)
, _dgFields :: !(Maybe Text)
, _dgAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'DealsGet'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'dgQuotaUser'
--
-- * 'dgPrettyPrint'
--
-- * 'dgUserIp'
--
-- * 'dgDealId'
--
-- * 'dgKey'
--
-- * 'dgOauthToken'
--
-- * 'dgFields'
--
-- * 'dgAlt'
dealsGet
:: Int64 -- ^ 'dealId'
-> DealsGet
dealsGet pDgDealId_ =
DealsGet
{ _dgQuotaUser = Nothing
, _dgPrettyPrint = True
, _dgUserIp = Nothing
, _dgDealId = pDgDealId_
, _dgKey = Nothing
, _dgOauthToken = Nothing
, _dgFields = Nothing
, _dgAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
dgQuotaUser :: Lens' DealsGet' (Maybe Text)
dgQuotaUser
= lens _dgQuotaUser (\ s a -> s{_dgQuotaUser = a})
-- | Returns response with indentations and line breaks.
dgPrettyPrint :: Lens' DealsGet' Bool
dgPrettyPrint
= lens _dgPrettyPrint
(\ s a -> s{_dgPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
dgUserIp :: Lens' DealsGet' (Maybe Text)
dgUserIp = lens _dgUserIp (\ s a -> s{_dgUserIp = a})
dgDealId :: Lens' DealsGet' Int64
dgDealId = lens _dgDealId (\ s a -> s{_dgDealId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
dgKey :: Lens' DealsGet' (Maybe Text)
dgKey = lens _dgKey (\ s a -> s{_dgKey = a})
-- | OAuth 2.0 token for the current user.
dgOauthToken :: Lens' DealsGet' (Maybe Text)
dgOauthToken
= lens _dgOauthToken (\ s a -> s{_dgOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
dgFields :: Lens' DealsGet' (Maybe Text)
dgFields = lens _dgFields (\ s a -> s{_dgFields = a})
-- | Data format for the response.
dgAlt :: Lens' DealsGet' Text
dgAlt = lens _dgAlt (\ s a -> s{_dgAlt = a})
instance GoogleRequest DealsGet' where
type Rs DealsGet' = NegotiationDto
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u DealsGet{..}
= go _dgQuotaUser _dgPrettyPrint _dgUserIp _dgDealId
_dgKey
_dgOauthToken
_dgFields
_dgAlt
where go
= clientWithRoute (Proxy :: Proxy DealsGetAPI) r u

View File

@ -0,0 +1,160 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Marketplacedeals.Delete
-- Copyright : (c) 2015 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)
--
-- | Delete the specified deals from the order
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerMarketplacedealsDelete@.
module AdExchangeBuyer.Marketplacedeals.Delete
(
-- * REST Resource
MarketplacedealsDeleteAPI
-- * Creating a Request
, marketplacedealsDelete
, MarketplacedealsDelete
-- * Request Lenses
, mddQuotaUser
, mddPrettyPrint
, mddUserIp
, mddKey
, mddOauthToken
, mddOrderId
, mddFields
, mddAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerMarketplacedealsDelete@ which the
-- 'MarketplacedealsDelete' request conforms to.
type MarketplacedealsDeleteAPI =
"marketplaceOrders" :>
Capture "orderId" Text :>
"deals" :>
"delete" :> Post '[JSON] DeleteOrderDealsResponse
-- | Delete the specified deals from the order
--
-- /See:/ 'marketplacedealsDelete' smart constructor.
data MarketplacedealsDelete = MarketplacedealsDelete
{ _mddQuotaUser :: !(Maybe Text)
, _mddPrettyPrint :: !Bool
, _mddUserIp :: !(Maybe Text)
, _mddKey :: !(Maybe Text)
, _mddOauthToken :: !(Maybe Text)
, _mddOrderId :: !Text
, _mddFields :: !(Maybe Text)
, _mddAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'MarketplacedealsDelete'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'mddQuotaUser'
--
-- * 'mddPrettyPrint'
--
-- * 'mddUserIp'
--
-- * 'mddKey'
--
-- * 'mddOauthToken'
--
-- * 'mddOrderId'
--
-- * 'mddFields'
--
-- * 'mddAlt'
marketplacedealsDelete
:: Text -- ^ 'orderId'
-> MarketplacedealsDelete
marketplacedealsDelete pMddOrderId_ =
MarketplacedealsDelete
{ _mddQuotaUser = Nothing
, _mddPrettyPrint = True
, _mddUserIp = Nothing
, _mddKey = Nothing
, _mddOauthToken = Nothing
, _mddOrderId = pMddOrderId_
, _mddFields = Nothing
, _mddAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
mddQuotaUser :: Lens' MarketplacedealsDelete' (Maybe Text)
mddQuotaUser
= lens _mddQuotaUser (\ s a -> s{_mddQuotaUser = a})
-- | Returns response with indentations and line breaks.
mddPrettyPrint :: Lens' MarketplacedealsDelete' Bool
mddPrettyPrint
= lens _mddPrettyPrint
(\ s a -> s{_mddPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
mddUserIp :: Lens' MarketplacedealsDelete' (Maybe Text)
mddUserIp
= lens _mddUserIp (\ s a -> s{_mddUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
mddKey :: Lens' MarketplacedealsDelete' (Maybe Text)
mddKey = lens _mddKey (\ s a -> s{_mddKey = a})
-- | OAuth 2.0 token for the current user.
mddOauthToken :: Lens' MarketplacedealsDelete' (Maybe Text)
mddOauthToken
= lens _mddOauthToken
(\ s a -> s{_mddOauthToken = a})
-- | The orderId to delete deals from.
mddOrderId :: Lens' MarketplacedealsDelete' Text
mddOrderId
= lens _mddOrderId (\ s a -> s{_mddOrderId = a})
-- | Selector specifying which fields to include in a partial response.
mddFields :: Lens' MarketplacedealsDelete' (Maybe Text)
mddFields
= lens _mddFields (\ s a -> s{_mddFields = a})
-- | Data format for the response.
mddAlt :: Lens' MarketplacedealsDelete' Text
mddAlt = lens _mddAlt (\ s a -> s{_mddAlt = a})
instance GoogleRequest MarketplacedealsDelete' where
type Rs MarketplacedealsDelete' =
DeleteOrderDealsResponse
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u MarketplacedealsDelete{..}
= go _mddQuotaUser _mddPrettyPrint _mddUserIp _mddKey
_mddOauthToken
_mddOrderId
_mddFields
_mddAlt
where go
= clientWithRoute
(Proxy :: Proxy MarketplacedealsDeleteAPI)
r
u

View File

@ -0,0 +1,160 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Marketplacedeals.Insert
-- Copyright : (c) 2015 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)
--
-- | Add new deals for the specified order
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerMarketplacedealsInsert@.
module AdExchangeBuyer.Marketplacedeals.Insert
(
-- * REST Resource
MarketplacedealsInsertAPI
-- * Creating a Request
, marketplacedealsInsert
, MarketplacedealsInsert
-- * Request Lenses
, miiQuotaUser
, miiPrettyPrint
, miiUserIp
, miiKey
, miiOauthToken
, miiOrderId
, miiFields
, miiAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerMarketplacedealsInsert@ which the
-- 'MarketplacedealsInsert' request conforms to.
type MarketplacedealsInsertAPI =
"marketplaceOrders" :>
Capture "orderId" Text :>
"deals" :>
"insert" :> Post '[JSON] AddOrderDealsResponse
-- | Add new deals for the specified order
--
-- /See:/ 'marketplacedealsInsert' smart constructor.
data MarketplacedealsInsert = MarketplacedealsInsert
{ _miiQuotaUser :: !(Maybe Text)
, _miiPrettyPrint :: !Bool
, _miiUserIp :: !(Maybe Text)
, _miiKey :: !(Maybe Text)
, _miiOauthToken :: !(Maybe Text)
, _miiOrderId :: !Text
, _miiFields :: !(Maybe Text)
, _miiAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'MarketplacedealsInsert'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'miiQuotaUser'
--
-- * 'miiPrettyPrint'
--
-- * 'miiUserIp'
--
-- * 'miiKey'
--
-- * 'miiOauthToken'
--
-- * 'miiOrderId'
--
-- * 'miiFields'
--
-- * 'miiAlt'
marketplacedealsInsert
:: Text -- ^ 'orderId'
-> MarketplacedealsInsert
marketplacedealsInsert pMiiOrderId_ =
MarketplacedealsInsert
{ _miiQuotaUser = Nothing
, _miiPrettyPrint = True
, _miiUserIp = Nothing
, _miiKey = Nothing
, _miiOauthToken = Nothing
, _miiOrderId = pMiiOrderId_
, _miiFields = Nothing
, _miiAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
miiQuotaUser :: Lens' MarketplacedealsInsert' (Maybe Text)
miiQuotaUser
= lens _miiQuotaUser (\ s a -> s{_miiQuotaUser = a})
-- | Returns response with indentations and line breaks.
miiPrettyPrint :: Lens' MarketplacedealsInsert' Bool
miiPrettyPrint
= lens _miiPrettyPrint
(\ s a -> s{_miiPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
miiUserIp :: Lens' MarketplacedealsInsert' (Maybe Text)
miiUserIp
= lens _miiUserIp (\ s a -> s{_miiUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
miiKey :: Lens' MarketplacedealsInsert' (Maybe Text)
miiKey = lens _miiKey (\ s a -> s{_miiKey = a})
-- | OAuth 2.0 token for the current user.
miiOauthToken :: Lens' MarketplacedealsInsert' (Maybe Text)
miiOauthToken
= lens _miiOauthToken
(\ s a -> s{_miiOauthToken = a})
-- | OrderId for which deals need to be added.
miiOrderId :: Lens' MarketplacedealsInsert' Text
miiOrderId
= lens _miiOrderId (\ s a -> s{_miiOrderId = a})
-- | Selector specifying which fields to include in a partial response.
miiFields :: Lens' MarketplacedealsInsert' (Maybe Text)
miiFields
= lens _miiFields (\ s a -> s{_miiFields = a})
-- | Data format for the response.
miiAlt :: Lens' MarketplacedealsInsert' Text
miiAlt = lens _miiAlt (\ s a -> s{_miiAlt = a})
instance GoogleRequest MarketplacedealsInsert' where
type Rs MarketplacedealsInsert' =
AddOrderDealsResponse
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u MarketplacedealsInsert{..}
= go _miiQuotaUser _miiPrettyPrint _miiUserIp _miiKey
_miiOauthToken
_miiOrderId
_miiFields
_miiAlt
where go
= clientWithRoute
(Proxy :: Proxy MarketplacedealsInsertAPI)
r
u

View File

@ -0,0 +1,158 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Marketplacedeals.List
-- Copyright : (c) 2015 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)
--
-- | List all the deals for a given order
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerMarketplacedealsList@.
module AdExchangeBuyer.Marketplacedeals.List
(
-- * REST Resource
MarketplacedealsListAPI
-- * Creating a Request
, marketplacedealsList
, MarketplacedealsList
-- * Request Lenses
, mllQuotaUser
, mllPrettyPrint
, mllUserIp
, mllKey
, mllOauthToken
, mllOrderId
, mllFields
, mllAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerMarketplacedealsList@ which the
-- 'MarketplacedealsList' request conforms to.
type MarketplacedealsListAPI =
"marketplaceOrders" :>
Capture "orderId" Text :>
"deals" :> Get '[JSON] GetOrderDealsResponse
-- | List all the deals for a given order
--
-- /See:/ 'marketplacedealsList' smart constructor.
data MarketplacedealsList = MarketplacedealsList
{ _mllQuotaUser :: !(Maybe Text)
, _mllPrettyPrint :: !Bool
, _mllUserIp :: !(Maybe Text)
, _mllKey :: !(Maybe Text)
, _mllOauthToken :: !(Maybe Text)
, _mllOrderId :: !Text
, _mllFields :: !(Maybe Text)
, _mllAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'MarketplacedealsList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'mllQuotaUser'
--
-- * 'mllPrettyPrint'
--
-- * 'mllUserIp'
--
-- * 'mllKey'
--
-- * 'mllOauthToken'
--
-- * 'mllOrderId'
--
-- * 'mllFields'
--
-- * 'mllAlt'
marketplacedealsList
:: Text -- ^ 'orderId'
-> MarketplacedealsList
marketplacedealsList pMllOrderId_ =
MarketplacedealsList
{ _mllQuotaUser = Nothing
, _mllPrettyPrint = True
, _mllUserIp = Nothing
, _mllKey = Nothing
, _mllOauthToken = Nothing
, _mllOrderId = pMllOrderId_
, _mllFields = Nothing
, _mllAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
mllQuotaUser :: Lens' MarketplacedealsList' (Maybe Text)
mllQuotaUser
= lens _mllQuotaUser (\ s a -> s{_mllQuotaUser = a})
-- | Returns response with indentations and line breaks.
mllPrettyPrint :: Lens' MarketplacedealsList' Bool
mllPrettyPrint
= lens _mllPrettyPrint
(\ s a -> s{_mllPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
mllUserIp :: Lens' MarketplacedealsList' (Maybe Text)
mllUserIp
= lens _mllUserIp (\ s a -> s{_mllUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
mllKey :: Lens' MarketplacedealsList' (Maybe Text)
mllKey = lens _mllKey (\ s a -> s{_mllKey = a})
-- | OAuth 2.0 token for the current user.
mllOauthToken :: Lens' MarketplacedealsList' (Maybe Text)
mllOauthToken
= lens _mllOauthToken
(\ s a -> s{_mllOauthToken = a})
-- | The orderId to get deals for.
mllOrderId :: Lens' MarketplacedealsList' Text
mllOrderId
= lens _mllOrderId (\ s a -> s{_mllOrderId = a})
-- | Selector specifying which fields to include in a partial response.
mllFields :: Lens' MarketplacedealsList' (Maybe Text)
mllFields
= lens _mllFields (\ s a -> s{_mllFields = a})
-- | Data format for the response.
mllAlt :: Lens' MarketplacedealsList' Text
mllAlt = lens _mllAlt (\ s a -> s{_mllAlt = a})
instance GoogleRequest MarketplacedealsList' where
type Rs MarketplacedealsList' = GetOrderDealsResponse
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u MarketplacedealsList{..}
= go _mllQuotaUser _mllPrettyPrint _mllUserIp _mllKey
_mllOauthToken
_mllOrderId
_mllFields
_mllAlt
where go
= clientWithRoute
(Proxy :: Proxy MarketplacedealsListAPI)
r
u

View File

@ -0,0 +1,160 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Marketplacedeals.Update
-- Copyright : (c) 2015 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)
--
-- | Replaces all the deals in the order with the passed in deals
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerMarketplacedealsUpdate@.
module AdExchangeBuyer.Marketplacedeals.Update
(
-- * REST Resource
MarketplacedealsUpdateAPI
-- * Creating a Request
, marketplacedealsUpdate
, MarketplacedealsUpdate
-- * Request Lenses
, muuQuotaUser
, muuPrettyPrint
, muuUserIp
, muuKey
, muuOauthToken
, muuOrderId
, muuFields
, muuAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerMarketplacedealsUpdate@ which the
-- 'MarketplacedealsUpdate' request conforms to.
type MarketplacedealsUpdateAPI =
"marketplaceOrders" :>
Capture "orderId" Text :>
"deals" :>
"update" :> Post '[JSON] EditAllOrderDealsResponse
-- | Replaces all the deals in the order with the passed in deals
--
-- /See:/ 'marketplacedealsUpdate' smart constructor.
data MarketplacedealsUpdate = MarketplacedealsUpdate
{ _muuQuotaUser :: !(Maybe Text)
, _muuPrettyPrint :: !Bool
, _muuUserIp :: !(Maybe Text)
, _muuKey :: !(Maybe Text)
, _muuOauthToken :: !(Maybe Text)
, _muuOrderId :: !Text
, _muuFields :: !(Maybe Text)
, _muuAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'MarketplacedealsUpdate'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'muuQuotaUser'
--
-- * 'muuPrettyPrint'
--
-- * 'muuUserIp'
--
-- * 'muuKey'
--
-- * 'muuOauthToken'
--
-- * 'muuOrderId'
--
-- * 'muuFields'
--
-- * 'muuAlt'
marketplacedealsUpdate
:: Text -- ^ 'orderId'
-> MarketplacedealsUpdate
marketplacedealsUpdate pMuuOrderId_ =
MarketplacedealsUpdate
{ _muuQuotaUser = Nothing
, _muuPrettyPrint = True
, _muuUserIp = Nothing
, _muuKey = Nothing
, _muuOauthToken = Nothing
, _muuOrderId = pMuuOrderId_
, _muuFields = Nothing
, _muuAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
muuQuotaUser :: Lens' MarketplacedealsUpdate' (Maybe Text)
muuQuotaUser
= lens _muuQuotaUser (\ s a -> s{_muuQuotaUser = a})
-- | Returns response with indentations and line breaks.
muuPrettyPrint :: Lens' MarketplacedealsUpdate' Bool
muuPrettyPrint
= lens _muuPrettyPrint
(\ s a -> s{_muuPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
muuUserIp :: Lens' MarketplacedealsUpdate' (Maybe Text)
muuUserIp
= lens _muuUserIp (\ s a -> s{_muuUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
muuKey :: Lens' MarketplacedealsUpdate' (Maybe Text)
muuKey = lens _muuKey (\ s a -> s{_muuKey = a})
-- | OAuth 2.0 token for the current user.
muuOauthToken :: Lens' MarketplacedealsUpdate' (Maybe Text)
muuOauthToken
= lens _muuOauthToken
(\ s a -> s{_muuOauthToken = a})
-- | The orderId to edit deals on.
muuOrderId :: Lens' MarketplacedealsUpdate' Text
muuOrderId
= lens _muuOrderId (\ s a -> s{_muuOrderId = a})
-- | Selector specifying which fields to include in a partial response.
muuFields :: Lens' MarketplacedealsUpdate' (Maybe Text)
muuFields
= lens _muuFields (\ s a -> s{_muuFields = a})
-- | Data format for the response.
muuAlt :: Lens' MarketplacedealsUpdate' Text
muuAlt = lens _muuAlt (\ s a -> s{_muuAlt = a})
instance GoogleRequest MarketplacedealsUpdate' where
type Rs MarketplacedealsUpdate' =
EditAllOrderDealsResponse
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u MarketplacedealsUpdate{..}
= go _muuQuotaUser _muuPrettyPrint _muuUserIp _muuKey
_muuOauthToken
_muuOrderId
_muuFields
_muuAlt
where go
= clientWithRoute
(Proxy :: Proxy MarketplacedealsUpdateAPI)
r
u

View File

@ -0,0 +1,157 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Marketplacenotes.Insert
-- Copyright : (c) 2015 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)
--
-- | Add notes to the order
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerMarketplacenotesInsert@.
module AdExchangeBuyer.Marketplacenotes.Insert
(
-- * REST Resource
MarketplacenotesInsertAPI
-- * Creating a Request
, marketplacenotesInsert
, MarketplacenotesInsert
-- * Request Lenses
, miQuotaUser
, miPrettyPrint
, miUserIp
, miKey
, miOauthToken
, miOrderId
, miFields
, miAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerMarketplacenotesInsert@ which the
-- 'MarketplacenotesInsert' request conforms to.
type MarketplacenotesInsertAPI =
"marketplaceOrders" :>
Capture "orderId" Text :>
"notes" :>
"insert" :> Post '[JSON] AddOrderNotesResponse
-- | Add notes to the order
--
-- /See:/ 'marketplacenotesInsert' smart constructor.
data MarketplacenotesInsert = MarketplacenotesInsert
{ _miQuotaUser :: !(Maybe Text)
, _miPrettyPrint :: !Bool
, _miUserIp :: !(Maybe Text)
, _miKey :: !(Maybe Text)
, _miOauthToken :: !(Maybe Text)
, _miOrderId :: !Text
, _miFields :: !(Maybe Text)
, _miAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'MarketplacenotesInsert'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'miQuotaUser'
--
-- * 'miPrettyPrint'
--
-- * 'miUserIp'
--
-- * 'miKey'
--
-- * 'miOauthToken'
--
-- * 'miOrderId'
--
-- * 'miFields'
--
-- * 'miAlt'
marketplacenotesInsert
:: Text -- ^ 'orderId'
-> MarketplacenotesInsert
marketplacenotesInsert pMiOrderId_ =
MarketplacenotesInsert
{ _miQuotaUser = Nothing
, _miPrettyPrint = True
, _miUserIp = Nothing
, _miKey = Nothing
, _miOauthToken = Nothing
, _miOrderId = pMiOrderId_
, _miFields = Nothing
, _miAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
miQuotaUser :: Lens' MarketplacenotesInsert' (Maybe Text)
miQuotaUser
= lens _miQuotaUser (\ s a -> s{_miQuotaUser = a})
-- | Returns response with indentations and line breaks.
miPrettyPrint :: Lens' MarketplacenotesInsert' Bool
miPrettyPrint
= lens _miPrettyPrint
(\ s a -> s{_miPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
miUserIp :: Lens' MarketplacenotesInsert' (Maybe Text)
miUserIp = lens _miUserIp (\ s a -> s{_miUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
miKey :: Lens' MarketplacenotesInsert' (Maybe Text)
miKey = lens _miKey (\ s a -> s{_miKey = a})
-- | OAuth 2.0 token for the current user.
miOauthToken :: Lens' MarketplacenotesInsert' (Maybe Text)
miOauthToken
= lens _miOauthToken (\ s a -> s{_miOauthToken = a})
-- | The orderId to add notes for.
miOrderId :: Lens' MarketplacenotesInsert' Text
miOrderId
= lens _miOrderId (\ s a -> s{_miOrderId = a})
-- | Selector specifying which fields to include in a partial response.
miFields :: Lens' MarketplacenotesInsert' (Maybe Text)
miFields = lens _miFields (\ s a -> s{_miFields = a})
-- | Data format for the response.
miAlt :: Lens' MarketplacenotesInsert' Text
miAlt = lens _miAlt (\ s a -> s{_miAlt = a})
instance GoogleRequest MarketplacenotesInsert' where
type Rs MarketplacenotesInsert' =
AddOrderNotesResponse
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u MarketplacenotesInsert{..}
= go _miQuotaUser _miPrettyPrint _miUserIp _miKey
_miOauthToken
_miOrderId
_miFields
_miAlt
where go
= clientWithRoute
(Proxy :: Proxy MarketplacenotesInsertAPI)
r
u

View File

@ -0,0 +1,155 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Marketplacenotes.List
-- Copyright : (c) 2015 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)
--
-- | Get all the notes associated with an order
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerMarketplacenotesList@.
module AdExchangeBuyer.Marketplacenotes.List
(
-- * REST Resource
MarketplacenotesListAPI
-- * Creating a Request
, marketplacenotesList
, MarketplacenotesList
-- * Request Lenses
, mlQuotaUser
, mlPrettyPrint
, mlUserIp
, mlKey
, mlOauthToken
, mlOrderId
, mlFields
, mlAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerMarketplacenotesList@ which the
-- 'MarketplacenotesList' request conforms to.
type MarketplacenotesListAPI =
"marketplaceOrders" :>
Capture "orderId" Text :>
"notes" :> Get '[JSON] GetOrderNotesResponse
-- | Get all the notes associated with an order
--
-- /See:/ 'marketplacenotesList' smart constructor.
data MarketplacenotesList = MarketplacenotesList
{ _mlQuotaUser :: !(Maybe Text)
, _mlPrettyPrint :: !Bool
, _mlUserIp :: !(Maybe Text)
, _mlKey :: !(Maybe Text)
, _mlOauthToken :: !(Maybe Text)
, _mlOrderId :: !Text
, _mlFields :: !(Maybe Text)
, _mlAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'MarketplacenotesList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'mlQuotaUser'
--
-- * 'mlPrettyPrint'
--
-- * 'mlUserIp'
--
-- * 'mlKey'
--
-- * 'mlOauthToken'
--
-- * 'mlOrderId'
--
-- * 'mlFields'
--
-- * 'mlAlt'
marketplacenotesList
:: Text -- ^ 'orderId'
-> MarketplacenotesList
marketplacenotesList pMlOrderId_ =
MarketplacenotesList
{ _mlQuotaUser = Nothing
, _mlPrettyPrint = True
, _mlUserIp = Nothing
, _mlKey = Nothing
, _mlOauthToken = Nothing
, _mlOrderId = pMlOrderId_
, _mlFields = Nothing
, _mlAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
mlQuotaUser :: Lens' MarketplacenotesList' (Maybe Text)
mlQuotaUser
= lens _mlQuotaUser (\ s a -> s{_mlQuotaUser = a})
-- | Returns response with indentations and line breaks.
mlPrettyPrint :: Lens' MarketplacenotesList' Bool
mlPrettyPrint
= lens _mlPrettyPrint
(\ s a -> s{_mlPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
mlUserIp :: Lens' MarketplacenotesList' (Maybe Text)
mlUserIp = lens _mlUserIp (\ s a -> s{_mlUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
mlKey :: Lens' MarketplacenotesList' (Maybe Text)
mlKey = lens _mlKey (\ s a -> s{_mlKey = a})
-- | OAuth 2.0 token for the current user.
mlOauthToken :: Lens' MarketplacenotesList' (Maybe Text)
mlOauthToken
= lens _mlOauthToken (\ s a -> s{_mlOauthToken = a})
-- | The orderId to get notes for.
mlOrderId :: Lens' MarketplacenotesList' Text
mlOrderId
= lens _mlOrderId (\ s a -> s{_mlOrderId = a})
-- | Selector specifying which fields to include in a partial response.
mlFields :: Lens' MarketplacenotesList' (Maybe Text)
mlFields = lens _mlFields (\ s a -> s{_mlFields = a})
-- | Data format for the response.
mlAlt :: Lens' MarketplacenotesList' Text
mlAlt = lens _mlAlt (\ s a -> s{_mlAlt = a})
instance GoogleRequest MarketplacenotesList' where
type Rs MarketplacenotesList' = GetOrderNotesResponse
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u MarketplacenotesList{..}
= go _mlQuotaUser _mlPrettyPrint _mlUserIp _mlKey
_mlOauthToken
_mlOrderId
_mlFields
_mlAlt
where go
= clientWithRoute
(Proxy :: Proxy MarketplacenotesListAPI)
r
u

View File

@ -0,0 +1,155 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Marketplaceoffers.Get
-- Copyright : (c) 2015 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)
--
-- | Gets the requested negotiation.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerMarketplaceoffersGet@.
module AdExchangeBuyer.Marketplaceoffers.Get
(
-- * REST Resource
MarketplaceoffersGetAPI
-- * Creating a Request
, marketplaceoffersGet
, MarketplaceoffersGet
-- * Request Lenses
, mgQuotaUser
, mgPrettyPrint
, mgUserIp
, mgKey
, mgOfferId
, mgOauthToken
, mgFields
, mgAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerMarketplaceoffersGet@ which the
-- 'MarketplaceoffersGet' request conforms to.
type MarketplaceoffersGetAPI =
"marketplaceOffers" :>
Capture "offerId" Text :>
Get '[JSON] MarketplaceOffer
-- | Gets the requested negotiation.
--
-- /See:/ 'marketplaceoffersGet' smart constructor.
data MarketplaceoffersGet = MarketplaceoffersGet
{ _mgQuotaUser :: !(Maybe Text)
, _mgPrettyPrint :: !Bool
, _mgUserIp :: !(Maybe Text)
, _mgKey :: !(Maybe Text)
, _mgOfferId :: !Text
, _mgOauthToken :: !(Maybe Text)
, _mgFields :: !(Maybe Text)
, _mgAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'MarketplaceoffersGet'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'mgQuotaUser'
--
-- * 'mgPrettyPrint'
--
-- * 'mgUserIp'
--
-- * 'mgKey'
--
-- * 'mgOfferId'
--
-- * 'mgOauthToken'
--
-- * 'mgFields'
--
-- * 'mgAlt'
marketplaceoffersGet
:: Text -- ^ 'offerId'
-> MarketplaceoffersGet
marketplaceoffersGet pMgOfferId_ =
MarketplaceoffersGet
{ _mgQuotaUser = Nothing
, _mgPrettyPrint = True
, _mgUserIp = Nothing
, _mgKey = Nothing
, _mgOfferId = pMgOfferId_
, _mgOauthToken = Nothing
, _mgFields = Nothing
, _mgAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
mgQuotaUser :: Lens' MarketplaceoffersGet' (Maybe Text)
mgQuotaUser
= lens _mgQuotaUser (\ s a -> s{_mgQuotaUser = a})
-- | Returns response with indentations and line breaks.
mgPrettyPrint :: Lens' MarketplaceoffersGet' Bool
mgPrettyPrint
= lens _mgPrettyPrint
(\ s a -> s{_mgPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
mgUserIp :: Lens' MarketplaceoffersGet' (Maybe Text)
mgUserIp = lens _mgUserIp (\ s a -> s{_mgUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
mgKey :: Lens' MarketplaceoffersGet' (Maybe Text)
mgKey = lens _mgKey (\ s a -> s{_mgKey = a})
-- | The offerId for the offer to get the head revision for.
mgOfferId :: Lens' MarketplaceoffersGet' Text
mgOfferId
= lens _mgOfferId (\ s a -> s{_mgOfferId = a})
-- | OAuth 2.0 token for the current user.
mgOauthToken :: Lens' MarketplaceoffersGet' (Maybe Text)
mgOauthToken
= lens _mgOauthToken (\ s a -> s{_mgOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
mgFields :: Lens' MarketplaceoffersGet' (Maybe Text)
mgFields = lens _mgFields (\ s a -> s{_mgFields = a})
-- | Data format for the response.
mgAlt :: Lens' MarketplaceoffersGet' Text
mgAlt = lens _mgAlt (\ s a -> s{_mgAlt = a})
instance GoogleRequest MarketplaceoffersGet' where
type Rs MarketplaceoffersGet' = MarketplaceOffer
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u MarketplaceoffersGet{..}
= go _mgQuotaUser _mgPrettyPrint _mgUserIp _mgKey
_mgOfferId
_mgOauthToken
_mgFields
_mgAlt
where go
= clientWithRoute
(Proxy :: Proxy MarketplaceoffersGetAPI)
r
u

View File

@ -0,0 +1,155 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Marketplaceoffers.Search
-- Copyright : (c) 2015 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)
--
-- | Gets the requested negotiation.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerMarketplaceoffersSearch@.
module AdExchangeBuyer.Marketplaceoffers.Search
(
-- * REST Resource
MarketplaceoffersSearchAPI
-- * Creating a Request
, marketplaceoffersSearch
, MarketplaceoffersSearch
-- * Request Lenses
, msQuotaUser
, msPrettyPrint
, msUserIp
, msKey
, msPqlQuery
, msOauthToken
, msFields
, msAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerMarketplaceoffersSearch@ which the
-- 'MarketplaceoffersSearch' request conforms to.
type MarketplaceoffersSearchAPI =
"marketplaceOffers" :>
"search" :>
QueryParam "pqlQuery" Text :>
Get '[JSON] GetOffersResponse
-- | Gets the requested negotiation.
--
-- /See:/ 'marketplaceoffersSearch' smart constructor.
data MarketplaceoffersSearch = MarketplaceoffersSearch
{ _msQuotaUser :: !(Maybe Text)
, _msPrettyPrint :: !Bool
, _msUserIp :: !(Maybe Text)
, _msKey :: !(Maybe Text)
, _msPqlQuery :: !(Maybe Text)
, _msOauthToken :: !(Maybe Text)
, _msFields :: !(Maybe Text)
, _msAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'MarketplaceoffersSearch'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'msQuotaUser'
--
-- * 'msPrettyPrint'
--
-- * 'msUserIp'
--
-- * 'msKey'
--
-- * 'msPqlQuery'
--
-- * 'msOauthToken'
--
-- * 'msFields'
--
-- * 'msAlt'
marketplaceoffersSearch
:: MarketplaceoffersSearch
marketplaceoffersSearch =
MarketplaceoffersSearch
{ _msQuotaUser = Nothing
, _msPrettyPrint = True
, _msUserIp = Nothing
, _msKey = Nothing
, _msPqlQuery = Nothing
, _msOauthToken = Nothing
, _msFields = Nothing
, _msAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
msQuotaUser :: Lens' MarketplaceoffersSearch' (Maybe Text)
msQuotaUser
= lens _msQuotaUser (\ s a -> s{_msQuotaUser = a})
-- | Returns response with indentations and line breaks.
msPrettyPrint :: Lens' MarketplaceoffersSearch' Bool
msPrettyPrint
= lens _msPrettyPrint
(\ s a -> s{_msPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
msUserIp :: Lens' MarketplaceoffersSearch' (Maybe Text)
msUserIp = lens _msUserIp (\ s a -> s{_msUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
msKey :: Lens' MarketplaceoffersSearch' (Maybe Text)
msKey = lens _msKey (\ s a -> s{_msKey = a})
-- | The pql query used to query for offers.
msPqlQuery :: Lens' MarketplaceoffersSearch' (Maybe Text)
msPqlQuery
= lens _msPqlQuery (\ s a -> s{_msPqlQuery = a})
-- | OAuth 2.0 token for the current user.
msOauthToken :: Lens' MarketplaceoffersSearch' (Maybe Text)
msOauthToken
= lens _msOauthToken (\ s a -> s{_msOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
msFields :: Lens' MarketplaceoffersSearch' (Maybe Text)
msFields = lens _msFields (\ s a -> s{_msFields = a})
-- | Data format for the response.
msAlt :: Lens' MarketplaceoffersSearch' Text
msAlt = lens _msAlt (\ s a -> s{_msAlt = a})
instance GoogleRequest MarketplaceoffersSearch' where
type Rs MarketplaceoffersSearch' = GetOffersResponse
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u MarketplaceoffersSearch{..}
= go _msQuotaUser _msPrettyPrint _msUserIp _msKey
_msPqlQuery
_msOauthToken
_msFields
_msAlt
where go
= clientWithRoute
(Proxy :: Proxy MarketplaceoffersSearchAPI)
r
u

View File

@ -0,0 +1,158 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Marketplaceorders.Get
-- Copyright : (c) 2015 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)
--
-- | Get an order given its id
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerMarketplaceordersGet@.
module AdExchangeBuyer.Marketplaceorders.Get
(
-- * REST Resource
MarketplaceordersGetAPI
-- * Creating a Request
, marketplaceordersGet
, MarketplaceordersGet
-- * Request Lenses
, marQuotaUser
, marPrettyPrint
, marUserIp
, marKey
, marOauthToken
, marOrderId
, marFields
, marAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerMarketplaceordersGet@ which the
-- 'MarketplaceordersGet' request conforms to.
type MarketplaceordersGetAPI =
"marketplaceOrders" :>
Capture "orderId" Text :>
Get '[JSON] MarketplaceOrder
-- | Get an order given its id
--
-- /See:/ 'marketplaceordersGet' smart constructor.
data MarketplaceordersGet = MarketplaceordersGet
{ _marQuotaUser :: !(Maybe Text)
, _marPrettyPrint :: !Bool
, _marUserIp :: !(Maybe Text)
, _marKey :: !(Maybe Text)
, _marOauthToken :: !(Maybe Text)
, _marOrderId :: !Text
, _marFields :: !(Maybe Text)
, _marAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'MarketplaceordersGet'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'marQuotaUser'
--
-- * 'marPrettyPrint'
--
-- * 'marUserIp'
--
-- * 'marKey'
--
-- * 'marOauthToken'
--
-- * 'marOrderId'
--
-- * 'marFields'
--
-- * 'marAlt'
marketplaceordersGet
:: Text -- ^ 'orderId'
-> MarketplaceordersGet
marketplaceordersGet pMarOrderId_ =
MarketplaceordersGet
{ _marQuotaUser = Nothing
, _marPrettyPrint = True
, _marUserIp = Nothing
, _marKey = Nothing
, _marOauthToken = Nothing
, _marOrderId = pMarOrderId_
, _marFields = Nothing
, _marAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
marQuotaUser :: Lens' MarketplaceordersGet' (Maybe Text)
marQuotaUser
= lens _marQuotaUser (\ s a -> s{_marQuotaUser = a})
-- | Returns response with indentations and line breaks.
marPrettyPrint :: Lens' MarketplaceordersGet' Bool
marPrettyPrint
= lens _marPrettyPrint
(\ s a -> s{_marPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
marUserIp :: Lens' MarketplaceordersGet' (Maybe Text)
marUserIp
= lens _marUserIp (\ s a -> s{_marUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
marKey :: Lens' MarketplaceordersGet' (Maybe Text)
marKey = lens _marKey (\ s a -> s{_marKey = a})
-- | OAuth 2.0 token for the current user.
marOauthToken :: Lens' MarketplaceordersGet' (Maybe Text)
marOauthToken
= lens _marOauthToken
(\ s a -> s{_marOauthToken = a})
-- | Id of the order to retrieve.
marOrderId :: Lens' MarketplaceordersGet' Text
marOrderId
= lens _marOrderId (\ s a -> s{_marOrderId = a})
-- | Selector specifying which fields to include in a partial response.
marFields :: Lens' MarketplaceordersGet' (Maybe Text)
marFields
= lens _marFields (\ s a -> s{_marFields = a})
-- | Data format for the response.
marAlt :: Lens' MarketplaceordersGet' Text
marAlt = lens _marAlt (\ s a -> s{_marAlt = a})
instance GoogleRequest MarketplaceordersGet' where
type Rs MarketplaceordersGet' = MarketplaceOrder
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u MarketplaceordersGet{..}
= go _marQuotaUser _marPrettyPrint _marUserIp _marKey
_marOauthToken
_marOrderId
_marFields
_marAlt
where go
= clientWithRoute
(Proxy :: Proxy MarketplaceordersGetAPI)
r
u

View File

@ -0,0 +1,142 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Marketplaceorders.Insert
-- Copyright : (c) 2015 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)
--
-- | Create the given list of orders
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerMarketplaceordersInsert@.
module AdExchangeBuyer.Marketplaceorders.Insert
(
-- * REST Resource
MarketplaceordersInsertAPI
-- * Creating a Request
, marketplaceordersInsert
, MarketplaceordersInsert
-- * Request Lenses
, mQuotaUser
, mPrettyPrint
, mUserIp
, mKey
, mOauthToken
, mFields
, mAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerMarketplaceordersInsert@ which the
-- 'MarketplaceordersInsert' request conforms to.
type MarketplaceordersInsertAPI =
"marketplaceOrders" :>
"insert" :> Post '[JSON] CreateOrdersResponse
-- | Create the given list of orders
--
-- /See:/ 'marketplaceordersInsert' smart constructor.
data MarketplaceordersInsert = MarketplaceordersInsert
{ _mQuotaUser :: !(Maybe Text)
, _mPrettyPrint :: !Bool
, _mUserIp :: !(Maybe Text)
, _mKey :: !(Maybe Text)
, _mOauthToken :: !(Maybe Text)
, _mFields :: !(Maybe Text)
, _mAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'MarketplaceordersInsert'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'mQuotaUser'
--
-- * 'mPrettyPrint'
--
-- * 'mUserIp'
--
-- * 'mKey'
--
-- * 'mOauthToken'
--
-- * 'mFields'
--
-- * 'mAlt'
marketplaceordersInsert
:: MarketplaceordersInsert
marketplaceordersInsert =
MarketplaceordersInsert
{ _mQuotaUser = Nothing
, _mPrettyPrint = True
, _mUserIp = Nothing
, _mKey = Nothing
, _mOauthToken = Nothing
, _mFields = Nothing
, _mAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
mQuotaUser :: Lens' MarketplaceordersInsert' (Maybe Text)
mQuotaUser
= lens _mQuotaUser (\ s a -> s{_mQuotaUser = a})
-- | Returns response with indentations and line breaks.
mPrettyPrint :: Lens' MarketplaceordersInsert' Bool
mPrettyPrint
= lens _mPrettyPrint (\ s a -> s{_mPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
mUserIp :: Lens' MarketplaceordersInsert' (Maybe Text)
mUserIp = lens _mUserIp (\ s a -> s{_mUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
mKey :: Lens' MarketplaceordersInsert' (Maybe Text)
mKey = lens _mKey (\ s a -> s{_mKey = a})
-- | OAuth 2.0 token for the current user.
mOauthToken :: Lens' MarketplaceordersInsert' (Maybe Text)
mOauthToken
= lens _mOauthToken (\ s a -> s{_mOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
mFields :: Lens' MarketplaceordersInsert' (Maybe Text)
mFields = lens _mFields (\ s a -> s{_mFields = a})
-- | Data format for the response.
mAlt :: Lens' MarketplaceordersInsert' Text
mAlt = lens _mAlt (\ s a -> s{_mAlt = a})
instance GoogleRequest MarketplaceordersInsert' where
type Rs MarketplaceordersInsert' =
CreateOrdersResponse
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u MarketplaceordersInsert{..}
= go _mQuotaUser _mPrettyPrint _mUserIp _mKey
_mOauthToken
_mFields
_mAlt
where go
= clientWithRoute
(Proxy :: Proxy MarketplaceordersInsertAPI)
r
u

View File

@ -0,0 +1,187 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Marketplaceorders.Patch
-- Copyright : (c) 2015 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)
--
-- | Update the given order. This method supports patch semantics.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerMarketplaceordersPatch@.
module AdExchangeBuyer.Marketplaceorders.Patch
(
-- * REST Resource
MarketplaceordersPatchAPI
-- * Creating a Request
, marketplaceordersPatch
, MarketplaceordersPatch
-- * Request Lenses
, mpQuotaUser
, mpUpdateAction
, mpPrettyPrint
, mpUserIp
, mpRevisionNumber
, mpKey
, mpOauthToken
, mpOrderId
, mpFields
, mpAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerMarketplaceordersPatch@ which the
-- 'MarketplaceordersPatch' request conforms to.
type MarketplaceordersPatchAPI =
"marketplaceOrders" :>
Capture "orderId" Text :>
Capture "revisionNumber" Int64 :>
Capture "updateAction" Text :>
Patch '[JSON] MarketplaceOrder
-- | Update the given order. This method supports patch semantics.
--
-- /See:/ 'marketplaceordersPatch' smart constructor.
data MarketplaceordersPatch = MarketplaceordersPatch
{ _mpQuotaUser :: !(Maybe Text)
, _mpUpdateAction :: !Text
, _mpPrettyPrint :: !Bool
, _mpUserIp :: !(Maybe Text)
, _mpRevisionNumber :: !Int64
, _mpKey :: !(Maybe Text)
, _mpOauthToken :: !(Maybe Text)
, _mpOrderId :: !Text
, _mpFields :: !(Maybe Text)
, _mpAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'MarketplaceordersPatch'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'mpQuotaUser'
--
-- * 'mpUpdateAction'
--
-- * 'mpPrettyPrint'
--
-- * 'mpUserIp'
--
-- * 'mpRevisionNumber'
--
-- * 'mpKey'
--
-- * 'mpOauthToken'
--
-- * 'mpOrderId'
--
-- * 'mpFields'
--
-- * 'mpAlt'
marketplaceordersPatch
:: Text -- ^ 'updateAction'
-> Int64 -- ^ 'revisionNumber'
-> Text -- ^ 'orderId'
-> MarketplaceordersPatch
marketplaceordersPatch pMpUpdateAction_ pMpRevisionNumber_ pMpOrderId_ =
MarketplaceordersPatch
{ _mpQuotaUser = Nothing
, _mpUpdateAction = pMpUpdateAction_
, _mpPrettyPrint = True
, _mpUserIp = Nothing
, _mpRevisionNumber = pMpRevisionNumber_
, _mpKey = Nothing
, _mpOauthToken = Nothing
, _mpOrderId = pMpOrderId_
, _mpFields = Nothing
, _mpAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
mpQuotaUser :: Lens' MarketplaceordersPatch' (Maybe Text)
mpQuotaUser
= lens _mpQuotaUser (\ s a -> s{_mpQuotaUser = a})
-- | The proposed action to take on the order.
mpUpdateAction :: Lens' MarketplaceordersPatch' Text
mpUpdateAction
= lens _mpUpdateAction
(\ s a -> s{_mpUpdateAction = a})
-- | Returns response with indentations and line breaks.
mpPrettyPrint :: Lens' MarketplaceordersPatch' Bool
mpPrettyPrint
= lens _mpPrettyPrint
(\ s a -> s{_mpPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
mpUserIp :: Lens' MarketplaceordersPatch' (Maybe Text)
mpUserIp = lens _mpUserIp (\ s a -> s{_mpUserIp = a})
-- | The last known revision number to update. If the head revision in the
-- marketplace database has since changed, an error will be thrown. The
-- caller should then fetch the lastest order at head revision and retry
-- the update at that revision.
mpRevisionNumber :: Lens' MarketplaceordersPatch' Int64
mpRevisionNumber
= lens _mpRevisionNumber
(\ s a -> s{_mpRevisionNumber = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
mpKey :: Lens' MarketplaceordersPatch' (Maybe Text)
mpKey = lens _mpKey (\ s a -> s{_mpKey = a})
-- | OAuth 2.0 token for the current user.
mpOauthToken :: Lens' MarketplaceordersPatch' (Maybe Text)
mpOauthToken
= lens _mpOauthToken (\ s a -> s{_mpOauthToken = a})
-- | The order id to update.
mpOrderId :: Lens' MarketplaceordersPatch' Text
mpOrderId
= lens _mpOrderId (\ s a -> s{_mpOrderId = a})
-- | Selector specifying which fields to include in a partial response.
mpFields :: Lens' MarketplaceordersPatch' (Maybe Text)
mpFields = lens _mpFields (\ s a -> s{_mpFields = a})
-- | Data format for the response.
mpAlt :: Lens' MarketplaceordersPatch' Text
mpAlt = lens _mpAlt (\ s a -> s{_mpAlt = a})
instance GoogleRequest MarketplaceordersPatch' where
type Rs MarketplaceordersPatch' = MarketplaceOrder
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u MarketplaceordersPatch{..}
= go _mpQuotaUser _mpUpdateAction _mpPrettyPrint
_mpUserIp
_mpRevisionNumber
_mpKey
_mpOauthToken
_mpOrderId
_mpFields
_mpAlt
where go
= clientWithRoute
(Proxy :: Proxy MarketplaceordersPatchAPI)
r
u

View File

@ -0,0 +1,158 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Marketplaceorders.Search
-- Copyright : (c) 2015 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)
--
-- | Search for orders using pql query
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerMarketplaceordersSearch@.
module AdExchangeBuyer.Marketplaceorders.Search
(
-- * REST Resource
MarketplaceordersSearchAPI
-- * Creating a Request
, marketplaceordersSearch
, MarketplaceordersSearch
-- * Request Lenses
, mssQuotaUser
, mssPrettyPrint
, mssUserIp
, mssKey
, mssPqlQuery
, mssOauthToken
, mssFields
, mssAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerMarketplaceordersSearch@ which the
-- 'MarketplaceordersSearch' request conforms to.
type MarketplaceordersSearchAPI =
"marketplaceOrders" :>
"search" :>
QueryParam "pqlQuery" Text :>
Get '[JSON] GetOrdersResponse
-- | Search for orders using pql query
--
-- /See:/ 'marketplaceordersSearch' smart constructor.
data MarketplaceordersSearch = MarketplaceordersSearch
{ _mssQuotaUser :: !(Maybe Text)
, _mssPrettyPrint :: !Bool
, _mssUserIp :: !(Maybe Text)
, _mssKey :: !(Maybe Text)
, _mssPqlQuery :: !(Maybe Text)
, _mssOauthToken :: !(Maybe Text)
, _mssFields :: !(Maybe Text)
, _mssAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'MarketplaceordersSearch'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'mssQuotaUser'
--
-- * 'mssPrettyPrint'
--
-- * 'mssUserIp'
--
-- * 'mssKey'
--
-- * 'mssPqlQuery'
--
-- * 'mssOauthToken'
--
-- * 'mssFields'
--
-- * 'mssAlt'
marketplaceordersSearch
:: MarketplaceordersSearch
marketplaceordersSearch =
MarketplaceordersSearch
{ _mssQuotaUser = Nothing
, _mssPrettyPrint = True
, _mssUserIp = Nothing
, _mssKey = Nothing
, _mssPqlQuery = Nothing
, _mssOauthToken = Nothing
, _mssFields = Nothing
, _mssAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
mssQuotaUser :: Lens' MarketplaceordersSearch' (Maybe Text)
mssQuotaUser
= lens _mssQuotaUser (\ s a -> s{_mssQuotaUser = a})
-- | Returns response with indentations and line breaks.
mssPrettyPrint :: Lens' MarketplaceordersSearch' Bool
mssPrettyPrint
= lens _mssPrettyPrint
(\ s a -> s{_mssPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
mssUserIp :: Lens' MarketplaceordersSearch' (Maybe Text)
mssUserIp
= lens _mssUserIp (\ s a -> s{_mssUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
mssKey :: Lens' MarketplaceordersSearch' (Maybe Text)
mssKey = lens _mssKey (\ s a -> s{_mssKey = a})
-- | Query string to retrieve specific orders.
mssPqlQuery :: Lens' MarketplaceordersSearch' (Maybe Text)
mssPqlQuery
= lens _mssPqlQuery (\ s a -> s{_mssPqlQuery = a})
-- | OAuth 2.0 token for the current user.
mssOauthToken :: Lens' MarketplaceordersSearch' (Maybe Text)
mssOauthToken
= lens _mssOauthToken
(\ s a -> s{_mssOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
mssFields :: Lens' MarketplaceordersSearch' (Maybe Text)
mssFields
= lens _mssFields (\ s a -> s{_mssFields = a})
-- | Data format for the response.
mssAlt :: Lens' MarketplaceordersSearch' Text
mssAlt = lens _mssAlt (\ s a -> s{_mssAlt = a})
instance GoogleRequest MarketplaceordersSearch' where
type Rs MarketplaceordersSearch' = GetOrdersResponse
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u MarketplaceordersSearch{..}
= go _mssQuotaUser _mssPrettyPrint _mssUserIp _mssKey
_mssPqlQuery
_mssOauthToken
_mssFields
_mssAlt
where go
= clientWithRoute
(Proxy :: Proxy MarketplaceordersSearchAPI)
r
u

View File

@ -0,0 +1,187 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Marketplaceorders.Update
-- Copyright : (c) 2015 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)
--
-- | Update the given order
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerMarketplaceordersUpdate@.
module AdExchangeBuyer.Marketplaceorders.Update
(
-- * REST Resource
MarketplaceordersUpdateAPI
-- * Creating a Request
, marketplaceordersUpdate
, MarketplaceordersUpdate
-- * Request Lenses
, muQuotaUser
, muUpdateAction
, muPrettyPrint
, muUserIp
, muRevisionNumber
, muKey
, muOauthToken
, muOrderId
, muFields
, muAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerMarketplaceordersUpdate@ which the
-- 'MarketplaceordersUpdate' request conforms to.
type MarketplaceordersUpdateAPI =
"marketplaceOrders" :>
Capture "orderId" Text :>
Capture "revisionNumber" Int64 :>
Capture "updateAction" Text :>
Put '[JSON] MarketplaceOrder
-- | Update the given order
--
-- /See:/ 'marketplaceordersUpdate' smart constructor.
data MarketplaceordersUpdate = MarketplaceordersUpdate
{ _muQuotaUser :: !(Maybe Text)
, _muUpdateAction :: !Text
, _muPrettyPrint :: !Bool
, _muUserIp :: !(Maybe Text)
, _muRevisionNumber :: !Int64
, _muKey :: !(Maybe Text)
, _muOauthToken :: !(Maybe Text)
, _muOrderId :: !Text
, _muFields :: !(Maybe Text)
, _muAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'MarketplaceordersUpdate'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'muQuotaUser'
--
-- * 'muUpdateAction'
--
-- * 'muPrettyPrint'
--
-- * 'muUserIp'
--
-- * 'muRevisionNumber'
--
-- * 'muKey'
--
-- * 'muOauthToken'
--
-- * 'muOrderId'
--
-- * 'muFields'
--
-- * 'muAlt'
marketplaceordersUpdate
:: Text -- ^ 'updateAction'
-> Int64 -- ^ 'revisionNumber'
-> Text -- ^ 'orderId'
-> MarketplaceordersUpdate
marketplaceordersUpdate pMuUpdateAction_ pMuRevisionNumber_ pMuOrderId_ =
MarketplaceordersUpdate
{ _muQuotaUser = Nothing
, _muUpdateAction = pMuUpdateAction_
, _muPrettyPrint = True
, _muUserIp = Nothing
, _muRevisionNumber = pMuRevisionNumber_
, _muKey = Nothing
, _muOauthToken = Nothing
, _muOrderId = pMuOrderId_
, _muFields = Nothing
, _muAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
muQuotaUser :: Lens' MarketplaceordersUpdate' (Maybe Text)
muQuotaUser
= lens _muQuotaUser (\ s a -> s{_muQuotaUser = a})
-- | The proposed action to take on the order.
muUpdateAction :: Lens' MarketplaceordersUpdate' Text
muUpdateAction
= lens _muUpdateAction
(\ s a -> s{_muUpdateAction = a})
-- | Returns response with indentations and line breaks.
muPrettyPrint :: Lens' MarketplaceordersUpdate' Bool
muPrettyPrint
= lens _muPrettyPrint
(\ s a -> s{_muPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
muUserIp :: Lens' MarketplaceordersUpdate' (Maybe Text)
muUserIp = lens _muUserIp (\ s a -> s{_muUserIp = a})
-- | The last known revision number to update. If the head revision in the
-- marketplace database has since changed, an error will be thrown. The
-- caller should then fetch the lastest order at head revision and retry
-- the update at that revision.
muRevisionNumber :: Lens' MarketplaceordersUpdate' Int64
muRevisionNumber
= lens _muRevisionNumber
(\ s a -> s{_muRevisionNumber = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
muKey :: Lens' MarketplaceordersUpdate' (Maybe Text)
muKey = lens _muKey (\ s a -> s{_muKey = a})
-- | OAuth 2.0 token for the current user.
muOauthToken :: Lens' MarketplaceordersUpdate' (Maybe Text)
muOauthToken
= lens _muOauthToken (\ s a -> s{_muOauthToken = a})
-- | The order id to update.
muOrderId :: Lens' MarketplaceordersUpdate' Text
muOrderId
= lens _muOrderId (\ s a -> s{_muOrderId = a})
-- | Selector specifying which fields to include in a partial response.
muFields :: Lens' MarketplaceordersUpdate' (Maybe Text)
muFields = lens _muFields (\ s a -> s{_muFields = a})
-- | Data format for the response.
muAlt :: Lens' MarketplaceordersUpdate' Text
muAlt = lens _muAlt (\ s a -> s{_muAlt = a})
instance GoogleRequest MarketplaceordersUpdate' where
type Rs MarketplaceordersUpdate' = MarketplaceOrder
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u MarketplaceordersUpdate{..}
= go _muQuotaUser _muUpdateAction _muPrettyPrint
_muUserIp
_muRevisionNumber
_muKey
_muOauthToken
_muOrderId
_muFields
_muAlt
where go
= clientWithRoute
(Proxy :: Proxy MarketplaceordersUpdateAPI)
r
u

View File

@ -0,0 +1,157 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Negotiationrounds.Insert
-- Copyright : (c) 2015 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)
--
-- | Adds the requested negotiationRound to the requested negotiation.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerNegotiationroundsInsert@.
module AdExchangeBuyer.Negotiationrounds.Insert
(
-- * REST Resource
NegotiationroundsInsertAPI
-- * Creating a Request
, negotiationroundsInsert
, NegotiationroundsInsert
-- * Request Lenses
, niQuotaUser
, niPrettyPrint
, niUserIp
, niKey
, niOauthToken
, niNegotiationId
, niFields
, niAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerNegotiationroundsInsert@ which the
-- 'NegotiationroundsInsert' request conforms to.
type NegotiationroundsInsertAPI =
"negotiations" :>
Capture "negotiationId" Int64 :>
"negotiationrounds" :>
Post '[JSON] NegotiationRoundDto
-- | Adds the requested negotiationRound to the requested negotiation.
--
-- /See:/ 'negotiationroundsInsert' smart constructor.
data NegotiationroundsInsert = NegotiationroundsInsert
{ _niQuotaUser :: !(Maybe Text)
, _niPrettyPrint :: !Bool
, _niUserIp :: !(Maybe Text)
, _niKey :: !(Maybe Text)
, _niOauthToken :: !(Maybe Text)
, _niNegotiationId :: !Int64
, _niFields :: !(Maybe Text)
, _niAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'NegotiationroundsInsert'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'niQuotaUser'
--
-- * 'niPrettyPrint'
--
-- * 'niUserIp'
--
-- * 'niKey'
--
-- * 'niOauthToken'
--
-- * 'niNegotiationId'
--
-- * 'niFields'
--
-- * 'niAlt'
negotiationroundsInsert
:: Int64 -- ^ 'negotiationId'
-> NegotiationroundsInsert
negotiationroundsInsert pNiNegotiationId_ =
NegotiationroundsInsert
{ _niQuotaUser = Nothing
, _niPrettyPrint = True
, _niUserIp = Nothing
, _niKey = Nothing
, _niOauthToken = Nothing
, _niNegotiationId = pNiNegotiationId_
, _niFields = Nothing
, _niAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
niQuotaUser :: Lens' NegotiationroundsInsert' (Maybe Text)
niQuotaUser
= lens _niQuotaUser (\ s a -> s{_niQuotaUser = a})
-- | Returns response with indentations and line breaks.
niPrettyPrint :: Lens' NegotiationroundsInsert' Bool
niPrettyPrint
= lens _niPrettyPrint
(\ s a -> s{_niPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
niUserIp :: Lens' NegotiationroundsInsert' (Maybe Text)
niUserIp = lens _niUserIp (\ s a -> s{_niUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
niKey :: Lens' NegotiationroundsInsert' (Maybe Text)
niKey = lens _niKey (\ s a -> s{_niKey = a})
-- | OAuth 2.0 token for the current user.
niOauthToken :: Lens' NegotiationroundsInsert' (Maybe Text)
niOauthToken
= lens _niOauthToken (\ s a -> s{_niOauthToken = a})
niNegotiationId :: Lens' NegotiationroundsInsert' Int64
niNegotiationId
= lens _niNegotiationId
(\ s a -> s{_niNegotiationId = a})
-- | Selector specifying which fields to include in a partial response.
niFields :: Lens' NegotiationroundsInsert' (Maybe Text)
niFields = lens _niFields (\ s a -> s{_niFields = a})
-- | Data format for the response.
niAlt :: Lens' NegotiationroundsInsert' Text
niAlt = lens _niAlt (\ s a -> s{_niAlt = a})
instance GoogleRequest NegotiationroundsInsert' where
type Rs NegotiationroundsInsert' =
NegotiationRoundDto
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u NegotiationroundsInsert{..}
= go _niQuotaUser _niPrettyPrint _niUserIp _niKey
_niOauthToken
_niNegotiationId
_niFields
_niAlt
where go
= clientWithRoute
(Proxy :: Proxy NegotiationroundsInsertAPI)
r
u

View File

@ -0,0 +1,154 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Negotiations.Get
-- Copyright : (c) 2015 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)
--
-- | Gets the requested negotiation.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerNegotiationsGet@.
module AdExchangeBuyer.Negotiations.Get
(
-- * REST Resource
NegotiationsGetAPI
-- * Creating a Request
, negotiationsGet
, NegotiationsGet
-- * Request Lenses
, ngQuotaUser
, ngPrettyPrint
, ngUserIp
, ngKey
, ngOauthToken
, ngNegotiationId
, ngFields
, ngAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerNegotiationsGet@ which the
-- 'NegotiationsGet' request conforms to.
type NegotiationsGetAPI =
"negotiations" :>
Capture "negotiationId" Int64 :>
Get '[JSON] NegotiationDto
-- | Gets the requested negotiation.
--
-- /See:/ 'negotiationsGet' smart constructor.
data NegotiationsGet = NegotiationsGet
{ _ngQuotaUser :: !(Maybe Text)
, _ngPrettyPrint :: !Bool
, _ngUserIp :: !(Maybe Text)
, _ngKey :: !(Maybe Text)
, _ngOauthToken :: !(Maybe Text)
, _ngNegotiationId :: !Int64
, _ngFields :: !(Maybe Text)
, _ngAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'NegotiationsGet'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'ngQuotaUser'
--
-- * 'ngPrettyPrint'
--
-- * 'ngUserIp'
--
-- * 'ngKey'
--
-- * 'ngOauthToken'
--
-- * 'ngNegotiationId'
--
-- * 'ngFields'
--
-- * 'ngAlt'
negotiationsGet
:: Int64 -- ^ 'negotiationId'
-> NegotiationsGet
negotiationsGet pNgNegotiationId_ =
NegotiationsGet
{ _ngQuotaUser = Nothing
, _ngPrettyPrint = True
, _ngUserIp = Nothing
, _ngKey = Nothing
, _ngOauthToken = Nothing
, _ngNegotiationId = pNgNegotiationId_
, _ngFields = Nothing
, _ngAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
ngQuotaUser :: Lens' NegotiationsGet' (Maybe Text)
ngQuotaUser
= lens _ngQuotaUser (\ s a -> s{_ngQuotaUser = a})
-- | Returns response with indentations and line breaks.
ngPrettyPrint :: Lens' NegotiationsGet' Bool
ngPrettyPrint
= lens _ngPrettyPrint
(\ s a -> s{_ngPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
ngUserIp :: Lens' NegotiationsGet' (Maybe Text)
ngUserIp = lens _ngUserIp (\ s a -> s{_ngUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
ngKey :: Lens' NegotiationsGet' (Maybe Text)
ngKey = lens _ngKey (\ s a -> s{_ngKey = a})
-- | OAuth 2.0 token for the current user.
ngOauthToken :: Lens' NegotiationsGet' (Maybe Text)
ngOauthToken
= lens _ngOauthToken (\ s a -> s{_ngOauthToken = a})
ngNegotiationId :: Lens' NegotiationsGet' Int64
ngNegotiationId
= lens _ngNegotiationId
(\ s a -> s{_ngNegotiationId = a})
-- | Selector specifying which fields to include in a partial response.
ngFields :: Lens' NegotiationsGet' (Maybe Text)
ngFields = lens _ngFields (\ s a -> s{_ngFields = a})
-- | Data format for the response.
ngAlt :: Lens' NegotiationsGet' Text
ngAlt = lens _ngAlt (\ s a -> s{_ngAlt = a})
instance GoogleRequest NegotiationsGet' where
type Rs NegotiationsGet' = NegotiationDto
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u NegotiationsGet{..}
= go _ngQuotaUser _ngPrettyPrint _ngUserIp _ngKey
_ngOauthToken
_ngNegotiationId
_ngFields
_ngAlt
where go
= clientWithRoute (Proxy :: Proxy NegotiationsGetAPI)
r
u

View File

@ -0,0 +1,140 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Negotiations.Insert
-- Copyright : (c) 2015 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)
--
-- | Creates or updates the requested negotiation.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerNegotiationsInsert@.
module AdExchangeBuyer.Negotiations.Insert
(
-- * REST Resource
NegotiationsInsertAPI
-- * Creating a Request
, negotiationsInsert
, NegotiationsInsert
-- * Request Lenses
, nQuotaUser
, nPrettyPrint
, nUserIp
, nKey
, nOauthToken
, nFields
, nAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerNegotiationsInsert@ which the
-- 'NegotiationsInsert' request conforms to.
type NegotiationsInsertAPI =
"negotiations" :> Post '[JSON] NegotiationDto
-- | Creates or updates the requested negotiation.
--
-- /See:/ 'negotiationsInsert' smart constructor.
data NegotiationsInsert = NegotiationsInsert
{ _nQuotaUser :: !(Maybe Text)
, _nPrettyPrint :: !Bool
, _nUserIp :: !(Maybe Text)
, _nKey :: !(Maybe Text)
, _nOauthToken :: !(Maybe Text)
, _nFields :: !(Maybe Text)
, _nAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'NegotiationsInsert'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'nQuotaUser'
--
-- * 'nPrettyPrint'
--
-- * 'nUserIp'
--
-- * 'nKey'
--
-- * 'nOauthToken'
--
-- * 'nFields'
--
-- * 'nAlt'
negotiationsInsert
:: NegotiationsInsert
negotiationsInsert =
NegotiationsInsert
{ _nQuotaUser = Nothing
, _nPrettyPrint = True
, _nUserIp = Nothing
, _nKey = Nothing
, _nOauthToken = Nothing
, _nFields = Nothing
, _nAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
nQuotaUser :: Lens' NegotiationsInsert' (Maybe Text)
nQuotaUser
= lens _nQuotaUser (\ s a -> s{_nQuotaUser = a})
-- | Returns response with indentations and line breaks.
nPrettyPrint :: Lens' NegotiationsInsert' Bool
nPrettyPrint
= lens _nPrettyPrint (\ s a -> s{_nPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
nUserIp :: Lens' NegotiationsInsert' (Maybe Text)
nUserIp = lens _nUserIp (\ s a -> s{_nUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
nKey :: Lens' NegotiationsInsert' (Maybe Text)
nKey = lens _nKey (\ s a -> s{_nKey = a})
-- | OAuth 2.0 token for the current user.
nOauthToken :: Lens' NegotiationsInsert' (Maybe Text)
nOauthToken
= lens _nOauthToken (\ s a -> s{_nOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
nFields :: Lens' NegotiationsInsert' (Maybe Text)
nFields = lens _nFields (\ s a -> s{_nFields = a})
-- | Data format for the response.
nAlt :: Lens' NegotiationsInsert' Text
nAlt = lens _nAlt (\ s a -> s{_nAlt = a})
instance GoogleRequest NegotiationsInsert' where
type Rs NegotiationsInsert' = NegotiationDto
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u NegotiationsInsert{..}
= go _nQuotaUser _nPrettyPrint _nUserIp _nKey
_nOauthToken
_nFields
_nAlt
where go
= clientWithRoute
(Proxy :: Proxy NegotiationsInsertAPI)
r
u

View File

@ -0,0 +1,141 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Negotiations.List
-- Copyright : (c) 2015 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)
--
-- | Lists all negotiations the authenticated user has access to.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerNegotiationsList@.
module AdExchangeBuyer.Negotiations.List
(
-- * REST Resource
NegotiationsListAPI
-- * Creating a Request
, negotiationsList
, NegotiationsList
-- * Request Lenses
, nlQuotaUser
, nlPrettyPrint
, nlUserIp
, nlKey
, nlOauthToken
, nlFields
, nlAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerNegotiationsList@ which the
-- 'NegotiationsList' request conforms to.
type NegotiationsListAPI =
"negotiations" :> Get '[JSON] GetNegotiationsResponse
-- | Lists all negotiations the authenticated user has access to.
--
-- /See:/ 'negotiationsList' smart constructor.
data NegotiationsList = NegotiationsList
{ _nlQuotaUser :: !(Maybe Text)
, _nlPrettyPrint :: !Bool
, _nlUserIp :: !(Maybe Text)
, _nlKey :: !(Maybe Text)
, _nlOauthToken :: !(Maybe Text)
, _nlFields :: !(Maybe Text)
, _nlAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'NegotiationsList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'nlQuotaUser'
--
-- * 'nlPrettyPrint'
--
-- * 'nlUserIp'
--
-- * 'nlKey'
--
-- * 'nlOauthToken'
--
-- * 'nlFields'
--
-- * 'nlAlt'
negotiationsList
:: NegotiationsList
negotiationsList =
NegotiationsList
{ _nlQuotaUser = Nothing
, _nlPrettyPrint = True
, _nlUserIp = Nothing
, _nlKey = Nothing
, _nlOauthToken = Nothing
, _nlFields = Nothing
, _nlAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
nlQuotaUser :: Lens' NegotiationsList' (Maybe Text)
nlQuotaUser
= lens _nlQuotaUser (\ s a -> s{_nlQuotaUser = a})
-- | Returns response with indentations and line breaks.
nlPrettyPrint :: Lens' NegotiationsList' Bool
nlPrettyPrint
= lens _nlPrettyPrint
(\ s a -> s{_nlPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
nlUserIp :: Lens' NegotiationsList' (Maybe Text)
nlUserIp = lens _nlUserIp (\ s a -> s{_nlUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
nlKey :: Lens' NegotiationsList' (Maybe Text)
nlKey = lens _nlKey (\ s a -> s{_nlKey = a})
-- | OAuth 2.0 token for the current user.
nlOauthToken :: Lens' NegotiationsList' (Maybe Text)
nlOauthToken
= lens _nlOauthToken (\ s a -> s{_nlOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
nlFields :: Lens' NegotiationsList' (Maybe Text)
nlFields = lens _nlFields (\ s a -> s{_nlFields = a})
-- | Data format for the response.
nlAlt :: Lens' NegotiationsList' Text
nlAlt = lens _nlAlt (\ s a -> s{_nlAlt = a})
instance GoogleRequest NegotiationsList' where
type Rs NegotiationsList' = GetNegotiationsResponse
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u NegotiationsList{..}
= go _nlQuotaUser _nlPrettyPrint _nlUserIp _nlKey
_nlOauthToken
_nlFields
_nlAlt
where go
= clientWithRoute
(Proxy :: Proxy NegotiationsListAPI)
r
u

View File

@ -0,0 +1,150 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Offers.Get
-- Copyright : (c) 2015 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)
--
-- | Gets the requested offer.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerOffersGet@.
module AdExchangeBuyer.Offers.Get
(
-- * REST Resource
OffersGetAPI
-- * Creating a Request
, offersGet
, OffersGet
-- * Request Lenses
, ogQuotaUser
, ogPrettyPrint
, ogUserIp
, ogKey
, ogOfferId
, ogOauthToken
, ogFields
, ogAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerOffersGet@ which the
-- 'OffersGet' request conforms to.
type OffersGetAPI =
"offers" :>
Capture "offerId" Int64 :> Get '[JSON] OfferDto
-- | Gets the requested offer.
--
-- /See:/ 'offersGet' smart constructor.
data OffersGet = OffersGet
{ _ogQuotaUser :: !(Maybe Text)
, _ogPrettyPrint :: !Bool
, _ogUserIp :: !(Maybe Text)
, _ogKey :: !(Maybe Text)
, _ogOfferId :: !Int64
, _ogOauthToken :: !(Maybe Text)
, _ogFields :: !(Maybe Text)
, _ogAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'OffersGet'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'ogQuotaUser'
--
-- * 'ogPrettyPrint'
--
-- * 'ogUserIp'
--
-- * 'ogKey'
--
-- * 'ogOfferId'
--
-- * 'ogOauthToken'
--
-- * 'ogFields'
--
-- * 'ogAlt'
offersGet
:: Int64 -- ^ 'offerId'
-> OffersGet
offersGet pOgOfferId_ =
OffersGet
{ _ogQuotaUser = Nothing
, _ogPrettyPrint = True
, _ogUserIp = Nothing
, _ogKey = Nothing
, _ogOfferId = pOgOfferId_
, _ogOauthToken = Nothing
, _ogFields = Nothing
, _ogAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
ogQuotaUser :: Lens' OffersGet' (Maybe Text)
ogQuotaUser
= lens _ogQuotaUser (\ s a -> s{_ogQuotaUser = a})
-- | Returns response with indentations and line breaks.
ogPrettyPrint :: Lens' OffersGet' Bool
ogPrettyPrint
= lens _ogPrettyPrint
(\ s a -> s{_ogPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
ogUserIp :: Lens' OffersGet' (Maybe Text)
ogUserIp = lens _ogUserIp (\ s a -> s{_ogUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
ogKey :: Lens' OffersGet' (Maybe Text)
ogKey = lens _ogKey (\ s a -> s{_ogKey = a})
ogOfferId :: Lens' OffersGet' Int64
ogOfferId
= lens _ogOfferId (\ s a -> s{_ogOfferId = a})
-- | OAuth 2.0 token for the current user.
ogOauthToken :: Lens' OffersGet' (Maybe Text)
ogOauthToken
= lens _ogOauthToken (\ s a -> s{_ogOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
ogFields :: Lens' OffersGet' (Maybe Text)
ogFields = lens _ogFields (\ s a -> s{_ogFields = a})
-- | Data format for the response.
ogAlt :: Lens' OffersGet' Text
ogAlt = lens _ogAlt (\ s a -> s{_ogAlt = a})
instance GoogleRequest OffersGet' where
type Rs OffersGet' = OfferDto
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u OffersGet{..}
= go _ogQuotaUser _ogPrettyPrint _ogUserIp _ogKey
_ogOfferId
_ogOauthToken
_ogFields
_ogAlt
where go
= clientWithRoute (Proxy :: Proxy OffersGetAPI) r u

View File

@ -0,0 +1,139 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Offers.Insert
-- Copyright : (c) 2015 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)
--
-- | Creates or updates the requested offer.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerOffersInsert@.
module AdExchangeBuyer.Offers.Insert
(
-- * REST Resource
OffersInsertAPI
-- * Creating a Request
, offersInsert
, OffersInsert
-- * Request Lenses
, oiQuotaUser
, oiPrettyPrint
, oiUserIp
, oiKey
, oiOauthToken
, oiFields
, oiAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerOffersInsert@ which the
-- 'OffersInsert' request conforms to.
type OffersInsertAPI =
"offers" :> Post '[JSON] OfferDto
-- | Creates or updates the requested offer.
--
-- /See:/ 'offersInsert' smart constructor.
data OffersInsert = OffersInsert
{ _oiQuotaUser :: !(Maybe Text)
, _oiPrettyPrint :: !Bool
, _oiUserIp :: !(Maybe Text)
, _oiKey :: !(Maybe Text)
, _oiOauthToken :: !(Maybe Text)
, _oiFields :: !(Maybe Text)
, _oiAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'OffersInsert'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'oiQuotaUser'
--
-- * 'oiPrettyPrint'
--
-- * 'oiUserIp'
--
-- * 'oiKey'
--
-- * 'oiOauthToken'
--
-- * 'oiFields'
--
-- * 'oiAlt'
offersInsert
:: OffersInsert
offersInsert =
OffersInsert
{ _oiQuotaUser = Nothing
, _oiPrettyPrint = True
, _oiUserIp = Nothing
, _oiKey = Nothing
, _oiOauthToken = Nothing
, _oiFields = Nothing
, _oiAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
oiQuotaUser :: Lens' OffersInsert' (Maybe Text)
oiQuotaUser
= lens _oiQuotaUser (\ s a -> s{_oiQuotaUser = a})
-- | Returns response with indentations and line breaks.
oiPrettyPrint :: Lens' OffersInsert' Bool
oiPrettyPrint
= lens _oiPrettyPrint
(\ s a -> s{_oiPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
oiUserIp :: Lens' OffersInsert' (Maybe Text)
oiUserIp = lens _oiUserIp (\ s a -> s{_oiUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
oiKey :: Lens' OffersInsert' (Maybe Text)
oiKey = lens _oiKey (\ s a -> s{_oiKey = a})
-- | OAuth 2.0 token for the current user.
oiOauthToken :: Lens' OffersInsert' (Maybe Text)
oiOauthToken
= lens _oiOauthToken (\ s a -> s{_oiOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
oiFields :: Lens' OffersInsert' (Maybe Text)
oiFields = lens _oiFields (\ s a -> s{_oiFields = a})
-- | Data format for the response.
oiAlt :: Lens' OffersInsert' Text
oiAlt = lens _oiAlt (\ s a -> s{_oiAlt = a})
instance GoogleRequest OffersInsert' where
type Rs OffersInsert' = OfferDto
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u OffersInsert{..}
= go _oiQuotaUser _oiPrettyPrint _oiUserIp _oiKey
_oiOauthToken
_oiFields
_oiAlt
where go
= clientWithRoute (Proxy :: Proxy OffersInsertAPI) r
u

View File

@ -0,0 +1,138 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.Offers.List
-- Copyright : (c) 2015 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)
--
-- | Lists all offers the authenticated user has access to.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerOffersList@.
module AdExchangeBuyer.Offers.List
(
-- * REST Resource
OffersListAPI
-- * Creating a Request
, offersList
, OffersList
-- * Request Lenses
, olQuotaUser
, olPrettyPrint
, olUserIp
, olKey
, olOauthToken
, olFields
, olAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerOffersList@ which the
-- 'OffersList' request conforms to.
type OffersListAPI =
"offers" :> Get '[JSON] ListOffersResponse
-- | Lists all offers the authenticated user has access to.
--
-- /See:/ 'offersList' smart constructor.
data OffersList = OffersList
{ _olQuotaUser :: !(Maybe Text)
, _olPrettyPrint :: !Bool
, _olUserIp :: !(Maybe Text)
, _olKey :: !(Maybe Text)
, _olOauthToken :: !(Maybe Text)
, _olFields :: !(Maybe Text)
, _olAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'OffersList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'olQuotaUser'
--
-- * 'olPrettyPrint'
--
-- * 'olUserIp'
--
-- * 'olKey'
--
-- * 'olOauthToken'
--
-- * 'olFields'
--
-- * 'olAlt'
offersList
:: OffersList
offersList =
OffersList
{ _olQuotaUser = Nothing
, _olPrettyPrint = True
, _olUserIp = Nothing
, _olKey = Nothing
, _olOauthToken = Nothing
, _olFields = Nothing
, _olAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
olQuotaUser :: Lens' OffersList' (Maybe Text)
olQuotaUser
= lens _olQuotaUser (\ s a -> s{_olQuotaUser = a})
-- | Returns response with indentations and line breaks.
olPrettyPrint :: Lens' OffersList' Bool
olPrettyPrint
= lens _olPrettyPrint
(\ s a -> s{_olPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
olUserIp :: Lens' OffersList' (Maybe Text)
olUserIp = lens _olUserIp (\ s a -> s{_olUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
olKey :: Lens' OffersList' (Maybe Text)
olKey = lens _olKey (\ s a -> s{_olKey = a})
-- | OAuth 2.0 token for the current user.
olOauthToken :: Lens' OffersList' (Maybe Text)
olOauthToken
= lens _olOauthToken (\ s a -> s{_olOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
olFields :: Lens' OffersList' (Maybe Text)
olFields = lens _olFields (\ s a -> s{_olFields = a})
-- | Data format for the response.
olAlt :: Lens' OffersList' Text
olAlt = lens _olAlt (\ s a -> s{_olAlt = a})
instance GoogleRequest OffersList' where
type Rs OffersList' = ListOffersResponse
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u OffersList{..}
= go _olQuotaUser _olPrettyPrint _olUserIp _olKey
_olOauthToken
_olFields
_olAlt
where go
= clientWithRoute (Proxy :: Proxy OffersListAPI) r u

View File

@ -0,0 +1,216 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.PerformanceReport.List
-- Copyright : (c) 2015 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)
--
-- | Retrieves the authenticated user\'s list of performance metrics.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerPerformanceReportList@.
module AdExchangeBuyer.PerformanceReport.List
(
-- * REST Resource
PerformanceReportListAPI
-- * Creating a Request
, performanceReportList
, PerformanceReportList
-- * Request Lenses
, prlQuotaUser
, prlPrettyPrint
, prlUserIp
, prlAccountId
, prlKey
, prlPageToken
, prlOauthToken
, prlEndDateTime
, prlMaxResults
, prlStartDateTime
, prlFields
, prlAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerPerformanceReportList@ which the
-- 'PerformanceReportList' request conforms to.
type PerformanceReportListAPI =
"performancereport" :>
QueryParam "accountId" Int64 :>
QueryParam "pageToken" Text :>
QueryParam "endDateTime" Text :>
QueryParam "maxResults" Word32 :>
QueryParam "startDateTime" Text :>
Get '[JSON] PerformanceReportList
-- | Retrieves the authenticated user\'s list of performance metrics.
--
-- /See:/ 'performanceReportList' smart constructor.
data PerformanceReportList = PerformanceReportList
{ _prlQuotaUser :: !(Maybe Text)
, _prlPrettyPrint :: !Bool
, _prlUserIp :: !(Maybe Text)
, _prlAccountId :: !Int64
, _prlKey :: !(Maybe Text)
, _prlPageToken :: !(Maybe Text)
, _prlOauthToken :: !(Maybe Text)
, _prlEndDateTime :: !Text
, _prlMaxResults :: !(Maybe Word32)
, _prlStartDateTime :: !Text
, _prlFields :: !(Maybe Text)
, _prlAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'PerformanceReportList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'prlQuotaUser'
--
-- * 'prlPrettyPrint'
--
-- * 'prlUserIp'
--
-- * 'prlAccountId'
--
-- * 'prlKey'
--
-- * 'prlPageToken'
--
-- * 'prlOauthToken'
--
-- * 'prlEndDateTime'
--
-- * 'prlMaxResults'
--
-- * 'prlStartDateTime'
--
-- * 'prlFields'
--
-- * 'prlAlt'
performanceReportList
:: Int64 -- ^ 'accountId'
-> Text -- ^ 'endDateTime'
-> Text -- ^ 'startDateTime'
-> PerformanceReportList
performanceReportList pPrlAccountId_ pPrlEndDateTime_ pPrlStartDateTime_ =
PerformanceReportList
{ _prlQuotaUser = Nothing
, _prlPrettyPrint = True
, _prlUserIp = Nothing
, _prlAccountId = pPrlAccountId_
, _prlKey = Nothing
, _prlPageToken = Nothing
, _prlOauthToken = Nothing
, _prlEndDateTime = pPrlEndDateTime_
, _prlMaxResults = Nothing
, _prlStartDateTime = pPrlStartDateTime_
, _prlFields = Nothing
, _prlAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
prlQuotaUser :: Lens' PerformanceReportList' (Maybe Text)
prlQuotaUser
= lens _prlQuotaUser (\ s a -> s{_prlQuotaUser = a})
-- | Returns response with indentations and line breaks.
prlPrettyPrint :: Lens' PerformanceReportList' Bool
prlPrettyPrint
= lens _prlPrettyPrint
(\ s a -> s{_prlPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
prlUserIp :: Lens' PerformanceReportList' (Maybe Text)
prlUserIp
= lens _prlUserIp (\ s a -> s{_prlUserIp = a})
-- | The account id to get the reports.
prlAccountId :: Lens' PerformanceReportList' Int64
prlAccountId
= lens _prlAccountId (\ s a -> s{_prlAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
prlKey :: Lens' PerformanceReportList' (Maybe Text)
prlKey = lens _prlKey (\ s a -> s{_prlKey = a})
-- | A continuation token, used to page through performance reports. To
-- retrieve the next page, set this parameter to the value of
-- \"nextPageToken\" from the previous response. Optional.
prlPageToken :: Lens' PerformanceReportList' (Maybe Text)
prlPageToken
= lens _prlPageToken (\ s a -> s{_prlPageToken = a})
-- | OAuth 2.0 token for the current user.
prlOauthToken :: Lens' PerformanceReportList' (Maybe Text)
prlOauthToken
= lens _prlOauthToken
(\ s a -> s{_prlOauthToken = a})
-- | The end time of the report in ISO 8601 timestamp format using UTC.
prlEndDateTime :: Lens' PerformanceReportList' Text
prlEndDateTime
= lens _prlEndDateTime
(\ s a -> s{_prlEndDateTime = a})
-- | Maximum number of entries returned on one result page. If not set, the
-- default is 100. Optional.
prlMaxResults :: Lens' PerformanceReportList' (Maybe Word32)
prlMaxResults
= lens _prlMaxResults
(\ s a -> s{_prlMaxResults = a})
-- | The start time of the report in ISO 8601 timestamp format using UTC.
prlStartDateTime :: Lens' PerformanceReportList' Text
prlStartDateTime
= lens _prlStartDateTime
(\ s a -> s{_prlStartDateTime = a})
-- | Selector specifying which fields to include in a partial response.
prlFields :: Lens' PerformanceReportList' (Maybe Text)
prlFields
= lens _prlFields (\ s a -> s{_prlFields = a})
-- | Data format for the response.
prlAlt :: Lens' PerformanceReportList' Text
prlAlt = lens _prlAlt (\ s a -> s{_prlAlt = a})
instance GoogleRequest PerformanceReportList' where
type Rs PerformanceReportList' =
PerformanceReportList
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u PerformanceReportList{..}
= go _prlQuotaUser _prlPrettyPrint _prlUserIp
(Just _prlAccountId)
_prlKey
_prlPageToken
_prlOauthToken
(Just _prlEndDateTime)
_prlMaxResults
(Just _prlStartDateTime)
_prlFields
_prlAlt
where go
= clientWithRoute
(Proxy :: Proxy PerformanceReportListAPI)
r
u

View File

@ -0,0 +1,172 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.PretargetingConfig.Delete
-- Copyright : (c) 2015 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)
--
-- | Deletes an existing pretargeting config.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerPretargetingConfigDelete@.
module AdExchangeBuyer.PretargetingConfig.Delete
(
-- * REST Resource
PretargetingConfigDeleteAPI
-- * Creating a Request
, pretargetingConfigDelete
, PretargetingConfigDelete
-- * Request Lenses
, pcdQuotaUser
, pcdPrettyPrint
, pcdUserIp
, pcdAccountId
, pcdKey
, pcdConfigId
, pcdOauthToken
, pcdFields
, pcdAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerPretargetingConfigDelete@ which the
-- 'PretargetingConfigDelete' request conforms to.
type PretargetingConfigDeleteAPI =
"pretargetingconfigs" :>
Capture "accountId" Int64 :>
Capture "configId" Int64 :> Delete '[JSON] ()
-- | Deletes an existing pretargeting config.
--
-- /See:/ 'pretargetingConfigDelete' smart constructor.
data PretargetingConfigDelete = PretargetingConfigDelete
{ _pcdQuotaUser :: !(Maybe Text)
, _pcdPrettyPrint :: !Bool
, _pcdUserIp :: !(Maybe Text)
, _pcdAccountId :: !Int64
, _pcdKey :: !(Maybe Text)
, _pcdConfigId :: !Int64
, _pcdOauthToken :: !(Maybe Text)
, _pcdFields :: !(Maybe Text)
, _pcdAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'PretargetingConfigDelete'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'pcdQuotaUser'
--
-- * 'pcdPrettyPrint'
--
-- * 'pcdUserIp'
--
-- * 'pcdAccountId'
--
-- * 'pcdKey'
--
-- * 'pcdConfigId'
--
-- * 'pcdOauthToken'
--
-- * 'pcdFields'
--
-- * 'pcdAlt'
pretargetingConfigDelete
:: Int64 -- ^ 'accountId'
-> Int64 -- ^ 'configId'
-> PretargetingConfigDelete
pretargetingConfigDelete pPcdAccountId_ pPcdConfigId_ =
PretargetingConfigDelete
{ _pcdQuotaUser = Nothing
, _pcdPrettyPrint = True
, _pcdUserIp = Nothing
, _pcdAccountId = pPcdAccountId_
, _pcdKey = Nothing
, _pcdConfigId = pPcdConfigId_
, _pcdOauthToken = Nothing
, _pcdFields = Nothing
, _pcdAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
pcdQuotaUser :: Lens' PretargetingConfigDelete' (Maybe Text)
pcdQuotaUser
= lens _pcdQuotaUser (\ s a -> s{_pcdQuotaUser = a})
-- | Returns response with indentations and line breaks.
pcdPrettyPrint :: Lens' PretargetingConfigDelete' Bool
pcdPrettyPrint
= lens _pcdPrettyPrint
(\ s a -> s{_pcdPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
pcdUserIp :: Lens' PretargetingConfigDelete' (Maybe Text)
pcdUserIp
= lens _pcdUserIp (\ s a -> s{_pcdUserIp = a})
-- | The account id to delete the pretargeting config for.
pcdAccountId :: Lens' PretargetingConfigDelete' Int64
pcdAccountId
= lens _pcdAccountId (\ s a -> s{_pcdAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
pcdKey :: Lens' PretargetingConfigDelete' (Maybe Text)
pcdKey = lens _pcdKey (\ s a -> s{_pcdKey = a})
-- | The specific id of the configuration to delete.
pcdConfigId :: Lens' PretargetingConfigDelete' Int64
pcdConfigId
= lens _pcdConfigId (\ s a -> s{_pcdConfigId = a})
-- | OAuth 2.0 token for the current user.
pcdOauthToken :: Lens' PretargetingConfigDelete' (Maybe Text)
pcdOauthToken
= lens _pcdOauthToken
(\ s a -> s{_pcdOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
pcdFields :: Lens' PretargetingConfigDelete' (Maybe Text)
pcdFields
= lens _pcdFields (\ s a -> s{_pcdFields = a})
-- | Data format for the response.
pcdAlt :: Lens' PretargetingConfigDelete' Text
pcdAlt = lens _pcdAlt (\ s a -> s{_pcdAlt = a})
instance GoogleRequest PretargetingConfigDelete'
where
type Rs PretargetingConfigDelete' = ()
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u PretargetingConfigDelete{..}
= go _pcdQuotaUser _pcdPrettyPrint _pcdUserIp
_pcdAccountId
_pcdKey
_pcdConfigId
_pcdOauthToken
_pcdFields
_pcdAlt
where go
= clientWithRoute
(Proxy :: Proxy PretargetingConfigDeleteAPI)
r
u

View File

@ -0,0 +1,172 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.PretargetingConfig.Get
-- Copyright : (c) 2015 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)
--
-- | Gets a specific pretargeting configuration
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerPretargetingConfigGet@.
module AdExchangeBuyer.PretargetingConfig.Get
(
-- * REST Resource
PretargetingConfigGetAPI
-- * Creating a Request
, pretargetingConfigGet
, PretargetingConfigGet
-- * Request Lenses
, pcgQuotaUser
, pcgPrettyPrint
, pcgUserIp
, pcgAccountId
, pcgKey
, pcgConfigId
, pcgOauthToken
, pcgFields
, pcgAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerPretargetingConfigGet@ which the
-- 'PretargetingConfigGet' request conforms to.
type PretargetingConfigGetAPI =
"pretargetingconfigs" :>
Capture "accountId" Int64 :>
Capture "configId" Int64 :>
Get '[JSON] PretargetingConfig
-- | Gets a specific pretargeting configuration
--
-- /See:/ 'pretargetingConfigGet' smart constructor.
data PretargetingConfigGet = PretargetingConfigGet
{ _pcgQuotaUser :: !(Maybe Text)
, _pcgPrettyPrint :: !Bool
, _pcgUserIp :: !(Maybe Text)
, _pcgAccountId :: !Int64
, _pcgKey :: !(Maybe Text)
, _pcgConfigId :: !Int64
, _pcgOauthToken :: !(Maybe Text)
, _pcgFields :: !(Maybe Text)
, _pcgAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'PretargetingConfigGet'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'pcgQuotaUser'
--
-- * 'pcgPrettyPrint'
--
-- * 'pcgUserIp'
--
-- * 'pcgAccountId'
--
-- * 'pcgKey'
--
-- * 'pcgConfigId'
--
-- * 'pcgOauthToken'
--
-- * 'pcgFields'
--
-- * 'pcgAlt'
pretargetingConfigGet
:: Int64 -- ^ 'accountId'
-> Int64 -- ^ 'configId'
-> PretargetingConfigGet
pretargetingConfigGet pPcgAccountId_ pPcgConfigId_ =
PretargetingConfigGet
{ _pcgQuotaUser = Nothing
, _pcgPrettyPrint = True
, _pcgUserIp = Nothing
, _pcgAccountId = pPcgAccountId_
, _pcgKey = Nothing
, _pcgConfigId = pPcgConfigId_
, _pcgOauthToken = Nothing
, _pcgFields = Nothing
, _pcgAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
pcgQuotaUser :: Lens' PretargetingConfigGet' (Maybe Text)
pcgQuotaUser
= lens _pcgQuotaUser (\ s a -> s{_pcgQuotaUser = a})
-- | Returns response with indentations and line breaks.
pcgPrettyPrint :: Lens' PretargetingConfigGet' Bool
pcgPrettyPrint
= lens _pcgPrettyPrint
(\ s a -> s{_pcgPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
pcgUserIp :: Lens' PretargetingConfigGet' (Maybe Text)
pcgUserIp
= lens _pcgUserIp (\ s a -> s{_pcgUserIp = a})
-- | The account id to get the pretargeting config for.
pcgAccountId :: Lens' PretargetingConfigGet' Int64
pcgAccountId
= lens _pcgAccountId (\ s a -> s{_pcgAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
pcgKey :: Lens' PretargetingConfigGet' (Maybe Text)
pcgKey = lens _pcgKey (\ s a -> s{_pcgKey = a})
-- | The specific id of the configuration to retrieve.
pcgConfigId :: Lens' PretargetingConfigGet' Int64
pcgConfigId
= lens _pcgConfigId (\ s a -> s{_pcgConfigId = a})
-- | OAuth 2.0 token for the current user.
pcgOauthToken :: Lens' PretargetingConfigGet' (Maybe Text)
pcgOauthToken
= lens _pcgOauthToken
(\ s a -> s{_pcgOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
pcgFields :: Lens' PretargetingConfigGet' (Maybe Text)
pcgFields
= lens _pcgFields (\ s a -> s{_pcgFields = a})
-- | Data format for the response.
pcgAlt :: Lens' PretargetingConfigGet' Text
pcgAlt = lens _pcgAlt (\ s a -> s{_pcgAlt = a})
instance GoogleRequest PretargetingConfigGet' where
type Rs PretargetingConfigGet' = PretargetingConfig
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u PretargetingConfigGet{..}
= go _pcgQuotaUser _pcgPrettyPrint _pcgUserIp
_pcgAccountId
_pcgKey
_pcgConfigId
_pcgOauthToken
_pcgFields
_pcgAlt
where go
= clientWithRoute
(Proxy :: Proxy PretargetingConfigGetAPI)
r
u

View File

@ -0,0 +1,161 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.PretargetingConfig.Insert
-- Copyright : (c) 2015 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)
--
-- | Inserts a new pretargeting configuration.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerPretargetingConfigInsert@.
module AdExchangeBuyer.PretargetingConfig.Insert
(
-- * REST Resource
PretargetingConfigInsertAPI
-- * Creating a Request
, pretargetingConfigInsert
, PretargetingConfigInsert
-- * Request Lenses
, pciQuotaUser
, pciPrettyPrint
, pciUserIp
, pciAccountId
, pciKey
, pciOauthToken
, pciFields
, pciAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerPretargetingConfigInsert@ which the
-- 'PretargetingConfigInsert' request conforms to.
type PretargetingConfigInsertAPI =
"pretargetingconfigs" :>
Capture "accountId" Int64 :>
Post '[JSON] PretargetingConfig
-- | Inserts a new pretargeting configuration.
--
-- /See:/ 'pretargetingConfigInsert' smart constructor.
data PretargetingConfigInsert = PretargetingConfigInsert
{ _pciQuotaUser :: !(Maybe Text)
, _pciPrettyPrint :: !Bool
, _pciUserIp :: !(Maybe Text)
, _pciAccountId :: !Int64
, _pciKey :: !(Maybe Text)
, _pciOauthToken :: !(Maybe Text)
, _pciFields :: !(Maybe Text)
, _pciAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'PretargetingConfigInsert'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'pciQuotaUser'
--
-- * 'pciPrettyPrint'
--
-- * 'pciUserIp'
--
-- * 'pciAccountId'
--
-- * 'pciKey'
--
-- * 'pciOauthToken'
--
-- * 'pciFields'
--
-- * 'pciAlt'
pretargetingConfigInsert
:: Int64 -- ^ 'accountId'
-> PretargetingConfigInsert
pretargetingConfigInsert pPciAccountId_ =
PretargetingConfigInsert
{ _pciQuotaUser = Nothing
, _pciPrettyPrint = True
, _pciUserIp = Nothing
, _pciAccountId = pPciAccountId_
, _pciKey = Nothing
, _pciOauthToken = Nothing
, _pciFields = Nothing
, _pciAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
pciQuotaUser :: Lens' PretargetingConfigInsert' (Maybe Text)
pciQuotaUser
= lens _pciQuotaUser (\ s a -> s{_pciQuotaUser = a})
-- | Returns response with indentations and line breaks.
pciPrettyPrint :: Lens' PretargetingConfigInsert' Bool
pciPrettyPrint
= lens _pciPrettyPrint
(\ s a -> s{_pciPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
pciUserIp :: Lens' PretargetingConfigInsert' (Maybe Text)
pciUserIp
= lens _pciUserIp (\ s a -> s{_pciUserIp = a})
-- | The account id to insert the pretargeting config for.
pciAccountId :: Lens' PretargetingConfigInsert' Int64
pciAccountId
= lens _pciAccountId (\ s a -> s{_pciAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
pciKey :: Lens' PretargetingConfigInsert' (Maybe Text)
pciKey = lens _pciKey (\ s a -> s{_pciKey = a})
-- | OAuth 2.0 token for the current user.
pciOauthToken :: Lens' PretargetingConfigInsert' (Maybe Text)
pciOauthToken
= lens _pciOauthToken
(\ s a -> s{_pciOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
pciFields :: Lens' PretargetingConfigInsert' (Maybe Text)
pciFields
= lens _pciFields (\ s a -> s{_pciFields = a})
-- | Data format for the response.
pciAlt :: Lens' PretargetingConfigInsert' Text
pciAlt = lens _pciAlt (\ s a -> s{_pciAlt = a})
instance GoogleRequest PretargetingConfigInsert'
where
type Rs PretargetingConfigInsert' =
PretargetingConfig
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u PretargetingConfigInsert{..}
= go _pciQuotaUser _pciPrettyPrint _pciUserIp
_pciAccountId
_pciKey
_pciOauthToken
_pciFields
_pciAlt
where go
= clientWithRoute
(Proxy :: Proxy PretargetingConfigInsertAPI)
r
u

View File

@ -0,0 +1,162 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.PretargetingConfig.List
-- Copyright : (c) 2015 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)
--
-- | Retrieves a list of the authenticated user\'s pretargeting
-- configurations.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerPretargetingConfigList@.
module AdExchangeBuyer.PretargetingConfig.List
(
-- * REST Resource
PretargetingConfigListAPI
-- * Creating a Request
, pretargetingConfigList
, PretargetingConfigList
-- * Request Lenses
, pclQuotaUser
, pclPrettyPrint
, pclUserIp
, pclAccountId
, pclKey
, pclOauthToken
, pclFields
, pclAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerPretargetingConfigList@ which the
-- 'PretargetingConfigList' request conforms to.
type PretargetingConfigListAPI =
"pretargetingconfigs" :>
Capture "accountId" Int64 :>
Get '[JSON] PretargetingConfigList
-- | Retrieves a list of the authenticated user\'s pretargeting
-- configurations.
--
-- /See:/ 'pretargetingConfigList' smart constructor.
data PretargetingConfigList = PretargetingConfigList
{ _pclQuotaUser :: !(Maybe Text)
, _pclPrettyPrint :: !Bool
, _pclUserIp :: !(Maybe Text)
, _pclAccountId :: !Int64
, _pclKey :: !(Maybe Text)
, _pclOauthToken :: !(Maybe Text)
, _pclFields :: !(Maybe Text)
, _pclAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'PretargetingConfigList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'pclQuotaUser'
--
-- * 'pclPrettyPrint'
--
-- * 'pclUserIp'
--
-- * 'pclAccountId'
--
-- * 'pclKey'
--
-- * 'pclOauthToken'
--
-- * 'pclFields'
--
-- * 'pclAlt'
pretargetingConfigList
:: Int64 -- ^ 'accountId'
-> PretargetingConfigList
pretargetingConfigList pPclAccountId_ =
PretargetingConfigList
{ _pclQuotaUser = Nothing
, _pclPrettyPrint = True
, _pclUserIp = Nothing
, _pclAccountId = pPclAccountId_
, _pclKey = Nothing
, _pclOauthToken = Nothing
, _pclFields = Nothing
, _pclAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
pclQuotaUser :: Lens' PretargetingConfigList' (Maybe Text)
pclQuotaUser
= lens _pclQuotaUser (\ s a -> s{_pclQuotaUser = a})
-- | Returns response with indentations and line breaks.
pclPrettyPrint :: Lens' PretargetingConfigList' Bool
pclPrettyPrint
= lens _pclPrettyPrint
(\ s a -> s{_pclPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
pclUserIp :: Lens' PretargetingConfigList' (Maybe Text)
pclUserIp
= lens _pclUserIp (\ s a -> s{_pclUserIp = a})
-- | The account id to get the pretargeting configs for.
pclAccountId :: Lens' PretargetingConfigList' Int64
pclAccountId
= lens _pclAccountId (\ s a -> s{_pclAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
pclKey :: Lens' PretargetingConfigList' (Maybe Text)
pclKey = lens _pclKey (\ s a -> s{_pclKey = a})
-- | OAuth 2.0 token for the current user.
pclOauthToken :: Lens' PretargetingConfigList' (Maybe Text)
pclOauthToken
= lens _pclOauthToken
(\ s a -> s{_pclOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
pclFields :: Lens' PretargetingConfigList' (Maybe Text)
pclFields
= lens _pclFields (\ s a -> s{_pclFields = a})
-- | Data format for the response.
pclAlt :: Lens' PretargetingConfigList' Text
pclAlt = lens _pclAlt (\ s a -> s{_pclAlt = a})
instance GoogleRequest PretargetingConfigList' where
type Rs PretargetingConfigList' =
PretargetingConfigList
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u PretargetingConfigList{..}
= go _pclQuotaUser _pclPrettyPrint _pclUserIp
_pclAccountId
_pclKey
_pclOauthToken
_pclFields
_pclAlt
where go
= clientWithRoute
(Proxy :: Proxy PretargetingConfigListAPI)
r
u

View File

@ -0,0 +1,174 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.PretargetingConfig.Patch
-- Copyright : (c) 2015 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)
--
-- | Updates an existing pretargeting config. This method supports patch
-- semantics.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerPretargetingConfigPatch@.
module AdExchangeBuyer.PretargetingConfig.Patch
(
-- * REST Resource
PretargetingConfigPatchAPI
-- * Creating a Request
, pretargetingConfigPatch
, PretargetingConfigPatch
-- * Request Lenses
, pcpQuotaUser
, pcpPrettyPrint
, pcpUserIp
, pcpAccountId
, pcpKey
, pcpConfigId
, pcpOauthToken
, pcpFields
, pcpAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerPretargetingConfigPatch@ which the
-- 'PretargetingConfigPatch' request conforms to.
type PretargetingConfigPatchAPI =
"pretargetingconfigs" :>
Capture "accountId" Int64 :>
Capture "configId" Int64 :>
Patch '[JSON] PretargetingConfig
-- | Updates an existing pretargeting config. This method supports patch
-- semantics.
--
-- /See:/ 'pretargetingConfigPatch' smart constructor.
data PretargetingConfigPatch = PretargetingConfigPatch
{ _pcpQuotaUser :: !(Maybe Text)
, _pcpPrettyPrint :: !Bool
, _pcpUserIp :: !(Maybe Text)
, _pcpAccountId :: !Int64
, _pcpKey :: !(Maybe Text)
, _pcpConfigId :: !Int64
, _pcpOauthToken :: !(Maybe Text)
, _pcpFields :: !(Maybe Text)
, _pcpAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'PretargetingConfigPatch'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'pcpQuotaUser'
--
-- * 'pcpPrettyPrint'
--
-- * 'pcpUserIp'
--
-- * 'pcpAccountId'
--
-- * 'pcpKey'
--
-- * 'pcpConfigId'
--
-- * 'pcpOauthToken'
--
-- * 'pcpFields'
--
-- * 'pcpAlt'
pretargetingConfigPatch
:: Int64 -- ^ 'accountId'
-> Int64 -- ^ 'configId'
-> PretargetingConfigPatch
pretargetingConfigPatch pPcpAccountId_ pPcpConfigId_ =
PretargetingConfigPatch
{ _pcpQuotaUser = Nothing
, _pcpPrettyPrint = True
, _pcpUserIp = Nothing
, _pcpAccountId = pPcpAccountId_
, _pcpKey = Nothing
, _pcpConfigId = pPcpConfigId_
, _pcpOauthToken = Nothing
, _pcpFields = Nothing
, _pcpAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
pcpQuotaUser :: Lens' PretargetingConfigPatch' (Maybe Text)
pcpQuotaUser
= lens _pcpQuotaUser (\ s a -> s{_pcpQuotaUser = a})
-- | Returns response with indentations and line breaks.
pcpPrettyPrint :: Lens' PretargetingConfigPatch' Bool
pcpPrettyPrint
= lens _pcpPrettyPrint
(\ s a -> s{_pcpPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
pcpUserIp :: Lens' PretargetingConfigPatch' (Maybe Text)
pcpUserIp
= lens _pcpUserIp (\ s a -> s{_pcpUserIp = a})
-- | The account id to update the pretargeting config for.
pcpAccountId :: Lens' PretargetingConfigPatch' Int64
pcpAccountId
= lens _pcpAccountId (\ s a -> s{_pcpAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
pcpKey :: Lens' PretargetingConfigPatch' (Maybe Text)
pcpKey = lens _pcpKey (\ s a -> s{_pcpKey = a})
-- | The specific id of the configuration to update.
pcpConfigId :: Lens' PretargetingConfigPatch' Int64
pcpConfigId
= lens _pcpConfigId (\ s a -> s{_pcpConfigId = a})
-- | OAuth 2.0 token for the current user.
pcpOauthToken :: Lens' PretargetingConfigPatch' (Maybe Text)
pcpOauthToken
= lens _pcpOauthToken
(\ s a -> s{_pcpOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
pcpFields :: Lens' PretargetingConfigPatch' (Maybe Text)
pcpFields
= lens _pcpFields (\ s a -> s{_pcpFields = a})
-- | Data format for the response.
pcpAlt :: Lens' PretargetingConfigPatch' Text
pcpAlt = lens _pcpAlt (\ s a -> s{_pcpAlt = a})
instance GoogleRequest PretargetingConfigPatch' where
type Rs PretargetingConfigPatch' = PretargetingConfig
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u PretargetingConfigPatch{..}
= go _pcpQuotaUser _pcpPrettyPrint _pcpUserIp
_pcpAccountId
_pcpKey
_pcpConfigId
_pcpOauthToken
_pcpFields
_pcpAlt
where go
= clientWithRoute
(Proxy :: Proxy PretargetingConfigPatchAPI)
r
u

View File

@ -0,0 +1,174 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeBuyer.PretargetingConfig.Update
-- Copyright : (c) 2015 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)
--
-- | Updates an existing pretargeting config.
--
-- /See:/ <https://developers.google.com/ad-exchange/buyer-rest Ad Exchange Buyer API Reference> for @AdexchangebuyerPretargetingConfigUpdate@.
module AdExchangeBuyer.PretargetingConfig.Update
(
-- * REST Resource
PretargetingConfigUpdateAPI
-- * Creating a Request
, pretargetingConfigUpdate
, PretargetingConfigUpdate
-- * Request Lenses
, pcuQuotaUser
, pcuPrettyPrint
, pcuUserIp
, pcuAccountId
, pcuKey
, pcuConfigId
, pcuOauthToken
, pcuFields
, pcuAlt
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangebuyerPretargetingConfigUpdate@ which the
-- 'PretargetingConfigUpdate' request conforms to.
type PretargetingConfigUpdateAPI =
"pretargetingconfigs" :>
Capture "accountId" Int64 :>
Capture "configId" Int64 :>
Put '[JSON] PretargetingConfig
-- | Updates an existing pretargeting config.
--
-- /See:/ 'pretargetingConfigUpdate' smart constructor.
data PretargetingConfigUpdate = PretargetingConfigUpdate
{ _pcuQuotaUser :: !(Maybe Text)
, _pcuPrettyPrint :: !Bool
, _pcuUserIp :: !(Maybe Text)
, _pcuAccountId :: !Int64
, _pcuKey :: !(Maybe Text)
, _pcuConfigId :: !Int64
, _pcuOauthToken :: !(Maybe Text)
, _pcuFields :: !(Maybe Text)
, _pcuAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'PretargetingConfigUpdate'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'pcuQuotaUser'
--
-- * 'pcuPrettyPrint'
--
-- * 'pcuUserIp'
--
-- * 'pcuAccountId'
--
-- * 'pcuKey'
--
-- * 'pcuConfigId'
--
-- * 'pcuOauthToken'
--
-- * 'pcuFields'
--
-- * 'pcuAlt'
pretargetingConfigUpdate
:: Int64 -- ^ 'accountId'
-> Int64 -- ^ 'configId'
-> PretargetingConfigUpdate
pretargetingConfigUpdate pPcuAccountId_ pPcuConfigId_ =
PretargetingConfigUpdate
{ _pcuQuotaUser = Nothing
, _pcuPrettyPrint = True
, _pcuUserIp = Nothing
, _pcuAccountId = pPcuAccountId_
, _pcuKey = Nothing
, _pcuConfigId = pPcuConfigId_
, _pcuOauthToken = Nothing
, _pcuFields = Nothing
, _pcuAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
pcuQuotaUser :: Lens' PretargetingConfigUpdate' (Maybe Text)
pcuQuotaUser
= lens _pcuQuotaUser (\ s a -> s{_pcuQuotaUser = a})
-- | Returns response with indentations and line breaks.
pcuPrettyPrint :: Lens' PretargetingConfigUpdate' Bool
pcuPrettyPrint
= lens _pcuPrettyPrint
(\ s a -> s{_pcuPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
pcuUserIp :: Lens' PretargetingConfigUpdate' (Maybe Text)
pcuUserIp
= lens _pcuUserIp (\ s a -> s{_pcuUserIp = a})
-- | The account id to update the pretargeting config for.
pcuAccountId :: Lens' PretargetingConfigUpdate' Int64
pcuAccountId
= lens _pcuAccountId (\ s a -> s{_pcuAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
pcuKey :: Lens' PretargetingConfigUpdate' (Maybe Text)
pcuKey = lens _pcuKey (\ s a -> s{_pcuKey = a})
-- | The specific id of the configuration to update.
pcuConfigId :: Lens' PretargetingConfigUpdate' Int64
pcuConfigId
= lens _pcuConfigId (\ s a -> s{_pcuConfigId = a})
-- | OAuth 2.0 token for the current user.
pcuOauthToken :: Lens' PretargetingConfigUpdate' (Maybe Text)
pcuOauthToken
= lens _pcuOauthToken
(\ s a -> s{_pcuOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
pcuFields :: Lens' PretargetingConfigUpdate' (Maybe Text)
pcuFields
= lens _pcuFields (\ s a -> s{_pcuFields = a})
-- | Data format for the response.
pcuAlt :: Lens' PretargetingConfigUpdate' Text
pcuAlt = lens _pcuAlt (\ s a -> s{_pcuAlt = a})
instance GoogleRequest PretargetingConfigUpdate'
where
type Rs PretargetingConfigUpdate' =
PretargetingConfig
request = requestWithRoute defReq adExchangeBuyerURL
requestWithRoute r u PretargetingConfigUpdate{..}
= go _pcuQuotaUser _pcuPrettyPrint _pcuUserIp
_pcuAccountId
_pcuKey
_pcuConfigId
_pcuOauthToken
_pcuFields
_pcuAlt
where go
= clientWithRoute
(Proxy :: Proxy PretargetingConfigUpdateAPI)
r
u

View File

@ -0,0 +1,90 @@
name: gogol-adexchange-buyer
version: 0.0.1
synopsis: Ad Exchange Buyer API Client.
homepage: https://github.com/brendanhay/gogol
bug-reports: https://github.com/brendanhay/gogol/issues
license: OtherLicense
license-file: LICENSE
author: Brendan Hay
maintainer: Brendan Hay <brendan.g.hay@gmail.com>
copyright: Copyright (c) 2015 Brendan Hay
category: Network, Google, Cloud
build-type: Simple
cabal-version: >= 1.10
extra-source-files: README.md
description:
Accesses your bidding-account information, submits creatives for
validation, finds available direct deals, and retrieves performance
reports.
.
/Warning:/ This is an experimental prototype/preview release which is still
under exploratory development and not intended for public use, caveat emptor!
source-repository head
type: git
location: git://github.com/brendanhay/gogol.git
library
default-language: Haskell2010
hs-source-dirs: src gen
ghc-options: -Wall
exposed-modules:
Network.Google.AdExchangeBuyer
, Network.Google.AdExchangeBuyer.Types
, Network.Google.Resource.AdExchangeBuyer.Accounts.Get
, Network.Google.Resource.AdExchangeBuyer.Accounts.List
, Network.Google.Resource.AdExchangeBuyer.Accounts.Patch
, Network.Google.Resource.AdExchangeBuyer.Accounts.Update
, Network.Google.Resource.AdExchangeBuyer.BillingInfo.Get
, Network.Google.Resource.AdExchangeBuyer.BillingInfo.List
, Network.Google.Resource.AdExchangeBuyer.Budget.Get
, Network.Google.Resource.AdExchangeBuyer.Budget.Patch
, Network.Google.Resource.AdExchangeBuyer.Budget.Update
, Network.Google.Resource.AdExchangeBuyer.Clientaccess.Delete
, Network.Google.Resource.AdExchangeBuyer.Clientaccess.Get
, Network.Google.Resource.AdExchangeBuyer.Clientaccess.Insert
, Network.Google.Resource.AdExchangeBuyer.Clientaccess.List
, Network.Google.Resource.AdExchangeBuyer.Clientaccess.Patch
, Network.Google.Resource.AdExchangeBuyer.Clientaccess.Update
, Network.Google.Resource.AdExchangeBuyer.Creatives.Get
, Network.Google.Resource.AdExchangeBuyer.Creatives.Insert
, Network.Google.Resource.AdExchangeBuyer.Creatives.List
, Network.Google.Resource.AdExchangeBuyer.Deals.Get
, Network.Google.Resource.AdExchangeBuyer.Marketplacedeals.Delete
, Network.Google.Resource.AdExchangeBuyer.Marketplacedeals.Insert
, Network.Google.Resource.AdExchangeBuyer.Marketplacedeals.List
, Network.Google.Resource.AdExchangeBuyer.Marketplacedeals.Update
, Network.Google.Resource.AdExchangeBuyer.Marketplacenotes.Insert
, Network.Google.Resource.AdExchangeBuyer.Marketplacenotes.List
, Network.Google.Resource.AdExchangeBuyer.Marketplaceoffers.Get
, Network.Google.Resource.AdExchangeBuyer.Marketplaceoffers.Search
, Network.Google.Resource.AdExchangeBuyer.Marketplaceorders.Get
, Network.Google.Resource.AdExchangeBuyer.Marketplaceorders.Insert
, Network.Google.Resource.AdExchangeBuyer.Marketplaceorders.Patch
, Network.Google.Resource.AdExchangeBuyer.Marketplaceorders.Search
, Network.Google.Resource.AdExchangeBuyer.Marketplaceorders.Update
, Network.Google.Resource.AdExchangeBuyer.Negotiationrounds.Insert
, Network.Google.Resource.AdExchangeBuyer.Negotiations.Get
, Network.Google.Resource.AdExchangeBuyer.Negotiations.Insert
, Network.Google.Resource.AdExchangeBuyer.Negotiations.List
, Network.Google.Resource.AdExchangeBuyer.Offers.Get
, Network.Google.Resource.AdExchangeBuyer.Offers.Insert
, Network.Google.Resource.AdExchangeBuyer.Offers.List
, Network.Google.Resource.AdExchangeBuyer.PerformanceReport.List
, Network.Google.Resource.AdExchangeBuyer.PretargetingConfig.Delete
, Network.Google.Resource.AdExchangeBuyer.PretargetingConfig.Get
, Network.Google.Resource.AdExchangeBuyer.PretargetingConfig.Insert
, Network.Google.Resource.AdExchangeBuyer.PretargetingConfig.List
, Network.Google.Resource.AdExchangeBuyer.PretargetingConfig.Patch
, Network.Google.Resource.AdExchangeBuyer.PretargetingConfig.Update
other-modules:
Network.Google.AdExchangeBuyer.Types.Product
, Network.Google.AdExchangeBuyer.Types.Sum
build-depends:
gogol-core == 0.0.1.*
, base >= 4.7 && < 5

View File

View File

@ -0,0 +1,373 @@
Mozilla Public License Version 2.0
==================================
1. Definitions
--------------
1.1. "Contributor"
means each individual or legal entity that creates, contributes to
the creation of, or owns Covered Software.
1.2. "Contributor Version"
means the combination of the Contributions of others (if any) used
by a Contributor and that particular Contributor's Contribution.
1.3. "Contribution"
means Covered Software of a particular Contributor.
1.4. "Covered Software"
means Source Code Form to which the initial Contributor has attached
the notice in Exhibit A, the Executable Form of such Source Code
Form, and Modifications of such Source Code Form, in each case
including portions thereof.
1.5. "Incompatible With Secondary Licenses"
means
(a) that the initial Contributor has attached the notice described
in Exhibit B to the Covered Software; or
(b) that the Covered Software was made available under the terms of
version 1.1 or earlier of the License, but not also under the
terms of a Secondary License.
1.6. "Executable Form"
means any form of the work other than Source Code Form.
1.7. "Larger Work"
means a work that combines Covered Software with other material, in
a separate file or files, that is not Covered Software.
1.8. "License"
means this document.
1.9. "Licensable"
means having the right to grant, to the maximum extent possible,
whether at the time of the initial grant or subsequently, any and
all of the rights conveyed by this License.
1.10. "Modifications"
means any of the following:
(a) any file in Source Code Form that results from an addition to,
deletion from, or modification of the contents of Covered
Software; or
(b) any new file in Source Code Form that contains any Covered
Software.
1.11. "Patent Claims" of a Contributor
means any patent claim(s), including without limitation, method,
process, and apparatus claims, in any patent Licensable by such
Contributor that would be infringed, but for the grant of the
License, by the making, using, selling, offering for sale, having
made, import, or transfer of either its Contributions or its
Contributor Version.
1.12. "Secondary License"
means either the GNU General Public License, Version 2.0, the GNU
Lesser General Public License, Version 2.1, the GNU Affero General
Public License, Version 3.0, or any later versions of those
licenses.
1.13. "Source Code Form"
means the form of the work preferred for making modifications.
1.14. "You" (or "Your")
means an individual or a legal entity exercising rights under this
License. For legal entities, "You" includes any entity that
controls, is controlled by, or is under common control with You. For
purposes of this definition, "control" means (a) the power, direct
or indirect, to cause the direction or management of such entity,
whether by contract or otherwise, or (b) ownership of more than
fifty percent (50%) of the outstanding shares or beneficial
ownership of such entity.
2. License Grants and Conditions
--------------------------------
2.1. Grants
Each Contributor hereby grants You a world-wide, royalty-free,
non-exclusive license:
(a) under intellectual property rights (other than patent or trademark)
Licensable by such Contributor to use, reproduce, make available,
modify, display, perform, distribute, and otherwise exploit its
Contributions, either on an unmodified basis, with Modifications, or
as part of a Larger Work; and
(b) under Patent Claims of such Contributor to make, use, sell, offer
for sale, have made, import, and otherwise transfer either its
Contributions or its Contributor Version.
2.2. Effective Date
The licenses granted in Section 2.1 with respect to any Contribution
become effective for each Contribution on the date the Contributor first
distributes such Contribution.
2.3. Limitations on Grant Scope
The licenses granted in this Section 2 are the only rights granted under
this License. No additional rights or licenses will be implied from the
distribution or licensing of Covered Software under this License.
Notwithstanding Section 2.1(b) above, no patent license is granted by a
Contributor:
(a) for any code that a Contributor has removed from Covered Software;
or
(b) for infringements caused by: (i) Your and any other third party's
modifications of Covered Software, or (ii) the combination of its
Contributions with other software (except as part of its Contributor
Version); or
(c) under Patent Claims infringed by Covered Software in the absence of
its Contributions.
This License does not grant any rights in the trademarks, service marks,
or logos of any Contributor (except as may be necessary to comply with
the notice requirements in Section 3.4).
2.4. Subsequent Licenses
No Contributor makes additional grants as a result of Your choice to
distribute the Covered Software under a subsequent version of this
License (see Section 10.2) or under the terms of a Secondary License (if
permitted under the terms of Section 3.3).
2.5. Representation
Each Contributor represents that the Contributor believes its
Contributions are its original creation(s) or it has sufficient rights
to grant the rights to its Contributions conveyed by this License.
2.6. Fair Use
This License is not intended to limit any rights You have under
applicable copyright doctrines of fair use, fair dealing, or other
equivalents.
2.7. Conditions
Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted
in Section 2.1.
3. Responsibilities
-------------------
3.1. Distribution of Source Form
All distribution of Covered Software in Source Code Form, including any
Modifications that You create or to which You contribute, must be under
the terms of this License. You must inform recipients that the Source
Code Form of the Covered Software is governed by the terms of this
License, and how they can obtain a copy of this License. You may not
attempt to alter or restrict the recipients' rights in the Source Code
Form.
3.2. Distribution of Executable Form
If You distribute Covered Software in Executable Form then:
(a) such Covered Software must also be made available in Source Code
Form, as described in Section 3.1, and You must inform recipients of
the Executable Form how they can obtain a copy of such Source Code
Form by reasonable means in a timely manner, at a charge no more
than the cost of distribution to the recipient; and
(b) You may distribute such Executable Form under the terms of this
License, or sublicense it under different terms, provided that the
license for the Executable Form does not attempt to limit or alter
the recipients' rights in the Source Code Form under this License.
3.3. Distribution of a Larger Work
You may create and distribute a Larger Work under terms of Your choice,
provided that You also comply with the requirements of this License for
the Covered Software. If the Larger Work is a combination of Covered
Software with a work governed by one or more Secondary Licenses, and the
Covered Software is not Incompatible With Secondary Licenses, this
License permits You to additionally distribute such Covered Software
under the terms of such Secondary License(s), so that the recipient of
the Larger Work may, at their option, further distribute the Covered
Software under the terms of either this License or such Secondary
License(s).
3.4. Notices
You may not remove or alter the substance of any license notices
(including copyright notices, patent notices, disclaimers of warranty,
or limitations of liability) contained within the Source Code Form of
the Covered Software, except that You may alter any license notices to
the extent required to remedy known factual inaccuracies.
3.5. Application of Additional Terms
You may choose to offer, and to charge a fee for, warranty, support,
indemnity or liability obligations to one or more recipients of Covered
Software. However, You may do so only on Your own behalf, and not on
behalf of any Contributor. You must make it absolutely clear that any
such warranty, support, indemnity, or liability obligation is offered by
You alone, and You hereby agree to indemnify every Contributor for any
liability incurred by such Contributor as a result of warranty, support,
indemnity or liability terms You offer. You may include additional
disclaimers of warranty and limitations of liability specific to any
jurisdiction.
4. Inability to Comply Due to Statute or Regulation
---------------------------------------------------
If it is impossible for You to comply with any of the terms of this
License with respect to some or all of the Covered Software due to
statute, judicial order, or regulation then You must: (a) comply with
the terms of this License to the maximum extent possible; and (b)
describe the limitations and the code they affect. Such description must
be placed in a text file included with all distributions of the Covered
Software under this License. Except to the extent prohibited by statute
or regulation, such description must be sufficiently detailed for a
recipient of ordinary skill to be able to understand it.
5. Termination
--------------
5.1. The rights granted under this License will terminate automatically
if You fail to comply with any of its terms. However, if You become
compliant, then the rights granted under this License from a particular
Contributor are reinstated (a) provisionally, unless and until such
Contributor explicitly and finally terminates Your grants, and (b) on an
ongoing basis, if such Contributor fails to notify You of the
non-compliance by some reasonable means prior to 60 days after You have
come back into compliance. Moreover, Your grants from a particular
Contributor are reinstated on an ongoing basis if such Contributor
notifies You of the non-compliance by some reasonable means, this is the
first time You have received notice of non-compliance with this License
from such Contributor, and You become compliant prior to 30 days after
Your receipt of the notice.
5.2. If You initiate litigation against any entity by asserting a patent
infringement claim (excluding declaratory judgment actions,
counter-claims, and cross-claims) alleging that a Contributor Version
directly or indirectly infringes any patent, then the rights granted to
You by any and all Contributors for the Covered Software under Section
2.1 of this License shall terminate.
5.3. In the event of termination under Sections 5.1 or 5.2 above, all
end user license agreements (excluding distributors and resellers) which
have been validly granted by You or Your distributors under this License
prior to termination shall survive termination.
************************************************************************
* *
* 6. Disclaimer of Warranty *
* ------------------------- *
* *
* Covered Software is provided under this License on an "as is" *
* basis, without warranty of any kind, either expressed, implied, or *
* statutory, including, without limitation, warranties that the *
* Covered Software is free of defects, merchantable, fit for a *
* particular purpose or non-infringing. The entire risk as to the *
* quality and performance of the Covered Software is with You. *
* Should any Covered Software prove defective in any respect, You *
* (not any Contributor) assume the cost of any necessary servicing, *
* repair, or correction. This disclaimer of warranty constitutes an *
* essential part of this License. No use of any Covered Software is *
* authorized under this License except under this disclaimer. *
* *
************************************************************************
************************************************************************
* *
* 7. Limitation of Liability *
* -------------------------- *
* *
* Under no circumstances and under no legal theory, whether tort *
* (including negligence), contract, or otherwise, shall any *
* Contributor, or anyone who distributes Covered Software as *
* permitted above, be liable to You for any direct, indirect, *
* special, incidental, or consequential damages of any character *
* including, without limitation, damages for lost profits, loss of *
* goodwill, work stoppage, computer failure or malfunction, or any *
* and all other commercial damages or losses, even if such party *
* shall have been informed of the possibility of such damages. This *
* limitation of liability shall not apply to liability for death or *
* personal injury resulting from such party's negligence to the *
* extent applicable law prohibits such limitation. Some *
* jurisdictions do not allow the exclusion or limitation of *
* incidental or consequential damages, so this exclusion and *
* limitation may not apply to You. *
* *
************************************************************************
8. Litigation
-------------
Any litigation relating to this License may be brought only in the
courts of a jurisdiction where the defendant maintains its principal
place of business and such litigation shall be governed by laws of that
jurisdiction, without reference to its conflict-of-law provisions.
Nothing in this Section shall prevent a party's ability to bring
cross-claims or counter-claims.
9. Miscellaneous
----------------
This License represents the complete agreement concerning the subject
matter hereof. If any provision of this License is held to be
unenforceable, such provision shall be reformed only to the extent
necessary to make it enforceable. Any law or regulation which provides
that the language of a contract shall be construed against the drafter
shall not be used to construe this License against a Contributor.
10. Versions of the License
---------------------------
10.1. New Versions
Mozilla Foundation is the license steward. Except as provided in Section
10.3, no one other than the license steward has the right to modify or
publish new versions of this License. Each version will be given a
distinguishing version number.
10.2. Effect of New Versions
You may distribute the Covered Software under the terms of the version
of the License under which You originally received the Covered Software,
or under the terms of any subsequent version published by the license
steward.
10.3. Modified Versions
If you create software not governed by this License, and you want to
create a new license for such software, you may create and use a
modified version of this License if you rename the license and remove
any references to the name of the license steward (except to note that
such modified license differs from this License).
10.4. Distributing Source Code Form that is Incompatible With Secondary
Licenses
If You choose to distribute Source Code Form that is Incompatible With
Secondary Licenses under the terms of this version of the License, the
notice described in Exhibit B of this License must be attached.
Exhibit A - Source Code Form License Notice
-------------------------------------------
This Source Code Form is subject to the terms of the Mozilla Public
License, v. 2.0. If a copy of the MPL was not distributed with this
file, You can obtain one at http://mozilla.org/MPL/2.0/.
If it is not possible or desirable to put the notice in a particular
file, then You may include the notice in a location (such as a LICENSE
file in a relevant directory) where a recipient would be likely to look
for such a notice.
You may add additional accurate notices of copyright ownership.
Exhibit B - "Incompatible With Secondary Licenses" Notice
---------------------------------------------------------
This Source Code Form is "Incompatible With Secondary Licenses", as
defined by the Mozilla Public License, v. 2.0.

View File

@ -0,0 +1 @@
include ../share/library.mk

View File

@ -0,0 +1,28 @@
# gogol-adexchange-seller
* [Version](#version)
* [Description](#description)
* [Contribute](#contribute)
* [Licence](#licence)
## Version
`0.0.1`
## Description
A client library for the Ad Exchange Seller API.
## Contribute
For any problems, comments, or feedback please create an issue [here on GitHub](https://github.com/brendanhay/amazonka/issues).
> _Note:_ this library is an auto-generated Haskell package. Please see `amazonka-gen` for more information.
## Licence
`gogol-adexchange-seller` is released under the [Mozilla Public License Version 2.0](http://www.mozilla.org/MPL/).

View File

@ -0,0 +1,2 @@
import Distribution.Simple
main = defaultMain

View File

@ -0,0 +1,239 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.AdExchangeSeller
-- Copyright : (c) 2015 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)
--
-- -- | Gives Ad Exchange seller users access to their inventory and the ability
-- to generate reports
--
-- /See:/ <https://developers.google.com/ad-exchange/seller-rest/ Ad Exchange Seller API Reference>
module Network.Google.AdExchangeSeller
(
-- * API
AdExchangeSellerAPI
, adExchangeSellerAPI
, adExchangeSellerURL
-- * Service Methods
-- * REST Resources
-- ** AdexchangesellerAccountsAdclientsList
, module AdExchangeSeller.Accounts.Adclients.List
-- ** AdexchangesellerAccountsAlertsList
, module AdExchangeSeller.Accounts.Alerts.List
-- ** AdexchangesellerAccountsCustomchannelsGet
, module AdExchangeSeller.Accounts.Customchannels.Get
-- ** AdexchangesellerAccountsCustomchannelsList
, module AdExchangeSeller.Accounts.Customchannels.List
-- ** AdexchangesellerAccountsGet
, module AdExchangeSeller.Accounts.Get
-- ** AdexchangesellerAccountsList
, module AdExchangeSeller.Accounts.List
-- ** AdexchangesellerAccountsMetadataDimensionsList
, module AdExchangeSeller.Accounts.Metadata.Dimensions.List
-- ** AdexchangesellerAccountsMetadataMetricsList
, module AdExchangeSeller.Accounts.Metadata.Metrics.List
-- ** AdexchangesellerAccountsPreferreddealsGet
, module AdExchangeSeller.Accounts.Preferreddeals.Get
-- ** AdexchangesellerAccountsPreferreddealsList
, module AdExchangeSeller.Accounts.Preferreddeals.List
-- ** AdexchangesellerAccountsReportsGenerate
, module AdExchangeSeller.Accounts.Reports.Generate
-- ** AdexchangesellerAccountsReportsSavedGenerate
, module AdExchangeSeller.Accounts.Reports.Saved.Generate
-- ** AdexchangesellerAccountsReportsSavedList
, module AdExchangeSeller.Accounts.Reports.Saved.List
-- ** AdexchangesellerAccountsURLchannelsList
, module AdExchangeSeller.Accounts.URLchannels.List
-- * Types
-- ** ReportingMetadataEntry
, ReportingMetadataEntry
, reportingMetadataEntry
, rmeKind
, rmeRequiredMetrics
, rmeCompatibleMetrics
, rmeRequiredDimensions
, rmeId
, rmeCompatibleDimensions
, rmeSupportedProducts
-- ** AdClients
, AdClients
, adClients
, acEtag
, acNextPageToken
, acKind
, acItems
-- ** Accounts
, Accounts
, accounts
, aEtag
, aNextPageToken
, aKind
, aItems
-- ** Alerts
, Alerts
, alerts
, aleKind
, aleItems
-- ** SavedReports
, SavedReports
, savedReports
, srEtag
, srNextPageToken
, srKind
, srItems
-- ** SavedReport
, SavedReport
, savedReport
, sKind
, sName
, sId
-- ** URLChannels
, URLChannels
, uRLChannels
, ucEtag
, ucNextPageToken
, ucKind
, ucItems
-- ** CustomChannels
, CustomChannels
, customChannels
, ccEtag
, ccNextPageToken
, ccKind
, ccItems
-- ** Alert
, Alert
, alert
, aaKind
, aaSeverity
, aaId
, aaType
, aaMessage
-- ** Report
, Report
, report
, rKind
, rAverages
, rWarnings
, rRows
, rTotals
, rHeaders
, rTotalMatchedRows
-- ** Account
, Account
, account
, accKind
, accName
, accId
-- ** AdClient
, AdClient
, adClient
, adKind
, adArcOptIn
, adSupportsReporting
, adId
, adProductCode
-- ** PreferredDeals
, PreferredDeals
, preferredDeals
, pdKind
, pdItems
-- ** Metadata
, Metadata
, metadata
, mKind
, mItems
-- ** CustomChannel
, CustomChannel
, customChannel
, cTargetingInfo
, cKind
, cName
, cCode
, cId
-- ** URLChannel
, URLChannel
, uRLChannel
, urlcKind
, urlcId
, urlcUrlPattern
-- ** PreferredDeal
, PreferredDeal
, preferredDeal
, pAdvertiserName
, pCurrencyCode
, pStartTime
, pKind
, pBuyerNetworkName
, pEndTime
, pId
, pFixedCpm
) where
import Network.Google.AdExchangeSeller.Types
import Network.Google.Prelude
import Network.Google.Resource.AdExchangeSeller.Accounts.Adclients.List
import Network.Google.Resource.AdExchangeSeller.Accounts.Alerts.List
import Network.Google.Resource.AdExchangeSeller.Accounts.Customchannels.Get
import Network.Google.Resource.AdExchangeSeller.Accounts.Customchannels.List
import Network.Google.Resource.AdExchangeSeller.Accounts.Get
import Network.Google.Resource.AdExchangeSeller.Accounts.List
import Network.Google.Resource.AdExchangeSeller.Accounts.Metadata.Dimensions.List
import Network.Google.Resource.AdExchangeSeller.Accounts.Metadata.Metrics.List
import Network.Google.Resource.AdExchangeSeller.Accounts.Preferreddeals.Get
import Network.Google.Resource.AdExchangeSeller.Accounts.Preferreddeals.List
import Network.Google.Resource.AdExchangeSeller.Accounts.Reports.Generate
import Network.Google.Resource.AdExchangeSeller.Accounts.Reports.Saved.Generate
import Network.Google.Resource.AdExchangeSeller.Accounts.Reports.Saved.List
import Network.Google.Resource.AdExchangeSeller.Accounts.URLchannels.List
{- $resources
TODO
-}
type AdExchangeSellerAPI = Accounts
adExchangeSellerAPI :: Proxy AdExchangeSellerAPI
adExchangeSellerAPI = Proxy

View File

@ -0,0 +1,170 @@
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE OverloadedStrings #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
-- |
-- Module : Network.Google.AdExchangeSeller.Types
-- Copyright : (c) 2015 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)
--
module Network.Google.AdExchangeSeller.Types
(
-- * Service URL
adExchangeSellerURL
-- * ReportingMetadataEntry
, ReportingMetadataEntry
, reportingMetadataEntry
, rmeKind
, rmeRequiredMetrics
, rmeCompatibleMetrics
, rmeRequiredDimensions
, rmeId
, rmeCompatibleDimensions
, rmeSupportedProducts
-- * AdClients
, AdClients
, adClients
, acEtag
, acNextPageToken
, acKind
, acItems
-- * Accounts
, Accounts
, accounts
, aEtag
, aNextPageToken
, aKind
, aItems
-- * Alerts
, Alerts
, alerts
, aleKind
, aleItems
-- * SavedReports
, SavedReports
, savedReports
, srEtag
, srNextPageToken
, srKind
, srItems
-- * SavedReport
, SavedReport
, savedReport
, sKind
, sName
, sId
-- * URLChannels
, URLChannels
, uRLChannels
, ucEtag
, ucNextPageToken
, ucKind
, ucItems
-- * CustomChannels
, CustomChannels
, customChannels
, ccEtag
, ccNextPageToken
, ccKind
, ccItems
-- * Alert
, Alert
, alert
, aaKind
, aaSeverity
, aaId
, aaType
, aaMessage
-- * Report
, Report
, report
, rKind
, rAverages
, rWarnings
, rRows
, rTotals
, rHeaders
, rTotalMatchedRows
-- * Account
, Account
, account
, accKind
, accName
, accId
-- * AdClient
, AdClient
, adClient
, adKind
, adArcOptIn
, adSupportsReporting
, adId
, adProductCode
-- * PreferredDeals
, PreferredDeals
, preferredDeals
, pdKind
, pdItems
-- * Metadata
, Metadata
, metadata
, mKind
, mItems
-- * CustomChannel
, CustomChannel
, customChannel
, cTargetingInfo
, cKind
, cName
, cCode
, cId
-- * URLChannel
, URLChannel
, uRLChannel
, urlcKind
, urlcId
, urlcUrlPattern
-- * PreferredDeal
, PreferredDeal
, preferredDeal
, pAdvertiserName
, pCurrencyCode
, pStartTime
, pKind
, pBuyerNetworkName
, pEndTime
, pId
, pFixedCpm
) where
import Network.Google.AdExchangeSeller.Types.Product
import Network.Google.AdExchangeSeller.Types.Sum
import Network.Google.Prelude
-- | URL referring to version 'v2.0' of the Ad Exchange Seller API.
adExchangeSellerURL :: BaseURL
adExchangeSellerURL
= BaseUrl Https
"https://www.googleapis.com/adexchangeseller/v2.0/"
443

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,18 @@
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE OverloadedStrings #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
-- |
-- Module : Network.Google.AdExchangeSeller.Types.Sum
-- Copyright : (c) 2015 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)
--
module Network.Google.AdExchangeSeller.Types.Sum where
import Network.Google.Prelude

View File

@ -0,0 +1,188 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeSeller.Accounts.Adclients.List
-- Copyright : (c) 2015 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)
--
-- | List all ad clients in this Ad Exchange account.
--
-- /See:/ <https://developers.google.com/ad-exchange/seller-rest/ Ad Exchange Seller API Reference> for @AdexchangesellerAccountsAdclientsList@.
module AdExchangeSeller.Accounts.Adclients.List
(
-- * REST Resource
AccountsAdclientsListAPI
-- * Creating a Request
, accountsAdclientsList
, AccountsAdclientsList
-- * Request Lenses
, aalQuotaUser
, aalPrettyPrint
, aalUserIp
, aalAccountId
, aalKey
, aalPageToken
, aalOauthToken
, aalMaxResults
, aalFields
, aalAlt
) where
import Network.Google.AdExchangeSeller.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangesellerAccountsAdclientsList@ which the
-- 'AccountsAdclientsList' request conforms to.
type AccountsAdclientsListAPI =
"accounts" :>
Capture "accountId" Text :>
"adclients" :>
QueryParam "pageToken" Text :>
QueryParam "maxResults" Word32 :>
Get '[JSON] AdClients
-- | List all ad clients in this Ad Exchange account.
--
-- /See:/ 'accountsAdclientsList' smart constructor.
data AccountsAdclientsList = AccountsAdclientsList
{ _aalQuotaUser :: !(Maybe Text)
, _aalPrettyPrint :: !Bool
, _aalUserIp :: !(Maybe Text)
, _aalAccountId :: !Text
, _aalKey :: !(Maybe Text)
, _aalPageToken :: !(Maybe Text)
, _aalOauthToken :: !(Maybe Text)
, _aalMaxResults :: !(Maybe Word32)
, _aalFields :: !(Maybe Text)
, _aalAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'AccountsAdclientsList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'aalQuotaUser'
--
-- * 'aalPrettyPrint'
--
-- * 'aalUserIp'
--
-- * 'aalAccountId'
--
-- * 'aalKey'
--
-- * 'aalPageToken'
--
-- * 'aalOauthToken'
--
-- * 'aalMaxResults'
--
-- * 'aalFields'
--
-- * 'aalAlt'
accountsAdclientsList
:: Text -- ^ 'accountId'
-> AccountsAdclientsList
accountsAdclientsList pAalAccountId_ =
AccountsAdclientsList
{ _aalQuotaUser = Nothing
, _aalPrettyPrint = True
, _aalUserIp = Nothing
, _aalAccountId = pAalAccountId_
, _aalKey = Nothing
, _aalPageToken = Nothing
, _aalOauthToken = Nothing
, _aalMaxResults = Nothing
, _aalFields = Nothing
, _aalAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
aalQuotaUser :: Lens' AccountsAdclientsList' (Maybe Text)
aalQuotaUser
= lens _aalQuotaUser (\ s a -> s{_aalQuotaUser = a})
-- | Returns response with indentations and line breaks.
aalPrettyPrint :: Lens' AccountsAdclientsList' Bool
aalPrettyPrint
= lens _aalPrettyPrint
(\ s a -> s{_aalPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
aalUserIp :: Lens' AccountsAdclientsList' (Maybe Text)
aalUserIp
= lens _aalUserIp (\ s a -> s{_aalUserIp = a})
-- | Account to which the ad client belongs.
aalAccountId :: Lens' AccountsAdclientsList' Text
aalAccountId
= lens _aalAccountId (\ s a -> s{_aalAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
aalKey :: Lens' AccountsAdclientsList' (Maybe Text)
aalKey = lens _aalKey (\ s a -> s{_aalKey = a})
-- | A continuation token, used to page through ad clients. To retrieve the
-- next page, set this parameter to the value of \"nextPageToken\" from the
-- previous response.
aalPageToken :: Lens' AccountsAdclientsList' (Maybe Text)
aalPageToken
= lens _aalPageToken (\ s a -> s{_aalPageToken = a})
-- | OAuth 2.0 token for the current user.
aalOauthToken :: Lens' AccountsAdclientsList' (Maybe Text)
aalOauthToken
= lens _aalOauthToken
(\ s a -> s{_aalOauthToken = a})
-- | The maximum number of ad clients to include in the response, used for
-- paging.
aalMaxResults :: Lens' AccountsAdclientsList' (Maybe Word32)
aalMaxResults
= lens _aalMaxResults
(\ s a -> s{_aalMaxResults = a})
-- | Selector specifying which fields to include in a partial response.
aalFields :: Lens' AccountsAdclientsList' (Maybe Text)
aalFields
= lens _aalFields (\ s a -> s{_aalFields = a})
-- | Data format for the response.
aalAlt :: Lens' AccountsAdclientsList' Text
aalAlt = lens _aalAlt (\ s a -> s{_aalAlt = a})
instance GoogleRequest AccountsAdclientsList' where
type Rs AccountsAdclientsList' = AdClients
request = requestWithRoute defReq adExchangeSellerURL
requestWithRoute r u AccountsAdclientsList{..}
= go _aalQuotaUser _aalPrettyPrint _aalUserIp
_aalAccountId
_aalKey
_aalPageToken
_aalOauthToken
_aalMaxResults
_aalFields
_aalAlt
where go
= clientWithRoute
(Proxy :: Proxy AccountsAdclientsListAPI)
r
u

View File

@ -0,0 +1,167 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeSeller.Accounts.Alerts.List
-- Copyright : (c) 2015 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)
--
-- | List the alerts for this Ad Exchange account.
--
-- /See:/ <https://developers.google.com/ad-exchange/seller-rest/ Ad Exchange Seller API Reference> for @AdexchangesellerAccountsAlertsList@.
module AdExchangeSeller.Accounts.Alerts.List
(
-- * REST Resource
AccountsAlertsListAPI
-- * Creating a Request
, accountsAlertsList
, AccountsAlertsList
-- * Request Lenses
, aQuotaUser
, aPrettyPrint
, aUserIp
, aLocale
, aAccountId
, aKey
, aOauthToken
, aFields
, aAlt
) where
import Network.Google.AdExchangeSeller.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangesellerAccountsAlertsList@ which the
-- 'AccountsAlertsList' request conforms to.
type AccountsAlertsListAPI =
"accounts" :>
Capture "accountId" Text :>
"alerts" :>
QueryParam "locale" Text :> Get '[JSON] Alerts
-- | List the alerts for this Ad Exchange account.
--
-- /See:/ 'accountsAlertsList' smart constructor.
data AccountsAlertsList = AccountsAlertsList
{ _aQuotaUser :: !(Maybe Text)
, _aPrettyPrint :: !Bool
, _aUserIp :: !(Maybe Text)
, _aLocale :: !(Maybe Text)
, _aAccountId :: !Text
, _aKey :: !(Maybe Text)
, _aOauthToken :: !(Maybe Text)
, _aFields :: !(Maybe Text)
, _aAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'AccountsAlertsList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'aQuotaUser'
--
-- * 'aPrettyPrint'
--
-- * 'aUserIp'
--
-- * 'aLocale'
--
-- * 'aAccountId'
--
-- * 'aKey'
--
-- * 'aOauthToken'
--
-- * 'aFields'
--
-- * 'aAlt'
accountsAlertsList
:: Text -- ^ 'accountId'
-> AccountsAlertsList
accountsAlertsList pAAccountId_ =
AccountsAlertsList
{ _aQuotaUser = Nothing
, _aPrettyPrint = True
, _aUserIp = Nothing
, _aLocale = Nothing
, _aAccountId = pAAccountId_
, _aKey = Nothing
, _aOauthToken = Nothing
, _aFields = Nothing
, _aAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
aQuotaUser :: Lens' AccountsAlertsList' (Maybe Text)
aQuotaUser
= lens _aQuotaUser (\ s a -> s{_aQuotaUser = a})
-- | Returns response with indentations and line breaks.
aPrettyPrint :: Lens' AccountsAlertsList' Bool
aPrettyPrint
= lens _aPrettyPrint (\ s a -> s{_aPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
aUserIp :: Lens' AccountsAlertsList' (Maybe Text)
aUserIp = lens _aUserIp (\ s a -> s{_aUserIp = a})
-- | The locale to use for translating alert messages. The account locale
-- will be used if this is not supplied. The AdSense default (English) will
-- be used if the supplied locale is invalid or unsupported.
aLocale :: Lens' AccountsAlertsList' (Maybe Text)
aLocale = lens _aLocale (\ s a -> s{_aLocale = a})
-- | Account owning the alerts.
aAccountId :: Lens' AccountsAlertsList' Text
aAccountId
= lens _aAccountId (\ s a -> s{_aAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
aKey :: Lens' AccountsAlertsList' (Maybe Text)
aKey = lens _aKey (\ s a -> s{_aKey = a})
-- | OAuth 2.0 token for the current user.
aOauthToken :: Lens' AccountsAlertsList' (Maybe Text)
aOauthToken
= lens _aOauthToken (\ s a -> s{_aOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
aFields :: Lens' AccountsAlertsList' (Maybe Text)
aFields = lens _aFields (\ s a -> s{_aFields = a})
-- | Data format for the response.
aAlt :: Lens' AccountsAlertsList' Text
aAlt = lens _aAlt (\ s a -> s{_aAlt = a})
instance GoogleRequest AccountsAlertsList' where
type Rs AccountsAlertsList' = Alerts
request = requestWithRoute defReq adExchangeSellerURL
requestWithRoute r u AccountsAlertsList{..}
= go _aQuotaUser _aPrettyPrint _aUserIp _aLocale
_aAccountId
_aKey
_aOauthToken
_aFields
_aAlt
where go
= clientWithRoute
(Proxy :: Proxy AccountsAlertsListAPI)
r
u

View File

@ -0,0 +1,191 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeSeller.Accounts.Customchannels.Get
-- Copyright : (c) 2015 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)
--
-- | Get the specified custom channel from the specified ad client.
--
-- /See:/ <https://developers.google.com/ad-exchange/seller-rest/ Ad Exchange Seller API Reference> for @AdexchangesellerAccountsCustomchannelsGet@.
module AdExchangeSeller.Accounts.Customchannels.Get
(
-- * REST Resource
AccountsCustomchannelsGetAPI
-- * Creating a Request
, accountsCustomchannelsGet
, AccountsCustomchannelsGet
-- * Request Lenses
, acgQuotaUser
, acgPrettyPrint
, acgCustomChannelId
, acgUserIp
, acgAdClientId
, acgAccountId
, acgKey
, acgOauthToken
, acgFields
, acgAlt
) where
import Network.Google.AdExchangeSeller.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangesellerAccountsCustomchannelsGet@ which the
-- 'AccountsCustomchannelsGet' request conforms to.
type AccountsCustomchannelsGetAPI =
"accounts" :>
Capture "accountId" Text :>
"adclients" :>
Capture "adClientId" Text :>
"customchannels" :>
Capture "customChannelId" Text :>
Get '[JSON] CustomChannel
-- | Get the specified custom channel from the specified ad client.
--
-- /See:/ 'accountsCustomchannelsGet' smart constructor.
data AccountsCustomchannelsGet = AccountsCustomchannelsGet
{ _acgQuotaUser :: !(Maybe Text)
, _acgPrettyPrint :: !Bool
, _acgCustomChannelId :: !Text
, _acgUserIp :: !(Maybe Text)
, _acgAdClientId :: !Text
, _acgAccountId :: !Text
, _acgKey :: !(Maybe Text)
, _acgOauthToken :: !(Maybe Text)
, _acgFields :: !(Maybe Text)
, _acgAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'AccountsCustomchannelsGet'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'acgQuotaUser'
--
-- * 'acgPrettyPrint'
--
-- * 'acgCustomChannelId'
--
-- * 'acgUserIp'
--
-- * 'acgAdClientId'
--
-- * 'acgAccountId'
--
-- * 'acgKey'
--
-- * 'acgOauthToken'
--
-- * 'acgFields'
--
-- * 'acgAlt'
accountsCustomchannelsGet
:: Text -- ^ 'customChannelId'
-> Text -- ^ 'adClientId'
-> Text -- ^ 'accountId'
-> AccountsCustomchannelsGet
accountsCustomchannelsGet pAcgCustomChannelId_ pAcgAdClientId_ pAcgAccountId_ =
AccountsCustomchannelsGet
{ _acgQuotaUser = Nothing
, _acgPrettyPrint = True
, _acgCustomChannelId = pAcgCustomChannelId_
, _acgUserIp = Nothing
, _acgAdClientId = pAcgAdClientId_
, _acgAccountId = pAcgAccountId_
, _acgKey = Nothing
, _acgOauthToken = Nothing
, _acgFields = Nothing
, _acgAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
acgQuotaUser :: Lens' AccountsCustomchannelsGet' (Maybe Text)
acgQuotaUser
= lens _acgQuotaUser (\ s a -> s{_acgQuotaUser = a})
-- | Returns response with indentations and line breaks.
acgPrettyPrint :: Lens' AccountsCustomchannelsGet' Bool
acgPrettyPrint
= lens _acgPrettyPrint
(\ s a -> s{_acgPrettyPrint = a})
-- | Custom channel to retrieve.
acgCustomChannelId :: Lens' AccountsCustomchannelsGet' Text
acgCustomChannelId
= lens _acgCustomChannelId
(\ s a -> s{_acgCustomChannelId = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
acgUserIp :: Lens' AccountsCustomchannelsGet' (Maybe Text)
acgUserIp
= lens _acgUserIp (\ s a -> s{_acgUserIp = a})
-- | Ad client which contains the custom channel.
acgAdClientId :: Lens' AccountsCustomchannelsGet' Text
acgAdClientId
= lens _acgAdClientId
(\ s a -> s{_acgAdClientId = a})
-- | Account to which the ad client belongs.
acgAccountId :: Lens' AccountsCustomchannelsGet' Text
acgAccountId
= lens _acgAccountId (\ s a -> s{_acgAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
acgKey :: Lens' AccountsCustomchannelsGet' (Maybe Text)
acgKey = lens _acgKey (\ s a -> s{_acgKey = a})
-- | OAuth 2.0 token for the current user.
acgOauthToken :: Lens' AccountsCustomchannelsGet' (Maybe Text)
acgOauthToken
= lens _acgOauthToken
(\ s a -> s{_acgOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
acgFields :: Lens' AccountsCustomchannelsGet' (Maybe Text)
acgFields
= lens _acgFields (\ s a -> s{_acgFields = a})
-- | Data format for the response.
acgAlt :: Lens' AccountsCustomchannelsGet' Text
acgAlt = lens _acgAlt (\ s a -> s{_acgAlt = a})
instance GoogleRequest AccountsCustomchannelsGet'
where
type Rs AccountsCustomchannelsGet' = CustomChannel
request = requestWithRoute defReq adExchangeSellerURL
requestWithRoute r u AccountsCustomchannelsGet{..}
= go _acgQuotaUser _acgPrettyPrint
_acgCustomChannelId
_acgUserIp
_acgAdClientId
_acgAccountId
_acgKey
_acgOauthToken
_acgFields
_acgAlt
where go
= clientWithRoute
(Proxy :: Proxy AccountsCustomchannelsGetAPI)
r
u

View File

@ -0,0 +1,206 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeSeller.Accounts.Customchannels.List
-- Copyright : (c) 2015 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)
--
-- | List all custom channels in the specified ad client for this Ad Exchange
-- account.
--
-- /See:/ <https://developers.google.com/ad-exchange/seller-rest/ Ad Exchange Seller API Reference> for @AdexchangesellerAccountsCustomchannelsList@.
module AdExchangeSeller.Accounts.Customchannels.List
(
-- * REST Resource
AccountsCustomchannelsListAPI
-- * Creating a Request
, accountsCustomchannelsList
, AccountsCustomchannelsList
-- * Request Lenses
, aclQuotaUser
, aclPrettyPrint
, aclUserIp
, aclAdClientId
, aclAccountId
, aclKey
, aclPageToken
, aclOauthToken
, aclMaxResults
, aclFields
, aclAlt
) where
import Network.Google.AdExchangeSeller.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangesellerAccountsCustomchannelsList@ which the
-- 'AccountsCustomchannelsList' request conforms to.
type AccountsCustomchannelsListAPI =
"accounts" :>
Capture "accountId" Text :>
"adclients" :>
Capture "adClientId" Text :>
"customchannels" :>
QueryParam "pageToken" Text :>
QueryParam "maxResults" Word32 :>
Get '[JSON] CustomChannels
-- | List all custom channels in the specified ad client for this Ad Exchange
-- account.
--
-- /See:/ 'accountsCustomchannelsList' smart constructor.
data AccountsCustomchannelsList = AccountsCustomchannelsList
{ _aclQuotaUser :: !(Maybe Text)
, _aclPrettyPrint :: !Bool
, _aclUserIp :: !(Maybe Text)
, _aclAdClientId :: !Text
, _aclAccountId :: !Text
, _aclKey :: !(Maybe Text)
, _aclPageToken :: !(Maybe Text)
, _aclOauthToken :: !(Maybe Text)
, _aclMaxResults :: !(Maybe Word32)
, _aclFields :: !(Maybe Text)
, _aclAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'AccountsCustomchannelsList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'aclQuotaUser'
--
-- * 'aclPrettyPrint'
--
-- * 'aclUserIp'
--
-- * 'aclAdClientId'
--
-- * 'aclAccountId'
--
-- * 'aclKey'
--
-- * 'aclPageToken'
--
-- * 'aclOauthToken'
--
-- * 'aclMaxResults'
--
-- * 'aclFields'
--
-- * 'aclAlt'
accountsCustomchannelsList
:: Text -- ^ 'adClientId'
-> Text -- ^ 'accountId'
-> AccountsCustomchannelsList
accountsCustomchannelsList pAclAdClientId_ pAclAccountId_ =
AccountsCustomchannelsList
{ _aclQuotaUser = Nothing
, _aclPrettyPrint = True
, _aclUserIp = Nothing
, _aclAdClientId = pAclAdClientId_
, _aclAccountId = pAclAccountId_
, _aclKey = Nothing
, _aclPageToken = Nothing
, _aclOauthToken = Nothing
, _aclMaxResults = Nothing
, _aclFields = Nothing
, _aclAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
aclQuotaUser :: Lens' AccountsCustomchannelsList' (Maybe Text)
aclQuotaUser
= lens _aclQuotaUser (\ s a -> s{_aclQuotaUser = a})
-- | Returns response with indentations and line breaks.
aclPrettyPrint :: Lens' AccountsCustomchannelsList' Bool
aclPrettyPrint
= lens _aclPrettyPrint
(\ s a -> s{_aclPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
aclUserIp :: Lens' AccountsCustomchannelsList' (Maybe Text)
aclUserIp
= lens _aclUserIp (\ s a -> s{_aclUserIp = a})
-- | Ad client for which to list custom channels.
aclAdClientId :: Lens' AccountsCustomchannelsList' Text
aclAdClientId
= lens _aclAdClientId
(\ s a -> s{_aclAdClientId = a})
-- | Account to which the ad client belongs.
aclAccountId :: Lens' AccountsCustomchannelsList' Text
aclAccountId
= lens _aclAccountId (\ s a -> s{_aclAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
aclKey :: Lens' AccountsCustomchannelsList' (Maybe Text)
aclKey = lens _aclKey (\ s a -> s{_aclKey = a})
-- | A continuation token, used to page through custom channels. To retrieve
-- the next page, set this parameter to the value of \"nextPageToken\" from
-- the previous response.
aclPageToken :: Lens' AccountsCustomchannelsList' (Maybe Text)
aclPageToken
= lens _aclPageToken (\ s a -> s{_aclPageToken = a})
-- | OAuth 2.0 token for the current user.
aclOauthToken :: Lens' AccountsCustomchannelsList' (Maybe Text)
aclOauthToken
= lens _aclOauthToken
(\ s a -> s{_aclOauthToken = a})
-- | The maximum number of custom channels to include in the response, used
-- for paging.
aclMaxResults :: Lens' AccountsCustomchannelsList' (Maybe Word32)
aclMaxResults
= lens _aclMaxResults
(\ s a -> s{_aclMaxResults = a})
-- | Selector specifying which fields to include in a partial response.
aclFields :: Lens' AccountsCustomchannelsList' (Maybe Text)
aclFields
= lens _aclFields (\ s a -> s{_aclFields = a})
-- | Data format for the response.
aclAlt :: Lens' AccountsCustomchannelsList' Text
aclAlt = lens _aclAlt (\ s a -> s{_aclAlt = a})
instance GoogleRequest AccountsCustomchannelsList'
where
type Rs AccountsCustomchannelsList' = CustomChannels
request = requestWithRoute defReq adExchangeSellerURL
requestWithRoute r u AccountsCustomchannelsList{..}
= go _aclQuotaUser _aclPrettyPrint _aclUserIp
_aclAdClientId
_aclAccountId
_aclKey
_aclPageToken
_aclOauthToken
_aclMaxResults
_aclFields
_aclAlt
where go
= clientWithRoute
(Proxy :: Proxy AccountsCustomchannelsListAPI)
r
u

View File

@ -0,0 +1,152 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeSeller.Accounts.Get
-- Copyright : (c) 2015 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)
--
-- | Get information about the selected Ad Exchange account.
--
-- /See:/ <https://developers.google.com/ad-exchange/seller-rest/ Ad Exchange Seller API Reference> for @AdexchangesellerAccountsGet@.
module AdExchangeSeller.Accounts.Get
(
-- * REST Resource
AccountsGetAPI
-- * Creating a Request
, accountsGet
, AccountsGet
-- * Request Lenses
, agQuotaUser
, agPrettyPrint
, agUserIp
, agAccountId
, agKey
, agOauthToken
, agFields
, agAlt
) where
import Network.Google.AdExchangeSeller.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangesellerAccountsGet@ which the
-- 'AccountsGet' request conforms to.
type AccountsGetAPI =
"accounts" :>
Capture "accountId" Text :> Get '[JSON] Account
-- | Get information about the selected Ad Exchange account.
--
-- /See:/ 'accountsGet' smart constructor.
data AccountsGet = AccountsGet
{ _agQuotaUser :: !(Maybe Text)
, _agPrettyPrint :: !Bool
, _agUserIp :: !(Maybe Text)
, _agAccountId :: !Text
, _agKey :: !(Maybe Text)
, _agOauthToken :: !(Maybe Text)
, _agFields :: !(Maybe Text)
, _agAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'AccountsGet'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'agQuotaUser'
--
-- * 'agPrettyPrint'
--
-- * 'agUserIp'
--
-- * 'agAccountId'
--
-- * 'agKey'
--
-- * 'agOauthToken'
--
-- * 'agFields'
--
-- * 'agAlt'
accountsGet
:: Text -- ^ 'accountId'
-> AccountsGet
accountsGet pAgAccountId_ =
AccountsGet
{ _agQuotaUser = Nothing
, _agPrettyPrint = True
, _agUserIp = Nothing
, _agAccountId = pAgAccountId_
, _agKey = Nothing
, _agOauthToken = Nothing
, _agFields = Nothing
, _agAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
agQuotaUser :: Lens' AccountsGet' (Maybe Text)
agQuotaUser
= lens _agQuotaUser (\ s a -> s{_agQuotaUser = a})
-- | Returns response with indentations and line breaks.
agPrettyPrint :: Lens' AccountsGet' Bool
agPrettyPrint
= lens _agPrettyPrint
(\ s a -> s{_agPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
agUserIp :: Lens' AccountsGet' (Maybe Text)
agUserIp = lens _agUserIp (\ s a -> s{_agUserIp = a})
-- | Account to get information about. Tip: \'myaccount\' is a valid ID.
agAccountId :: Lens' AccountsGet' Text
agAccountId
= lens _agAccountId (\ s a -> s{_agAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
agKey :: Lens' AccountsGet' (Maybe Text)
agKey = lens _agKey (\ s a -> s{_agKey = a})
-- | OAuth 2.0 token for the current user.
agOauthToken :: Lens' AccountsGet' (Maybe Text)
agOauthToken
= lens _agOauthToken (\ s a -> s{_agOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
agFields :: Lens' AccountsGet' (Maybe Text)
agFields = lens _agFields (\ s a -> s{_agFields = a})
-- | Data format for the response.
agAlt :: Lens' AccountsGet' Text
agAlt = lens _agAlt (\ s a -> s{_agAlt = a})
instance GoogleRequest AccountsGet' where
type Rs AccountsGet' = Account
request = requestWithRoute defReq adExchangeSellerURL
requestWithRoute r u AccountsGet{..}
= go _agQuotaUser _agPrettyPrint _agUserIp
_agAccountId
_agKey
_agOauthToken
_agFields
_agAlt
where go
= clientWithRoute (Proxy :: Proxy AccountsGetAPI) r u

View File

@ -0,0 +1,166 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeSeller.Accounts.List
-- Copyright : (c) 2015 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)
--
-- | List all accounts available to this Ad Exchange account.
--
-- /See:/ <https://developers.google.com/ad-exchange/seller-rest/ Ad Exchange Seller API Reference> for @AdexchangesellerAccountsList@.
module AdExchangeSeller.Accounts.List
(
-- * REST Resource
AccountsListAPI
-- * Creating a Request
, accountsList
, AccountsList
-- * Request Lenses
, alQuotaUser
, alPrettyPrint
, alUserIp
, alKey
, alPageToken
, alOauthToken
, alMaxResults
, alFields
, alAlt
) where
import Network.Google.AdExchangeSeller.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangesellerAccountsList@ which the
-- 'AccountsList' request conforms to.
type AccountsListAPI =
"accounts" :>
QueryParam "pageToken" Text :>
QueryParam "maxResults" Int32 :> Get '[JSON] Accounts
-- | List all accounts available to this Ad Exchange account.
--
-- /See:/ 'accountsList' smart constructor.
data AccountsList = AccountsList
{ _alQuotaUser :: !(Maybe Text)
, _alPrettyPrint :: !Bool
, _alUserIp :: !(Maybe Text)
, _alKey :: !(Maybe Text)
, _alPageToken :: !(Maybe Text)
, _alOauthToken :: !(Maybe Text)
, _alMaxResults :: !(Maybe Int32)
, _alFields :: !(Maybe Text)
, _alAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'AccountsList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'alQuotaUser'
--
-- * 'alPrettyPrint'
--
-- * 'alUserIp'
--
-- * 'alKey'
--
-- * 'alPageToken'
--
-- * 'alOauthToken'
--
-- * 'alMaxResults'
--
-- * 'alFields'
--
-- * 'alAlt'
accountsList
:: AccountsList
accountsList =
AccountsList
{ _alQuotaUser = Nothing
, _alPrettyPrint = True
, _alUserIp = Nothing
, _alKey = Nothing
, _alPageToken = Nothing
, _alOauthToken = Nothing
, _alMaxResults = Nothing
, _alFields = Nothing
, _alAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
alQuotaUser :: Lens' AccountsList' (Maybe Text)
alQuotaUser
= lens _alQuotaUser (\ s a -> s{_alQuotaUser = a})
-- | Returns response with indentations and line breaks.
alPrettyPrint :: Lens' AccountsList' Bool
alPrettyPrint
= lens _alPrettyPrint
(\ s a -> s{_alPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
alUserIp :: Lens' AccountsList' (Maybe Text)
alUserIp = lens _alUserIp (\ s a -> s{_alUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
alKey :: Lens' AccountsList' (Maybe Text)
alKey = lens _alKey (\ s a -> s{_alKey = a})
-- | A continuation token, used to page through accounts. To retrieve the
-- next page, set this parameter to the value of \"nextPageToken\" from the
-- previous response.
alPageToken :: Lens' AccountsList' (Maybe Text)
alPageToken
= lens _alPageToken (\ s a -> s{_alPageToken = a})
-- | OAuth 2.0 token for the current user.
alOauthToken :: Lens' AccountsList' (Maybe Text)
alOauthToken
= lens _alOauthToken (\ s a -> s{_alOauthToken = a})
-- | The maximum number of accounts to include in the response, used for
-- paging.
alMaxResults :: Lens' AccountsList' (Maybe Int32)
alMaxResults
= lens _alMaxResults (\ s a -> s{_alMaxResults = a})
-- | Selector specifying which fields to include in a partial response.
alFields :: Lens' AccountsList' (Maybe Text)
alFields = lens _alFields (\ s a -> s{_alFields = a})
-- | Data format for the response.
alAlt :: Lens' AccountsList' Text
alAlt = lens _alAlt (\ s a -> s{_alAlt = a})
instance GoogleRequest AccountsList' where
type Rs AccountsList' = Accounts
request = requestWithRoute defReq adExchangeSellerURL
requestWithRoute r u AccountsList{..}
= go _alQuotaUser _alPrettyPrint _alUserIp _alKey
_alPageToken
_alOauthToken
_alMaxResults
_alFields
_alAlt
where go
= clientWithRoute (Proxy :: Proxy AccountsListAPI) r
u

View File

@ -0,0 +1,165 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeSeller.Accounts.Metadata.Dimensions.List
-- Copyright : (c) 2015 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)
--
-- | List the metadata for the dimensions available to this AdExchange
-- account.
--
-- /See:/ <https://developers.google.com/ad-exchange/seller-rest/ Ad Exchange Seller API Reference> for @AdexchangesellerAccountsMetadataDimensionsList@.
module AdExchangeSeller.Accounts.Metadata.Dimensions.List
(
-- * REST Resource
AccountsMetadataDimensionsListAPI
-- * Creating a Request
, accountsMetadataDimensionsList
, AccountsMetadataDimensionsList
-- * Request Lenses
, amdlQuotaUser
, amdlPrettyPrint
, amdlUserIp
, amdlAccountId
, amdlKey
, amdlOauthToken
, amdlFields
, amdlAlt
) where
import Network.Google.AdExchangeSeller.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangesellerAccountsMetadataDimensionsList@ which the
-- 'AccountsMetadataDimensionsList' request conforms to.
type AccountsMetadataDimensionsListAPI =
"accounts" :>
Capture "accountId" Text :>
"metadata" :> "dimensions" :> Get '[JSON] Metadata
-- | List the metadata for the dimensions available to this AdExchange
-- account.
--
-- /See:/ 'accountsMetadataDimensionsList' smart constructor.
data AccountsMetadataDimensionsList = AccountsMetadataDimensionsList
{ _amdlQuotaUser :: !(Maybe Text)
, _amdlPrettyPrint :: !Bool
, _amdlUserIp :: !(Maybe Text)
, _amdlAccountId :: !Text
, _amdlKey :: !(Maybe Text)
, _amdlOauthToken :: !(Maybe Text)
, _amdlFields :: !(Maybe Text)
, _amdlAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'AccountsMetadataDimensionsList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'amdlQuotaUser'
--
-- * 'amdlPrettyPrint'
--
-- * 'amdlUserIp'
--
-- * 'amdlAccountId'
--
-- * 'amdlKey'
--
-- * 'amdlOauthToken'
--
-- * 'amdlFields'
--
-- * 'amdlAlt'
accountsMetadataDimensionsList
:: Text -- ^ 'accountId'
-> AccountsMetadataDimensionsList
accountsMetadataDimensionsList pAmdlAccountId_ =
AccountsMetadataDimensionsList
{ _amdlQuotaUser = Nothing
, _amdlPrettyPrint = True
, _amdlUserIp = Nothing
, _amdlAccountId = pAmdlAccountId_
, _amdlKey = Nothing
, _amdlOauthToken = Nothing
, _amdlFields = Nothing
, _amdlAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
amdlQuotaUser :: Lens' AccountsMetadataDimensionsList' (Maybe Text)
amdlQuotaUser
= lens _amdlQuotaUser
(\ s a -> s{_amdlQuotaUser = a})
-- | Returns response with indentations and line breaks.
amdlPrettyPrint :: Lens' AccountsMetadataDimensionsList' Bool
amdlPrettyPrint
= lens _amdlPrettyPrint
(\ s a -> s{_amdlPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
amdlUserIp :: Lens' AccountsMetadataDimensionsList' (Maybe Text)
amdlUserIp
= lens _amdlUserIp (\ s a -> s{_amdlUserIp = a})
-- | Account with visibility to the dimensions.
amdlAccountId :: Lens' AccountsMetadataDimensionsList' Text
amdlAccountId
= lens _amdlAccountId
(\ s a -> s{_amdlAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
amdlKey :: Lens' AccountsMetadataDimensionsList' (Maybe Text)
amdlKey = lens _amdlKey (\ s a -> s{_amdlKey = a})
-- | OAuth 2.0 token for the current user.
amdlOauthToken :: Lens' AccountsMetadataDimensionsList' (Maybe Text)
amdlOauthToken
= lens _amdlOauthToken
(\ s a -> s{_amdlOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
amdlFields :: Lens' AccountsMetadataDimensionsList' (Maybe Text)
amdlFields
= lens _amdlFields (\ s a -> s{_amdlFields = a})
-- | Data format for the response.
amdlAlt :: Lens' AccountsMetadataDimensionsList' Text
amdlAlt = lens _amdlAlt (\ s a -> s{_amdlAlt = a})
instance GoogleRequest
AccountsMetadataDimensionsList' where
type Rs AccountsMetadataDimensionsList' = Metadata
request = requestWithRoute defReq adExchangeSellerURL
requestWithRoute r u
AccountsMetadataDimensionsList{..}
= go _amdlQuotaUser _amdlPrettyPrint _amdlUserIp
_amdlAccountId
_amdlKey
_amdlOauthToken
_amdlFields
_amdlAlt
where go
= clientWithRoute
(Proxy :: Proxy AccountsMetadataDimensionsListAPI)
r
u

View File

@ -0,0 +1,162 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeSeller.Accounts.Metadata.Metrics.List
-- Copyright : (c) 2015 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)
--
-- | List the metadata for the metrics available to this AdExchange account.
--
-- /See:/ <https://developers.google.com/ad-exchange/seller-rest/ Ad Exchange Seller API Reference> for @AdexchangesellerAccountsMetadataMetricsList@.
module AdExchangeSeller.Accounts.Metadata.Metrics.List
(
-- * REST Resource
AccountsMetadataMetricsListAPI
-- * Creating a Request
, accountsMetadataMetricsList
, AccountsMetadataMetricsList
-- * Request Lenses
, ammlQuotaUser
, ammlPrettyPrint
, ammlUserIp
, ammlAccountId
, ammlKey
, ammlOauthToken
, ammlFields
, ammlAlt
) where
import Network.Google.AdExchangeSeller.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangesellerAccountsMetadataMetricsList@ which the
-- 'AccountsMetadataMetricsList' request conforms to.
type AccountsMetadataMetricsListAPI =
"accounts" :>
Capture "accountId" Text :>
"metadata" :> "metrics" :> Get '[JSON] Metadata
-- | List the metadata for the metrics available to this AdExchange account.
--
-- /See:/ 'accountsMetadataMetricsList' smart constructor.
data AccountsMetadataMetricsList = AccountsMetadataMetricsList
{ _ammlQuotaUser :: !(Maybe Text)
, _ammlPrettyPrint :: !Bool
, _ammlUserIp :: !(Maybe Text)
, _ammlAccountId :: !Text
, _ammlKey :: !(Maybe Text)
, _ammlOauthToken :: !(Maybe Text)
, _ammlFields :: !(Maybe Text)
, _ammlAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'AccountsMetadataMetricsList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'ammlQuotaUser'
--
-- * 'ammlPrettyPrint'
--
-- * 'ammlUserIp'
--
-- * 'ammlAccountId'
--
-- * 'ammlKey'
--
-- * 'ammlOauthToken'
--
-- * 'ammlFields'
--
-- * 'ammlAlt'
accountsMetadataMetricsList
:: Text -- ^ 'accountId'
-> AccountsMetadataMetricsList
accountsMetadataMetricsList pAmmlAccountId_ =
AccountsMetadataMetricsList
{ _ammlQuotaUser = Nothing
, _ammlPrettyPrint = True
, _ammlUserIp = Nothing
, _ammlAccountId = pAmmlAccountId_
, _ammlKey = Nothing
, _ammlOauthToken = Nothing
, _ammlFields = Nothing
, _ammlAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
ammlQuotaUser :: Lens' AccountsMetadataMetricsList' (Maybe Text)
ammlQuotaUser
= lens _ammlQuotaUser
(\ s a -> s{_ammlQuotaUser = a})
-- | Returns response with indentations and line breaks.
ammlPrettyPrint :: Lens' AccountsMetadataMetricsList' Bool
ammlPrettyPrint
= lens _ammlPrettyPrint
(\ s a -> s{_ammlPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
ammlUserIp :: Lens' AccountsMetadataMetricsList' (Maybe Text)
ammlUserIp
= lens _ammlUserIp (\ s a -> s{_ammlUserIp = a})
-- | Account with visibility to the metrics.
ammlAccountId :: Lens' AccountsMetadataMetricsList' Text
ammlAccountId
= lens _ammlAccountId
(\ s a -> s{_ammlAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
ammlKey :: Lens' AccountsMetadataMetricsList' (Maybe Text)
ammlKey = lens _ammlKey (\ s a -> s{_ammlKey = a})
-- | OAuth 2.0 token for the current user.
ammlOauthToken :: Lens' AccountsMetadataMetricsList' (Maybe Text)
ammlOauthToken
= lens _ammlOauthToken
(\ s a -> s{_ammlOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
ammlFields :: Lens' AccountsMetadataMetricsList' (Maybe Text)
ammlFields
= lens _ammlFields (\ s a -> s{_ammlFields = a})
-- | Data format for the response.
ammlAlt :: Lens' AccountsMetadataMetricsList' Text
ammlAlt = lens _ammlAlt (\ s a -> s{_ammlAlt = a})
instance GoogleRequest AccountsMetadataMetricsList'
where
type Rs AccountsMetadataMetricsList' = Metadata
request = requestWithRoute defReq adExchangeSellerURL
requestWithRoute r u AccountsMetadataMetricsList{..}
= go _ammlQuotaUser _ammlPrettyPrint _ammlUserIp
_ammlAccountId
_ammlKey
_ammlOauthToken
_ammlFields
_ammlAlt
where go
= clientWithRoute
(Proxy :: Proxy AccountsMetadataMetricsListAPI)
r
u

View File

@ -0,0 +1,173 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeSeller.Accounts.Preferreddeals.Get
-- Copyright : (c) 2015 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)
--
-- | Get information about the selected Ad Exchange Preferred Deal.
--
-- /See:/ <https://developers.google.com/ad-exchange/seller-rest/ Ad Exchange Seller API Reference> for @AdexchangesellerAccountsPreferreddealsGet@.
module AdExchangeSeller.Accounts.Preferreddeals.Get
(
-- * REST Resource
AccountsPreferreddealsGetAPI
-- * Creating a Request
, accountsPreferreddealsGet
, AccountsPreferreddealsGet
-- * Request Lenses
, apgQuotaUser
, apgPrettyPrint
, apgUserIp
, apgDealId
, apgAccountId
, apgKey
, apgOauthToken
, apgFields
, apgAlt
) where
import Network.Google.AdExchangeSeller.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangesellerAccountsPreferreddealsGet@ which the
-- 'AccountsPreferreddealsGet' request conforms to.
type AccountsPreferreddealsGetAPI =
"accounts" :>
Capture "accountId" Text :>
"preferreddeals" :>
Capture "dealId" Text :> Get '[JSON] PreferredDeal
-- | Get information about the selected Ad Exchange Preferred Deal.
--
-- /See:/ 'accountsPreferreddealsGet' smart constructor.
data AccountsPreferreddealsGet = AccountsPreferreddealsGet
{ _apgQuotaUser :: !(Maybe Text)
, _apgPrettyPrint :: !Bool
, _apgUserIp :: !(Maybe Text)
, _apgDealId :: !Text
, _apgAccountId :: !Text
, _apgKey :: !(Maybe Text)
, _apgOauthToken :: !(Maybe Text)
, _apgFields :: !(Maybe Text)
, _apgAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'AccountsPreferreddealsGet'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'apgQuotaUser'
--
-- * 'apgPrettyPrint'
--
-- * 'apgUserIp'
--
-- * 'apgDealId'
--
-- * 'apgAccountId'
--
-- * 'apgKey'
--
-- * 'apgOauthToken'
--
-- * 'apgFields'
--
-- * 'apgAlt'
accountsPreferreddealsGet
:: Text -- ^ 'dealId'
-> Text -- ^ 'accountId'
-> AccountsPreferreddealsGet
accountsPreferreddealsGet pApgDealId_ pApgAccountId_ =
AccountsPreferreddealsGet
{ _apgQuotaUser = Nothing
, _apgPrettyPrint = True
, _apgUserIp = Nothing
, _apgDealId = pApgDealId_
, _apgAccountId = pApgAccountId_
, _apgKey = Nothing
, _apgOauthToken = Nothing
, _apgFields = Nothing
, _apgAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
apgQuotaUser :: Lens' AccountsPreferreddealsGet' (Maybe Text)
apgQuotaUser
= lens _apgQuotaUser (\ s a -> s{_apgQuotaUser = a})
-- | Returns response with indentations and line breaks.
apgPrettyPrint :: Lens' AccountsPreferreddealsGet' Bool
apgPrettyPrint
= lens _apgPrettyPrint
(\ s a -> s{_apgPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
apgUserIp :: Lens' AccountsPreferreddealsGet' (Maybe Text)
apgUserIp
= lens _apgUserIp (\ s a -> s{_apgUserIp = a})
-- | Preferred deal to get information about.
apgDealId :: Lens' AccountsPreferreddealsGet' Text
apgDealId
= lens _apgDealId (\ s a -> s{_apgDealId = a})
-- | Account owning the deal.
apgAccountId :: Lens' AccountsPreferreddealsGet' Text
apgAccountId
= lens _apgAccountId (\ s a -> s{_apgAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
apgKey :: Lens' AccountsPreferreddealsGet' (Maybe Text)
apgKey = lens _apgKey (\ s a -> s{_apgKey = a})
-- | OAuth 2.0 token for the current user.
apgOauthToken :: Lens' AccountsPreferreddealsGet' (Maybe Text)
apgOauthToken
= lens _apgOauthToken
(\ s a -> s{_apgOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
apgFields :: Lens' AccountsPreferreddealsGet' (Maybe Text)
apgFields
= lens _apgFields (\ s a -> s{_apgFields = a})
-- | Data format for the response.
apgAlt :: Lens' AccountsPreferreddealsGet' Text
apgAlt = lens _apgAlt (\ s a -> s{_apgAlt = a})
instance GoogleRequest AccountsPreferreddealsGet'
where
type Rs AccountsPreferreddealsGet' = PreferredDeal
request = requestWithRoute defReq adExchangeSellerURL
requestWithRoute r u AccountsPreferreddealsGet{..}
= go _apgQuotaUser _apgPrettyPrint _apgUserIp
_apgDealId
_apgAccountId
_apgKey
_apgOauthToken
_apgFields
_apgAlt
where go
= clientWithRoute
(Proxy :: Proxy AccountsPreferreddealsGetAPI)
r
u

View File

@ -0,0 +1,160 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeSeller.Accounts.Preferreddeals.List
-- Copyright : (c) 2015 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)
--
-- | List the preferred deals for this Ad Exchange account.
--
-- /See:/ <https://developers.google.com/ad-exchange/seller-rest/ Ad Exchange Seller API Reference> for @AdexchangesellerAccountsPreferreddealsList@.
module AdExchangeSeller.Accounts.Preferreddeals.List
(
-- * REST Resource
AccountsPreferreddealsListAPI
-- * Creating a Request
, accountsPreferreddealsList
, AccountsPreferreddealsList
-- * Request Lenses
, aplQuotaUser
, aplPrettyPrint
, aplUserIp
, aplAccountId
, aplKey
, aplOauthToken
, aplFields
, aplAlt
) where
import Network.Google.AdExchangeSeller.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangesellerAccountsPreferreddealsList@ which the
-- 'AccountsPreferreddealsList' request conforms to.
type AccountsPreferreddealsListAPI =
"accounts" :>
Capture "accountId" Text :>
"preferreddeals" :> Get '[JSON] PreferredDeals
-- | List the preferred deals for this Ad Exchange account.
--
-- /See:/ 'accountsPreferreddealsList' smart constructor.
data AccountsPreferreddealsList = AccountsPreferreddealsList
{ _aplQuotaUser :: !(Maybe Text)
, _aplPrettyPrint :: !Bool
, _aplUserIp :: !(Maybe Text)
, _aplAccountId :: !Text
, _aplKey :: !(Maybe Text)
, _aplOauthToken :: !(Maybe Text)
, _aplFields :: !(Maybe Text)
, _aplAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'AccountsPreferreddealsList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'aplQuotaUser'
--
-- * 'aplPrettyPrint'
--
-- * 'aplUserIp'
--
-- * 'aplAccountId'
--
-- * 'aplKey'
--
-- * 'aplOauthToken'
--
-- * 'aplFields'
--
-- * 'aplAlt'
accountsPreferreddealsList
:: Text -- ^ 'accountId'
-> AccountsPreferreddealsList
accountsPreferreddealsList pAplAccountId_ =
AccountsPreferreddealsList
{ _aplQuotaUser = Nothing
, _aplPrettyPrint = True
, _aplUserIp = Nothing
, _aplAccountId = pAplAccountId_
, _aplKey = Nothing
, _aplOauthToken = Nothing
, _aplFields = Nothing
, _aplAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
aplQuotaUser :: Lens' AccountsPreferreddealsList' (Maybe Text)
aplQuotaUser
= lens _aplQuotaUser (\ s a -> s{_aplQuotaUser = a})
-- | Returns response with indentations and line breaks.
aplPrettyPrint :: Lens' AccountsPreferreddealsList' Bool
aplPrettyPrint
= lens _aplPrettyPrint
(\ s a -> s{_aplPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
aplUserIp :: Lens' AccountsPreferreddealsList' (Maybe Text)
aplUserIp
= lens _aplUserIp (\ s a -> s{_aplUserIp = a})
-- | Account owning the deals.
aplAccountId :: Lens' AccountsPreferreddealsList' Text
aplAccountId
= lens _aplAccountId (\ s a -> s{_aplAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
aplKey :: Lens' AccountsPreferreddealsList' (Maybe Text)
aplKey = lens _aplKey (\ s a -> s{_aplKey = a})
-- | OAuth 2.0 token for the current user.
aplOauthToken :: Lens' AccountsPreferreddealsList' (Maybe Text)
aplOauthToken
= lens _aplOauthToken
(\ s a -> s{_aplOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
aplFields :: Lens' AccountsPreferreddealsList' (Maybe Text)
aplFields
= lens _aplFields (\ s a -> s{_aplFields = a})
-- | Data format for the response.
aplAlt :: Lens' AccountsPreferreddealsList' Text
aplAlt = lens _aplAlt (\ s a -> s{_aplAlt = a})
instance GoogleRequest AccountsPreferreddealsList'
where
type Rs AccountsPreferreddealsList' = PreferredDeals
request = requestWithRoute defReq adExchangeSellerURL
requestWithRoute r u AccountsPreferreddealsList{..}
= go _aplQuotaUser _aplPrettyPrint _aplUserIp
_aplAccountId
_aplKey
_aplOauthToken
_aplFields
_aplAlt
where go
= clientWithRoute
(Proxy :: Proxy AccountsPreferreddealsListAPI)
r
u

View File

@ -0,0 +1,278 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeSeller.Accounts.Reports.Generate
-- Copyright : (c) 2015 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)
--
-- | Generate an Ad Exchange report based on the report request sent in the
-- query parameters. Returns the result as JSON; to retrieve output in CSV
-- format specify \"alt=csv\" as a query parameter.
--
-- /See:/ <https://developers.google.com/ad-exchange/seller-rest/ Ad Exchange Seller API Reference> for @AdexchangesellerAccountsReportsGenerate@.
module AdExchangeSeller.Accounts.Reports.Generate
(
-- * REST Resource
AccountsReportsGenerateAPI
-- * Creating a Request
, accountsReportsGenerate
, AccountsReportsGenerate
-- * Request Lenses
, argQuotaUser
, argPrettyPrint
, argUserIp
, argDimension
, argLocale
, argEndDate
, argStartDate
, argAccountId
, argMetric
, argKey
, argSort
, argFilter
, argOauthToken
, argStartIndex
, argMaxResults
, argFields
, argAlt
) where
import Network.Google.AdExchangeSeller.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangesellerAccountsReportsGenerate@ which the
-- 'AccountsReportsGenerate' request conforms to.
type AccountsReportsGenerateAPI =
"accounts" :>
Capture "accountId" Text :>
"reports" :>
QueryParams "dimension" Text :>
QueryParam "locale" Text :>
QueryParam "endDate" Text :>
QueryParam "startDate" Text :>
QueryParams "metric" Text :>
QueryParams "sort" Text :>
QueryParams "filter" Text :>
QueryParam "startIndex" Word32 :>
QueryParam "maxResults" Word32 :> Get '[JSON] Report
-- | Generate an Ad Exchange report based on the report request sent in the
-- query parameters. Returns the result as JSON; to retrieve output in CSV
-- format specify \"alt=csv\" as a query parameter.
--
-- /See:/ 'accountsReportsGenerate' smart constructor.
data AccountsReportsGenerate = AccountsReportsGenerate
{ _argQuotaUser :: !(Maybe Text)
, _argPrettyPrint :: !Bool
, _argUserIp :: !(Maybe Text)
, _argDimension :: !(Maybe Text)
, _argLocale :: !(Maybe Text)
, _argEndDate :: !Text
, _argStartDate :: !Text
, _argAccountId :: !Text
, _argMetric :: !(Maybe Text)
, _argKey :: !(Maybe Text)
, _argSort :: !(Maybe Text)
, _argFilter :: !(Maybe Text)
, _argOauthToken :: !(Maybe Text)
, _argStartIndex :: !(Maybe Word32)
, _argMaxResults :: !(Maybe Word32)
, _argFields :: !(Maybe Text)
, _argAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'AccountsReportsGenerate'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'argQuotaUser'
--
-- * 'argPrettyPrint'
--
-- * 'argUserIp'
--
-- * 'argDimension'
--
-- * 'argLocale'
--
-- * 'argEndDate'
--
-- * 'argStartDate'
--
-- * 'argAccountId'
--
-- * 'argMetric'
--
-- * 'argKey'
--
-- * 'argSort'
--
-- * 'argFilter'
--
-- * 'argOauthToken'
--
-- * 'argStartIndex'
--
-- * 'argMaxResults'
--
-- * 'argFields'
--
-- * 'argAlt'
accountsReportsGenerate
:: Text -- ^ 'endDate'
-> Text -- ^ 'startDate'
-> Text -- ^ 'accountId'
-> AccountsReportsGenerate
accountsReportsGenerate pArgEndDate_ pArgStartDate_ pArgAccountId_ =
AccountsReportsGenerate
{ _argQuotaUser = Nothing
, _argPrettyPrint = True
, _argUserIp = Nothing
, _argDimension = Nothing
, _argLocale = Nothing
, _argEndDate = pArgEndDate_
, _argStartDate = pArgStartDate_
, _argAccountId = pArgAccountId_
, _argMetric = Nothing
, _argKey = Nothing
, _argSort = Nothing
, _argFilter = Nothing
, _argOauthToken = Nothing
, _argStartIndex = Nothing
, _argMaxResults = Nothing
, _argFields = Nothing
, _argAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
argQuotaUser :: Lens' AccountsReportsGenerate' (Maybe Text)
argQuotaUser
= lens _argQuotaUser (\ s a -> s{_argQuotaUser = a})
-- | Returns response with indentations and line breaks.
argPrettyPrint :: Lens' AccountsReportsGenerate' Bool
argPrettyPrint
= lens _argPrettyPrint
(\ s a -> s{_argPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
argUserIp :: Lens' AccountsReportsGenerate' (Maybe Text)
argUserIp
= lens _argUserIp (\ s a -> s{_argUserIp = a})
-- | Dimensions to base the report on.
argDimension :: Lens' AccountsReportsGenerate' (Maybe Text)
argDimension
= lens _argDimension (\ s a -> s{_argDimension = a})
-- | Optional locale to use for translating report output to a local
-- language. Defaults to \"en_US\" if not specified.
argLocale :: Lens' AccountsReportsGenerate' (Maybe Text)
argLocale
= lens _argLocale (\ s a -> s{_argLocale = a})
-- | End of the date range to report on in \"YYYY-MM-DD\" format, inclusive.
argEndDate :: Lens' AccountsReportsGenerate' Text
argEndDate
= lens _argEndDate (\ s a -> s{_argEndDate = a})
-- | Start of the date range to report on in \"YYYY-MM-DD\" format,
-- inclusive.
argStartDate :: Lens' AccountsReportsGenerate' Text
argStartDate
= lens _argStartDate (\ s a -> s{_argStartDate = a})
-- | Account which owns the generated report.
argAccountId :: Lens' AccountsReportsGenerate' Text
argAccountId
= lens _argAccountId (\ s a -> s{_argAccountId = a})
-- | Numeric columns to include in the report.
argMetric :: Lens' AccountsReportsGenerate' (Maybe Text)
argMetric
= lens _argMetric (\ s a -> s{_argMetric = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
argKey :: Lens' AccountsReportsGenerate' (Maybe Text)
argKey = lens _argKey (\ s a -> s{_argKey = a})
-- | The name of a dimension or metric to sort the resulting report on,
-- optionally prefixed with \"+\" to sort ascending or \"-\" to sort
-- descending. If no prefix is specified, the column is sorted ascending.
argSort :: Lens' AccountsReportsGenerate' (Maybe Text)
argSort = lens _argSort (\ s a -> s{_argSort = a})
-- | Filters to be run on the report.
argFilter :: Lens' AccountsReportsGenerate' (Maybe Text)
argFilter
= lens _argFilter (\ s a -> s{_argFilter = a})
-- | OAuth 2.0 token for the current user.
argOauthToken :: Lens' AccountsReportsGenerate' (Maybe Text)
argOauthToken
= lens _argOauthToken
(\ s a -> s{_argOauthToken = a})
-- | Index of the first row of report data to return.
argStartIndex :: Lens' AccountsReportsGenerate' (Maybe Word32)
argStartIndex
= lens _argStartIndex
(\ s a -> s{_argStartIndex = a})
-- | The maximum number of rows of report data to return.
argMaxResults :: Lens' AccountsReportsGenerate' (Maybe Word32)
argMaxResults
= lens _argMaxResults
(\ s a -> s{_argMaxResults = a})
-- | Selector specifying which fields to include in a partial response.
argFields :: Lens' AccountsReportsGenerate' (Maybe Text)
argFields
= lens _argFields (\ s a -> s{_argFields = a})
-- | Data format for the response.
argAlt :: Lens' AccountsReportsGenerate' Text
argAlt = lens _argAlt (\ s a -> s{_argAlt = a})
instance GoogleRequest AccountsReportsGenerate' where
type Rs AccountsReportsGenerate' = Report
request = requestWithRoute defReq adExchangeSellerURL
requestWithRoute r u AccountsReportsGenerate{..}
= go _argQuotaUser _argPrettyPrint _argUserIp
_argDimension
_argLocale
(Just _argEndDate)
(Just _argStartDate)
_argAccountId
_argMetric
_argKey
_argSort
_argFilter
_argOauthToken
_argStartIndex
_argMaxResults
_argFields
_argAlt
where go
= clientWithRoute
(Proxy :: Proxy AccountsReportsGenerateAPI)
r
u

View File

@ -0,0 +1,217 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeSeller.Accounts.Reports.Saved.Generate
-- Copyright : (c) 2015 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)
--
-- | Generate an Ad Exchange report based on the saved report ID sent in the
-- query parameters.
--
-- /See:/ <https://developers.google.com/ad-exchange/seller-rest/ Ad Exchange Seller API Reference> for @AdexchangesellerAccountsReportsSavedGenerate@.
module AdExchangeSeller.Accounts.Reports.Saved.Generate
(
-- * REST Resource
AccountsReportsSavedGenerateAPI
-- * Creating a Request
, accountsReportsSavedGenerate
, AccountsReportsSavedGenerate
-- * Request Lenses
, arsgQuotaUser
, arsgPrettyPrint
, arsgUserIp
, arsgLocale
, arsgSavedReportId
, arsgAccountId
, arsgKey
, arsgOauthToken
, arsgStartIndex
, arsgMaxResults
, arsgFields
, arsgAlt
) where
import Network.Google.AdExchangeSeller.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangesellerAccountsReportsSavedGenerate@ which the
-- 'AccountsReportsSavedGenerate' request conforms to.
type AccountsReportsSavedGenerateAPI =
"accounts" :>
Capture "accountId" Text :>
"reports" :>
Capture "savedReportId" Text :>
QueryParam "locale" Text :>
QueryParam "startIndex" Int32 :>
QueryParam "maxResults" Int32 :> Get '[JSON] Report
-- | Generate an Ad Exchange report based on the saved report ID sent in the
-- query parameters.
--
-- /See:/ 'accountsReportsSavedGenerate' smart constructor.
data AccountsReportsSavedGenerate = AccountsReportsSavedGenerate
{ _arsgQuotaUser :: !(Maybe Text)
, _arsgPrettyPrint :: !Bool
, _arsgUserIp :: !(Maybe Text)
, _arsgLocale :: !(Maybe Text)
, _arsgSavedReportId :: !Text
, _arsgAccountId :: !Text
, _arsgKey :: !(Maybe Text)
, _arsgOauthToken :: !(Maybe Text)
, _arsgStartIndex :: !(Maybe Int32)
, _arsgMaxResults :: !(Maybe Int32)
, _arsgFields :: !(Maybe Text)
, _arsgAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'AccountsReportsSavedGenerate'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'arsgQuotaUser'
--
-- * 'arsgPrettyPrint'
--
-- * 'arsgUserIp'
--
-- * 'arsgLocale'
--
-- * 'arsgSavedReportId'
--
-- * 'arsgAccountId'
--
-- * 'arsgKey'
--
-- * 'arsgOauthToken'
--
-- * 'arsgStartIndex'
--
-- * 'arsgMaxResults'
--
-- * 'arsgFields'
--
-- * 'arsgAlt'
accountsReportsSavedGenerate
:: Text -- ^ 'savedReportId'
-> Text -- ^ 'accountId'
-> AccountsReportsSavedGenerate
accountsReportsSavedGenerate pArsgSavedReportId_ pArsgAccountId_ =
AccountsReportsSavedGenerate
{ _arsgQuotaUser = Nothing
, _arsgPrettyPrint = True
, _arsgUserIp = Nothing
, _arsgLocale = Nothing
, _arsgSavedReportId = pArsgSavedReportId_
, _arsgAccountId = pArsgAccountId_
, _arsgKey = Nothing
, _arsgOauthToken = Nothing
, _arsgStartIndex = Nothing
, _arsgMaxResults = Nothing
, _arsgFields = Nothing
, _arsgAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
arsgQuotaUser :: Lens' AccountsReportsSavedGenerate' (Maybe Text)
arsgQuotaUser
= lens _arsgQuotaUser
(\ s a -> s{_arsgQuotaUser = a})
-- | Returns response with indentations and line breaks.
arsgPrettyPrint :: Lens' AccountsReportsSavedGenerate' Bool
arsgPrettyPrint
= lens _arsgPrettyPrint
(\ s a -> s{_arsgPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
arsgUserIp :: Lens' AccountsReportsSavedGenerate' (Maybe Text)
arsgUserIp
= lens _arsgUserIp (\ s a -> s{_arsgUserIp = a})
-- | Optional locale to use for translating report output to a local
-- language. Defaults to \"en_US\" if not specified.
arsgLocale :: Lens' AccountsReportsSavedGenerate' (Maybe Text)
arsgLocale
= lens _arsgLocale (\ s a -> s{_arsgLocale = a})
-- | The saved report to retrieve.
arsgSavedReportId :: Lens' AccountsReportsSavedGenerate' Text
arsgSavedReportId
= lens _arsgSavedReportId
(\ s a -> s{_arsgSavedReportId = a})
-- | Account owning the saved report.
arsgAccountId :: Lens' AccountsReportsSavedGenerate' Text
arsgAccountId
= lens _arsgAccountId
(\ s a -> s{_arsgAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
arsgKey :: Lens' AccountsReportsSavedGenerate' (Maybe Text)
arsgKey = lens _arsgKey (\ s a -> s{_arsgKey = a})
-- | OAuth 2.0 token for the current user.
arsgOauthToken :: Lens' AccountsReportsSavedGenerate' (Maybe Text)
arsgOauthToken
= lens _arsgOauthToken
(\ s a -> s{_arsgOauthToken = a})
-- | Index of the first row of report data to return.
arsgStartIndex :: Lens' AccountsReportsSavedGenerate' (Maybe Int32)
arsgStartIndex
= lens _arsgStartIndex
(\ s a -> s{_arsgStartIndex = a})
-- | The maximum number of rows of report data to return.
arsgMaxResults :: Lens' AccountsReportsSavedGenerate' (Maybe Int32)
arsgMaxResults
= lens _arsgMaxResults
(\ s a -> s{_arsgMaxResults = a})
-- | Selector specifying which fields to include in a partial response.
arsgFields :: Lens' AccountsReportsSavedGenerate' (Maybe Text)
arsgFields
= lens _arsgFields (\ s a -> s{_arsgFields = a})
-- | Data format for the response.
arsgAlt :: Lens' AccountsReportsSavedGenerate' Text
arsgAlt = lens _arsgAlt (\ s a -> s{_arsgAlt = a})
instance GoogleRequest AccountsReportsSavedGenerate'
where
type Rs AccountsReportsSavedGenerate' = Report
request = requestWithRoute defReq adExchangeSellerURL
requestWithRoute r u AccountsReportsSavedGenerate{..}
= go _arsgQuotaUser _arsgPrettyPrint _arsgUserIp
_arsgLocale
_arsgSavedReportId
_arsgAccountId
_arsgKey
_arsgOauthToken
_arsgStartIndex
_arsgMaxResults
_arsgFields
_arsgAlt
where go
= clientWithRoute
(Proxy :: Proxy AccountsReportsSavedGenerateAPI)
r
u

View File

@ -0,0 +1,193 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeSeller.Accounts.Reports.Saved.List
-- Copyright : (c) 2015 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)
--
-- | List all saved reports in this Ad Exchange account.
--
-- /See:/ <https://developers.google.com/ad-exchange/seller-rest/ Ad Exchange Seller API Reference> for @AdexchangesellerAccountsReportsSavedList@.
module AdExchangeSeller.Accounts.Reports.Saved.List
(
-- * REST Resource
AccountsReportsSavedListAPI
-- * Creating a Request
, accountsReportsSavedList
, AccountsReportsSavedList
-- * Request Lenses
, arslQuotaUser
, arslPrettyPrint
, arslUserIp
, arslAccountId
, arslKey
, arslPageToken
, arslOauthToken
, arslMaxResults
, arslFields
, arslAlt
) where
import Network.Google.AdExchangeSeller.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangesellerAccountsReportsSavedList@ which the
-- 'AccountsReportsSavedList' request conforms to.
type AccountsReportsSavedListAPI =
"accounts" :>
Capture "accountId" Text :>
"reports" :>
"saved" :>
QueryParam "pageToken" Text :>
QueryParam "maxResults" Int32 :>
Get '[JSON] SavedReports
-- | List all saved reports in this Ad Exchange account.
--
-- /See:/ 'accountsReportsSavedList' smart constructor.
data AccountsReportsSavedList = AccountsReportsSavedList
{ _arslQuotaUser :: !(Maybe Text)
, _arslPrettyPrint :: !Bool
, _arslUserIp :: !(Maybe Text)
, _arslAccountId :: !Text
, _arslKey :: !(Maybe Text)
, _arslPageToken :: !(Maybe Text)
, _arslOauthToken :: !(Maybe Text)
, _arslMaxResults :: !(Maybe Int32)
, _arslFields :: !(Maybe Text)
, _arslAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'AccountsReportsSavedList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'arslQuotaUser'
--
-- * 'arslPrettyPrint'
--
-- * 'arslUserIp'
--
-- * 'arslAccountId'
--
-- * 'arslKey'
--
-- * 'arslPageToken'
--
-- * 'arslOauthToken'
--
-- * 'arslMaxResults'
--
-- * 'arslFields'
--
-- * 'arslAlt'
accountsReportsSavedList
:: Text -- ^ 'accountId'
-> AccountsReportsSavedList
accountsReportsSavedList pArslAccountId_ =
AccountsReportsSavedList
{ _arslQuotaUser = Nothing
, _arslPrettyPrint = True
, _arslUserIp = Nothing
, _arslAccountId = pArslAccountId_
, _arslKey = Nothing
, _arslPageToken = Nothing
, _arslOauthToken = Nothing
, _arslMaxResults = Nothing
, _arslFields = Nothing
, _arslAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
arslQuotaUser :: Lens' AccountsReportsSavedList' (Maybe Text)
arslQuotaUser
= lens _arslQuotaUser
(\ s a -> s{_arslQuotaUser = a})
-- | Returns response with indentations and line breaks.
arslPrettyPrint :: Lens' AccountsReportsSavedList' Bool
arslPrettyPrint
= lens _arslPrettyPrint
(\ s a -> s{_arslPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
arslUserIp :: Lens' AccountsReportsSavedList' (Maybe Text)
arslUserIp
= lens _arslUserIp (\ s a -> s{_arslUserIp = a})
-- | Account owning the saved reports.
arslAccountId :: Lens' AccountsReportsSavedList' Text
arslAccountId
= lens _arslAccountId
(\ s a -> s{_arslAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
arslKey :: Lens' AccountsReportsSavedList' (Maybe Text)
arslKey = lens _arslKey (\ s a -> s{_arslKey = a})
-- | A continuation token, used to page through saved reports. To retrieve
-- the next page, set this parameter to the value of \"nextPageToken\" from
-- the previous response.
arslPageToken :: Lens' AccountsReportsSavedList' (Maybe Text)
arslPageToken
= lens _arslPageToken
(\ s a -> s{_arslPageToken = a})
-- | OAuth 2.0 token for the current user.
arslOauthToken :: Lens' AccountsReportsSavedList' (Maybe Text)
arslOauthToken
= lens _arslOauthToken
(\ s a -> s{_arslOauthToken = a})
-- | The maximum number of saved reports to include in the response, used for
-- paging.
arslMaxResults :: Lens' AccountsReportsSavedList' (Maybe Int32)
arslMaxResults
= lens _arslMaxResults
(\ s a -> s{_arslMaxResults = a})
-- | Selector specifying which fields to include in a partial response.
arslFields :: Lens' AccountsReportsSavedList' (Maybe Text)
arslFields
= lens _arslFields (\ s a -> s{_arslFields = a})
-- | Data format for the response.
arslAlt :: Lens' AccountsReportsSavedList' Text
arslAlt = lens _arslAlt (\ s a -> s{_arslAlt = a})
instance GoogleRequest AccountsReportsSavedList'
where
type Rs AccountsReportsSavedList' = SavedReports
request = requestWithRoute defReq adExchangeSellerURL
requestWithRoute r u AccountsReportsSavedList{..}
= go _arslQuotaUser _arslPrettyPrint _arslUserIp
_arslAccountId
_arslKey
_arslPageToken
_arslOauthToken
_arslMaxResults
_arslFields
_arslAlt
where go
= clientWithRoute
(Proxy :: Proxy AccountsReportsSavedListAPI)
r
u

View File

@ -0,0 +1,205 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.AdExchangeSeller.Accounts.URLchannels.List
-- Copyright : (c) 2015 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)
--
-- | List all URL channels in the specified ad client for this Ad Exchange
-- account.
--
-- /See:/ <https://developers.google.com/ad-exchange/seller-rest/ Ad Exchange Seller API Reference> for @AdexchangesellerAccountsURLchannelsList@.
module AdExchangeSeller.Accounts.URLchannels.List
(
-- * REST Resource
AccountsUrlchannelsListAPI
-- * Creating a Request
, accountsURLchannelsList
, AccountsURLchannelsList
-- * Request Lenses
, aulQuotaUser
, aulPrettyPrint
, aulUserIp
, aulAdClientId
, aulAccountId
, aulKey
, aulPageToken
, aulOauthToken
, aulMaxResults
, aulFields
, aulAlt
) where
import Network.Google.AdExchangeSeller.Types
import Network.Google.Prelude
-- | A resource alias for @AdexchangesellerAccountsURLchannelsList@ which the
-- 'AccountsURLchannelsList' request conforms to.
type AccountsUrlchannelsListAPI =
"accounts" :>
Capture "accountId" Text :>
"adclients" :>
Capture "adClientId" Text :>
"urlchannels" :>
QueryParam "pageToken" Text :>
QueryParam "maxResults" Word32 :>
Get '[JSON] URLChannels
-- | List all URL channels in the specified ad client for this Ad Exchange
-- account.
--
-- /See:/ 'accountsURLchannelsList' smart constructor.
data AccountsURLchannelsList = AccountsURLchannelsList
{ _aulQuotaUser :: !(Maybe Text)
, _aulPrettyPrint :: !Bool
, _aulUserIp :: !(Maybe Text)
, _aulAdClientId :: !Text
, _aulAccountId :: !Text
, _aulKey :: !(Maybe Text)
, _aulPageToken :: !(Maybe Text)
, _aulOauthToken :: !(Maybe Text)
, _aulMaxResults :: !(Maybe Word32)
, _aulFields :: !(Maybe Text)
, _aulAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'AccountsURLchannelsList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'aulQuotaUser'
--
-- * 'aulPrettyPrint'
--
-- * 'aulUserIp'
--
-- * 'aulAdClientId'
--
-- * 'aulAccountId'
--
-- * 'aulKey'
--
-- * 'aulPageToken'
--
-- * 'aulOauthToken'
--
-- * 'aulMaxResults'
--
-- * 'aulFields'
--
-- * 'aulAlt'
accountsURLchannelsList
:: Text -- ^ 'adClientId'
-> Text -- ^ 'accountId'
-> AccountsURLchannelsList
accountsURLchannelsList pAulAdClientId_ pAulAccountId_ =
AccountsURLchannelsList
{ _aulQuotaUser = Nothing
, _aulPrettyPrint = True
, _aulUserIp = Nothing
, _aulAdClientId = pAulAdClientId_
, _aulAccountId = pAulAccountId_
, _aulKey = Nothing
, _aulPageToken = Nothing
, _aulOauthToken = Nothing
, _aulMaxResults = Nothing
, _aulFields = Nothing
, _aulAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
aulQuotaUser :: Lens' AccountsURLchannelsList' (Maybe Text)
aulQuotaUser
= lens _aulQuotaUser (\ s a -> s{_aulQuotaUser = a})
-- | Returns response with indentations and line breaks.
aulPrettyPrint :: Lens' AccountsURLchannelsList' Bool
aulPrettyPrint
= lens _aulPrettyPrint
(\ s a -> s{_aulPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
aulUserIp :: Lens' AccountsURLchannelsList' (Maybe Text)
aulUserIp
= lens _aulUserIp (\ s a -> s{_aulUserIp = a})
-- | Ad client for which to list URL channels.
aulAdClientId :: Lens' AccountsURLchannelsList' Text
aulAdClientId
= lens _aulAdClientId
(\ s a -> s{_aulAdClientId = a})
-- | Account to which the ad client belongs.
aulAccountId :: Lens' AccountsURLchannelsList' Text
aulAccountId
= lens _aulAccountId (\ s a -> s{_aulAccountId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
aulKey :: Lens' AccountsURLchannelsList' (Maybe Text)
aulKey = lens _aulKey (\ s a -> s{_aulKey = a})
-- | A continuation token, used to page through URL channels. To retrieve the
-- next page, set this parameter to the value of \"nextPageToken\" from the
-- previous response.
aulPageToken :: Lens' AccountsURLchannelsList' (Maybe Text)
aulPageToken
= lens _aulPageToken (\ s a -> s{_aulPageToken = a})
-- | OAuth 2.0 token for the current user.
aulOauthToken :: Lens' AccountsURLchannelsList' (Maybe Text)
aulOauthToken
= lens _aulOauthToken
(\ s a -> s{_aulOauthToken = a})
-- | The maximum number of URL channels to include in the response, used for
-- paging.
aulMaxResults :: Lens' AccountsURLchannelsList' (Maybe Word32)
aulMaxResults
= lens _aulMaxResults
(\ s a -> s{_aulMaxResults = a})
-- | Selector specifying which fields to include in a partial response.
aulFields :: Lens' AccountsURLchannelsList' (Maybe Text)
aulFields
= lens _aulFields (\ s a -> s{_aulFields = a})
-- | Data format for the response.
aulAlt :: Lens' AccountsURLchannelsList' Text
aulAlt = lens _aulAlt (\ s a -> s{_aulAlt = a})
instance GoogleRequest AccountsURLchannelsList' where
type Rs AccountsURLchannelsList' = URLChannels
request = requestWithRoute defReq adExchangeSellerURL
requestWithRoute r u AccountsURLchannelsList{..}
= go _aulQuotaUser _aulPrettyPrint _aulUserIp
_aulAdClientId
_aulAccountId
_aulKey
_aulPageToken
_aulOauthToken
_aulMaxResults
_aulFields
_aulAlt
where go
= clientWithRoute
(Proxy :: Proxy AccountsUrlchannelsListAPI)
r
u

View File

@ -0,0 +1,57 @@
name: gogol-adexchange-seller
version: 0.0.1
synopsis: Ad Exchange Seller API Client.
homepage: https://github.com/brendanhay/gogol
bug-reports: https://github.com/brendanhay/gogol/issues
license: OtherLicense
license-file: LICENSE
author: Brendan Hay
maintainer: Brendan Hay <brendan.g.hay@gmail.com>
copyright: Copyright (c) 2015 Brendan Hay
category: Network, Google, Cloud
build-type: Simple
cabal-version: >= 1.10
extra-source-files: README.md
description:
Gives Ad Exchange seller users access to their inventory and the ability
to generate reports
.
/Warning:/ This is an experimental prototype/preview release which is still
under exploratory development and not intended for public use, caveat emptor!
source-repository head
type: git
location: git://github.com/brendanhay/gogol.git
library
default-language: Haskell2010
hs-source-dirs: src gen
ghc-options: -Wall
exposed-modules:
Network.Google.AdExchangeSeller
, Network.Google.AdExchangeSeller.Types
, Network.Google.Resource.AdExchangeSeller.Accounts.Adclients.List
, Network.Google.Resource.AdExchangeSeller.Accounts.Alerts.List
, Network.Google.Resource.AdExchangeSeller.Accounts.Customchannels.Get
, Network.Google.Resource.AdExchangeSeller.Accounts.Customchannels.List
, Network.Google.Resource.AdExchangeSeller.Accounts.Get
, Network.Google.Resource.AdExchangeSeller.Accounts.List
, Network.Google.Resource.AdExchangeSeller.Accounts.Metadata.Dimensions.List
, Network.Google.Resource.AdExchangeSeller.Accounts.Metadata.Metrics.List
, Network.Google.Resource.AdExchangeSeller.Accounts.Preferreddeals.Get
, Network.Google.Resource.AdExchangeSeller.Accounts.Preferreddeals.List
, Network.Google.Resource.AdExchangeSeller.Accounts.Reports.Generate
, Network.Google.Resource.AdExchangeSeller.Accounts.Reports.Saved.Generate
, Network.Google.Resource.AdExchangeSeller.Accounts.Reports.Saved.List
, Network.Google.Resource.AdExchangeSeller.Accounts.URLchannels.List
other-modules:
Network.Google.AdExchangeSeller.Types.Product
, Network.Google.AdExchangeSeller.Types.Sum
build-depends:
gogol-core == 0.0.1.*
, base >= 4.7 && < 5

View File

View File

@ -0,0 +1,373 @@
Mozilla Public License Version 2.0
==================================
1. Definitions
--------------
1.1. "Contributor"
means each individual or legal entity that creates, contributes to
the creation of, or owns Covered Software.
1.2. "Contributor Version"
means the combination of the Contributions of others (if any) used
by a Contributor and that particular Contributor's Contribution.
1.3. "Contribution"
means Covered Software of a particular Contributor.
1.4. "Covered Software"
means Source Code Form to which the initial Contributor has attached
the notice in Exhibit A, the Executable Form of such Source Code
Form, and Modifications of such Source Code Form, in each case
including portions thereof.
1.5. "Incompatible With Secondary Licenses"
means
(a) that the initial Contributor has attached the notice described
in Exhibit B to the Covered Software; or
(b) that the Covered Software was made available under the terms of
version 1.1 or earlier of the License, but not also under the
terms of a Secondary License.
1.6. "Executable Form"
means any form of the work other than Source Code Form.
1.7. "Larger Work"
means a work that combines Covered Software with other material, in
a separate file or files, that is not Covered Software.
1.8. "License"
means this document.
1.9. "Licensable"
means having the right to grant, to the maximum extent possible,
whether at the time of the initial grant or subsequently, any and
all of the rights conveyed by this License.
1.10. "Modifications"
means any of the following:
(a) any file in Source Code Form that results from an addition to,
deletion from, or modification of the contents of Covered
Software; or
(b) any new file in Source Code Form that contains any Covered
Software.
1.11. "Patent Claims" of a Contributor
means any patent claim(s), including without limitation, method,
process, and apparatus claims, in any patent Licensable by such
Contributor that would be infringed, but for the grant of the
License, by the making, using, selling, offering for sale, having
made, import, or transfer of either its Contributions or its
Contributor Version.
1.12. "Secondary License"
means either the GNU General Public License, Version 2.0, the GNU
Lesser General Public License, Version 2.1, the GNU Affero General
Public License, Version 3.0, or any later versions of those
licenses.
1.13. "Source Code Form"
means the form of the work preferred for making modifications.
1.14. "You" (or "Your")
means an individual or a legal entity exercising rights under this
License. For legal entities, "You" includes any entity that
controls, is controlled by, or is under common control with You. For
purposes of this definition, "control" means (a) the power, direct
or indirect, to cause the direction or management of such entity,
whether by contract or otherwise, or (b) ownership of more than
fifty percent (50%) of the outstanding shares or beneficial
ownership of such entity.
2. License Grants and Conditions
--------------------------------
2.1. Grants
Each Contributor hereby grants You a world-wide, royalty-free,
non-exclusive license:
(a) under intellectual property rights (other than patent or trademark)
Licensable by such Contributor to use, reproduce, make available,
modify, display, perform, distribute, and otherwise exploit its
Contributions, either on an unmodified basis, with Modifications, or
as part of a Larger Work; and
(b) under Patent Claims of such Contributor to make, use, sell, offer
for sale, have made, import, and otherwise transfer either its
Contributions or its Contributor Version.
2.2. Effective Date
The licenses granted in Section 2.1 with respect to any Contribution
become effective for each Contribution on the date the Contributor first
distributes such Contribution.
2.3. Limitations on Grant Scope
The licenses granted in this Section 2 are the only rights granted under
this License. No additional rights or licenses will be implied from the
distribution or licensing of Covered Software under this License.
Notwithstanding Section 2.1(b) above, no patent license is granted by a
Contributor:
(a) for any code that a Contributor has removed from Covered Software;
or
(b) for infringements caused by: (i) Your and any other third party's
modifications of Covered Software, or (ii) the combination of its
Contributions with other software (except as part of its Contributor
Version); or
(c) under Patent Claims infringed by Covered Software in the absence of
its Contributions.
This License does not grant any rights in the trademarks, service marks,
or logos of any Contributor (except as may be necessary to comply with
the notice requirements in Section 3.4).
2.4. Subsequent Licenses
No Contributor makes additional grants as a result of Your choice to
distribute the Covered Software under a subsequent version of this
License (see Section 10.2) or under the terms of a Secondary License (if
permitted under the terms of Section 3.3).
2.5. Representation
Each Contributor represents that the Contributor believes its
Contributions are its original creation(s) or it has sufficient rights
to grant the rights to its Contributions conveyed by this License.
2.6. Fair Use
This License is not intended to limit any rights You have under
applicable copyright doctrines of fair use, fair dealing, or other
equivalents.
2.7. Conditions
Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted
in Section 2.1.
3. Responsibilities
-------------------
3.1. Distribution of Source Form
All distribution of Covered Software in Source Code Form, including any
Modifications that You create or to which You contribute, must be under
the terms of this License. You must inform recipients that the Source
Code Form of the Covered Software is governed by the terms of this
License, and how they can obtain a copy of this License. You may not
attempt to alter or restrict the recipients' rights in the Source Code
Form.
3.2. Distribution of Executable Form
If You distribute Covered Software in Executable Form then:
(a) such Covered Software must also be made available in Source Code
Form, as described in Section 3.1, and You must inform recipients of
the Executable Form how they can obtain a copy of such Source Code
Form by reasonable means in a timely manner, at a charge no more
than the cost of distribution to the recipient; and
(b) You may distribute such Executable Form under the terms of this
License, or sublicense it under different terms, provided that the
license for the Executable Form does not attempt to limit or alter
the recipients' rights in the Source Code Form under this License.
3.3. Distribution of a Larger Work
You may create and distribute a Larger Work under terms of Your choice,
provided that You also comply with the requirements of this License for
the Covered Software. If the Larger Work is a combination of Covered
Software with a work governed by one or more Secondary Licenses, and the
Covered Software is not Incompatible With Secondary Licenses, this
License permits You to additionally distribute such Covered Software
under the terms of such Secondary License(s), so that the recipient of
the Larger Work may, at their option, further distribute the Covered
Software under the terms of either this License or such Secondary
License(s).
3.4. Notices
You may not remove or alter the substance of any license notices
(including copyright notices, patent notices, disclaimers of warranty,
or limitations of liability) contained within the Source Code Form of
the Covered Software, except that You may alter any license notices to
the extent required to remedy known factual inaccuracies.
3.5. Application of Additional Terms
You may choose to offer, and to charge a fee for, warranty, support,
indemnity or liability obligations to one or more recipients of Covered
Software. However, You may do so only on Your own behalf, and not on
behalf of any Contributor. You must make it absolutely clear that any
such warranty, support, indemnity, or liability obligation is offered by
You alone, and You hereby agree to indemnify every Contributor for any
liability incurred by such Contributor as a result of warranty, support,
indemnity or liability terms You offer. You may include additional
disclaimers of warranty and limitations of liability specific to any
jurisdiction.
4. Inability to Comply Due to Statute or Regulation
---------------------------------------------------
If it is impossible for You to comply with any of the terms of this
License with respect to some or all of the Covered Software due to
statute, judicial order, or regulation then You must: (a) comply with
the terms of this License to the maximum extent possible; and (b)
describe the limitations and the code they affect. Such description must
be placed in a text file included with all distributions of the Covered
Software under this License. Except to the extent prohibited by statute
or regulation, such description must be sufficiently detailed for a
recipient of ordinary skill to be able to understand it.
5. Termination
--------------
5.1. The rights granted under this License will terminate automatically
if You fail to comply with any of its terms. However, if You become
compliant, then the rights granted under this License from a particular
Contributor are reinstated (a) provisionally, unless and until such
Contributor explicitly and finally terminates Your grants, and (b) on an
ongoing basis, if such Contributor fails to notify You of the
non-compliance by some reasonable means prior to 60 days after You have
come back into compliance. Moreover, Your grants from a particular
Contributor are reinstated on an ongoing basis if such Contributor
notifies You of the non-compliance by some reasonable means, this is the
first time You have received notice of non-compliance with this License
from such Contributor, and You become compliant prior to 30 days after
Your receipt of the notice.
5.2. If You initiate litigation against any entity by asserting a patent
infringement claim (excluding declaratory judgment actions,
counter-claims, and cross-claims) alleging that a Contributor Version
directly or indirectly infringes any patent, then the rights granted to
You by any and all Contributors for the Covered Software under Section
2.1 of this License shall terminate.
5.3. In the event of termination under Sections 5.1 or 5.2 above, all
end user license agreements (excluding distributors and resellers) which
have been validly granted by You or Your distributors under this License
prior to termination shall survive termination.
************************************************************************
* *
* 6. Disclaimer of Warranty *
* ------------------------- *
* *
* Covered Software is provided under this License on an "as is" *
* basis, without warranty of any kind, either expressed, implied, or *
* statutory, including, without limitation, warranties that the *
* Covered Software is free of defects, merchantable, fit for a *
* particular purpose or non-infringing. The entire risk as to the *
* quality and performance of the Covered Software is with You. *
* Should any Covered Software prove defective in any respect, You *
* (not any Contributor) assume the cost of any necessary servicing, *
* repair, or correction. This disclaimer of warranty constitutes an *
* essential part of this License. No use of any Covered Software is *
* authorized under this License except under this disclaimer. *
* *
************************************************************************
************************************************************************
* *
* 7. Limitation of Liability *
* -------------------------- *
* *
* Under no circumstances and under no legal theory, whether tort *
* (including negligence), contract, or otherwise, shall any *
* Contributor, or anyone who distributes Covered Software as *
* permitted above, be liable to You for any direct, indirect, *
* special, incidental, or consequential damages of any character *
* including, without limitation, damages for lost profits, loss of *
* goodwill, work stoppage, computer failure or malfunction, or any *
* and all other commercial damages or losses, even if such party *
* shall have been informed of the possibility of such damages. This *
* limitation of liability shall not apply to liability for death or *
* personal injury resulting from such party's negligence to the *
* extent applicable law prohibits such limitation. Some *
* jurisdictions do not allow the exclusion or limitation of *
* incidental or consequential damages, so this exclusion and *
* limitation may not apply to You. *
* *
************************************************************************
8. Litigation
-------------
Any litigation relating to this License may be brought only in the
courts of a jurisdiction where the defendant maintains its principal
place of business and such litigation shall be governed by laws of that
jurisdiction, without reference to its conflict-of-law provisions.
Nothing in this Section shall prevent a party's ability to bring
cross-claims or counter-claims.
9. Miscellaneous
----------------
This License represents the complete agreement concerning the subject
matter hereof. If any provision of this License is held to be
unenforceable, such provision shall be reformed only to the extent
necessary to make it enforceable. Any law or regulation which provides
that the language of a contract shall be construed against the drafter
shall not be used to construe this License against a Contributor.
10. Versions of the License
---------------------------
10.1. New Versions
Mozilla Foundation is the license steward. Except as provided in Section
10.3, no one other than the license steward has the right to modify or
publish new versions of this License. Each version will be given a
distinguishing version number.
10.2. Effect of New Versions
You may distribute the Covered Software under the terms of the version
of the License under which You originally received the Covered Software,
or under the terms of any subsequent version published by the license
steward.
10.3. Modified Versions
If you create software not governed by this License, and you want to
create a new license for such software, you may create and use a
modified version of this License if you rename the license and remove
any references to the name of the license steward (except to note that
such modified license differs from this License).
10.4. Distributing Source Code Form that is Incompatible With Secondary
Licenses
If You choose to distribute Source Code Form that is Incompatible With
Secondary Licenses under the terms of this version of the License, the
notice described in Exhibit B of this License must be attached.
Exhibit A - Source Code Form License Notice
-------------------------------------------
This Source Code Form is subject to the terms of the Mozilla Public
License, v. 2.0. If a copy of the MPL was not distributed with this
file, You can obtain one at http://mozilla.org/MPL/2.0/.
If it is not possible or desirable to put the notice in a particular
file, then You may include the notice in a location (such as a LICENSE
file in a relevant directory) where a recipient would be likely to look
for such a notice.
You may add additional accurate notices of copyright ownership.
Exhibit B - "Incompatible With Secondary Licenses" Notice
---------------------------------------------------------
This Source Code Form is "Incompatible With Secondary Licenses", as
defined by the Mozilla Public License, v. 2.0.

View File

@ -0,0 +1 @@
include ../share/library.mk

View File

@ -0,0 +1,28 @@
# gogol-admin-datatransfer
* [Version](#version)
* [Description](#description)
* [Contribute](#contribute)
* [Licence](#licence)
## Version
`0.0.1`
## Description
A client library for the Admin Data Transfer API.
## Contribute
For any problems, comments, or feedback please create an issue [here on GitHub](https://github.com/brendanhay/amazonka/issues).
> _Note:_ this library is an auto-generated Haskell package. Please see `amazonka-gen` for more information.
## Licence
`gogol-admin-datatransfer` is released under the [Mozilla Public License Version 2.0](http://www.mozilla.org/MPL/).

View File

@ -0,0 +1,2 @@
import Distribution.Simple
main = defaultMain

View File

@ -0,0 +1,114 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.AdminDataTransfer
-- Copyright : (c) 2015 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)
--
-- -- | Admin Data Transfer API lets you transfer user data from one user to
-- another.
--
-- /See:/ <https://developers.google.com/admin-sdk/data-transfer/ Admin Data Transfer API Reference>
module Network.Google.AdminDataTransfer
(
-- * API
AdminDataTransferAPI
, adminDataTransferAPI
, adminDataTransferURL
-- * Service Methods
-- * REST Resources
-- ** DatatransferApplicationsGet
, module Datatransfer.Applications.Get
-- ** DatatransferApplicationsList
, module Datatransfer.Applications.List
-- ** DatatransferTransfersGet
, module Datatransfer.Transfers.Get
-- ** DatatransferTransfersInsert
, module Datatransfer.Transfers.Insert
-- ** DatatransferTransfersList
, module Datatransfer.Transfers.List
-- * Types
-- ** Application
, Application
, application
, aTransferParams
, aEtag
, aKind
, aName
, aId
-- ** ApplicationTransferParam
, ApplicationTransferParam
, applicationTransferParam
, atpValue
, atpKey
-- ** ApplicationsListResponse
, ApplicationsListResponse
, applicationsListResponse
, alrEtag
, alrNextPageToken
, alrKind
, alrApplications
-- ** DataTransfer
, DataTransfer
, dataTransfer
, dtEtag
, dtOldOwnerUserId
, dtKind
, dtNewOwnerUserId
, dtRequestTime
, dtApplicationDataTransfers
, dtId
, dtOverallTransferStatusCode
-- ** DataTransfersListResponse
, DataTransfersListResponse
, dataTransfersListResponse
, dtlrEtag
, dtlrNextPageToken
, dtlrKind
, dtlrDataTransfers
-- ** ApplicationDataTransfer
, ApplicationDataTransfer
, applicationDataTransfer
, adtApplicationTransferParams
, adtApplicationId
, adtApplicationTransferStatus
) where
import Network.Google.AdminDataTransfer.Types
import Network.Google.Prelude
import Network.Google.Resource.Datatransfer.Applications.Get
import Network.Google.Resource.Datatransfer.Applications.List
import Network.Google.Resource.Datatransfer.Transfers.Get
import Network.Google.Resource.Datatransfer.Transfers.Insert
import Network.Google.Resource.Datatransfer.Transfers.List
{- $resources
TODO
-}
type AdminDataTransferAPI =
Transfers :<|> Applications
adminDataTransferAPI :: Proxy AdminDataTransferAPI
adminDataTransferAPI = Proxy

View File

@ -0,0 +1,80 @@
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE OverloadedStrings #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
-- |
-- Module : Network.Google.AdminDataTransfer.Types
-- Copyright : (c) 2015 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)
--
module Network.Google.AdminDataTransfer.Types
(
-- * Service URL
adminDataTransferURL
-- * Application
, Application
, application
, aTransferParams
, aEtag
, aKind
, aName
, aId
-- * ApplicationTransferParam
, ApplicationTransferParam
, applicationTransferParam
, atpValue
, atpKey
-- * ApplicationsListResponse
, ApplicationsListResponse
, applicationsListResponse
, alrEtag
, alrNextPageToken
, alrKind
, alrApplications
-- * DataTransfer
, DataTransfer
, dataTransfer
, dtEtag
, dtOldOwnerUserId
, dtKind
, dtNewOwnerUserId
, dtRequestTime
, dtApplicationDataTransfers
, dtId
, dtOverallTransferStatusCode
-- * DataTransfersListResponse
, DataTransfersListResponse
, dataTransfersListResponse
, dtlrEtag
, dtlrNextPageToken
, dtlrKind
, dtlrDataTransfers
-- * ApplicationDataTransfer
, ApplicationDataTransfer
, applicationDataTransfer
, adtApplicationTransferParams
, adtApplicationId
, adtApplicationTransferStatus
) where
import Network.Google.AdminDataTransfer.Types.Product
import Network.Google.AdminDataTransfer.Types.Sum
import Network.Google.Prelude
-- | URL referring to version 'datatransfer_v1' of the Admin Data Transfer API.
adminDataTransferURL :: BaseURL
adminDataTransferURL
= BaseUrl Https
"https://www.googleapis.com/admin/datatransfer/v1/"
443

View File

@ -0,0 +1,485 @@
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
-- |
-- Module : Network.Google.AdminDataTransfer.Types.Product
-- Copyright : (c) 2015 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)
--
module Network.Google.AdminDataTransfer.Types.Product where
import Network.Google.AdminDataTransfer.Types.Sum
import Network.Google.Prelude
-- | The JSON template for an Application resource.
--
-- /See:/ 'application' smart constructor.
data Application = Application
{ _aTransferParams :: !(Maybe [Maybe ApplicationTransferParam])
, _aEtag :: !(Maybe Text)
, _aKind :: !Text
, _aName :: !(Maybe Text)
, _aId :: !(Maybe Int64)
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'Application' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'aTransferParams'
--
-- * 'aEtag'
--
-- * 'aKind'
--
-- * 'aName'
--
-- * 'aId'
application
:: Application
application =
Application
{ _aTransferParams = Nothing
, _aEtag = Nothing
, _aKind = "admin#datatransfer#ApplicationResource"
, _aName = Nothing
, _aId = Nothing
}
-- | The list of all possible transfer parameters for this application. These
-- parameters can be used to select the data of the user in this
-- application to be transfered.
aTransferParams :: Lens' Application [Maybe ApplicationTransferParam]
aTransferParams
= lens _aTransferParams
(\ s a -> s{_aTransferParams = a})
. _Default
. _Coerce
-- | Etag of the resource.
aEtag :: Lens' Application (Maybe Text)
aEtag = lens _aEtag (\ s a -> s{_aEtag = a})
-- | Identifies the resource as a DataTransfer Application Resource.
aKind :: Lens' Application Text
aKind = lens _aKind (\ s a -> s{_aKind = a})
-- | The application\'s name.
aName :: Lens' Application (Maybe Text)
aName = lens _aName (\ s a -> s{_aName = a})
-- | The application\'s ID.
aId :: Lens' Application (Maybe Int64)
aId = lens _aId (\ s a -> s{_aId = a})
instance FromJSON Application where
parseJSON
= withObject "Application"
(\ o ->
Application <$>
(o .:? "transferParams" .!= mempty) <*>
(o .:? "etag")
<*>
(o .:? "kind" .!=
"admin#datatransfer#ApplicationResource")
<*> (o .:? "name")
<*> (o .:? "id"))
instance ToJSON Application where
toJSON Application{..}
= object
(catMaybes
[("transferParams" .=) <$> _aTransferParams,
("etag" .=) <$> _aEtag, Just ("kind" .= _aKind),
("name" .=) <$> _aName, ("id" .=) <$> _aId])
-- | Template for application transfer parameters.
--
-- /See:/ 'applicationTransferParam' smart constructor.
data ApplicationTransferParam = ApplicationTransferParam
{ _atpValue :: !(Maybe [Text])
, _atpKey :: !(Maybe Text)
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'ApplicationTransferParam' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'atpValue'
--
-- * 'atpKey'
applicationTransferParam
:: ApplicationTransferParam
applicationTransferParam =
ApplicationTransferParam
{ _atpValue = Nothing
, _atpKey = Nothing
}
-- | The value of the coressponding transfer parameter. eg: \'PRIVATE\' or
-- \'SHARED\'
atpValue :: Lens' ApplicationTransferParam [Text]
atpValue
= lens _atpValue (\ s a -> s{_atpValue = a}) .
_Default
. _Coerce
-- | The type of the transfer parameter. eg: \'PRIVACY_LEVEL\'
atpKey :: Lens' ApplicationTransferParam (Maybe Text)
atpKey = lens _atpKey (\ s a -> s{_atpKey = a})
instance FromJSON ApplicationTransferParam where
parseJSON
= withObject "ApplicationTransferParam"
(\ o ->
ApplicationTransferParam <$>
(o .:? "value" .!= mempty) <*> (o .:? "key"))
instance ToJSON ApplicationTransferParam where
toJSON ApplicationTransferParam{..}
= object
(catMaybes
[("value" .=) <$> _atpValue, ("key" .=) <$> _atpKey])
-- | Template for a collection of Applications.
--
-- /See:/ 'applicationsListResponse' smart constructor.
data ApplicationsListResponse = ApplicationsListResponse
{ _alrEtag :: !(Maybe Text)
, _alrNextPageToken :: !(Maybe Text)
, _alrKind :: !Text
, _alrApplications :: !(Maybe [Maybe Application])
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'ApplicationsListResponse' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'alrEtag'
--
-- * 'alrNextPageToken'
--
-- * 'alrKind'
--
-- * 'alrApplications'
applicationsListResponse
:: ApplicationsListResponse
applicationsListResponse =
ApplicationsListResponse
{ _alrEtag = Nothing
, _alrNextPageToken = Nothing
, _alrKind = "admin#datatransfer#applicationsList"
, _alrApplications = Nothing
}
-- | ETag of the resource.
alrEtag :: Lens' ApplicationsListResponse (Maybe Text)
alrEtag = lens _alrEtag (\ s a -> s{_alrEtag = a})
-- | Continuation token which will be used to specify next page in list API.
alrNextPageToken :: Lens' ApplicationsListResponse (Maybe Text)
alrNextPageToken
= lens _alrNextPageToken
(\ s a -> s{_alrNextPageToken = a})
-- | Identifies the resource as a collection of Applications.
alrKind :: Lens' ApplicationsListResponse Text
alrKind = lens _alrKind (\ s a -> s{_alrKind = a})
-- | List of applications that support data transfer and are also installed
-- for the customer.
alrApplications :: Lens' ApplicationsListResponse [Maybe Application]
alrApplications
= lens _alrApplications
(\ s a -> s{_alrApplications = a})
. _Default
. _Coerce
instance FromJSON ApplicationsListResponse where
parseJSON
= withObject "ApplicationsListResponse"
(\ o ->
ApplicationsListResponse <$>
(o .:? "etag") <*> (o .:? "nextPageToken") <*>
(o .:? "kind" .!=
"admin#datatransfer#applicationsList")
<*> (o .:? "applications" .!= mempty))
instance ToJSON ApplicationsListResponse where
toJSON ApplicationsListResponse{..}
= object
(catMaybes
[("etag" .=) <$> _alrEtag,
("nextPageToken" .=) <$> _alrNextPageToken,
Just ("kind" .= _alrKind),
("applications" .=) <$> _alrApplications])
-- | The JSON template for a DataTransfer resource.
--
-- /See:/ 'dataTransfer' smart constructor.
data DataTransfer = DataTransfer
{ _dtEtag :: !(Maybe Text)
, _dtOldOwnerUserId :: !(Maybe Text)
, _dtKind :: !Text
, _dtNewOwnerUserId :: !(Maybe Text)
, _dtRequestTime :: !(Maybe UTCTime)
, _dtApplicationDataTransfers :: !(Maybe [Maybe ApplicationDataTransfer])
, _dtId :: !(Maybe Text)
, _dtOverallTransferStatusCode :: !(Maybe Text)
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'DataTransfer' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'dtEtag'
--
-- * 'dtOldOwnerUserId'
--
-- * 'dtKind'
--
-- * 'dtNewOwnerUserId'
--
-- * 'dtRequestTime'
--
-- * 'dtApplicationDataTransfers'
--
-- * 'dtId'
--
-- * 'dtOverallTransferStatusCode'
dataTransfer
:: DataTransfer
dataTransfer =
DataTransfer
{ _dtEtag = Nothing
, _dtOldOwnerUserId = Nothing
, _dtKind = "admin#datatransfer#DataTransfer"
, _dtNewOwnerUserId = Nothing
, _dtRequestTime = Nothing
, _dtApplicationDataTransfers = Nothing
, _dtId = Nothing
, _dtOverallTransferStatusCode = Nothing
}
-- | ETag of the resource.
dtEtag :: Lens' DataTransfer (Maybe Text)
dtEtag = lens _dtEtag (\ s a -> s{_dtEtag = a})
-- | ID of the user whose data is being transfered.
dtOldOwnerUserId :: Lens' DataTransfer (Maybe Text)
dtOldOwnerUserId
= lens _dtOldOwnerUserId
(\ s a -> s{_dtOldOwnerUserId = a})
-- | Identifies the resource as a DataTransfer request.
dtKind :: Lens' DataTransfer Text
dtKind = lens _dtKind (\ s a -> s{_dtKind = a})
-- | ID of the user to whom the data is being transfered.
dtNewOwnerUserId :: Lens' DataTransfer (Maybe Text)
dtNewOwnerUserId
= lens _dtNewOwnerUserId
(\ s a -> s{_dtNewOwnerUserId = a})
-- | The time at which the data transfer was requested (Read-only).
dtRequestTime :: Lens' DataTransfer (Maybe UTCTime)
dtRequestTime
= lens _dtRequestTime
(\ s a -> s{_dtRequestTime = a})
-- | List of per application data transfer resources. It contains data
-- transfer details of the applications associated with this transfer
-- resource. Note that this list is also used to specify the applications
-- for which data transfer has to be done at the time of the transfer
-- resource creation.
dtApplicationDataTransfers :: Lens' DataTransfer [Maybe ApplicationDataTransfer]
dtApplicationDataTransfers
= lens _dtApplicationDataTransfers
(\ s a -> s{_dtApplicationDataTransfers = a})
. _Default
. _Coerce
-- | The transfer\'s ID (Read-only).
dtId :: Lens' DataTransfer (Maybe Text)
dtId = lens _dtId (\ s a -> s{_dtId = a})
-- | Overall transfer status (Read-only).
dtOverallTransferStatusCode :: Lens' DataTransfer (Maybe Text)
dtOverallTransferStatusCode
= lens _dtOverallTransferStatusCode
(\ s a -> s{_dtOverallTransferStatusCode = a})
instance FromJSON DataTransfer where
parseJSON
= withObject "DataTransfer"
(\ o ->
DataTransfer <$>
(o .:? "etag") <*> (o .:? "oldOwnerUserId") <*>
(o .:? "kind" .!= "admin#datatransfer#DataTransfer")
<*> (o .:? "newOwnerUserId")
<*> (o .:? "requestTime")
<*> (o .:? "applicationDataTransfers" .!= mempty)
<*> (o .:? "id")
<*> (o .:? "overallTransferStatusCode"))
instance ToJSON DataTransfer where
toJSON DataTransfer{..}
= object
(catMaybes
[("etag" .=) <$> _dtEtag,
("oldOwnerUserId" .=) <$> _dtOldOwnerUserId,
Just ("kind" .= _dtKind),
("newOwnerUserId" .=) <$> _dtNewOwnerUserId,
("requestTime" .=) <$> _dtRequestTime,
("applicationDataTransfers" .=) <$>
_dtApplicationDataTransfers,
("id" .=) <$> _dtId,
("overallTransferStatusCode" .=) <$>
_dtOverallTransferStatusCode])
-- | Template for a collection of DataTransfer resources.
--
-- /See:/ 'dataTransfersListResponse' smart constructor.
data DataTransfersListResponse = DataTransfersListResponse
{ _dtlrEtag :: !(Maybe Text)
, _dtlrNextPageToken :: !(Maybe Text)
, _dtlrKind :: !Text
, _dtlrDataTransfers :: !(Maybe [Maybe DataTransfer])
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'DataTransfersListResponse' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'dtlrEtag'
--
-- * 'dtlrNextPageToken'
--
-- * 'dtlrKind'
--
-- * 'dtlrDataTransfers'
dataTransfersListResponse
:: DataTransfersListResponse
dataTransfersListResponse =
DataTransfersListResponse
{ _dtlrEtag = Nothing
, _dtlrNextPageToken = Nothing
, _dtlrKind = "admin#datatransfer#dataTransfersList"
, _dtlrDataTransfers = Nothing
}
-- | ETag of the resource.
dtlrEtag :: Lens' DataTransfersListResponse (Maybe Text)
dtlrEtag = lens _dtlrEtag (\ s a -> s{_dtlrEtag = a})
-- | Continuation token which will be used to specify next page in list API.
dtlrNextPageToken :: Lens' DataTransfersListResponse (Maybe Text)
dtlrNextPageToken
= lens _dtlrNextPageToken
(\ s a -> s{_dtlrNextPageToken = a})
-- | Identifies the resource as a collection of data transfer requests.
dtlrKind :: Lens' DataTransfersListResponse Text
dtlrKind = lens _dtlrKind (\ s a -> s{_dtlrKind = a})
-- | List of data transfer requests.
dtlrDataTransfers :: Lens' DataTransfersListResponse [Maybe DataTransfer]
dtlrDataTransfers
= lens _dtlrDataTransfers
(\ s a -> s{_dtlrDataTransfers = a})
. _Default
. _Coerce
instance FromJSON DataTransfersListResponse where
parseJSON
= withObject "DataTransfersListResponse"
(\ o ->
DataTransfersListResponse <$>
(o .:? "etag") <*> (o .:? "nextPageToken") <*>
(o .:? "kind" .!=
"admin#datatransfer#dataTransfersList")
<*> (o .:? "dataTransfers" .!= mempty))
instance ToJSON DataTransfersListResponse where
toJSON DataTransfersListResponse{..}
= object
(catMaybes
[("etag" .=) <$> _dtlrEtag,
("nextPageToken" .=) <$> _dtlrNextPageToken,
Just ("kind" .= _dtlrKind),
("dataTransfers" .=) <$> _dtlrDataTransfers])
-- | Template to map fields of ApplicationDataTransfer resource.
--
-- /See:/ 'applicationDataTransfer' smart constructor.
data ApplicationDataTransfer = ApplicationDataTransfer
{ _adtApplicationTransferParams :: !(Maybe [Maybe ApplicationTransferParam])
, _adtApplicationId :: !(Maybe Int64)
, _adtApplicationTransferStatus :: !(Maybe Text)
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'ApplicationDataTransfer' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'adtApplicationTransferParams'
--
-- * 'adtApplicationId'
--
-- * 'adtApplicationTransferStatus'
applicationDataTransfer
:: ApplicationDataTransfer
applicationDataTransfer =
ApplicationDataTransfer
{ _adtApplicationTransferParams = Nothing
, _adtApplicationId = Nothing
, _adtApplicationTransferStatus = Nothing
}
-- | The transfer parameters for the application. These parameters are used
-- to select the data which will get transfered in context of this
-- application.
adtApplicationTransferParams :: Lens' ApplicationDataTransfer [Maybe ApplicationTransferParam]
adtApplicationTransferParams
= lens _adtApplicationTransferParams
(\ s a -> s{_adtApplicationTransferParams = a})
. _Default
. _Coerce
-- | The application\'s ID.
adtApplicationId :: Lens' ApplicationDataTransfer (Maybe Int64)
adtApplicationId
= lens _adtApplicationId
(\ s a -> s{_adtApplicationId = a})
-- | Current status of transfer for this application. (Read-only)
adtApplicationTransferStatus :: Lens' ApplicationDataTransfer (Maybe Text)
adtApplicationTransferStatus
= lens _adtApplicationTransferStatus
(\ s a -> s{_adtApplicationTransferStatus = a})
instance FromJSON ApplicationDataTransfer where
parseJSON
= withObject "ApplicationDataTransfer"
(\ o ->
ApplicationDataTransfer <$>
(o .:? "applicationTransferParams" .!= mempty) <*>
(o .:? "applicationId")
<*> (o .:? "applicationTransferStatus"))
instance ToJSON ApplicationDataTransfer where
toJSON ApplicationDataTransfer{..}
= object
(catMaybes
[("applicationTransferParams" .=) <$>
_adtApplicationTransferParams,
("applicationId" .=) <$> _adtApplicationId,
("applicationTransferStatus" .=) <$>
_adtApplicationTransferStatus])

View File

@ -0,0 +1,18 @@
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE OverloadedStrings #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
-- |
-- Module : Network.Google.AdminDataTransfer.Types.Sum
-- Copyright : (c) 2015 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)
--
module Network.Google.AdminDataTransfer.Types.Sum where
import Network.Google.Prelude

View File

@ -0,0 +1,157 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.Datatransfer.Applications.Get
-- Copyright : (c) 2015 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)
--
-- | Retrieves information about an application for the given application ID.
--
-- /See:/ <https://developers.google.com/admin-sdk/data-transfer/ Admin Data Transfer API Reference> for @DatatransferApplicationsGet@.
module Datatransfer.Applications.Get
(
-- * REST Resource
ApplicationsGetAPI
-- * Creating a Request
, applicationsGet
, ApplicationsGet
-- * Request Lenses
, agQuotaUser
, agPrettyPrint
, agUserIp
, agApplicationId
, agKey
, agOauthToken
, agFields
, agAlt
) where
import Network.Google.AdminDataTransfer.Types
import Network.Google.Prelude
-- | A resource alias for @DatatransferApplicationsGet@ which the
-- 'ApplicationsGet' request conforms to.
type ApplicationsGetAPI =
"applications" :>
Capture "applicationId" Int64 :>
Get '[JSON] Application
-- | Retrieves information about an application for the given application ID.
--
-- /See:/ 'applicationsGet' smart constructor.
data ApplicationsGet = ApplicationsGet
{ _agQuotaUser :: !(Maybe Text)
, _agPrettyPrint :: !Bool
, _agUserIp :: !(Maybe Text)
, _agApplicationId :: !Int64
, _agKey :: !(Maybe Text)
, _agOauthToken :: !(Maybe Text)
, _agFields :: !(Maybe Text)
, _agAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'ApplicationsGet'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'agQuotaUser'
--
-- * 'agPrettyPrint'
--
-- * 'agUserIp'
--
-- * 'agApplicationId'
--
-- * 'agKey'
--
-- * 'agOauthToken'
--
-- * 'agFields'
--
-- * 'agAlt'
applicationsGet
:: Int64 -- ^ 'applicationId'
-> ApplicationsGet
applicationsGet pAgApplicationId_ =
ApplicationsGet
{ _agQuotaUser = Nothing
, _agPrettyPrint = True
, _agUserIp = Nothing
, _agApplicationId = pAgApplicationId_
, _agKey = Nothing
, _agOauthToken = Nothing
, _agFields = Nothing
, _agAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
agQuotaUser :: Lens' ApplicationsGet' (Maybe Text)
agQuotaUser
= lens _agQuotaUser (\ s a -> s{_agQuotaUser = a})
-- | Returns response with indentations and line breaks.
agPrettyPrint :: Lens' ApplicationsGet' Bool
agPrettyPrint
= lens _agPrettyPrint
(\ s a -> s{_agPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
agUserIp :: Lens' ApplicationsGet' (Maybe Text)
agUserIp = lens _agUserIp (\ s a -> s{_agUserIp = a})
-- | ID of the application resource to be retrieved.
agApplicationId :: Lens' ApplicationsGet' Int64
agApplicationId
= lens _agApplicationId
(\ s a -> s{_agApplicationId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
agKey :: Lens' ApplicationsGet' (Maybe Text)
agKey = lens _agKey (\ s a -> s{_agKey = a})
-- | OAuth 2.0 token for the current user.
agOauthToken :: Lens' ApplicationsGet' (Maybe Text)
agOauthToken
= lens _agOauthToken (\ s a -> s{_agOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
agFields :: Lens' ApplicationsGet' (Maybe Text)
agFields = lens _agFields (\ s a -> s{_agFields = a})
-- | Data format for the response.
agAlt :: Lens' ApplicationsGet' Text
agAlt = lens _agAlt (\ s a -> s{_agAlt = a})
instance GoogleRequest ApplicationsGet' where
type Rs ApplicationsGet' = Application
request
= requestWithRoute defReq adminDataTransferURL
requestWithRoute r u ApplicationsGet{..}
= go _agQuotaUser _agPrettyPrint _agUserIp
_agApplicationId
_agKey
_agOauthToken
_agFields
_agAlt
where go
= clientWithRoute (Proxy :: Proxy ApplicationsGetAPI)
r
u

View File

@ -0,0 +1,180 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.Datatransfer.Applications.List
-- Copyright : (c) 2015 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)
--
-- | Lists the applications available for data transfer for a customer.
--
-- /See:/ <https://developers.google.com/admin-sdk/data-transfer/ Admin Data Transfer API Reference> for @DatatransferApplicationsList@.
module Datatransfer.Applications.List
(
-- * REST Resource
ApplicationsListAPI
-- * Creating a Request
, applicationsList
, ApplicationsList
-- * Request Lenses
, alQuotaUser
, alPrettyPrint
, alUserIp
, alCustomerId
, alKey
, alPageToken
, alOauthToken
, alMaxResults
, alFields
, alAlt
) where
import Network.Google.AdminDataTransfer.Types
import Network.Google.Prelude
-- | A resource alias for @DatatransferApplicationsList@ which the
-- 'ApplicationsList' request conforms to.
type ApplicationsListAPI =
"applications" :>
QueryParam "customerId" Text :>
QueryParam "pageToken" Text :>
QueryParam "maxResults" Word32 :>
Get '[JSON] ApplicationsListResponse
-- | Lists the applications available for data transfer for a customer.
--
-- /See:/ 'applicationsList' smart constructor.
data ApplicationsList = ApplicationsList
{ _alQuotaUser :: !(Maybe Text)
, _alPrettyPrint :: !Bool
, _alUserIp :: !(Maybe Text)
, _alCustomerId :: !(Maybe Text)
, _alKey :: !(Maybe Text)
, _alPageToken :: !(Maybe Text)
, _alOauthToken :: !(Maybe Text)
, _alMaxResults :: !(Maybe Word32)
, _alFields :: !(Maybe Text)
, _alAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'ApplicationsList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'alQuotaUser'
--
-- * 'alPrettyPrint'
--
-- * 'alUserIp'
--
-- * 'alCustomerId'
--
-- * 'alKey'
--
-- * 'alPageToken'
--
-- * 'alOauthToken'
--
-- * 'alMaxResults'
--
-- * 'alFields'
--
-- * 'alAlt'
applicationsList
:: ApplicationsList
applicationsList =
ApplicationsList
{ _alQuotaUser = Nothing
, _alPrettyPrint = True
, _alUserIp = Nothing
, _alCustomerId = Nothing
, _alKey = Nothing
, _alPageToken = Nothing
, _alOauthToken = Nothing
, _alMaxResults = Nothing
, _alFields = Nothing
, _alAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
alQuotaUser :: Lens' ApplicationsList' (Maybe Text)
alQuotaUser
= lens _alQuotaUser (\ s a -> s{_alQuotaUser = a})
-- | Returns response with indentations and line breaks.
alPrettyPrint :: Lens' ApplicationsList' Bool
alPrettyPrint
= lens _alPrettyPrint
(\ s a -> s{_alPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
alUserIp :: Lens' ApplicationsList' (Maybe Text)
alUserIp = lens _alUserIp (\ s a -> s{_alUserIp = a})
-- | Immutable ID of the Google Apps account.
alCustomerId :: Lens' ApplicationsList' (Maybe Text)
alCustomerId
= lens _alCustomerId (\ s a -> s{_alCustomerId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
alKey :: Lens' ApplicationsList' (Maybe Text)
alKey = lens _alKey (\ s a -> s{_alKey = a})
-- | Token to specify next page in the list.
alPageToken :: Lens' ApplicationsList' (Maybe Text)
alPageToken
= lens _alPageToken (\ s a -> s{_alPageToken = a})
-- | OAuth 2.0 token for the current user.
alOauthToken :: Lens' ApplicationsList' (Maybe Text)
alOauthToken
= lens _alOauthToken (\ s a -> s{_alOauthToken = a})
-- | Maximum number of results to return. Default is 100.
alMaxResults :: Lens' ApplicationsList' (Maybe Word32)
alMaxResults
= lens _alMaxResults (\ s a -> s{_alMaxResults = a})
-- | Selector specifying which fields to include in a partial response.
alFields :: Lens' ApplicationsList' (Maybe Text)
alFields = lens _alFields (\ s a -> s{_alFields = a})
-- | Data format for the response.
alAlt :: Lens' ApplicationsList' Text
alAlt = lens _alAlt (\ s a -> s{_alAlt = a})
instance GoogleRequest ApplicationsList' where
type Rs ApplicationsList' = ApplicationsListResponse
request
= requestWithRoute defReq adminDataTransferURL
requestWithRoute r u ApplicationsList{..}
= go _alQuotaUser _alPrettyPrint _alUserIp
_alCustomerId
_alKey
_alPageToken
_alOauthToken
_alMaxResults
_alFields
_alAlt
where go
= clientWithRoute
(Proxy :: Proxy ApplicationsListAPI)
r
u

View File

@ -0,0 +1,156 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.Datatransfer.Transfers.Get
-- Copyright : (c) 2015 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)
--
-- | Retrieves a data transfer request by its resource ID.
--
-- /See:/ <https://developers.google.com/admin-sdk/data-transfer/ Admin Data Transfer API Reference> for @DatatransferTransfersGet@.
module Datatransfer.Transfers.Get
(
-- * REST Resource
TransfersGetAPI
-- * Creating a Request
, transfersGet
, TransfersGet
-- * Request Lenses
, tgQuotaUser
, tgPrettyPrint
, tgUserIp
, tgKey
, tgOauthToken
, tgDataTransferId
, tgFields
, tgAlt
) where
import Network.Google.AdminDataTransfer.Types
import Network.Google.Prelude
-- | A resource alias for @DatatransferTransfersGet@ which the
-- 'TransfersGet' request conforms to.
type TransfersGetAPI =
"transfers" :>
Capture "dataTransferId" Text :>
Get '[JSON] DataTransfer
-- | Retrieves a data transfer request by its resource ID.
--
-- /See:/ 'transfersGet' smart constructor.
data TransfersGet = TransfersGet
{ _tgQuotaUser :: !(Maybe Text)
, _tgPrettyPrint :: !Bool
, _tgUserIp :: !(Maybe Text)
, _tgKey :: !(Maybe Text)
, _tgOauthToken :: !(Maybe Text)
, _tgDataTransferId :: !Text
, _tgFields :: !(Maybe Text)
, _tgAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'TransfersGet'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'tgQuotaUser'
--
-- * 'tgPrettyPrint'
--
-- * 'tgUserIp'
--
-- * 'tgKey'
--
-- * 'tgOauthToken'
--
-- * 'tgDataTransferId'
--
-- * 'tgFields'
--
-- * 'tgAlt'
transfersGet
:: Text -- ^ 'dataTransferId'
-> TransfersGet
transfersGet pTgDataTransferId_ =
TransfersGet
{ _tgQuotaUser = Nothing
, _tgPrettyPrint = True
, _tgUserIp = Nothing
, _tgKey = Nothing
, _tgOauthToken = Nothing
, _tgDataTransferId = pTgDataTransferId_
, _tgFields = Nothing
, _tgAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
tgQuotaUser :: Lens' TransfersGet' (Maybe Text)
tgQuotaUser
= lens _tgQuotaUser (\ s a -> s{_tgQuotaUser = a})
-- | Returns response with indentations and line breaks.
tgPrettyPrint :: Lens' TransfersGet' Bool
tgPrettyPrint
= lens _tgPrettyPrint
(\ s a -> s{_tgPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
tgUserIp :: Lens' TransfersGet' (Maybe Text)
tgUserIp = lens _tgUserIp (\ s a -> s{_tgUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
tgKey :: Lens' TransfersGet' (Maybe Text)
tgKey = lens _tgKey (\ s a -> s{_tgKey = a})
-- | OAuth 2.0 token for the current user.
tgOauthToken :: Lens' TransfersGet' (Maybe Text)
tgOauthToken
= lens _tgOauthToken (\ s a -> s{_tgOauthToken = a})
-- | ID of the resource to be retrieved. This is returned in the response
-- from the insert method.
tgDataTransferId :: Lens' TransfersGet' Text
tgDataTransferId
= lens _tgDataTransferId
(\ s a -> s{_tgDataTransferId = a})
-- | Selector specifying which fields to include in a partial response.
tgFields :: Lens' TransfersGet' (Maybe Text)
tgFields = lens _tgFields (\ s a -> s{_tgFields = a})
-- | Data format for the response.
tgAlt :: Lens' TransfersGet' Text
tgAlt = lens _tgAlt (\ s a -> s{_tgAlt = a})
instance GoogleRequest TransfersGet' where
type Rs TransfersGet' = DataTransfer
request
= requestWithRoute defReq adminDataTransferURL
requestWithRoute r u TransfersGet{..}
= go _tgQuotaUser _tgPrettyPrint _tgUserIp _tgKey
_tgOauthToken
_tgDataTransferId
_tgFields
_tgAlt
where go
= clientWithRoute (Proxy :: Proxy TransfersGetAPI) r
u

View File

@ -0,0 +1,141 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.Datatransfer.Transfers.Insert
-- Copyright : (c) 2015 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)
--
-- | Inserts a data transfer request.
--
-- /See:/ <https://developers.google.com/admin-sdk/data-transfer/ Admin Data Transfer API Reference> for @DatatransferTransfersInsert@.
module Datatransfer.Transfers.Insert
(
-- * REST Resource
TransfersInsertAPI
-- * Creating a Request
, transfersInsert
, TransfersInsert
-- * Request Lenses
, tiQuotaUser
, tiPrettyPrint
, tiUserIp
, tiKey
, tiOauthToken
, tiFields
, tiAlt
) where
import Network.Google.AdminDataTransfer.Types
import Network.Google.Prelude
-- | A resource alias for @DatatransferTransfersInsert@ which the
-- 'TransfersInsert' request conforms to.
type TransfersInsertAPI =
"transfers" :> Post '[JSON] DataTransfer
-- | Inserts a data transfer request.
--
-- /See:/ 'transfersInsert' smart constructor.
data TransfersInsert = TransfersInsert
{ _tiQuotaUser :: !(Maybe Text)
, _tiPrettyPrint :: !Bool
, _tiUserIp :: !(Maybe Text)
, _tiKey :: !(Maybe Text)
, _tiOauthToken :: !(Maybe Text)
, _tiFields :: !(Maybe Text)
, _tiAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'TransfersInsert'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'tiQuotaUser'
--
-- * 'tiPrettyPrint'
--
-- * 'tiUserIp'
--
-- * 'tiKey'
--
-- * 'tiOauthToken'
--
-- * 'tiFields'
--
-- * 'tiAlt'
transfersInsert
:: TransfersInsert
transfersInsert =
TransfersInsert
{ _tiQuotaUser = Nothing
, _tiPrettyPrint = True
, _tiUserIp = Nothing
, _tiKey = Nothing
, _tiOauthToken = Nothing
, _tiFields = Nothing
, _tiAlt = "json"
}
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
tiQuotaUser :: Lens' TransfersInsert' (Maybe Text)
tiQuotaUser
= lens _tiQuotaUser (\ s a -> s{_tiQuotaUser = a})
-- | Returns response with indentations and line breaks.
tiPrettyPrint :: Lens' TransfersInsert' Bool
tiPrettyPrint
= lens _tiPrettyPrint
(\ s a -> s{_tiPrettyPrint = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
tiUserIp :: Lens' TransfersInsert' (Maybe Text)
tiUserIp = lens _tiUserIp (\ s a -> s{_tiUserIp = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
tiKey :: Lens' TransfersInsert' (Maybe Text)
tiKey = lens _tiKey (\ s a -> s{_tiKey = a})
-- | OAuth 2.0 token for the current user.
tiOauthToken :: Lens' TransfersInsert' (Maybe Text)
tiOauthToken
= lens _tiOauthToken (\ s a -> s{_tiOauthToken = a})
-- | Selector specifying which fields to include in a partial response.
tiFields :: Lens' TransfersInsert' (Maybe Text)
tiFields = lens _tiFields (\ s a -> s{_tiFields = a})
-- | Data format for the response.
tiAlt :: Lens' TransfersInsert' Text
tiAlt = lens _tiAlt (\ s a -> s{_tiAlt = a})
instance GoogleRequest TransfersInsert' where
type Rs TransfersInsert' = DataTransfer
request
= requestWithRoute defReq adminDataTransferURL
requestWithRoute r u TransfersInsert{..}
= go _tiQuotaUser _tiPrettyPrint _tiUserIp _tiKey
_tiOauthToken
_tiFields
_tiAlt
where go
= clientWithRoute (Proxy :: Proxy TransfersInsertAPI)
r
u

View File

@ -0,0 +1,217 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.Resource.Datatransfer.Transfers.List
-- Copyright : (c) 2015 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)
--
-- | Lists the transfers for a customer by source user, destination user, or
-- status.
--
-- /See:/ <https://developers.google.com/admin-sdk/data-transfer/ Admin Data Transfer API Reference> for @DatatransferTransfersList@.
module Datatransfer.Transfers.List
(
-- * REST Resource
TransfersListAPI
-- * Creating a Request
, transfersList
, TransfersList
-- * Request Lenses
, tlStatus
, tlQuotaUser
, tlPrettyPrint
, tlOldOwnerUserId
, tlUserIp
, tlNewOwnerUserId
, tlCustomerId
, tlKey
, tlPageToken
, tlOauthToken
, tlMaxResults
, tlFields
, tlAlt
) where
import Network.Google.AdminDataTransfer.Types
import Network.Google.Prelude
-- | A resource alias for @DatatransferTransfersList@ which the
-- 'TransfersList' request conforms to.
type TransfersListAPI =
"transfers" :>
QueryParam "status" Text :>
QueryParam "oldOwnerUserId" Text :>
QueryParam "newOwnerUserId" Text :>
QueryParam "customerId" Text :>
QueryParam "pageToken" Text :>
QueryParam "maxResults" Int32 :>
Get '[JSON] DataTransfersListResponse
-- | Lists the transfers for a customer by source user, destination user, or
-- status.
--
-- /See:/ 'transfersList' smart constructor.
data TransfersList = TransfersList
{ _tlStatus :: !(Maybe Text)
, _tlQuotaUser :: !(Maybe Text)
, _tlPrettyPrint :: !Bool
, _tlOldOwnerUserId :: !(Maybe Text)
, _tlUserIp :: !(Maybe Text)
, _tlNewOwnerUserId :: !(Maybe Text)
, _tlCustomerId :: !(Maybe Text)
, _tlKey :: !(Maybe Text)
, _tlPageToken :: !(Maybe Text)
, _tlOauthToken :: !(Maybe Text)
, _tlMaxResults :: !(Maybe Int32)
, _tlFields :: !(Maybe Text)
, _tlAlt :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
-- | Creates a value of 'TransfersList'' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'tlStatus'
--
-- * 'tlQuotaUser'
--
-- * 'tlPrettyPrint'
--
-- * 'tlOldOwnerUserId'
--
-- * 'tlUserIp'
--
-- * 'tlNewOwnerUserId'
--
-- * 'tlCustomerId'
--
-- * 'tlKey'
--
-- * 'tlPageToken'
--
-- * 'tlOauthToken'
--
-- * 'tlMaxResults'
--
-- * 'tlFields'
--
-- * 'tlAlt'
transfersList
:: TransfersList
transfersList =
TransfersList
{ _tlStatus = Nothing
, _tlQuotaUser = Nothing
, _tlPrettyPrint = True
, _tlOldOwnerUserId = Nothing
, _tlUserIp = Nothing
, _tlNewOwnerUserId = Nothing
, _tlCustomerId = Nothing
, _tlKey = Nothing
, _tlPageToken = Nothing
, _tlOauthToken = Nothing
, _tlMaxResults = Nothing
, _tlFields = Nothing
, _tlAlt = "json"
}
-- | Status of the transfer.
tlStatus :: Lens' TransfersList' (Maybe Text)
tlStatus = lens _tlStatus (\ s a -> s{_tlStatus = a})
-- | Available to use for quota purposes for server-side applications. Can be
-- any arbitrary string assigned to a user, but should not exceed 40
-- characters. Overrides userIp if both are provided.
tlQuotaUser :: Lens' TransfersList' (Maybe Text)
tlQuotaUser
= lens _tlQuotaUser (\ s a -> s{_tlQuotaUser = a})
-- | Returns response with indentations and line breaks.
tlPrettyPrint :: Lens' TransfersList' Bool
tlPrettyPrint
= lens _tlPrettyPrint
(\ s a -> s{_tlPrettyPrint = a})
-- | Source user\'s profile ID.
tlOldOwnerUserId :: Lens' TransfersList' (Maybe Text)
tlOldOwnerUserId
= lens _tlOldOwnerUserId
(\ s a -> s{_tlOldOwnerUserId = a})
-- | IP address of the site where the request originates. Use this if you
-- want to enforce per-user limits.
tlUserIp :: Lens' TransfersList' (Maybe Text)
tlUserIp = lens _tlUserIp (\ s a -> s{_tlUserIp = a})
-- | Destination user\'s profile ID.
tlNewOwnerUserId :: Lens' TransfersList' (Maybe Text)
tlNewOwnerUserId
= lens _tlNewOwnerUserId
(\ s a -> s{_tlNewOwnerUserId = a})
-- | Immutable ID of the Google Apps account.
tlCustomerId :: Lens' TransfersList' (Maybe Text)
tlCustomerId
= lens _tlCustomerId (\ s a -> s{_tlCustomerId = a})
-- | API key. Your API key identifies your project and provides you with API
-- access, quota, and reports. Required unless you provide an OAuth 2.0
-- token.
tlKey :: Lens' TransfersList' (Maybe Text)
tlKey = lens _tlKey (\ s a -> s{_tlKey = a})
-- | Token to specify the next page in the list.
tlPageToken :: Lens' TransfersList' (Maybe Text)
tlPageToken
= lens _tlPageToken (\ s a -> s{_tlPageToken = a})
-- | OAuth 2.0 token for the current user.
tlOauthToken :: Lens' TransfersList' (Maybe Text)
tlOauthToken
= lens _tlOauthToken (\ s a -> s{_tlOauthToken = a})
-- | Maximum number of results to return. Default is 100.
tlMaxResults :: Lens' TransfersList' (Maybe Int32)
tlMaxResults
= lens _tlMaxResults (\ s a -> s{_tlMaxResults = a})
-- | Selector specifying which fields to include in a partial response.
tlFields :: Lens' TransfersList' (Maybe Text)
tlFields = lens _tlFields (\ s a -> s{_tlFields = a})
-- | Data format for the response.
tlAlt :: Lens' TransfersList' Text
tlAlt = lens _tlAlt (\ s a -> s{_tlAlt = a})
instance GoogleRequest TransfersList' where
type Rs TransfersList' = DataTransfersListResponse
request
= requestWithRoute defReq adminDataTransferURL
requestWithRoute r u TransfersList{..}
= go _tlStatus _tlQuotaUser _tlPrettyPrint
_tlOldOwnerUserId
_tlUserIp
_tlNewOwnerUserId
_tlCustomerId
_tlKey
_tlPageToken
_tlOauthToken
_tlMaxResults
_tlFields
_tlAlt
where go
= clientWithRoute (Proxy :: Proxy TransfersListAPI) r
u

View File

@ -0,0 +1,48 @@
name: gogol-admin-datatransfer
version: 0.0.1
synopsis: Admin Data Transfer API Client.
homepage: https://github.com/brendanhay/gogol
bug-reports: https://github.com/brendanhay/gogol/issues
license: OtherLicense
license-file: LICENSE
author: Brendan Hay
maintainer: Brendan Hay <brendan.g.hay@gmail.com>
copyright: Copyright (c) 2015 Brendan Hay
category: Network, Google, Cloud
build-type: Simple
cabal-version: >= 1.10
extra-source-files: README.md
description:
Admin Data Transfer API lets you transfer user data from one user to
another.
.
/Warning:/ This is an experimental prototype/preview release which is still
under exploratory development and not intended for public use, caveat emptor!
source-repository head
type: git
location: git://github.com/brendanhay/gogol.git
library
default-language: Haskell2010
hs-source-dirs: src gen
ghc-options: -Wall
exposed-modules:
Network.Google.AdminDataTransfer
, Network.Google.AdminDataTransfer.Types
, Network.Google.Resource.Datatransfer.Applications.Get
, Network.Google.Resource.Datatransfer.Applications.List
, Network.Google.Resource.Datatransfer.Transfers.Get
, Network.Google.Resource.Datatransfer.Transfers.Insert
, Network.Google.Resource.Datatransfer.Transfers.List
other-modules:
Network.Google.AdminDataTransfer.Types.Product
, Network.Google.AdminDataTransfer.Types.Sum
build-depends:
gogol-core == 0.0.1.*
, base >= 4.7 && < 5

View File

View File

@ -0,0 +1,373 @@
Mozilla Public License Version 2.0
==================================
1. Definitions
--------------
1.1. "Contributor"
means each individual or legal entity that creates, contributes to
the creation of, or owns Covered Software.
1.2. "Contributor Version"
means the combination of the Contributions of others (if any) used
by a Contributor and that particular Contributor's Contribution.
1.3. "Contribution"
means Covered Software of a particular Contributor.
1.4. "Covered Software"
means Source Code Form to which the initial Contributor has attached
the notice in Exhibit A, the Executable Form of such Source Code
Form, and Modifications of such Source Code Form, in each case
including portions thereof.
1.5. "Incompatible With Secondary Licenses"
means
(a) that the initial Contributor has attached the notice described
in Exhibit B to the Covered Software; or
(b) that the Covered Software was made available under the terms of
version 1.1 or earlier of the License, but not also under the
terms of a Secondary License.
1.6. "Executable Form"
means any form of the work other than Source Code Form.
1.7. "Larger Work"
means a work that combines Covered Software with other material, in
a separate file or files, that is not Covered Software.
1.8. "License"
means this document.
1.9. "Licensable"
means having the right to grant, to the maximum extent possible,
whether at the time of the initial grant or subsequently, any and
all of the rights conveyed by this License.
1.10. "Modifications"
means any of the following:
(a) any file in Source Code Form that results from an addition to,
deletion from, or modification of the contents of Covered
Software; or
(b) any new file in Source Code Form that contains any Covered
Software.
1.11. "Patent Claims" of a Contributor
means any patent claim(s), including without limitation, method,
process, and apparatus claims, in any patent Licensable by such
Contributor that would be infringed, but for the grant of the
License, by the making, using, selling, offering for sale, having
made, import, or transfer of either its Contributions or its
Contributor Version.
1.12. "Secondary License"
means either the GNU General Public License, Version 2.0, the GNU
Lesser General Public License, Version 2.1, the GNU Affero General
Public License, Version 3.0, or any later versions of those
licenses.
1.13. "Source Code Form"
means the form of the work preferred for making modifications.
1.14. "You" (or "Your")
means an individual or a legal entity exercising rights under this
License. For legal entities, "You" includes any entity that
controls, is controlled by, or is under common control with You. For
purposes of this definition, "control" means (a) the power, direct
or indirect, to cause the direction or management of such entity,
whether by contract or otherwise, or (b) ownership of more than
fifty percent (50%) of the outstanding shares or beneficial
ownership of such entity.
2. License Grants and Conditions
--------------------------------
2.1. Grants
Each Contributor hereby grants You a world-wide, royalty-free,
non-exclusive license:
(a) under intellectual property rights (other than patent or trademark)
Licensable by such Contributor to use, reproduce, make available,
modify, display, perform, distribute, and otherwise exploit its
Contributions, either on an unmodified basis, with Modifications, or
as part of a Larger Work; and
(b) under Patent Claims of such Contributor to make, use, sell, offer
for sale, have made, import, and otherwise transfer either its
Contributions or its Contributor Version.
2.2. Effective Date
The licenses granted in Section 2.1 with respect to any Contribution
become effective for each Contribution on the date the Contributor first
distributes such Contribution.
2.3. Limitations on Grant Scope
The licenses granted in this Section 2 are the only rights granted under
this License. No additional rights or licenses will be implied from the
distribution or licensing of Covered Software under this License.
Notwithstanding Section 2.1(b) above, no patent license is granted by a
Contributor:
(a) for any code that a Contributor has removed from Covered Software;
or
(b) for infringements caused by: (i) Your and any other third party's
modifications of Covered Software, or (ii) the combination of its
Contributions with other software (except as part of its Contributor
Version); or
(c) under Patent Claims infringed by Covered Software in the absence of
its Contributions.
This License does not grant any rights in the trademarks, service marks,
or logos of any Contributor (except as may be necessary to comply with
the notice requirements in Section 3.4).
2.4. Subsequent Licenses
No Contributor makes additional grants as a result of Your choice to
distribute the Covered Software under a subsequent version of this
License (see Section 10.2) or under the terms of a Secondary License (if
permitted under the terms of Section 3.3).
2.5. Representation
Each Contributor represents that the Contributor believes its
Contributions are its original creation(s) or it has sufficient rights
to grant the rights to its Contributions conveyed by this License.
2.6. Fair Use
This License is not intended to limit any rights You have under
applicable copyright doctrines of fair use, fair dealing, or other
equivalents.
2.7. Conditions
Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted
in Section 2.1.
3. Responsibilities
-------------------
3.1. Distribution of Source Form
All distribution of Covered Software in Source Code Form, including any
Modifications that You create or to which You contribute, must be under
the terms of this License. You must inform recipients that the Source
Code Form of the Covered Software is governed by the terms of this
License, and how they can obtain a copy of this License. You may not
attempt to alter or restrict the recipients' rights in the Source Code
Form.
3.2. Distribution of Executable Form
If You distribute Covered Software in Executable Form then:
(a) such Covered Software must also be made available in Source Code
Form, as described in Section 3.1, and You must inform recipients of
the Executable Form how they can obtain a copy of such Source Code
Form by reasonable means in a timely manner, at a charge no more
than the cost of distribution to the recipient; and
(b) You may distribute such Executable Form under the terms of this
License, or sublicense it under different terms, provided that the
license for the Executable Form does not attempt to limit or alter
the recipients' rights in the Source Code Form under this License.
3.3. Distribution of a Larger Work
You may create and distribute a Larger Work under terms of Your choice,
provided that You also comply with the requirements of this License for
the Covered Software. If the Larger Work is a combination of Covered
Software with a work governed by one or more Secondary Licenses, and the
Covered Software is not Incompatible With Secondary Licenses, this
License permits You to additionally distribute such Covered Software
under the terms of such Secondary License(s), so that the recipient of
the Larger Work may, at their option, further distribute the Covered
Software under the terms of either this License or such Secondary
License(s).
3.4. Notices
You may not remove or alter the substance of any license notices
(including copyright notices, patent notices, disclaimers of warranty,
or limitations of liability) contained within the Source Code Form of
the Covered Software, except that You may alter any license notices to
the extent required to remedy known factual inaccuracies.
3.5. Application of Additional Terms
You may choose to offer, and to charge a fee for, warranty, support,
indemnity or liability obligations to one or more recipients of Covered
Software. However, You may do so only on Your own behalf, and not on
behalf of any Contributor. You must make it absolutely clear that any
such warranty, support, indemnity, or liability obligation is offered by
You alone, and You hereby agree to indemnify every Contributor for any
liability incurred by such Contributor as a result of warranty, support,
indemnity or liability terms You offer. You may include additional
disclaimers of warranty and limitations of liability specific to any
jurisdiction.
4. Inability to Comply Due to Statute or Regulation
---------------------------------------------------
If it is impossible for You to comply with any of the terms of this
License with respect to some or all of the Covered Software due to
statute, judicial order, or regulation then You must: (a) comply with
the terms of this License to the maximum extent possible; and (b)
describe the limitations and the code they affect. Such description must
be placed in a text file included with all distributions of the Covered
Software under this License. Except to the extent prohibited by statute
or regulation, such description must be sufficiently detailed for a
recipient of ordinary skill to be able to understand it.
5. Termination
--------------
5.1. The rights granted under this License will terminate automatically
if You fail to comply with any of its terms. However, if You become
compliant, then the rights granted under this License from a particular
Contributor are reinstated (a) provisionally, unless and until such
Contributor explicitly and finally terminates Your grants, and (b) on an
ongoing basis, if such Contributor fails to notify You of the
non-compliance by some reasonable means prior to 60 days after You have
come back into compliance. Moreover, Your grants from a particular
Contributor are reinstated on an ongoing basis if such Contributor
notifies You of the non-compliance by some reasonable means, this is the
first time You have received notice of non-compliance with this License
from such Contributor, and You become compliant prior to 30 days after
Your receipt of the notice.
5.2. If You initiate litigation against any entity by asserting a patent
infringement claim (excluding declaratory judgment actions,
counter-claims, and cross-claims) alleging that a Contributor Version
directly or indirectly infringes any patent, then the rights granted to
You by any and all Contributors for the Covered Software under Section
2.1 of this License shall terminate.
5.3. In the event of termination under Sections 5.1 or 5.2 above, all
end user license agreements (excluding distributors and resellers) which
have been validly granted by You or Your distributors under this License
prior to termination shall survive termination.
************************************************************************
* *
* 6. Disclaimer of Warranty *
* ------------------------- *
* *
* Covered Software is provided under this License on an "as is" *
* basis, without warranty of any kind, either expressed, implied, or *
* statutory, including, without limitation, warranties that the *
* Covered Software is free of defects, merchantable, fit for a *
* particular purpose or non-infringing. The entire risk as to the *
* quality and performance of the Covered Software is with You. *
* Should any Covered Software prove defective in any respect, You *
* (not any Contributor) assume the cost of any necessary servicing, *
* repair, or correction. This disclaimer of warranty constitutes an *
* essential part of this License. No use of any Covered Software is *
* authorized under this License except under this disclaimer. *
* *
************************************************************************
************************************************************************
* *
* 7. Limitation of Liability *
* -------------------------- *
* *
* Under no circumstances and under no legal theory, whether tort *
* (including negligence), contract, or otherwise, shall any *
* Contributor, or anyone who distributes Covered Software as *
* permitted above, be liable to You for any direct, indirect, *
* special, incidental, or consequential damages of any character *
* including, without limitation, damages for lost profits, loss of *
* goodwill, work stoppage, computer failure or malfunction, or any *
* and all other commercial damages or losses, even if such party *
* shall have been informed of the possibility of such damages. This *
* limitation of liability shall not apply to liability for death or *
* personal injury resulting from such party's negligence to the *
* extent applicable law prohibits such limitation. Some *
* jurisdictions do not allow the exclusion or limitation of *
* incidental or consequential damages, so this exclusion and *
* limitation may not apply to You. *
* *
************************************************************************
8. Litigation
-------------
Any litigation relating to this License may be brought only in the
courts of a jurisdiction where the defendant maintains its principal
place of business and such litigation shall be governed by laws of that
jurisdiction, without reference to its conflict-of-law provisions.
Nothing in this Section shall prevent a party's ability to bring
cross-claims or counter-claims.
9. Miscellaneous
----------------
This License represents the complete agreement concerning the subject
matter hereof. If any provision of this License is held to be
unenforceable, such provision shall be reformed only to the extent
necessary to make it enforceable. Any law or regulation which provides
that the language of a contract shall be construed against the drafter
shall not be used to construe this License against a Contributor.
10. Versions of the License
---------------------------
10.1. New Versions
Mozilla Foundation is the license steward. Except as provided in Section
10.3, no one other than the license steward has the right to modify or
publish new versions of this License. Each version will be given a
distinguishing version number.
10.2. Effect of New Versions
You may distribute the Covered Software under the terms of the version
of the License under which You originally received the Covered Software,
or under the terms of any subsequent version published by the license
steward.
10.3. Modified Versions
If you create software not governed by this License, and you want to
create a new license for such software, you may create and use a
modified version of this License if you rename the license and remove
any references to the name of the license steward (except to note that
such modified license differs from this License).
10.4. Distributing Source Code Form that is Incompatible With Secondary
Licenses
If You choose to distribute Source Code Form that is Incompatible With
Secondary Licenses under the terms of this version of the License, the
notice described in Exhibit B of this License must be attached.
Exhibit A - Source Code Form License Notice
-------------------------------------------
This Source Code Form is subject to the terms of the Mozilla Public
License, v. 2.0. If a copy of the MPL was not distributed with this
file, You can obtain one at http://mozilla.org/MPL/2.0/.
If it is not possible or desirable to put the notice in a particular
file, then You may include the notice in a location (such as a LICENSE
file in a relevant directory) where a recipient would be likely to look
for such a notice.
You may add additional accurate notices of copyright ownership.
Exhibit B - "Incompatible With Secondary Licenses" Notice
---------------------------------------------------------
This Source Code Form is "Incompatible With Secondary Licenses", as
defined by the Mozilla Public License, v. 2.0.

View File

@ -0,0 +1 @@
include ../share/library.mk

View File

@ -0,0 +1,28 @@
# gogol-admin-directory
* [Version](#version)
* [Description](#description)
* [Contribute](#contribute)
* [Licence](#licence)
## Version
`0.0.1`
## Description
A client library for the Admin Directory API.
## Contribute
For any problems, comments, or feedback please create an issue [here on GitHub](https://github.com/brendanhay/amazonka/issues).
> _Note:_ this library is an auto-generated Haskell package. Please see `amazonka-gen` for more information.
## Licence
`gogol-admin-directory` is released under the [Mozilla Public License Version 2.0](http://www.mozilla.org/MPL/).

View File

@ -0,0 +1,2 @@
import Distribution.Simple
main = defaultMain

View File

@ -0,0 +1,765 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
-- |
-- Module : Network.Google.AdminDirectory
-- Copyright : (c) 2015 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)
--
-- -- | The Admin SDK Directory API lets you view and manage enterprise
-- resources such as users and groups, administrative notifications,
-- security features, and more.
--
-- /See:/ <https://developers.google.com/admin-sdk/directory/ Admin Directory API Reference>
module Network.Google.AdminDirectory
(
-- * API
AdminDirectoryAPI
, adminDirectoryAPI
, adminDirectoryURL
-- * Service Methods
-- * REST Resources
-- ** AdminChannelsStop
, module Admin.Channels.Stop
-- ** DirectoryAspsDelete
, module Directory.Asps.Delete
-- ** DirectoryAspsGet
, module Directory.Asps.Get
-- ** DirectoryAspsList
, module Directory.Asps.List
-- ** DirectoryChromeosdevicesGet
, module Directory.Chromeosdevices.Get
-- ** DirectoryChromeosdevicesList
, module Directory.Chromeosdevices.List
-- ** DirectoryChromeosdevicesPatch
, module Directory.Chromeosdevices.Patch
-- ** DirectoryChromeosdevicesUpdate
, module Directory.Chromeosdevices.Update
-- ** DirectoryGroupsAliasesDelete
, module Directory.Groups.Aliases.Delete
-- ** DirectoryGroupsAliasesInsert
, module Directory.Groups.Aliases.Insert
-- ** DirectoryGroupsAliasesList
, module Directory.Groups.Aliases.List
-- ** DirectoryGroupsDelete
, module Directory.Groups.Delete
-- ** DirectoryGroupsGet
, module Directory.Groups.Get
-- ** DirectoryGroupsInsert
, module Directory.Groups.Insert
-- ** DirectoryGroupsList
, module Directory.Groups.List
-- ** DirectoryGroupsPatch
, module Directory.Groups.Patch
-- ** DirectoryGroupsUpdate
, module Directory.Groups.Update
-- ** DirectoryMembersDelete
, module Directory.Members.Delete
-- ** DirectoryMembersGet
, module Directory.Members.Get
-- ** DirectoryMembersInsert
, module Directory.Members.Insert
-- ** DirectoryMembersList
, module Directory.Members.List
-- ** DirectoryMembersPatch
, module Directory.Members.Patch
-- ** DirectoryMembersUpdate
, module Directory.Members.Update
-- ** DirectoryMobiledevicesAction
, module Directory.Mobiledevices.Action
-- ** DirectoryMobiledevicesDelete
, module Directory.Mobiledevices.Delete
-- ** DirectoryMobiledevicesGet
, module Directory.Mobiledevices.Get
-- ** DirectoryMobiledevicesList
, module Directory.Mobiledevices.List
-- ** DirectoryNotificationsDelete
, module Directory.Notifications.Delete
-- ** DirectoryNotificationsGet
, module Directory.Notifications.Get
-- ** DirectoryNotificationsList
, module Directory.Notifications.List
-- ** DirectoryNotificationsPatch
, module Directory.Notifications.Patch
-- ** DirectoryNotificationsUpdate
, module Directory.Notifications.Update
-- ** DirectoryOrgunitsDelete
, module Directory.Orgunits.Delete
-- ** DirectoryOrgunitsGet
, module Directory.Orgunits.Get
-- ** DirectoryOrgunitsInsert
, module Directory.Orgunits.Insert
-- ** DirectoryOrgunitsList
, module Directory.Orgunits.List
-- ** DirectoryOrgunitsPatch
, module Directory.Orgunits.Patch
-- ** DirectoryOrgunitsUpdate
, module Directory.Orgunits.Update
-- ** DirectorySchemasDelete
, module Directory.Schemas.Delete
-- ** DirectorySchemasGet
, module Directory.Schemas.Get
-- ** DirectorySchemasInsert
, module Directory.Schemas.Insert
-- ** DirectorySchemasList
, module Directory.Schemas.List
-- ** DirectorySchemasPatch
, module Directory.Schemas.Patch
-- ** DirectorySchemasUpdate
, module Directory.Schemas.Update
-- ** DirectoryTokensDelete
, module Directory.Tokens.Delete
-- ** DirectoryTokensGet
, module Directory.Tokens.Get
-- ** DirectoryTokensList
, module Directory.Tokens.List
-- ** DirectoryUsersAliasesDelete
, module Directory.Users.Aliases.Delete
-- ** DirectoryUsersAliasesInsert
, module Directory.Users.Aliases.Insert
-- ** DirectoryUsersAliasesList
, module Directory.Users.Aliases.List
-- ** DirectoryUsersAliasesWatch
, module Directory.Users.Aliases.Watch
-- ** DirectoryUsersDelete
, module Directory.Users.Delete
-- ** DirectoryUsersGet
, module Directory.Users.Get
-- ** DirectoryUsersInsert
, module Directory.Users.Insert
-- ** DirectoryUsersList
, module Directory.Users.List
-- ** DirectoryUsersMakeAdmin
, module Directory.Users.MakeAdmin
-- ** DirectoryUsersPatch
, module Directory.Users.Patch
-- ** DirectoryUsersPhotosDelete
, module Directory.Users.Photos.Delete
-- ** DirectoryUsersPhotosGet
, module Directory.Users.Photos.Get
-- ** DirectoryUsersPhotosPatch
, module Directory.Users.Photos.Patch
-- ** DirectoryUsersPhotosUpdate
, module Directory.Users.Photos.Update
-- ** DirectoryUsersUndelete
, module Directory.Users.Undelete
-- ** DirectoryUsersUpdate
, module Directory.Users.Update
-- ** DirectoryUsersWatch
, module Directory.Users.Watch
-- ** DirectoryVerificationCodesGenerate
, module Directory.VerificationCodes.Generate
-- ** DirectoryVerificationCodesInvalidate
, module Directory.VerificationCodes.Invalidate
-- ** DirectoryVerificationCodesList
, module Directory.VerificationCodes.List
-- * Types
-- ** UserAbout
, UserAbout
, userAbout
, uaValue
, uaContentType
-- ** VerificationCode
, VerificationCode
, verificationCode
, vcVerificationCode
, vcEtag
, vcKind
, vcUserId
-- ** OrgUnit
, OrgUnit
, orgUnit
, ouEtag
, ouParentOrgUnitPath
, ouKind
, ouOrgUnitPath
, ouName
, ouBlockInheritance
, ouParentOrgUnitId
, ouDescription
, ouOrgUnitId
-- ** Groups
, Groups
, groups
, gGroups
, gEtag
, gNextPageToken
, gKind
-- ** UserMakeAdmin
, UserMakeAdmin
, userMakeAdmin
, umaStatus
-- ** UserAddress
, UserAddress
, userAddress
, uaStreetAddress
, uaPoBox
, uaCountry
, uaPostalCode
, uaFormatted
, uaExtendedAddress
, uaLocality
, uaPrimary
, uaCountryCode
, uaRegion
, uaType
, uaCustomType
, uaSourceIsStructured
-- ** Group
, Group
, group'
, groEmail
, groEtag
, groDirectMembersCount
, groKind
, groAliases
, groNonEditableAliases
, groName
, groAdminCreated
, groId
, groDescription
-- ** Asp
, Asp
, asp
, aspCreationTime
, aspEtag
, aspCodeId
, aspKind
, aspName
, aspLastTimeUsed
, aspUserKey
-- ** Schemas
, Schemas
, schemas
, sEtag
, sSchemas
, sKind
-- ** ChromeOsDevice
, ChromeOsDevice
, chromeOsDevice
, codStatus
, codEtag
, codAnnotatedUser
, codPlatformVersion
, codLastSync
, codActiveTimeRanges
, codKind
, codEthernetMacAddress
, codLastEnrollmentTime
, codAnnotatedLocation
, codMacAddress
, codOrgUnitPath
, codRecentUsers
, codSupportEndDate
, codModel
, codWillAutoRenew
, codMeid
, codDeviceId
, codBootMode
, codOrderNumber
, codAnnotatedAssetId
, codNotes
, codSerialNumber
, codFirmwareVersion
, codOsVersion
-- ** Users
, Users
, users
, uEtag
, uNextPageToken
, uUsers
, uKind
, uTriggerEvent
-- ** UserIm
, UserIm
, userIm
, uiIm
, uiProtocol
, uiPrimary
, uiCustomProtocol
, uiType
, uiCustomType
-- ** Notification
, Notification
, notification
, nSubject
, nEtag
, nKind
, nBody
, nFromAddress
, nIsUnread
, nNotificationId
, nSendTime
-- ** Aliases
, Aliases
, aliases
, aEtag
, aKind
, aAliases
-- ** Tokens
, Tokens
, tokens
, tEtag
, tKind
, tItems
-- ** Token
, Token
, token
, tokClientId
, tokEtag
, tokDisplayText
, tokKind
, tokScopes
, tokNativeApp
, tokAnonymous
, tokUserKey
-- ** UserUndelete
, UserUndelete
, userUndelete
, uuOrgUnitPath
-- ** MobileDevices
, MobileDevices
, mobileDevices
, mdEtag
, mdNextPageToken
, mdKind
, mdMobiledevices
-- ** Members
, Members
, members
, mEtag
, mNextPageToken
, mKind
, mMembers
-- ** Channel
, Channel
, channel
, cResourceUri
, cResourceId
, cKind
, cExpiration
, cToken
, cAddress
, cPayload
, cParams
, cId
, cType
-- ** Alias
, Alias
, alias
, aliEtag
, aliKind
, aliAlias
, aliId
, aliPrimaryEmail
-- ** UserName
, UserName
, userName
, unGivenName
, unFullName
, unFamilyName
-- ** User
, User
, user
, useCreationTime
, useLastLoginTime
, useThumbnailPhotoEtag
, useEtag
, useIpWhitelisted
, useRelations
, useHashFunction
, useKind
, useChangePasswordAtNextLogin
, useWebsites
, useAddresses
, useAliases
, useThumbnailPhotoUrl
, useExternalIds
, useSuspended
, useAgreedToTerms
, useDeletionTime
, useNonEditableAliases
, useOrgUnitPath
, useCustomerId
, useIncludeInGlobalAddressList
, usePhones
, useName
, usePassword
, useEmails
, useIms
, useIsAdmin
, useId
, useOrganizations
, usePrimaryEmail
, useNotes
, useIsDelegatedAdmin
, useIsMailboxSetup
, useCustomSchemas
, useSuspensionReason
-- ** Schema
, Schema
, schema
, schEtag
, schKind
, schSchemaName
, schSchemaId
, schFields
-- ** OrgUnits
, OrgUnits
, orgUnits
, oEtag
, oKind
, oOrganizationUnits
-- ** VerificationCodes
, VerificationCodes
, verificationCodes
, vEtag
, vKind
, vItems
-- ** UserRelation
, UserRelation
, userRelation
, urValue
, urType
, urCustomType
-- ** UserWebsite
, UserWebsite
, userWebsite
, uwValue
, uwPrimary
, uwType
, uwCustomType
-- ** UserOrganization
, UserOrganization
, userOrganization
, uoDepartment
, uoLocation
, uoCostCenter
, uoDomain
, uoSymbol
, uoPrimary
, uoName
, uoTitle
, uoType
, uoCustomType
, uoDescription
-- ** UserPhone
, UserPhone
, userPhone
, upValue
, upPrimary
, upType
, upCustomType
-- ** UserPhoto
, UserPhoto
, userPhoto
, upPhotoData
, upEtag
, upHeight
, upKind
, upWidth
, upMimeType
, upId
, upPrimaryEmail
-- ** UserEmail
, UserEmail
, userEmail
, ueAddress
, uePrimary
, ueType
, ueCustomType
-- ** Member
, Member
, member
, memEmail
, memEtag
, memKind
, memRole
, memId
, memType
-- ** MobileDevice
, MobileDevice
, mobileDevice
, mobEmail
, mobStatus
, mobEtag
, mobResourceId
, mobBuildNumber
, mobManagedAccountIsOnOwnerProfile
, mobLastSync
, mobOtherAccountsInfo
, mobKind
, mobAdbStatus
, mobNetworkOperator
, mobKernelVersion
, mobOs
, mobName
, mobModel
, mobDeveloperOptionsStatus
, mobUnknownSourcesStatus
, mobMeid
, mobDeviceId
, mobFirstSync
, mobUserAgent
, mobImei
, mobType
, mobWifiMacAddress
, mobSerialNumber
, mobHardwareId
, mobBasebandVersion
, mobSupportsWorkProfile
, mobDeviceCompromisedStatus
, mobApplications
, mobDefaultLanguage
-- ** UserCustomProperties
, UserCustomProperties
, userCustomProperties
-- ** MobileDeviceAction
, MobileDeviceAction
, mobileDeviceAction
, mdaAction
-- ** SchemaFieldSpec
, SchemaFieldSpec
, schemaFieldSpec
, sfsEtag
, sfsKind
, sfsNumericIndexingSpec
, sfsReadAccessType
, sfsFieldId
, sfsIndexed
, sfsFieldType
, sfsFieldName
, sfsMultiValued
-- ** Notifications
, Notifications
, notifications
, notEtag
, notNextPageToken
, notKind
, notItems
, notUnreadNotificationsCount
-- ** UserExternalId
, UserExternalId
, userExternalId
, ueiValue
, ueiType
, ueiCustomType
-- ** Asps
, Asps
, asps
, aaEtag
, aaKind
, aaItems
-- ** ChromeOsDevices
, ChromeOsDevices
, chromeOsDevices
, codsEtag
, codsNextPageToken
, codsKind
, codsChromeosdevices
) where
import Network.Google.AdminDirectory.Types
import Network.Google.Prelude
import Network.Google.Resource.Admin.Channels.Stop
import Network.Google.Resource.Directory.Asps.Delete
import Network.Google.Resource.Directory.Asps.Get
import Network.Google.Resource.Directory.Asps.List
import Network.Google.Resource.Directory.Chromeosdevices.Get
import Network.Google.Resource.Directory.Chromeosdevices.List
import Network.Google.Resource.Directory.Chromeosdevices.Patch
import Network.Google.Resource.Directory.Chromeosdevices.Update
import Network.Google.Resource.Directory.Groups.Aliases.Delete
import Network.Google.Resource.Directory.Groups.Aliases.Insert
import Network.Google.Resource.Directory.Groups.Aliases.List
import Network.Google.Resource.Directory.Groups.Delete
import Network.Google.Resource.Directory.Groups.Get
import Network.Google.Resource.Directory.Groups.Insert
import Network.Google.Resource.Directory.Groups.List
import Network.Google.Resource.Directory.Groups.Patch
import Network.Google.Resource.Directory.Groups.Update
import Network.Google.Resource.Directory.Members.Delete
import Network.Google.Resource.Directory.Members.Get
import Network.Google.Resource.Directory.Members.Insert
import Network.Google.Resource.Directory.Members.List
import Network.Google.Resource.Directory.Members.Patch
import Network.Google.Resource.Directory.Members.Update
import Network.Google.Resource.Directory.Mobiledevices.Action
import Network.Google.Resource.Directory.Mobiledevices.Delete
import Network.Google.Resource.Directory.Mobiledevices.Get
import Network.Google.Resource.Directory.Mobiledevices.List
import Network.Google.Resource.Directory.Notifications.Delete
import Network.Google.Resource.Directory.Notifications.Get
import Network.Google.Resource.Directory.Notifications.List
import Network.Google.Resource.Directory.Notifications.Patch
import Network.Google.Resource.Directory.Notifications.Update
import Network.Google.Resource.Directory.Orgunits.Delete
import Network.Google.Resource.Directory.Orgunits.Get
import Network.Google.Resource.Directory.Orgunits.Insert
import Network.Google.Resource.Directory.Orgunits.List
import Network.Google.Resource.Directory.Orgunits.Patch
import Network.Google.Resource.Directory.Orgunits.Update
import Network.Google.Resource.Directory.Schemas.Delete
import Network.Google.Resource.Directory.Schemas.Get
import Network.Google.Resource.Directory.Schemas.Insert
import Network.Google.Resource.Directory.Schemas.List
import Network.Google.Resource.Directory.Schemas.Patch
import Network.Google.Resource.Directory.Schemas.Update
import Network.Google.Resource.Directory.Tokens.Delete
import Network.Google.Resource.Directory.Tokens.Get
import Network.Google.Resource.Directory.Tokens.List
import Network.Google.Resource.Directory.Users.Aliases.Delete
import Network.Google.Resource.Directory.Users.Aliases.Insert
import Network.Google.Resource.Directory.Users.Aliases.List
import Network.Google.Resource.Directory.Users.Aliases.Watch
import Network.Google.Resource.Directory.Users.Delete
import Network.Google.Resource.Directory.Users.Get
import Network.Google.Resource.Directory.Users.Insert
import Network.Google.Resource.Directory.Users.List
import Network.Google.Resource.Directory.Users.MakeAdmin
import Network.Google.Resource.Directory.Users.Patch
import Network.Google.Resource.Directory.Users.Photos.Delete
import Network.Google.Resource.Directory.Users.Photos.Get
import Network.Google.Resource.Directory.Users.Photos.Patch
import Network.Google.Resource.Directory.Users.Photos.Update
import Network.Google.Resource.Directory.Users.Undelete
import Network.Google.Resource.Directory.Users.Update
import Network.Google.Resource.Directory.Users.Watch
import Network.Google.Resource.Directory.VerificationCodes.Generate
import Network.Google.Resource.Directory.VerificationCodes.Invalidate
import Network.Google.Resource.Directory.VerificationCodes.List
{- $resources
TODO
-}
type AdminDirectoryAPI =
Groups :<|> Users :<|> Schemas :<|> Tokens :<|>
Channels
:<|> Members
:<|> Mobiledevices
:<|> Orgunits
:<|> VerificationCodes
:<|> Notifications
:<|> Chromeosdevices
:<|> Asps
adminDirectoryAPI :: Proxy AdminDirectoryAPI
adminDirectoryAPI = Proxy

Some files were not shown because too many files have changed in this diff Show More