Skip to content

place_bid() method of the ShopGoodwillItem class does not include required authentication #3

@allardbrain

Description

@allardbrain

The place_bid() method of the ShopGoodwillItem class does not include a way to provide authentication credentials; thus, the method fails and returns False. I'm happy to work on a fix for this, but would need some direction on the particulars. Thanks!

def place_bid(itemid: int, sellerid: int, bid_amount: float, quantity: int = 1) -> bool:
api_url = 'https://buyerapi.shopgoodwill.com/api/ItemBid/PlaceBid'
json_request = {
"itemId":itemid,
"quantity":quantity,
"sellerId":sellerid,
"bidAmount":str(bid_amount)
}
post_response = ShopGoodwillPost.post(api_url, json_request, cookies=None)
# True if status_code < 400, else False
return post_response.ok

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions