UNPKG

ebay-api

Version:

eBay API for Node and Browser

37 lines (36 loc) 1.29 kB
"use strict"; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; Object.defineProperty(exports, "__esModule", { value: true }); const index_js_1 = __importDefault(require("../../index.js")); /** * The Api Offer API enables Partners to place proxy bids for a buyer and retrieve the auctions where the buyer is * bidding. Client Credentials: https://api.ebay.com/oauth/api_scope/buy.offer.auction */ class Offer extends index_js_1.default { get basePath() { return '/buy/offer/v1_beta'; } /** * This method retrieves the bidding details that are specific to the buyer of the specified auction. * * @param itemId */ getBidding(itemId) { const id = encodeURIComponent(itemId); return this.get(`/bidding/${id}`); } /** * This method uses a user access token to place a proxy bid for the buyer on a specific auction item. * * @param itemId * @param {PlaceProxyBidRequest} body */ placeProxyBid(itemId, body) { const id = encodeURIComponent(itemId); return this.post(`/bidding/${id}/place_proxy_bid`, body); } } exports.default = Offer; Offer.id = 'Offer';