kast0l Posted March 21 Report Posted March 21 The trade is successfully sent and confirmed, but then problems arise and I don’t understand why, if the cookies are set correctly async function SteamTrade(client, account, cookies) { const community = new SteamCommunity(); community.setCookies(cookies); const manager = new TradeOfferManager({ steam: client, community: community, language: 'en', }); await confirmTradeOffer(status, community, account.identity_secret); manager.getOffer(offer.id, (err, offerDetails) => { if (err) { console.error(`${offer.id}: ${err}`); reject(err); } else { console.log(`${offer.id} `); const itemsToGive = offerDetails.itemsToGive; console.log( itemsToGive); resolve({offerDetails, itemsToGive}); } }); the error occurs after this block of code Quote
Dr. McKay Posted March 23 Report Posted March 23 You need to call setCookies on the TradeOfferManager instance, not on the SteamCommunity instance. TradeOfferManager's setCookies also retrieves your account's API key. kast0l 1 Quote
kast0l Posted March 23 Author Report Posted March 23 (edited) Thanks for the answer, one more question, without an api key it’s not possible to use the getOffer method to view information about sent items in a trade? And if not, is it possible to find out information about a trade without an API key? Edited March 23 by kast0l Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.