halipso / php-steam-tradeoffers

Steam Trade Offers for PHP (based on node.js library by Alex7Kom)
76 stars 31 forks source link

Not working, Error making offer! Server response code: 401 #38

Open prepix opened 7 years ago

prepix commented 7 years ago

Is this script still working? got my login right and stuff but it won't send trade offers. My script:

<?php
opcache_reset();
define('php-steamlogin', true);
require('main.php');
include_once("../api/AuthFunctions.php");
require_once('../classes/steam.class.php');

$SteamLogin = new SteamLogin(array(
    'username' => 'USER',
    'password' => 'PASS',
    'datapath' => dirname(__FILE__) //path to saving cache files
));

if($SteamLogin->success){
    $SteamAuth = new SteamAuth;
    $authcode = $SteamAuth->GenerateSteamGuardCode("s1xxxxxxwgqBe2AY=");
    $logindata = $SteamLogin->login('', $authcode);
    $login = array_values($logindata);
    $steamId = $login[0];
    $sessionId = $login[1]; // session id
    $cookies = $login[2]; // cookies
    $steam = new SteamTrade();
    $steam->setup($sessionId, $cookies);
    echo json_encode($logindata);
    $itemsID = [ [
    "appid" => 730,
    "contextid" => "2",
    "amount" => 1,
    "assetid" => "xxxx"
    ]];
    $result = $steam->makeOffer([
        'partnerSteamId' => "xxxx",
        'itemsFromMe' => [],
        'itemsFromThem' => $itemsID,
        'message' => "Nice trade for you"
        ]);

    if($SteamLogin->error != '') echo $SteamLogin->error;
}else{
    echo $SteamLogin->error;
}
?>
emdy commented 7 years ago

Lib makeOffer dont work!

prepix commented 7 years ago

Ah oke thanks

emdy commented 7 years ago

@prepix what you really try to do? Its for fun or you have a goal like shop or..? I can teach you how..

prepix commented 7 years ago

Not for fun, I'm building a CSGO case opening website and I need a bot so people can deposit and withdraw items

emdy commented 7 years ago

@prepix I can easy help you for just simbolic price if your interested?!

prepix commented 7 years ago

What do you see as a simbolic price? can you add me on skype? prepixnl@gmail.com

emdy commented 7 years ago

@prepix i will add you.

emdy commented 7 years ago

@prepix if you still interested get tradeing bot script and stop beeng a cunt than add me on skype mareksmix1

emdy commented 7 years ago

@prepix if you still interested get tradeing bot script and stop beeng a cunt than add me on skype mareksdmix1