C_AuctionHouse.QueryOwnedAuctions

From Warcraft Wiki
Jump to navigation Jump to search

Queries the auction house for the player's active auctions.

C_AuctionHouse.QueryOwnedAuctions(sorts)

Arguments

sorts
AuctionHouseSortType[]
Field Type Description
sortOrder Enum.AuctionHouseSortOrder?
reverseSort boolean?
Enum.AuctionHouseSortOrder
Value Field Description
0 Price
1 Name
2 Level
3 Bid
4 Buyout
5 TimeRemaining Only works for Owned auctions. Added in 9.0.1

Example

Queries owned auctions, sorted by time remaining.

local btn = CreateFrame("Button", nil, UIParent, "UIPanelButtonTemplate")
btn:SetPoint("CENTER")
btn:SetSize(120, 40)
btn:SetText("Example")
btn:SetScript("OnClick", function(self, button)
	local sorts = {
		{sortOrder = Enum.AuctionHouseSortOrder.TimeRemaining, reverseSort = false},
	}
	C_AuctionHouse.QueryOwnedAuctions(sorts)
end)

Patch changes

Battle for Azeroth Patch 8.3.0 (2020-01-14): Added.