From the Super Mario Wiki
The Barter Box is a special item only found in Mario Party 3. It cannot be bought in an item shop or won in an item game. However, players can get it by buying an Item Bag at an item shop or meeting Toad on an Item Space.
When used, the Barter Box exchanges all of the player's items with the items of another player. The Plunder Chest works in a similar way; however, the Plunder Chest only steals one item. The Barter Box's ability is more similar to the much more common Swap Card of Mario Party 4; however, the Swap Card's target is chosen by roulette.